:root {
  --bg: #0a0c14;
  --surface: #12151f;
  --surface-2: #1a1e2c;
  --text: #eef0f4;
  --muted: #9aa3b2;
  --brand-blue: #2f6bff;
  --brand-magenta: #7c5cff;
  --accent: #b8a0ff;
  --accent-soft: rgba(184, 160, 255, 0.14);
  --border: #2a3140;
  --maxw: 44rem;
  --radius: 12px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  --icon-radius: 22%;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background:
    radial-gradient(ellipse 90% 55% at 88% -8%, rgba(124, 92, 255, 0.14), transparent),
    radial-gradient(ellipse 75% 50% at 8% -12%, rgba(47, 107, 255, 0.18), transparent),
    var(--bg);
  color: var(--text);
  line-height: 1.65;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  text-decoration: none;
}

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

header {
  padding: 1.5rem 1.25rem 1.1rem;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(10px);
}

.header-inner {
  max-width: var(--maxw);
  margin: 0 auto;
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.brand-mark {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--icon-radius);
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 6px 18px rgba(20, 16, 48, 0.45);
  background: transparent;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

header h1 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.03em;
}

header .tagline {
  margin: 0.2rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.brand-link {
  color: inherit;
  text-decoration: none;
}

.brand-link:hover .brand-name {
  color: var(--accent);
}

.brand-name {
  display: block;
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.page-title {
  margin-top: 0.85rem;
}

.page-title h1 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: -0.03em;
}

.page-title .tagline {
  margin-top: 0.2rem;
}

.locale-switch {
  position: relative;
  flex-shrink: 0;
}

.locale-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.3;
  cursor: pointer;
}

.locale-trigger:hover {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
  background: var(--accent-soft);
}

.locale-caret {
  width: 0;
  height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid var(--muted);
}

.locale-switch.is-open .locale-caret {
  transform: rotate(180deg);
}

