/* ============================================================
   APIKey 中转站 — 全局样式
   风格：简洁 / 浅色 / 蓝色主色调 / 卡片式
   ============================================================ */

:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #eff6ff;
  --gradient: linear-gradient(135deg, #2563eb 0%, #4f46e5 100%);
  --text: #111827;
  --text-secondary: #4b5563;
  --text-muted: #9ca3af;
  --border: #e5e7eb;
  --bg: #ffffff;
  --bg-soft: #f9fafb;
  --success: #16a34a;
  --danger: #dc2626;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow: 0 4px 16px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 12px 40px rgba(16, 24, 40, 0.12);
  --container: 1120px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --mono: "SF Mono", "JetBrains Mono", Consolas, "Courier New", monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { opacity: 0.85; }

img { max-width: 100%; display: block; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}
.btn-primary:hover { opacity: 0.92; transform: translateY(-1px); }
.btn-outline {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-outline:hover { border-color: var(--primary); color: var(--primary); }
.btn-ghost { background: transparent; color: var(--text-secondary); }
.btn-ghost:hover { color: var(--primary); background: var(--bg-soft); }
.btn-lg { padding: 14px 28px; font-size: 16px; border-radius: 12px; }
.btn-sm { padding: 6px 14px; font-size: 14px; }
.btn-block { width: 100%; }

/* ---------- 导航 ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
}
.nav-logo .logo-mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: var(--gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
}
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links a {
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 8px;
}
.nav-links a:hover { color: var(--primary); background: var(--primary-light); }
.nav-links a.active { color: var(--primary); font-weight: 600; }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-burger {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text);
  padding: 4px 8px;
}

/* ---------- Hero ---------- */
.hero {
  text-align: center;
  padding: 96px 24px 72px;
  background:
    radial-gradient(600px 300px at 20% 0%, rgba(37, 99, 235, 0.08), transparent 60%),
    radial-gradient(600px 300px at 80% 0%, rgba(79, 70, 229, 0.08), transparent 60%);
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--primary-light);
  color: var(--primary);
  font-size: 13px;
  font-weight: 600;
  border: 1px solid rgba(37, 99, 235, 0.2);
  margin-bottom: 24px;
}
.hero h1 {
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  max-width: 720px;
  margin: 0 auto 20px;
}
.hero h1 .gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p.sub {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 620px;
  margin: 0 auto 36px;
}
.hero-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero-stats {
  display: flex;
  justify-content: center;
  gap: 56px;
  margin-top: 64px;
  flex-wrap: wrap;
}
.hero-stats .stat { text-align: center; }
.hero-stats .stat b {
  display: block;
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
}
.hero-stats .stat span { font-size: 14px; color: var(--text-muted); }

/* ---------- 代码卡片 ---------- */
.code-card {
  max-width: 640px;
  margin: 48px auto 0;
  background: #0f172a;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  text-align: left;
  overflow: hidden;
}
.code-card .code-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: #1e293b;
}
.code-card .dot { width: 12px; height: 12px; border-radius: 50%; }
.code-card .dot.r { background: #f87171; }
.code-card .dot.y { background: #fbbf24; }
.code-card .dot.g { background: #34d399; }
.code-card .code-head span { margin-left: 8px; font-size: 12px; color: #94a3b8; }
.code-card pre {
  padding: 20px;
  font-family: var(--mono);
  font-size: 13px;
  color: #e2e8f0;
  overflow-x: auto;
  line-height: 1.7;
}
.code-card pre .c { color: #64748b; }
.code-card pre .k { color: #93c5fd; }
.code-card pre .s { color: #86efac; }

/* ---------- 区块通用 ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-soft); }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }
.section-head .tag {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.section-head h2 { font-size: clamp(26px, 3.5vw, 36px); font-weight: 800; letter-spacing: -0.01em; }
.section-head p { margin-top: 12px; color: var(--text-secondary); font-size: 16px; }

/* ---------- 卡片网格 ---------- */
.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.2s ease;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: #d1d5db; }

/* ---------- 模型卡片 ---------- */
.model-card { text-align: center; padding: 24px 16px; }
.model-card .model-logo {
  width: 44px; height: 44px;
  border-radius: 12px;
  margin: 0 auto 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 800; color: #fff;
}
.model-card h3 { font-size: 15px; font-weight: 600; }
.model-card p { font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.model-card .tag-list { display: flex; gap: 6px; justify-content: center; margin-top: 10px; flex-wrap: wrap; }
.model-card .tag-list span {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

/* ---------- 特性 ---------- */
.feature-card { display: flex; flex-direction: column; gap: 12px; }
.feature-card .icon {
  width: 44px; height: 44px;
  border-radius: 12px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 4px;
}
.feature-card h3 { font-size: 17px; font-weight: 700; }
.feature-card p { font-size: 14px; color: var(--text-secondary); }

/* ---------- 步骤 ---------- */
.steps { counter-reset: step; display: grid; gap: 24px; }
.step { position: relative; padding: 24px 28px 24px 76px; }
.step::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 24px; top: 24px;
  width: 36px; height: 36px;
  border-radius: 10px;
  background: var(--gradient);
  color: #fff;
  font-weight: 800;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}
.step h3 { font-size: 17px; font-weight: 700; margin-bottom: 6px; }
.step p { font-size: 14px; color: var(--text-secondary); }

/* ---------- 价格 ---------- */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: stretch; }
.price-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all 0.2s ease;
}
.price-card:hover { box-shadow: var(--shadow-lg); }
.price-card.hot {
  border-color: var(--primary);
  box-shadow: 0 8px 32px rgba(37, 99, 235, 0.15);
}
.price-card .flag {
  position: absolute;
  top: -13px; left: 50%;
  transform: translateX(-50%);
  background: var(--gradient);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 999px;
  white-space: nowrap;
}
.price-card .plan-name { font-size: 18px; font-weight: 700; }
.price-card .plan-desc { font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.price-card .price { margin: 20px 0; }
.price-card .price b { font-size: 40px; font-weight: 800; letter-spacing: -0.02em; }
.price-card .price span { color: var(--text-muted); font-size: 14px; }
.price-card ul { list-style: none; flex: 1; margin-bottom: 24px; }
.price-card ul li {
  padding: 8px 0 8px 28px;
  font-size: 14px;
  color: var(--text-secondary);
  position: relative;
  border-bottom: 1px dashed var(--border);
}
.price-card ul li:last-child { border-bottom: none; }
.price-card ul li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--success);
  font-weight: 800;
}

/* ---------- 接入代码块 ---------- */
.code-block {
  background: #0f172a;
  border-radius: var(--radius);
  padding: 16px 20px;
  font-family: var(--mono);
  font-size: 13px;
  color: #e2e8f0;
  overflow-x: auto;
  line-height: 1.7;
  margin: 16px 0;
}
.code-block .c { color: #64748b; }
.code-block .k { color: #93c5fd; }
.code-block .s { color: #86efac; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 760px; margin: 0 auto; }
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
  background: var(--bg);
}
.faq-item summary {
  padding: 18px 22px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  user-select: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-size: 22px;
  color: var(--primary);
  transition: transform 0.2s;
  flex-shrink: 0;
}
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-body { padding: 0 22px 18px; font-size: 14px; color: var(--text-secondary); }

/* ---------- CTA 横幅 ---------- */
.cta-band {
  background: var(--gradient);
  border-radius: var(--radius-lg);
  padding: 56px 48px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.cta-band h2 { font-size: clamp(24px, 3vw, 32px); font-weight: 800; margin-bottom: 12px; }
.cta-band p { opacity: 0.9; margin-bottom: 28px; font-size: 15px; }
.cta-band .btn { background: #fff; color: var(--primary); box-shadow: 0 4px 20px rgba(0,0,0,0.15); }

/* ---------- 页脚 ---------- */
.footer { border-top: 1px solid var(--border); padding: 56px 0 32px; background: var(--bg-soft); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer .brand p { font-size: 14px; color: var(--text-secondary); margin-top: 12px; max-width: 280px; }
.footer h4 { font-size: 14px; font-weight: 700; margin-bottom: 16px; }
.footer ul { list-style: none; }
.footer ul li { margin-bottom: 10px; }
.footer ul a { font-size: 14px; color: var(--text-secondary); }
.footer ul a:hover { color: var(--primary); }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- Toast 轻提示 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%) translateY(20px);
  background: #111827;
  color: #f9fafb;
  font-size: 14px;
  padding: 12px 20px;
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 9999;
  max-width: calc(100vw - 48px);
  text-align: center;
  line-height: 1.5;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 24px;
}
.modal {
  background: var(--bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 28px;
  width: 100%;
  max-width: 420px;
}
.modal h3 { font-size: 18px; font-weight: 700; margin-bottom: 18px; }

/* ---------- 登录/注册 ---------- */
.auth-wrap {
  min-height: calc(100vh - 64px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  background:
    radial-gradient(500px 300px at 15% 10%, rgba(37, 99, 235, 0.07), transparent 60%),
    radial-gradient(500px 300px at 85% 90%, rgba(79, 70, 229, 0.07), transparent 60%),
    var(--bg-soft);
}
.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow-lg);
}
.auth-card h1 { font-size: 24px; font-weight: 800; text-align: center; }
.auth-card > p { text-align: center; color: var(--text-secondary); font-size: 14px; margin: 8px 0 28px; }
.auth-form { display: block; }
.auth-tabs { display: flex; background: var(--bg-soft); border-radius: 10px; padding: 4px; margin-bottom: 24px; }
.auth-tabs button {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  font-family: var(--font);
}
.auth-tabs button.active { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.form-group input {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
  font-family: var(--font);
  transition: border-color 0.2s, box-shadow 0.2s;
  background: #fff;
  color: var(--text);
}
.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}
.form-hint { font-size: 12px; color: var(--text-muted); margin-top: 6px; }
.auth-foot { text-align: center; font-size: 13px; color: var(--text-muted); margin-top: 20px; }
.auth-foot a { color: var(--primary); font-weight: 600; }
.auth-tip {
  margin-top: 20px;
  padding: 12px 16px;
  background: var(--primary-light);
  border-radius: 10px;
  font-size: 13px;
  color: var(--primary-dark);
  text-align: center;
}

/* ---------- 控制台 ---------- */
.dash { display: flex; min-height: calc(100vh - 64px); background: var(--bg-soft); }
.dash-side {
  width: 220px;
  background: var(--bg);
  border-right: 1px solid var(--border);
  padding: 20px 12px;
  flex-shrink: 0;
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
  overflow-y: auto;
}
.dash-side .side-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 4px;
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  font-family: var(--font);
  text-align: left;
}
.dash-side .side-item:hover { background: var(--bg-soft); color: var(--text); }
.dash-side .side-item.active { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.dash-side .side-group { font-size: 12px; color: var(--text-muted); padding: 16px 14px 6px; font-weight: 700; }
.dash-main { flex: 1; padding: 28px 32px; min-width: 0; }
.dash-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  gap: 16px;
  flex-wrap: wrap;
}
.dash-topbar h1 { font-size: 24px; font-weight: 800; }
.dash-topbar p { color: var(--text-secondary); font-size: 14px; }
.stat-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.stat-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.stat-card .label { font-size: 13px; color: var(--text-muted); }
.stat-card .value { font-size: 26px; font-weight: 800; margin-top: 6px; }
.stat-card .delta { font-size: 12px; margin-top: 4px; }
.stat-card .delta.up { color: var(--success); }
.stat-card .delta.down { color: var(--danger); }
.dash-panel {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 24px;
}
.dash-panel h3 { font-size: 16px; font-weight: 700; margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; }
.dash-panel h3 a { font-size: 13px; font-weight: 500; }

/* 表格 */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th {
  text-align: left;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 600;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.table td {
  padding: 12px;
  border-bottom: 1px solid var(--bg-soft);
  color: var(--text-secondary);
  white-space: nowrap;
}
.table tr:last-child td { border-bottom: none; }
.table td b { color: var(--text); font-weight: 600; }
.badge {
  display: inline-block;
  font-size: 12px;
  padding: 2px 10px;
  border-radius: 999px;
  font-weight: 600;
}
.badge-green { background: #f0fdf4; color: var(--success); border: 1px solid #bbf7d0; }
.badge-red { background: #fef2f2; color: var(--danger); border: 1px solid #fecaca; }
.badge-blue { background: var(--primary-light); color: var(--primary); border: 1px solid #bfdbfe; }
.badge-gray { background: var(--bg-soft); color: var(--text-secondary); border: 1px solid var(--border); }

/* 简易条形图 */
.bars { display: flex; align-items: flex-end; gap: 10px; height: 160px; padding-top: 10px; }
.bars .bar {
  flex: 1;
  background: var(--gradient);
  border-radius: 6px 6px 0 0;
  min-height: 4px;
  opacity: 0.85;
  transition: opacity 0.2s;
  position: relative;
}
.bars .bar:hover { opacity: 1; }
.bars-x { display: flex; gap: 10px; margin-top: 8px; }
.bars-x span { flex: 1; text-align: center; font-size: 12px; color: var(--text-muted); }

/* ---------- 文档 ---------- */
.docs-layout { display: flex; gap: 48px; padding: 40px 0 80px; }
.docs-nav {
  width: 220px;
  flex-shrink: 0;
  position: sticky;
  top: 96px;
  align-self: flex-start;
}
.docs-nav a {
  display: block;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 2px;
  border-left: 2px solid transparent;
}
.docs-nav a:hover { color: var(--primary); background: var(--bg-soft); }
.docs-nav a.active { color: var(--primary); background: var(--primary-light); border-left-color: var(--primary); font-weight: 600; }
.docs-content { flex: 1; min-width: 0; max-width: 720px; }
.docs-content h2 { font-size: 26px; font-weight: 800; margin: 40px 0 16px; padding-top: 8px; }
.docs-content h2:first-child { margin-top: 0; }
.docs-content h3 { font-size: 18px; font-weight: 700; margin: 28px 0 12px; }
.docs-content p { margin-bottom: 14px; color: var(--text-secondary); }
.docs-content ul { margin: 0 0 14px 20px; color: var(--text-secondary); }
.docs-content li { margin-bottom: 6px; }
.docs-content .code-block { margin: 12px 0 20px; }
.docs-callout {
  background: var(--primary-light);
  border: 1px solid #bfdbfe;
  border-left: 4px solid var(--primary);
  border-radius: 10px;
  padding: 14px 18px;
  font-size: 14px;
  color: var(--primary-dark);
  margin: 16px 0;
}
.docs-callout.warn { background: #fffbeb; border-color: #fde68a; border-left-color: #f59e0b; color: #92400e; }
table.param { width: 100%; border-collapse: collapse; font-size: 14px; margin: 12px 0 20px; }
table.param th { text-align: left; padding: 10px 12px; background: var(--bg-soft); border: 1px solid var(--border); font-size: 13px; }
table.param td { padding: 10px 12px; border: 1px solid var(--border); color: var(--text-secondary); vertical-align: top; }
table.param td code, .docs-content code, .code-inline {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 1px 6px;
  font-family: var(--mono);
  font-size: 13px;
  color: #be185d;
}

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: 1fr; max-width: 420px; margin: 0 auto; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .docs-layout { flex-direction: column; }
  .docs-nav { position: static; width: 100%; display: flex; flex-wrap: wrap; gap: 4px; }
  .docs-nav a { border-left: none; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .dash-side { display: none; }
  .nav-links, .nav-actions { display: none; }
  .nav-links.open, .nav-actions.open { display: flex; flex-direction: column; align-items: stretch; }
  .nav-burger { display: block; }
  .nav-inner { flex-wrap: wrap; height: auto; padding: 12px 24px; }
  .nav-inner.open { box-shadow: var(--shadow); }
  .nav-links.open { position: absolute; top: 100%; left: 0; right: 0; background: #fff; padding: 12px 24px; border-bottom: 1px solid var(--border); }
  .hero { padding: 64px 24px 56px; }
  .hero-stats { gap: 32px; }
}

@media (max-width: 640px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: 1fr; }
  .section { padding: 64px 0; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .stat-cards { grid-template-columns: 1fr; }
  .dash-main { padding: 20px; }
}
