:root {
  --bg: #0f1021;
  --bg-alt: #16182e;
  --surface: rgba(30, 33, 58, 0.55);
  --surface-solid: #1c1f38;
  --border: rgba(255, 255, 255, 0.09);
  --text: #eef0ff;
  --text-muted: #a6accc;
  --accent: #ff4d8d;
  --accent-2: #7b5cff;
  --accent-3: #22d3ee;
  --gradient: linear-gradient(135deg, #ff4d8d 0%, #7b5cff 55%, #22d3ee 100%);
  --gradient-soft: linear-gradient(135deg, rgba(255, 77, 141, 0.16), rgba(123, 92, 255, 0.16), rgba(34, 211, 238, 0.12));
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --shadow-hover: 0 24px 60px rgba(123, 92, 255, 0.28);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --blur: blur(16px);
  --maxw: 1180px;
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f4f5fb;
    --bg-alt: #eceef8;
    --surface: rgba(255, 255, 255, 0.62);
    --surface-solid: #ffffff;
    --border: rgba(20, 24, 60, 0.1);
    --text: #16182e;
    --text-muted: #565d84;
    --shadow: 0 18px 40px rgba(30, 34, 80, 0.12);
    --shadow-hover: 0 24px 60px rgba(123, 92, 255, 0.22);
    --gradient-soft: linear-gradient(135deg, rgba(255, 77, 141, 0.1), rgba(123, 92, 255, 0.1), rgba(34, 211, 238, 0.08));
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(900px 500px at 12% -8%, rgba(255, 77, 141, 0.18), transparent 60%),
    radial-gradient(800px 480px at 92% 4%, rgba(123, 92, 255, 0.2), transparent 62%),
    radial-gradient(700px 420px at 50% 100%, rgba(34, 211, 238, 0.12), transparent 65%);
  background-attachment: fixed;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent-2);
  text-decoration: none;
  transition: color 0.25s ease, opacity 0.25s ease;
  word-break: break-word;
}

a:hover,
a:focus-visible {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

p {
  margin: 0 0 1em;
}

ul,
ol {
  margin: 0 0 1.2em;
  padding-left: 1.4em;
}

li {
  margin-bottom: 0.45em;
}

h1,
h2,
h3,
h4 {
  line-height: 1.35;
  margin: 0 0 0.6em;
  letter-spacing: 0.2px;
  font-weight: 800;
  color: var(--text);
}

h1 {
  font-size: clamp(1.7rem, 4.2vw, 2.7rem);
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

h2 {
  font-size: clamp(1.35rem, 3vw, 1.9rem);
  position: relative;
  padding-bottom: 0.5em;
}

h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 64px;
  height: 4px;
  border-radius: 4px;
  background: var(--gradient);
}

h3 {
  font-size: clamp(1.1rem, 2.2vw, 1.3rem);
  color: var(--text);
}

h4 {
  font-size: 1.05rem;
  color: var(--accent-3);
}

strong {
  color: var(--text);
  font-weight: 700;
}

small {
  color: var(--text-muted);
  font-size: 0.85rem;
}

time {
  color: var(--text-muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
}

blockquote {
  margin: 1.2em 0;
  padding: 1em 1.4em;
  border-left: 4px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--gradient-soft);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  color: var(--text-muted);
}

blockquote p:last-child {
  margin-bottom: 0;
}

dl {
  margin: 1.2em 0;
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 0.4em 1.2em;
  padding: 1.1em 1.3em;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
}

dt {
  font-weight: 700;
  color: var(--accent-3);
}

dd {
  margin: 0;
  color: var(--text-muted);
}

address {
  font-style: normal;
  padding: 1.2em 1.4em;
  border-radius: var(--radius-md);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  margin-bottom: 1.2em;
}

address p {
  margin-bottom: 0.5em;
}

address p:last-child {
  margin-bottom: 0;
}

header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 16, 33, 0.72);
  backdrop-filter: var(--blur) saturate(160%);
  -webkit-backdrop-filter: var(--blur) saturate(160%);
  border-bottom: 1px solid var(--border);
}

@media (prefers-color-scheme: light) {
  header {
    background: rgba(244, 245, 251, 0.78);
  }
}

.brand-bar {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0.9rem 1.25rem 0.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.4rem 1rem;
}

.logo {
  font-size: clamp(1.15rem, 2.6vw, 1.45rem);
  font-weight: 900;
  letter-spacing: 0.5px;
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  white-space: nowrap;
}

.slogan {
  font-size: 0.82rem;
  color: var(--text-muted);
  letter-spacing: 0.4px;
}

header nav {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1.25rem 0.7rem;
}

header nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

header nav li {
  margin: 0;
}

header nav a {
  display: inline-block;
  padding: 0.35em 0.85em;
  font-size: 0.88rem;
  color: var(--text-muted);
  border-radius: 999px;
  border: 1px solid transparent;
  transition: color 0.25s ease, background 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

header nav a:hover,
header nav a:focus-visible {
  color: var(--text);
  text-decoration: none;
  background: var(--gradient-soft);
  border-color: var(--border);
  transform: translateY(-2px);
}

main {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
}

section {
  margin-bottom: 2.2rem;
  padding: clamp(1.2rem, 3vw, 2rem);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--border);
  backdrop-filter: var(--blur);
  -webkit-backdrop-filter: var(--blur);
  box-shadow: var(--shadow);
  animation: fadeUp 0.7s ease both;
  transition: box-shadow 0.35s ease, transform 0.35s ease, border-color 0.35s ease;
}