.locale-menu {
  position: absolute;
  top: calc(100% + 6px);
  inset-inline-end: 0;
  z-index: 40;
  margin: 0;
  padding: 0.35rem;
  list-style: none;
  min-width: 11.5rem;
  max-height: min(70vh, 22rem);
  overflow-x: hidden;
  overflow-y: scroll;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: color-mix(in srgb, var(--muted) 70%, transparent) var(--surface-2);
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 12px 32px color-mix(in srgb, #000 18%, transparent);
}

/* Keep scrollbar always visible (incl. macOS overlay scrollbars). */
.locale-menu::-webkit-scrollbar {
  width: 10px;
}

.locale-menu::-webkit-scrollbar-track {
  background: var(--surface-2);
  border-radius: 999px;
}

.locale-menu::-webkit-scrollbar-thumb {
  background: color-mix(in srgb, var(--muted) 70%, transparent);
  border-radius: 999px;
  border: 2px solid var(--surface-2);
}

.locale-menu::-webkit-scrollbar-thumb:hover {
  background: var(--muted);
}

.locale-menu a {
  display: block;
  padding: 0.45rem 0.7rem;
  border-radius: 8px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 500;
  white-space: nowrap;
}

.locale-menu a:hover {
  background: var(--surface-2);
}

.locale-menu a[aria-current="page"],
.locale-menu a[aria-current="true"] {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
}

.locale-switch-group {
  display: none;
}

nav.site-nav {
  margin-top: 1rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.65rem;
  font-size: 0.88rem;
}

nav.site-nav a {
  color: var(--muted);
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
}

nav.site-nav a:hover {
  color: var(--text);
  border-color: var(--border);
  background: var(--surface-2);
}

nav.site-nav a[aria-current="page"] {
  color: var(--accent);
  font-weight: 600;
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
  background: var(--accent-soft);
}

@media (max-width: 480px) {
  .header-top {
    flex-direction: column;
    align-items: stretch;
  }

  .locale-switch {
    align-self: flex-end;
  }
}

main {
  flex: 1;
  max-width: var(--maxw);
  width: 100%;
  margin: 0 auto;
  padding: 2rem 1.25rem 2.5rem;
}

main h2 {
  margin: 2rem 0 0.75rem;
  font-size: 1.08rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

main h2:first-child,
.hero + h2 {
  margin-top: 0;
}

main p,
main li {
  color: #c8ced8;
  margin: 0.65rem 0;
}

main ul {
  padding-left: 1.25rem;
}

main .note {
  font-size: 0.92rem;
  color: var(--muted);
  background: var(--accent-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
  margin: 1.5rem 0;
}

.hero {
  background: linear-gradient(135deg, color-mix(in srgb, var(--brand-blue) 18%, var(--surface)), color-mix(in srgb, var(--brand-magenta) 14%, var(--surface-2)));
  border: 1px solid color-mix(in srgb, var(--brand-magenta) 22%, var(--border));
  border-radius: calc(var(--radius) + 2px);
  padding: 1.35rem 1.25rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.75rem;
}

.hero-with-icon {
  display: flex;
  gap: 1.1rem;
  align-items: flex-start;
}

.hero-icon {
  width: 4.5rem;
  height: 4.5rem;
  border-radius: var(--icon-radius);
  flex-shrink: 0;
  box-shadow: 0 8px 22px rgba(20, 16, 48, 0.45);
}

.hero p {
  margin: 0;
  font-size: 1.05rem;
  color: var(--text);
}

.feature-grid {
  display: grid;
  gap: 0.85rem;
  margin: 1rem 0 1.5rem;
  padding: 0;
  list-style: none;
}

.feature-grid li {
  margin: 0;
  padding: 0.95rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.feature-grid strong {
  display: block;
  color: var(--text);
  margin-bottom: 0.25rem;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}

.steps li {
  counter-increment: step;
  position: relative;
  margin: 0 0 0.75rem;
  padding: 0.85rem 1rem 0.85rem 2.75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0.85rem;
  top: 0.85rem;
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 1.25rem;
}

.site-footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--muted);
}

.site-footer-locale {
  display: inline-flex;
  padding: 2px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
  gap: 2px;
}

.site-footer-locale a {
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
}

.site-footer-locale a[aria-current="page"] {
  color: var(--text);
  background: var(--accent-soft);
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.85rem;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--accent);
}

.hub {
  flex: 1;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 3rem 1.25rem;
}

.hub-card {
  max-width: 28rem;
  width: 100%;
  padding: 2rem 1.5rem;
  background: linear-gradient(145deg, var(--surface), var(--surface-2));
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
}

.hub .brand-mark {
  width: 4.5rem;
  height: 4.5rem;
  margin: 0 auto 1rem;
  box-shadow: 0 10px 28px rgba(20, 16, 48, 0.5);
}

.hub .brand-mark img {
  width: 100%;
  height: 100%;
}

.hub h1 {
  font-size: 1.85rem;
  margin: 0 0 0.5rem;
  letter-spacing: -0.03em;
}

.hub p {
  color: var(--muted);
  margin: 0 0 1.75rem;
}

.hub-bilingual {
  line-height: 1.55;
}

.hub-sep {
  display: inline-block;
  margin: 0 0.35rem;
  opacity: 0.45;
}

.hub-hint {
  margin-top: 1.25rem;
  font-size: 0.92rem;
  color: var(--muted);
}

.hub-hint a {
  font-weight: 600;
}

.hub .choices {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface-2);
}

.hub .choices-label {
  display: block;
  margin-bottom: 0.65rem;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.hub .choices a {
  display: inline-block;
  min-width: 6.5rem;
  padding: 0.65rem 1.15rem;
  border: none;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
}

.hub .choices a:hover {
  color: var(--text);
  background: color-mix(in srgb, var(--surface) 80%, transparent);
}

.hub .choices a.is-active,
.hub .choices a[aria-current="page"] {
  color: var(--text);
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent) 40%, var(--border));
}

@media (min-width: 640px) {
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}


.locale-switch--hub {
  display: inline-block;
  margin: 0.5rem auto 0;
}

.hub .locale-switch--hub .locale-menu {
  inset-inline-start: 50%;
  inset-inline-end: auto;
  transform: translateX(-50%);
  text-align: start;
}

.hub .choices-label {
  margin-top: 1.25rem;
}
