/* ============================================================
   Nisaka API · 落地页（星空主题）
   设计北极星：深空里的控制台 —— 星空是背景，界面是唯一的光。
   ============================================================ */

:root {
  /* 深空底 */
  --bg-0: #04050b;
  --bg-1: #080b16;
  --bg-2: #0d1224;

  /* 光 */
  --teal: #2dd4bf;
  --teal-deep: #14b8a6;
  --star-blue: #7dd3fc;
  --nebula: #a78bfa;

  /* 文字 */
  --ink: #e8eefc;
  --ink-soft: #9fb0cc;
  --ink-dim: #6b7c99;

  /* 玻璃 */
  --glass: rgba(10, 15, 28, .74);
  --glass-line: rgba(255, 255, 255, .09);
  --glass-hi: rgba(255, 255, 255, .16);

  --ok: #34d399;
  --warn: #fbbf24;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --r-sm: 8px;
  --r-md: 14px;
  --r-lg: 20px;

  /* 背景图（站长提供：雪夜圣诞村，暗色版） */
  --bg-image: url("/site/assets/bg.jpg");
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background-color: var(--bg-0);   /* 兜底深色底，滚动到底也不会露白 */
}

body {
  position: relative;
  isolation: isolate;   /* 建立层叠上下文：负 z-index 的星空层才不会被 html 背景色盖住 */
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background-color: var(--bg-0);
  background-image:
    radial-gradient(1200px 700px at 78% -8%, rgba(45, 212, 191, .10), transparent 62%),
    radial-gradient(900px 600px at 12% 8%, rgba(167, 139, 250, .09), transparent 60%);
  background-repeat: no-repeat;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* 用户背景图：叠在渐变之上、内容之下 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: 20% 32%;
  opacity: .90;
  filter: saturate(1.04) brightness(.70);
  z-index: -3;
  pointer-events: none;
}

/* 压暗，保证文字可读（absolute 覆盖整页高度，避免长页下半截露浅色） */
body::after {
  content: "";
  position: absolute;
  inset: 0;
  /* 径向压暗：中间文字区更暗，四周留住场景 */
  background:
    radial-gradient(76% 66% at 50% 34%, rgba(4,5,11,.42) 0%, rgba(4,5,11,.6) 60%, rgba(4,5,11,.86) 100%),
    linear-gradient(180deg, rgba(4,5,11,.72) 0%, rgba(4,5,11,.28) 36%, rgba(4,5,11,.88) 100%);
  z-index: -2;
  pointer-events: none;
}

#stars {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  pointer-events: none;
}

.aurora {
  position: fixed;
  inset: -20% -10% auto -10%;
  height: 60vh;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(50% 60% at 30% 20%, rgba(45, 212, 191, .16), transparent 70%),
    radial-gradient(45% 55% at 72% 10%, rgba(125, 211, 252, .13), transparent 70%),
    radial-gradient(40% 50% at 55% 0%, rgba(167, 139, 250, .12), transparent 70%);
  filter: blur(30px);
  opacity: .9;
}

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 14px 32px;
  background: rgba(6, 8, 16, .72);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom: 1px solid var(--glass-line);
}

.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand-icon {
  width: 30px; height: 30px;
  border-radius: 9px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, .18);
  box-shadow: 0 0 18px rgba(125, 211, 252, .35);
}
.brand-name { font-weight: 650; letter-spacing: .02em; font-size: 15px; }
.brand-dot { color: var(--teal); }

.nav { display: flex; gap: 22px; margin-left: 8px; }
.nav a {
  color: var(--ink-soft); text-decoration: none; font-size: 14px;
  transition: color .2s ease;
}
.nav a:hover { color: var(--ink); }

.topbar-actions { margin-left: auto; display: flex; gap: 10px; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--r-sm);
  font-size: 14px; font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform .18s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  color: #04211f;
  background: linear-gradient(135deg, #5eead4, var(--teal) 55%, #22b8a8);
  box-shadow: 0 6px 24px rgba(45, 212, 191, .22);
}
.btn-primary:hover { box-shadow: 0 10px 34px rgba(45, 212, 191, .34); }
.btn-ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, .04);
  border-color: var(--glass-line);
}
.btn-ghost:hover { border-color: var(--glass-hi); background: rgba(255, 255, 255, .07); }
.btn-lg { padding: 13px 24px; font-size: 15px; border-radius: var(--r-md); }

