/* ============================================================
   TEMPLATE 14 — Deep Orbit
   靛紫深空+电光蓝,未来 OS 窗口界面感,宽体 display。
   字体:Unbounded(display)+ Inter Tight(body)。
   适用:AI 助理 / 效率工具 / 未来感 SaaS niche。
   ============================================================ */

:root {
  --bg: #0b0716;
  --panel: #130d24;
  --panel-2: #1a1230;
  --line: #2c2150;
  --line-bright: #453473;
  --ink: #edecfb;
  --muted: #a89ec9;
  --faint: #7a6f9e;
  --blue: #4f7cff;
  --blue-dim: #3355d4;
  --blue-soft: rgba(79, 124, 255, 0.12);
  --silver: #c9d2f5;
  --font-head: "Unbounded", "Segoe UI", sans-serif;
  --font-body: "Inter Tight", "Inter", -apple-system, sans-serif;
  --font-mono: "Inter Tight", monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-padding-top: 84px; }
body {
  font-family: var(--font-body); background:
    radial-gradient(1100px 500px at 15% -10%, rgba(79, 124, 255, 0.12), transparent),
    radial-gradient(900px 500px at 95% 0%, rgba(124, 58, 237, 0.08), transparent),
    var(--bg);
  color: var(--ink); line-height: 1.68; font-size: 16.5px; -webkit-font-smoothing: antialiased;
}
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--silver); }
h1, h2, h3 { font-family: var(--font-head); font-weight: 500; line-height: 1.22; letter-spacing: -0.01em; text-wrap: balance; }
h1 { font-size: clamp(1.7rem, 3.9vw, 2.7rem); }
h2 { font-size: 1.3rem; letter-spacing: 0.02em; }
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 780px; }

/* ---------- 顶栏:OS 菜单栏 ---------- */
.topbar { border-bottom: 1px solid var(--line); background: rgba(11, 7, 22, 0.88); backdrop-filter: blur(12px); }
.topbar-inner { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; }
.brand { font-family: var(--font-head); font-size: 0.95rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink); }
.brand .sat { color: var(--blue); }
.topnav { display: flex; gap: 8px; font-size: 0.85rem; }
.topnav a { color: var(--muted); padding: 6px 14px; border-radius: 8px; border: 1px solid transparent; }
.topnav a:hover { color: var(--ink); border-color: var(--line-bright); background: var(--panel); }
@media (max-width: 720px) { .topnav { display: none; } }

/* ---------- Hero:OS 窗口 ---------- */
.hero { padding: 56px 0 48px; }
.window { border: 1px solid var(--line-bright); border-radius: 16px; background: var(--panel); overflow: hidden; box-shadow: 0 40px 90px -40px rgba(79, 124, 255, 0.3); }
.win-bar { display: flex; align-items: center; gap: 8px; padding: 12px 18px; border-bottom: 1px solid var(--line); background: var(--panel-2); }
.win-bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--line-bright); }
.win-bar i:first-child { background: var(--blue); }
.win-title { margin-left: 10px; font-family: var(--font-mono); font-size: 0.74rem; color: var(--faint); letter-spacing: 0.08em; }
.win-body { padding: 40px 44px 44px; }
.hero h1 .lit { color: var(--blue); }
.hero .lede { color: var(--muted); max-width: 60ch; font-size: 1.08rem; margin-top: 16px; }
.dock { margin-top: 26px; display: flex; flex-wrap: wrap; gap: 10px; }
.dock-item { font-family: var(--font-mono); font-size: 0.76rem; color: var(--muted); border: 1px solid var(--line); background: var(--panel-2); padding: 7px 14px; border-radius: 10px; }
.dock-item b { color: var(--blue); font-weight: 600; }

/* ---------- 排名:OS 列表行 ---------- */
.launcher { padding: 34px 0 44px; display: grid; gap: 14px; }
.orb-card {
  display: grid; grid-template-columns: 88px 1fr 200px; align-items: center;
  border: 1px solid var(--line); border-radius: 14px; background: var(--panel);
  transition: border-color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}
