:root {
  --bg: oklch(97.7% 0.006 255);
  --surface: oklch(100% 0 0);
  --surface-muted: oklch(95.8% 0.009 255);
  --surface-accent: color-mix(in srgb, var(--accent) 8%, var(--surface));
  --text: oklch(23% 0.024 255);
  --text-strong: oklch(16% 0.025 255);
  --muted: oklch(45% 0.02 255);
  --subtle: oklch(55% 0.018 255);
  --line: oklch(89% 0.012 255);
  --line-strong: oklch(80% 0.018 255);
  --danger: oklch(55% 0.2 25);
  --success: oklch(52% 0.14 155);
  --shadow-float: 0 18px 48px rgb(25 40 70 / 12%);
  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 12px;
  --shell: 1180px;
  --motion-fast: 160ms;
  --motion-base: 220ms;
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: oklch(15.5% 0.015 255);
  --surface: oklch(19.5% 0.018 255);
  --surface-muted: oklch(23.5% 0.021 255);
  --surface-accent: color-mix(in srgb, var(--accent) 13%, var(--surface));
  --text: oklch(94% 0.01 255);
  --text-strong: oklch(98% 0.006 255);
  --muted: oklch(74% 0.016 255);
  --subtle: oklch(62% 0.018 255);
  --line: oklch(29% 0.021 255);
  --line-strong: oklch(38% 0.025 255);
  --danger: oklch(72% 0.16 25);
  --success: oklch(73% 0.12 155);
  --shadow-float: 0 20px 60px rgb(0 0 0 / 34%);
  color-scheme: dark;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  margin: 0;
  min-width: 320px;
  font: 400 16px/1.55 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body, #app { min-height: 100vh; min-height: 100dvh; }
#app { display: flex; flex-direction: column; }
#app > main { flex: 1 0 auto; }

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

button, input, textarea, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
svg { flex: 0 0 auto; }
[v-cloak] { display: none !important; }
[hidden] { display: none !important; }

::selection {
  color: var(--accent-contrast);
  background: var(--accent);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
  visibility: hidden;
}

.shell {
  width: min(calc(100% - 40px), var(--shell));
  margin-inline: auto;
}

main { min-height: 0; }

:where(a, button, input, textarea, [role="tab"]):focus-visible {
  outline: 3px solid var(--accent-focus) !important;
  outline-offset: 3px;
}

.site-header {
  position: relative;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(16px);
}

.header-inner {
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  min-width: 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-strong);
  font-size: 17px;
  font-weight: 760;
  letter-spacing: -0.02em;
}

.brand img { width: auto; height: 34px; object-fit: contain; }
.brand-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.brand-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--accent-contrast);
  background: var(--accent);
}

.brand-lens { width: 27px; height: 27px; fill: none; stroke: currentColor; stroke-width: 2; }
.brand-track { opacity: .48; stroke-width: 1; }

.header-nav, .operator-links { display: flex; align-items: center; gap: 10px; }
.header-nav { position: relative; }
.operator-links:empty { display: none; }
.operator-links a, .text-action { color: var(--muted); font-size: 14px; font-weight: 620; }
.operator-links a { min-height: 44px; display: inline-flex; align-items: center; }

.text-action, .theme-toggle {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 0;
  border-radius: 10px;
  padding: 8px 10px;
  color: var(--muted) !important;
  background: transparent !important;
  cursor: pointer;
  transition: color var(--motion-fast), background var(--motion-fast);
}

.text-action:hover, .theme-toggle:hover {
  color: var(--accent) !important;
  background: var(--surface-accent) !important;
}

.theme-toggle { width: 44px; border: 0; padding: 0; background: transparent !important; }
.mobile-links { display: none; }
.mobile-links summary { list-style: none; }
.mobile-links summary::-webkit-details-marker { display: none; }
.theme-icon { display: grid; place-items: center; }
.theme-icon-sun { display: none; }
:root[data-theme="dark"] .theme-icon-moon { display: none; }
:root[data-theme="dark"] .theme-icon-sun { display: grid; }

.site-footer {
  margin-top: 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: var(--surface);
}

.footer-inner {
  min-height: 72px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding-block: 14px;
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.footer-inner p { margin: 0; }
.footer-inner a { color: var(--text); font-weight: 650; }

.muted { color: var(--muted); }

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