/* ---------- 通用玻璃 ---------- */
.glass {
  background: var(--glass);
  border: 1px solid var(--glass-line);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--r-lg);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .05);
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  max-width: 1180px;
  margin: 0 auto;
  padding: 88px 40px 52px 50%;
  text-align: left;
}
/* 右侧文字区压暗，保证辨识度；左侧保持通透给人物 */
.hero::before {
  content: "";
  position: absolute;
  inset: -160px -120px 0 -60px;
  background: linear-gradient(90deg,
      rgba(4,5,11,0) 0%,
      rgba(4,5,11,.03) 30%,
      rgba(4,5,11,.10) 50%,
      rgba(4,5,11,.17) 72%,
      rgba(4,5,11,.22) 100%);
  pointer-events: none;
  z-index: -1;
}
/* hero 底部渐隐：把背景图收在首屏，下面回到纯深空 */
.hero::after {
  content: "";
  position: fixed;
  left: 0; right: 0; bottom: 0;
  height: 26vh;
  background: linear-gradient(180deg, rgba(4,5,11,0) 0%, rgba(4,5,11,.55) 45%, var(--bg-0) 100%);
  pointer-events: none;
  z-index: -1;
}

.eyebrow {
  display: inline-block;
  margin: 0 0 22px;
  padding: 6px 14px;
  font-size: 11.5px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--teal);
  border: 1px solid rgba(45, 212, 191, .28);
  border-radius: 999px;
  background: rgba(45, 212, 191, .06);
}

.hero h1 {
  text-shadow: 0 2px 18px rgba(0,0,0,.78), 0 1px 3px rgba(0,0,0,.55);
  margin: 0 0 22px;
  font-size: clamp(32px, 4.4vw, 54px);
  line-height: 1.12;
  font-weight: 680;
  letter-spacing: -.02em;
}
.grad {
  background: linear-gradient(100deg, #7dd3fc 0%, #5eead4 42%, #a78bfa 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lede {
  text-shadow: 0 1px 10px rgba(0,0,0,.8);
  max-width: 520px;
  margin-left: 0;
  text-wrap: pretty;
  margin: 0 auto 36px;
  font-size: 16.5px;
  line-height: 1.75;
  color: var(--ink-soft);
}
.lede .nw { white-space: nowrap; }
.lede code {
  font-family: var(--mono);
  font-size: 14px;
  padding: 2px 7px;
  border-radius: 6px;
  color: var(--teal);
  background: rgba(45, 212, 191, .1);
  border: 1px solid rgba(45, 212, 191, .18);
}

.cta-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- 状态条 ---------- */
.status-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px 20px;
  margin: 46px 0 0;
  padding: 18px 24px;
  max-width: 460px;
}
.status-strip .stat-live { grid-column: 1 / -1; }
.stat { display: flex; flex-direction: column; gap: 4px; min-width: 92px; }
.stat-value {
  font-family: var(--mono);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--ink);
}
.stat-value small { font-size: 12px; color: var(--ink-dim); margin-left: 2px; }
.stat-label { font-size: 12px; color: var(--ink-dim); letter-spacing: .02em; }
.stat-live { flex-direction: row; align-items: center; gap: 9px; padding-left: 18px; border-left: 1px solid var(--glass-line); }

.pulse {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--ok);
  box-shadow: 0 0 0 0 rgba(52, 211, 153, .6);
  animation: pulse 2.4s ease-out infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(52, 211, 153, .55); }
  70%  { box-shadow: 0 0 0 10px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

/* ---------- 区块 ---------- */
.section { max-width: 1080px; margin: 0 auto; padding: 56px 32px; }
.section-head { margin-bottom: 30px; }
.section-head h2 {
  margin: 0 0 8px;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 640;
  letter-spacing: -.01em;
}
.section-head p { margin: 0; color: var(--ink-soft); font-size: 15px; }

.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ---------- 卡片 ---------- */
.card {
  position: relative;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease;
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--glass-hi);
  box-shadow: 0 26px 70px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .08);
}

