/* ==========================================================================
   aogl.cn — 深色黑白灰 · Glassmorphism 设计系统
   tokens / base / header / footer / home / 通用组件
   ========================================================================== */

:root {
  /* 表面 */
  --bg: #07070a;
  --bg-elev: #0c0c10;
  --bg-sunken: #050506;
  --surface: rgba(255, 255, 255, 0.045);
  --surface-2: rgba(255, 255, 255, 0.075);
  --surface-3: rgba(255, 255, 255, 0.11);
  --glass-grad: linear-gradient(180deg, rgba(255, 255, 255, 0.065), rgba(255, 255, 255, 0.028));

  /* 玻璃 */
  --glass-blur: 18px;
  --glass-saturate: 1.05;

  /* 文字（对 #07070a 对比度 18.6 / 13.2 / 8.1 / 4.6） */
  --text: #f5f5f5;
  --text-soft: #d4d4d8;
  --muted: #9ca3af;
  --faint: #6b7280;

  /* 线条 */
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.16);
  --hairline: rgba(255, 255, 255, 0.06);

  /* 强调：黑白灰体系里 "accent" 即纯白 */
  --accent: #ffffff;
  --accent-ink: #0a0a0a;
  --focus: #ffffff;

  /* 阴影 */
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.55);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 30px 80px rgba(0, 0, 0, 0.6);
  --inset-hi: inset 0 1px 0 rgba(255, 255, 255, 0.07);

  /* 圆角 / 布局 */
  --radius-sm: 10px;
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 40px);

  --font: "Inter", "Segoe UI", system-ui, -apple-system, "PingFang SC", "Noto Sans SC", "Microsoft YaHei", sans-serif;
  --mono: "JetBrains Mono", "SFMono-Regular", ui-monospace, "Cascadia Code", Consolas, monospace;
}

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

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* 背景：极淡的白色径向光 + 顶部高光 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(1000px 700px at 12% -12%, rgba(255, 255, 255, 0.07), transparent 62%),
    radial-gradient(800px 560px at 92% -4%, rgba(255, 255, 255, 0.045), transparent 58%);
}

.bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -3;
  opacity: 0.5;
  pointer-events: none;
}

.bg-aura {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(1200px 800px at 50% 118%, rgba(255, 255, 255, 0.035), transparent 70%);
}

img { max-width: 100%; }

a { color: inherit; }

h1, h2, h3, h4 {
  font-weight: 620;
  letter-spacing: -0.02em;
  line-height: 1.2;
  margin: 0;
}

p { margin: 0; }

ul, ol { margin: 0; }

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

::selection {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
}

.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;
}

.skip-link {
  position: absolute;
  inset-inline-start: 16px;
  top: -60px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 999px;
  background: #f5f5f5;
  color: #0a0a0a;
  font-size: 13px;
  text-decoration: none;
  transition: top 0.2s;
}
.skip-link:focus { top: 12px; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.site-main { display: block; min-height: 50vh; }

/* ------------------------------------------------------------- glass 基类 */
.glass,
.card,
.pillar,
.doc,
.article,
.hero,
.editorial,
.tool-cats,
.brief-list,
.news-group,
.error-card,
.more-link,
.link-card {
  background: var(--glass-grad);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md), var(--inset-hi);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  border-radius: var(--radius-lg);
}

.glass-inset {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
}

@supports not ((backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px))) {
  .glass, .card, .pillar, .doc, .article, .hero, .editorial,
  .tool-cats, .brief-list, .news-group, .error-card, .more-link, .link-card {
    background: rgba(16, 16, 20, 0.96);
  }
}

/* ----------------------------------------------------------------- header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(7, 7, 10, 0.72);
  -webkit-backdrop-filter: blur(18px) saturate(1.1);
  backdrop-filter: blur(18px) saturate(1.1);
  border-bottom: 1px solid var(--hairline);
}

.head-row {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
}

.brand-logo-img {
  display: block;
  width: auto;
  height: 32px;
}

.site-nav { margin-inline-start: auto; }

.site-nav-list {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav-list a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  line-height: 1.4;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
}

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

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

/* 导航首位 CTA：需求提交（黑底白字 pill） */
.site-nav-list .is-cta a {
  background: rgba(245, 245, 245, 0.94);
  border-color: transparent;
  color: var(--accent-ink);
  font-weight: 650;
}
.site-nav-list .is-cta a:hover {
  background: #ffffff;
  color: var(--accent-ink);
  transform: translateY(-1px);
}
.site-nav-list .is-cta.is-active a {
  background: #ffffff;
  color: var(--accent-ink);
  border-color: var(--border);
}