section:hover {
  box-shadow: var(--shadow-hover);
  border-color: rgba(123, 92, 255, 0.35);
}

section#hero {
  background:
    linear-gradient(135deg, rgba(255, 77, 141, 0.22), rgba(123, 92, 255, 0.24) 50%, rgba(34, 211, 238, 0.16)),
    var(--surface);
  text-align: left;
  position: relative;
  overflow: hidden;
}

section#hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto auto;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.35), transparent 65%);
  filter: blur(10px);
  pointer-events: none;
  animation: floatGlow 9s ease-in-out infinite;
}

section#hero > * {
  position: relative;
  z-index: 1;
}

figure {
  margin: 1.5rem 0 0;
  padding: 0.9rem;
  border-radius: var(--radius-md);
  background: var(--surface-solid);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

figure:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

figure svg {
  border-radius: var(--radius-sm);
}

figcaption {
  margin-top: 0.7rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
}

article {
  padding: 1.1rem 1.25rem;
  margin-bottom: 1rem;
  border-radius: var(--radius-md);
  background: var(--surface-solid);
  border: 1px solid var(--border);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

article:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(255, 77, 141, 0.4);
}

article h3 {
  margin-bottom: 0.35em;
}

article p:last-child {
  margin-bottom: 0;
}

article a {
  display: inline-block;
  font-weight: 700;
  font-size: 0.9rem;
  padding: 0.3em 0.9em;
  border-radius: 999px;
  background: var(--gradient);
  color: #fff;
  -webkit-text-fill-color: #fff;
  transition: transform 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease;
}

article a:hover,
article a:focus-visible {
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(255, 77, 141, 0.35);
  opacity: 0.95;
}

#faq h3 {
  margin-top: 1.4em;
  padding-left: 0.75em;
  border-left: 4px solid var(--accent-2);
}

#faq h3:first-of-type {
  margin-top: 0.6em;
}

#faq p {
  color: var(--text-muted);
}

#sitemap ul,
#links ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.5rem;
}

#sitemap li,
#links li {
  margin: 0;
}

#sitemap a,
#links a {
  display: block;
  padding: 0.55em 0.9em;
  border-radius: var(--radius-sm);
  background: var(--gradient-soft);
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 0.9rem;
  transition: transform 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

#sitemap a:hover,
#links a:hover,
#sitemap a:focus-visible,
#links a:focus-visible {
  text-decoration: none;
  transform: translateX(4px);
  border-color: var(--accent);
  color: var(--accent);
}

footer {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1.25rem 3rem;
}

footer section {
  margin-bottom: 1.4rem;
  animation: fadeUp 0.7s ease both;
}

footer section h2 {
  font-size: 1.15rem;
}

footer section h2::after {
  width: 44px;
  height: 3px;
}

footer > p {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.82rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes floatGlow {
  0%, 100% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(-30px, 24px, 0) scale(1.08);
  }
}

@supports (animation-timeline: view()) {
  section,
  article {
    animation: fadeUp 0.9s ease both;
    animation-timeline: view();
    animation-range: entry 0% cover 26%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

@media (max-width: 900px) {
  .brand-bar {
    padding-bottom: 0.35rem;
  }

  header nav ul {
    gap: 0.25rem;
  }

  header nav a {
    font-size: 0.82rem;
    padding: 0.3em 0.7em;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 15px;
    line-height: 1.7;
  }

  main {
    padding: 1rem 0.85rem 2.4rem;
  }

  section {
    padding: 1.1rem 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.4rem;
  }

  .brand-bar {
    padding: 0.75rem 0.85rem 0.3rem;
  }

  .slogan {
    font-size: 0.75rem;
  }

  header nav {
    padding: 0 0.85rem 0.6rem;
  }

  header nav ul {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 0.2rem;
  }

  header nav ul::-webkit-scrollbar {
    display: none;
  }

  header nav a {
    white-space: nowrap;
  }

  dl {
    grid-template-columns: 1fr;
    gap: 0.15em;
  }

  dt {
    margin-top: 0.5em;
  }

  #sitemap ul,
  #links ul {
    grid-template-columns: 1fr;
  }

  article {
    padding: 0.95rem 1rem;
  }

  blockquote {
    padding: 0.85em 1em;
  }

  footer {
    padding: 0 0.85rem 2.4rem;
  }
}

@media (max-width: 380px) {
  header nav a {
    font-size: 0.78rem;
    padding: 0.28em 0.6em;
  }

  section {
    padding: 0.95rem 0.85rem;
  }
}

::selection {
  background: rgba(255, 77, 141, 0.4);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--accent-3);
  outline-offset: 3px;
  border-radius: 4px;
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--accent), var(--accent-2));
  border-radius: 999px;
  border: 2px solid transparent;
  background-clip: padding-box;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--accent-2), var(--accent-3));
  background-clip: padding-box;
}