.orb-card:hover { border-color: var(--blue-dim); transform: translateY(-2px); box-shadow: 0 22px 50px -24px rgba(79, 124, 255, 0.45); }
@media (max-width: 860px) { .orb-card { grid-template-columns: 64px 1fr; } .orb-card .o-readout { grid-column: 2; border-left: 0; border-top: 1px solid var(--line); } }
.o-orbit { display: grid; place-items: center; }
.o-ring {
  width: 46px; height: 46px; border-radius: 50%; border: 2px solid var(--line-bright);
  display: grid; place-items: center; font-family: var(--font-head); font-size: 0.85rem; color: var(--muted);
  position: relative;
}
.orb-card:first-child .o-ring { border-color: var(--blue); color: var(--blue); box-shadow: 0 0 18px rgba(79, 124, 255, 0.45); }
.o-ring::after { content: ""; position: absolute; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); top: -4px; right: 4px; }
.orb-card:hover .o-ring::after { background: var(--silver); }
.o-body { padding: 20px 24px; }
.o-body h3 { font-size: 1.15rem; margin-bottom: 7px; }
.o-body h3 .badge { font-family: var(--font-body); font-size: 0.68rem; font-weight: 600; color: var(--blue); background: var(--blue-soft); border: 1px solid var(--blue-dim); padding: 3px 11px; border-radius: 999px; margin-left: 10px; vertical-align: 2px; }
.o-body p { color: var(--muted); font-size: 0.95rem; }
.o-readout { border-left: 1px solid var(--line); padding: 18px 22px; font-family: var(--font-mono); display: flex; flex-direction: column; gap: 7px; justify-content: center; }
.rr { display: flex; justify-content: space-between; font-size: 0.75rem; color: var(--muted); }
.rr b { color: var(--ink); font-weight: 500; }
.o-score { font-family: var(--font-head); font-size: 1.8rem; color: var(--blue); text-align: right; line-height: 1.2; position: relative; display: inline-block; margin-bottom: 8px; margin-left: auto; }
.o-score small { display: block; font-family: var(--font-body); font-size: 0.62rem; color: var(--faint); letter-spacing: 0.16em; text-transform: uppercase; }
.o-score::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: var(--blue);
  transform: scaleX(0); transform-origin: right; transition: transform 0.7s cubic-bezier(0.22,1,0.36,1) 0.35s; }
.in .o-score::after { transform: scaleX(1); }

/* ---------- 表格 ---------- */
.compare-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 0.92rem; margin: 24px 0; font-variant-numeric: tabular-nums; }
.compare-table th, .compare-table td { border-bottom: 1px solid var(--line); padding: 12px 15px; text-align: left; }
.compare-table th { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--blue); background: var(--blue-soft); }
.compare-table th:first-child { border-radius: 10px 0 0 0; }
.compare-table th:last-child { border-radius: 0 10px 0 0; }
.compare-table td:first-child { color: var(--muted); }
@media (max-width: 640px) { .compare-table { display: block; overflow-x: auto; } .compare-table tbody { display: table; width: 100%; min-width: 480px; } }

/* ---------- 正文 ---------- */
.prose { padding: 46px 0 64px; }
.prose h2 { margin: 38px 0 14px; }
.prose p { margin-bottom: 16px; color: #cfc9e8; }
.sysmsg { border: 1px solid var(--blue-dim); background: var(--blue-soft); border-radius: 12px; padding: 18px 22px; margin: 26px 0; }
.sysmsg .s-label { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--blue); margin-bottom: 8px; }

/* ---------- 页脚 ---------- */
.footer { border-top: 1px solid var(--line); margin-top: 48px; font-size: 0.86rem; }
.footer-inner { padding: 32px 0; display: grid; gap: 12px; color: var(--muted); }
.related-note { font-size: 0.76rem; color: var(--faint); border-top: 1px solid var(--line); padding-top: 12px; }