.lang-switch { flex: 0 0 auto; }

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  padding: 8px 32px 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background:
    url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' fill='none'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%239ca3af' stroke-width='1.4' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center,
    var(--surface);
  color: var(--text-soft);
  font: 500 13px/1.4 var(--font);
  cursor: pointer;
  min-height: 36px;
}
.lang-select:hover { border-color: var(--border-strong); background-color: var(--surface-2); }
.lang-select option { background: #101014; color: #f5f5f5; }

/* ----------------------------------------------------------------- footer */
.site-footer {
  margin-top: 40px;
  border-top: 1px solid var(--hairline);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.012), transparent 60%);
}

.footer-wrap {
  display: grid;
  gap: 18px;
  padding-block: 40px 32px;
}

.footer-watermark { line-height: 0; }
.footer-watermark-svg {
  width: min(448px, 62vw);
  height: auto;
  opacity: 0.09;
  filter: grayscale(1);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--hairline);
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.footer-legal a {
  color: var(--faint);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.2s;
}
.footer-legal a:hover { color: var(--text); }

.footer-copy {
  color: var(--faint);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}

/* --------------------------------------------------------------- 首页 Hero */
.home {
  display: grid;
  gap: clamp(36px, 5vw, 60px);
  padding-block: clamp(28px, 5vw, 56px) 72px;
}

.hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  padding: clamp(26px, 5vw, 64px);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(620px 320px at 82% -18%, rgba(255, 255, 255, 0.1), transparent 62%);
}

.eyebrow {
  margin: 0;
  font-size: 11.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--faint);
}

.hero-title {
  margin: 14px 0 18px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.08;
  letter-spacing: -0.035em;
  font-weight: 650;
  max-width: 20ch;
}

.hero-lead {
  max-width: 58ch;
  color: var(--text-soft);
  font-size: clamp(15px, 1.5vw, 17.5px);
}

/* 首屏居中排版 */
.hero--center { text-align: center; }
.hero--center .hero-title,
.hero--center .hero-lead,
.hero--center .hero-req-note,
.hero--center .eyebrow { margin-inline: auto; }
.hero--center .hero-title { max-width: none; }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}
.hero--center .hero-actions { justify-content: center; }

/* 首屏快速提交表单 */
.rq-hp { position: absolute; left: -9999px; top: -9999px; }
.hero-quick {
  display: flex;
  align-items: stretch;
  gap: 10px;
  max-width: 720px;
  margin: 26px auto 0;
  text-align: left;
}
.hero-quick textarea {
  flex: 1;
  min-height: 56px;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  font: inherit;
  line-height: 1.6;
  resize: vertical;
  backdrop-filter: blur(8px);
}
.hero-quick textarea::placeholder { color: var(--muted); }
.hero-quick textarea:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.09);
}
.hero-quick .btn { white-space: nowrap; padding-block: 12px; }
@media (max-width: 640px) {
  .hero-quick { flex-direction: column; }
  .hero-quick .btn { width: 100%; }
}

.hero-req-note {
  margin-top: 18px;
  max-width: 64ch;
  color: var(--muted);
  font-size: 13.5px;
  line-height: 1.7;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 22px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: 600 14px/1.2 var(--font);
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.btn-primary {
  background: #f5f5f5;
  color: var(--accent-ink);
  box-shadow: 0 6px 20px rgba(255, 255, 255, 0.12);
}
.btn-primary:hover {
  background: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 10px 28px rgba(255, 255, 255, 0.18);
}

.btn-ghost {
  background: var(--surface);
  border-color: var(--border);
  color: var(--text);
}
.btn-ghost:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  transform: translateY(-1px);
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 28px 48px;
  margin: 38px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
}

.hero-stats dt {
  font-size: 11.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--faint);
}

.hero-stats dd {
  margin: 4px 0 0;
  font-size: 26px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

/* ---------------------------------------------------------------- section */
.section { display: grid; gap: 18px; }

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--hairline);
}

.section-title {
  font-size: clamp(18px, 2vw, 23px);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.section-title a { text-decoration: none; }

.section-lead {
  margin: 0;
  max-width: 72ch;
  color: var(--muted);
  font-size: 14.5px;
}

.section-count {
  color: var(--faint);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}

.link-more {
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s;
}
.link-more:hover { color: var(--text); }

/* ------------------------------------------------------------------ cards */
.card-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(258px, 1fr));
}

