:root {
  --brand: #0dbf9c;
  --brand-dark: #0bae8d;
  --bg: #ffffff;
  --surface: #f9fafb;
  --text: #111827;
  --muted: #6b7280;
  --border: #e5e7eb;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0b0f19;
    --surface: #111827;
    --text: #f9fafb;
    --muted: #9ca3af;
    --border: #1f2937;
  }
}

* {
  scroll-behavior: smooth;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

::selection {
  background-color: rgba(13, 191, 156, 0.2);
}

/* 按钮聚焦环 */
button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* 特性卡片统一过渡 */
.feature-card,
.view-card,
.doc-card {
  transition-property: transform, box-shadow, border-color;
  transition-duration: 200ms;
  transition-timing-function: ease-out;
}

/* Toast 动画 */
#toast {
  transition:
    opacity 200ms ease,
    transform 200ms ease;
  opacity: 0;
  transform: translate(-50%, 1rem);
}

#toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* 小屏菜单动画 */
#mobile-menu {
  transition: max-height 200ms ease;
  overflow: hidden;
}

/* 备案号链接 */
.beian-link svg {
  flex-shrink: 0;
}

/* 减少动画偏好 */
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