.card-head h3 { margin: 12px 0 4px; font-size: 19px; font-weight: 620; }
.card-sub { margin: 0; font-size: 13px; color: var(--ink-dim); }

.tag {
  display: inline-block;
  padding: 3px 10px;
  font-size: 10.5px;
  letter-spacing: .12em;
  border-radius: 999px;
  border: 1px solid;
}
.tag-free { color: var(--teal); border-color: rgba(45, 212, 191, .35); background: rgba(45, 212, 191, .08); }
.tag-svip { color: var(--star-blue); border-color: rgba(125, 211, 252, .35); background: rgba(125, 211, 252, .08); }
.tag-img  { color: var(--nebula); border-color: rgba(167, 139, 250, .35); background: rgba(167, 139, 250, .08); }

.model-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.model-list li {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 12px;
  padding: 9px 0;
  font-size: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, .05);
}
.model-list li:last-child { border-bottom: 0; }
.model-list span { font-family: var(--mono); font-size: 13px; color: var(--ink); }
.model-list em { font-style: normal; font-size: 12px; color: var(--ink-dim); }

.card-foot { margin-top: auto; padding-top: 6px; }
.card-foot a {
  color: var(--teal); text-decoration: none; font-size: 13.5px;
  transition: gap .2s ease, color .2s ease;
}
.card-foot a:hover { color: #5eead4; }

/* ---------- 表格 ---------- */
.table-card { padding: 6px 8px; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, .06);
  white-space: nowrap;
}
.table th { font-size: 12px; font-weight: 500; color: var(--ink-dim); letter-spacing: .06em; text-transform: uppercase; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: rgba(255, 255, 255, .03); }
.table td:first-child { font-family: var(--mono); color: var(--teal); }

/* ---------- 状态小卡 ---------- */
.mini {
  flex-direction: row; align-items: center; gap: 12px;
  padding: 16px 18px; font-size: 13.5px;
}
.mini span:not(.dot) { color: var(--ink-soft); }
.mini em { margin-left: auto; font-style: normal; font-size: 12.5px; color: var(--ink); }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot.ok { background: var(--ok); box-shadow: 0 0 10px rgba(52, 211, 153, .6); }
.dot.warn { background: var(--warn); box-shadow: 0 0 10px rgba(251, 191, 36, .6); }

/* ---------- 页脚 ---------- */
.footer { border-top: 1px solid var(--glass-line); margin-top: 40px; }
.footer-inner {
  max-width: 1080px; margin: 0 auto; padding: 28px 32px;
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  font-size: 13px; color: var(--ink-soft);
}
.footer .muted { color: var(--ink-dim); }
.footer a { margin-left: auto; color: var(--teal); text-decoration: none; }


/* ---------- 主推卡 ---------- */
.card-feature {
  border-color: rgba(45, 212, 191, .34);
  background: rgba(10, 20, 30, .8);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .42), inset 0 1px 0 rgba(94, 234, 212, .14);
}
.card-feature::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  background: linear-gradient(90deg, transparent, var(--teal) 30%, #5eead4 50%, var(--teal) 70%, transparent);
}
.card-feature:hover { border-color: rgba(45, 212, 191, .55); }

.ribbon {
  position: absolute;
  top: 14px; right: 16px;
  padding: 3px 9px;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .06em;
  color: #04211f;
  background: linear-gradient(135deg, #5eead4, var(--teal));
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(45, 212, 191, .3);
}

/* 模型行：名称 + 倍率 */
.model-list b {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--teal);
  letter-spacing: -.01em;
}
.model-list .list-note {
  display: block;
  margin-top: 2px;
  padding-top: 12px;
  border-top: 0;
  border-bottom: 0;
  font-size: 12px;
  color: var(--ink-dim);
  line-height: 1.6;
}