.card {
  overflow: hidden;
  transition: transform 0.25s, border-color 0.25s, background 0.25s, box-shadow 0.25s;
}

.card:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.082), rgba(255, 255, 255, 0.038));
  box-shadow: var(--shadow-lg), var(--inset-hi);
}

.card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

.card-media {
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #0d0d11;
  border-bottom: 1px solid var(--hairline);
}

.card-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.card:hover .card-media img { transform: scale(1.035); }

.card-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 15px 18px 18px;
}

.card-kicker {
  font-size: 11.5px;
  letter-spacing: 0.03em;
  color: var(--faint);
}

.card-title {
  font-size: 15.5px;
  font-weight: 600;
  line-height: 1.42;
  letter-spacing: -0.01em;
  color: var(--text);
}

.card-excerpt {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
}

/* ------------------------------------------------------------- pillar 卡片 */
.pillar-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(238px, 1fr));
}

.pillar {
  position: relative;
  display: grid;
  gap: 7px;
  padding: 22px 22px 24px;
  text-decoration: none;
  color: inherit;
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
}

.pillar:hover {
  transform: translateY(-2px);
  border-color: var(--border-strong);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.085), rgba(255, 255, 255, 0.04));
}

.pillar-kicker {
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--faint);
}

.pillar-title {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.015em;
  padding-inline-end: 26px;
}

.pillar-desc {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--muted);
}

.pillar-arrow {
  position: absolute;
  top: 20px;
  inset-inline-end: 22px;
  color: var(--faint);
  font-size: 14px;
  transition: transform 0.2s, color 0.2s;
}

.pillar:hover .pillar-arrow {
  color: var(--text);
  transform: translateX(3px);
}

/* ------------------------------------------------------------ tool 目录 */
.tool-cats { padding: 4px 24px; }

.tool-cat {
  display: grid;
  gap: 10px;
  padding: 20px 0;
  border-bottom: 1px solid var(--hairline);
}
.tool-cat:last-child { border-bottom: 0; }

.tool-cat-title {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-soft);
  letter-spacing: 0.01em;
}

.tool-chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-soft);
  font-size: 13px;
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.chip:hover {
  background: var(--surface-2);
  border-color: var(--border-strong);
  color: var(--text);
}

.chip-icon {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  object-fit: contain;
}

/* --------------------------------------------------------------- 列表样式 */
.brief-list { list-style: none; padding: 6px 22px; }

.brief-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  padding: 13px 0;
  border-bottom: 1px solid var(--hairline);
}
.brief-row:last-child { border-bottom: 0; }

.brief-title {
  color: var(--text);
  font-size: 14.5px;
  line-height: 1.5;
  text-decoration: none;
}
.brief-title:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(255, 255, 255, 0.4);
}

.brief-meta {
  color: var(--faint);
  font-size: 12.5px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------- 返回链接 */
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
  padding: 8px 2px;
  transition: color 0.2s;
}
.back-link:hover { color: var(--text); }

/* --------------------------------------------------------------- 响应式 */
@media (max-width: 960px) {
  .brand-logo-img { height: 28px; }
  .hero-stats { gap: 22px 36px; }
}

@media (max-width: 720px) {
  .head-row {
    gap: 10px;
    min-height: 58px;
    flex-wrap: wrap;
    padding-block: 8px;
  }
  .site-nav {
    order: 3;
    width: 100%;
    margin-inline-start: 0;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .site-nav::-webkit-scrollbar { display: none; }
  .site-nav-list { gap: 2px; }
  .site-nav-list a { padding: 7px 12px; font-size: 13px; }
  .lang-switch { margin-inline-start: auto; }
  .hero { border-radius: 22px; }
  .hero-stats dd { font-size: 22px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 560px) {
  .card-grid { grid-template-columns: 1fr; }
  .hero-actions .btn { flex: 1 1 auto; }
  .brief-row { flex-direction: column; gap: 4px; }
}

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

/* --------------------------------------------------------------- 页头通用 */
.page-head {
  display: grid;
  gap: 10px;
  max-width: 82ch;
  padding-block: clamp(24px, 4vw, 40px) 8px;
}

.page-title {
  margin-top: 4px;
  font-size: clamp(27px, 4vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.03em;
  font-weight: 650;
}

.page-lead {
  color: var(--muted);
  font-size: 15.5px;
  max-width: 72ch;
}

.page-meta {
  color: var(--faint);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}