/* ---- 微交互/无障碍/动效 ---- */
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
::selection { background: rgba(79, 124, 255, 0.3); }
a { text-underline-offset: 3px; }
.back-top { position: fixed; right: 18px; bottom: 18px; z-index: 30; width: 42px; height: 42px; border-radius: 12px;
  display: grid; place-items: center; background: var(--blue); color: #fff; font-size: 1.05rem;
  opacity: 0; pointer-events: none; transition: opacity 0.25s ease; }
.skip-link { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--blue); color: #fff; padding: 10px 18px; font-weight: 600; }
.skip-link:focus { left: 8px; }
[data-animate] { opacity: 0; transform: translateY(14px); transition: opacity 0.65s cubic-bezier(0.22,1,0.36,1), transform 0.65s cubic-bezier(0.22,1,0.36,1); transition-delay: inherit; will-change: opacity, transform; }
[data-animate].in { opacity: 1; transform: none; }
.topbar.scrolled { box-shadow: 0 10px 40px -14px rgba(79, 124, 255, 0.35); }
.topbar { transition: box-shadow 0.25s ease; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  [data-animate] { opacity: 1; transform: none; transition: none; }
}

/* R1 typography features */
body { font-feature-settings: "kern" 1, "liga" 1, "calt" 1; -webkit-tap-highlight-color: transparent; }

/* R2 editorial measure */
.prose p { text-wrap: pretty; orphans: 3; widows: 3; }
.prose { hyphens: auto; }

/* R5 hover inner response */
.orb-card:hover .o-ring { transform: scale(1.08); } .o-ring { transition: transform 0.25s ease; }

/* R6 prose link underline grow */
.prose p a {
  background: linear-gradient(currentColor, currentColor) bottom left / 0% 1px no-repeat;
  transition: background-size 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  padding-bottom: 2px;
}
.prose p a:hover { background-size: 100% 1px; }

/* R7 themed scrollbar */
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #4f7cff55; border-radius: 5px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #4f7cff; border: 2px solid transparent; background-clip: content-box; }

/* R8 touch feedback */
.orb-card:active { transform: scale(0.995); }

/* R9 back-top smooth elevator */
.back-top { transform: translateY(10px); transition: opacity 0.25s ease, transform 0.3s cubic-bezier(0.22, 1, 0.36, 1); }
.back-top[style*="opacity: 1"], .back-top:hover { transform: translateY(0); }
.back-top:active { transform: translateY(2px); }

/* R1 hero orbital decoration */
.win-body { position: relative; overflow: hidden; }
.win-body::after {
  content: ""; position: absolute; right: -140px; top: 50%;
  width: 380px; height: 380px; transform: translateY(-50%);
  border-radius: 50%;
  border: 1px solid rgba(79, 124, 255, 0.35);
  box-shadow: 0 0 0 60px rgba(79, 124, 255, 0.05), 0 0 0 120px rgba(79, 124, 255, 0.03), inset 0 0 60px rgba(79, 124, 255, 0.15);
  pointer-events: none;
}
.win-body::before {
  content: ""; position: absolute; right: 22px; top: 26%;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--blue); box-shadow: 0 0 16px rgba(79, 124, 255, 0.8);
  animation: satdrift 14s ease-in-out infinite alternate;
  pointer-events: none; z-index: 1;
}
@keyframes satdrift { to { transform: translate(-46px, 120px); } }
@media (max-width: 1100px) { .win-body::after, .win-body::before { display: none; } }
@media (prefers-reduced-motion: reduce) { .win-body::before { animation: none; } }

/* R2 metric label alignment */
.rr span { min-width: 84px; }

/* R3 footer two-column */
@media (min-width: 860px) {
  .footer-inner { grid-template-columns: 1fr auto; align-items: start; }
  .footer-inner > div:first-child { order: 1; }
  .related-note { order: 2; max-width: 56ch; border-top: 0; padding-top: 0; text-align: right; }
}

/* R4 current page nav state */
.topnav a[aria-current='page'] { border-color: var(--line-bright); background: var(--panel); color: var(--ink); }