/* ---------- 价格卡底部 ---------- */
.price-foot {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 14px 14px 16px;
  border-top: 1px solid rgba(255, 255, 255, .06);
  margin-top: 2px;
}
.price-note {
  flex: 1 1 320px;
  margin: 0;
  font-size: 12.5px;
  line-height: 1.65;
  color: var(--ink-dim);
}
.price-foot .btn { padding: 9px 18px; font-size: 13px; }

/* ---------- 状态区注脚 ---------- */
.status-note {
  margin: 12px 0 0;
  font-size: 12px;
  color: var(--ink-dim);
  letter-spacing: .01em;
}

/* ---------- 页脚链接 ---------- */
.footer-links { display: flex; gap: 18px; margin-left: auto; }
.footer-links a {
  color: var(--teal);
  text-decoration: none;
  font-size: 13px;
  transition: color .2s ease;
}
.footer-links a:hover { color: #5eead4; }

/* ---------- 响应式 ---------- */
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .nav { display: none; }
  .hero { padding: 56px 20px 30px; text-align: center; }
  .hero::before { display: none; }
  .status-strip { gap: 16px; justify-content: flex-start; margin-top: 34px; padding: 16px 20px; }
  .section { padding: 44px 20px; }
  .card { padding: 20px; }
}

@media (max-width: 560px) {
  .topbar { padding: 12px 16px; gap: 12px; }
  .topbar-actions .btn-ghost { display: none; }
  /* 窄屏隐藏"适合"列，避免横向溢出 */
  .table th:nth-child(4), .table td:nth-child(4) { display: none; }
  .grid-4 { grid-template-columns: 1fr; }
  .stat-live { border-left: 0; padding-left: 0; }
  .footer-links { margin-left: 0; width: 100%; }
}

/* 降低动效偏好 */
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}

/* ============================================================
   20261115 候选修复 · 只在 candidate-20261115 生效，未上线
   ============================================================ */

/* ---------- #1 首页装饰层不再横向越界 ---------- */
/* 装饰层不再超出页面横向边界；所有宽度生效 */
.aurora {
  inset: -20% 0 auto 0;
}

.hero::before {
  inset: -160px 0 0 0;
}

/* 保持现有移动布局，不重新开启遮罩 */
@media (max-width: 900px) {
  .hero::before {
    display: none;
  }
}

/* ---------- #2 移动端恢复四个导航入口（第二行） ---------- */
@media (max-width: 900px) {
  .topbar {
    flex-wrap: wrap;
    gap: 8px 12px;
  }

  .topbar > .brand,
  .topbar-actions {
    flex-shrink: 0;
  }

  .topbar > .nav {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    order: 3;
    flex: 0 0 100%;
    gap: 0;
    margin-left: 0;
    padding-top: 4px;
    border-top: 1px solid var(--glass-line);
  }

  .topbar > .nav a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 8px 4px;
    white-space: nowrap;
  }
}

/* 避免锚点标题被 sticky 顶栏盖住 */
main > section[id] {
  scroll-margin-top: 88px;
}

@media (max-width: 900px) {
  main > section[id] {
    scroll-margin-top: 144px;
  }
}

/* ---------- 20261115 r2-1：统一 Hero 对齐轴 ---------- */
.hero .lede { margin-inline: 0; }
.hero .cta-row { justify-content: flex-start; }

@media (max-width: 900px) {
  .hero .lede { margin-inline: auto; }
  .hero .cta-row { justify-content: center; }
  .hero .status-strip { margin-inline: auto; text-align: left; }
}

/* ---------- 20261115 r2-2：双行导航去掉工具栏感 ---------- */
.topbar > .nav a.active { color: var(--teal); }

@media (max-width: 900px) {
  .topbar { row-gap: 4px; }
  .topbar > .nav { padding-top: 0; border-top: 0; }
  .topbar > .nav a {
    min-height: 44px;
    padding: 8px 4px;
    font-size: 13px;
    line-height: 20px;
    letter-spacing: .04em;
  }
}
