/* ==========================================================================
   娱乐天地 · 共享站点样式 /assets/site.css
   夜间舞台 × 工具理性：深海蓝暗底、霓虹青路径、暖橙操作点
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 132px;
}

body,
h1, h2, h3, h4, h5, h6,
p, figure, blockquote, dl, dd, ul, ol {
  margin: 0;
}

ul[class],
ol[class] {
  list-style: none;
  padding: 0;
}

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

button {
  font: inherit;
  color: inherit;
}

/* --------------------------- Design tokens ------------------------------ */
:root {
  --ink: #04131F;
  --navy: #08263A;
  --panel: #0E3A50;
  --teal-shadow: #123F4A;
  --neon: #22E0D6;
  --neon-soft: #7CF7EC;
  --amber: #FF8A3D;
  --cream: #F4EFE6;
  --stone: #A9B7C2;
  --moss: #6F8F6A;
  --clay: #B5654F;

  --line: rgba(169, 183, 194, 0.18);
  --line-strong: rgba(169, 183, 194, 0.34);
  --line-neon: rgba(34, 224, 214, 0.42);

  --font-display: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", serif;
  --font-sans: "Noto Sans SC", "HarmonyOS Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", "JetBrains Mono", ui-monospace, "SFMono-Regular", Consolas, monospace;

  --shell: 1280px;
  --gutter: clamp(16px, 3vw, 40px);
  --radius: 3px;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

/* ------------------------------ Base ------------------------------------ */
body {
  min-height: 100vh;
  background-color: var(--ink);
  background-image:
    radial-gradient(1100px 560px at 88% -8%, rgba(34, 224, 214, 0.10), transparent 62%),
    radial-gradient(900px 520px at -6% 102%, rgba(255, 138, 61, 0.07), transparent 60%),
    linear-gradient(rgba(169, 183, 194, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(169, 183, 194, 0.045) 1px, transparent 1px);
  background-size: auto, auto, 68px 68px, 68px 68px;
  color: var(--cream);
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main {
  display: block;
  position: relative;
  z-index: 1;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -0.01em;
}

h1, h2 {
  font-family: var(--font-display);
}

h3, h4, h5, h6 {
  font-family: var(--font-sans);
}

p { line-height: 1.78; }

a {
  color: var(--neon);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover { color: var(--neon-soft); }

strong { font-weight: 800; }

::selection {
  background: rgba(34, 224, 214, 0.28);
  color: #FFFFFF;
}

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

/* --------------------------- Accessibility ------------------------------ */
.skip-link {
  position: absolute;
  top: 10px;
  left: 12px;
  z-index: 200;
  padding: 10px 18px;
  border-radius: var(--radius);
  background: var(--neon);
  color: #04131F;
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform 0.22s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
  color: #04131F;
}

/* ---------------------------- Typography -------------------------------- */
.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--stone);
}

.mono {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.prose {
  max-width: 68ch;
  color: rgba(244, 239, 230, 0.86);
  font-size: 1rem;
  line-height: 1.85;
}

.prose p + p { margin-top: 1em; }

.prose h3 {
  margin: 1.8em 0 0.6em;
  font-size: 1.2rem;
  color: var(--cream);
}

/* ----------------------------- Layout ----------------------------------- */
.container {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.container--narrow { max-width: 880px; }

.stack {
  display: grid;
  gap: clamp(16px, 2.4vw, 28px);
}

.grid {
  display: grid;
  gap: clamp(14px, 2vw, 24px);
}

.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.divider {
  height: 1px;
  border: 0;
  margin: clamp(28px, 4vw, 52px) 0;
  background: linear-gradient(90deg, var(--line-strong), rgba(169, 183, 194, 0.05));
}

/* --------------------------- Section head ------------------------------- */
.sec-head {
  display: grid;
  gap: 10px;
  margin-bottom: clamp(20px, 3vw, 34px);
  max-width: 74ch;
}

.sec-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  color: var(--neon);
}

.sec-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 40px);
  font-weight: 800;
  letter-spacing: -0.012em;
  color: var(--cream);
}

.sec-desc {
  color: var(--stone);
  font-size: 0.95rem;
  max-width: 62ch;
}

/* ----------------------------- Buttons ---------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.72rem 1.15rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: transparent;
  color: var(--cream);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.25;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.22s var(--ease), color 0.22s var(--ease),
              border-color 0.22s var(--ease), transform 0.22s var(--ease);
}

.btn:hover {
  border-color: var(--neon);
  color: var(--neon-soft);
  transform: translateY(-1px);
}

.btn--accent {
  background: var(--amber);
  border-color: var(--amber);
  color: #200D02;
}

.btn--accent:hover {
  background: #FFA163;
  border-color: #FFA163;
  color: #200D02;
}

.btn--neon {
  border-color: var(--line-neon);
  color: var(--neon);
}

.btn--neon:hover {
  background: rgba(34, 224, 214, 0.12);
  color: var(--neon-soft);
}

.btn--sm {
  padding: 0.5rem 0.85rem;
  font-size: 0.8rem;
}

.btn--block {
  display: flex;
  width: 100%;
}

/* ------------------------------ Tags ------------------------------------ */
.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  border: 1px solid rgba(169, 183, 194, 0.3);
  border-radius: 2px;
  background: rgba(169, 183, 194, 0.06);
  color: var(--stone);
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  white-space: nowrap;
}

.tag--neon {
  color: var(--neon);
  border-color: var(--line-neon);
  background: rgba(34, 224, 214, 0.08);
}

.tag--moss {
  color: #9DBB97;
  border-color: rgba(111, 143, 106, 0.62);
  background: rgba(111, 143, 106, 0.16);
}

.tag--clay {
  color: #E0A595;
  border-color: rgba(181, 101, 79, 0.65);
  background: rgba(181, 101, 79, 0.16);
}

.tag--amber {
  color: var(--amber);
  border-color: rgba(255, 138, 61, 0.5);
  background: rgba(255, 138, 61, 0.1);
}

/* ------------------------ Frames / Panels / Media ------------------------ */
.frame {
  position: relative;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: rgba(8, 38, 58, 0.42);
}

.frame::before,
.frame::after {
  content: "";
  position: absolute;
  width: 11px;
  height: 11px;
  border: 1px solid var(--line-neon);
  pointer-events: none;
}

.frame::before {
  top: -1px;
  left: -1px;
  border-right: 0;
  border-bottom: 0;
}

.frame::after {
  right: -1px;
  bottom: -1px;
  border-top: 0;
  border-left: 0;
}

.panel {
  position: relative;
  padding: clamp(16px, 2.2vw, 26px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(14, 58, 80, 0.85), rgba(8, 38, 58, 0.72));
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease),
              box-shadow 0.25s var(--ease);
}

.panel:hover {
  border-color: var(--line-neon);
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(2, 10, 16, 0.5);
}

.media {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: linear-gradient(150deg, var(--panel), var(--navy) 70%, var(--teal-shadow));
}

.media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(124, 247, 236, 0.09);
}

.media--wide { aspect-ratio: 21 / 9; }
.media--tall { aspect-ratio: 4 / 5; }
.media--square { aspect-ratio: 1 / 1; }

.media--grid::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(124, 247, 236, 0.09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 247, 236, 0.09) 1px, transparent 1px);
  background-size: 34px 34px;
}

/* ---------------------------- Breadcrumbs ------------------------------- */
.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding-top: 22px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--stone);
}

.breadcrumbs a {
  color: var(--stone);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

.breadcrumbs a:hover { color: var(--neon); }

.breadcrumbs li + li::before {
  content: "/";
  margin-right: 8px;
  color: rgba(169, 183, 194, 0.45);
}

/* ================================ HEADER ================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(4, 19, 31, 0.93);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  transition: box-shadow 0.3s var(--ease), background 0.3s var(--ease);
}

.site-header::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: linear-gradient(90deg, var(--neon) 0%, rgba(34, 224, 214, 0) 46%, var(--amber) 96%);
  opacity: 0.72;
  pointer-events: none;
}

.site-header[data-scrolled] {
  background: rgba(4, 19, 31, 0.985);
  box-shadow: 0 12px 32px rgba(2, 10, 16, 0.55);
}

.scroll-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--neon), var(--neon-soft));
  opacity: 0.92;
  pointer-events: none;
}

.header-shell {
  position: relative;
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ---- 顶部刻度轨 ---- */
.header-rail {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 7px 0 6px;
  border-bottom: 1px dashed rgba(169, 183, 194, 0.16);
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(169, 183, 194, 0.72);
  white-space: nowrap;
}

.rail-mark {
  color: var(--neon);
  opacity: 0.85;
  flex: 0 0 auto;
}

.rail-rule {
  flex: 1 1 auto;
  min-width: 28px;
  height: 7px;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(169, 183, 194, 0.45) 0 1px,
    transparent 1px 9px
  );
  opacity: 0.6;
}

.rail-note {
  flex: 0 0 auto;
  color: rgba(169, 183, 194, 0.62);
}

/* ---- 主栏 ---- */
.header-bar {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 26px);
  padding: 14px 0 15px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  color: var(--cream);
  text-decoration: none;
}

.brand:hover { color: var(--cream); }

.glyph {
  width: 32px;
  height: 32px;
  flex: none;
  display: grid;
  place-items: center;
  border: 1px solid rgba(34, 224, 214, 0.6);
  background: linear-gradient(135deg, rgba(34, 224, 214, 0.2), rgba(34, 224, 214, 0));
}

.glyph::after {
  content: "";
  width: 11px;
  height: 11px;
  background: var(--neon);
  box-shadow: 0 0 14px rgba(34, 224, 214, 0.65);
}

.brand-glyph {
  width: 34px;
  height: 34px;
}

.brand-text {
  display: block;
  min-width: 0;
}

.brand-name {
  display: block;
  font-family: var(--font-display);
  font-size: 1.18rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  line-height: 1.1;
  color: var(--cream);
}

.brand-sub {
  display: block;
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.16em;
  color: var(--stone);
  white-space: nowrap;
}

/* ---- 左右分置导航 ---- */
.site-nav {
  margin-left: auto;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: clamp(4px, 1.5vw, 22px);
}

.nav-list a {
  position: relative;
  display: inline-block;
  padding: 8px 2px;
  font-family: var(--font-sans);
  font-size: 0.94rem;
  font-weight: 600;
  color: rgba(244, 239, 230, 0.78);
  text-decoration: none;
  transition: color 0.2s var(--ease);
}

.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 2px;
  height: 1px;
  background: var(--neon);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.28s var(--ease), background 0.2s var(--ease);
}

.nav-list a:hover {
  color: var(--neon-soft);
}

.nav-list a:hover::after {
  transform: scaleX(1);
}

.nav-list a[aria-current="page"] {
  color: var(--neon);
}

.nav-list a[aria-current="page"]::after {
  transform: scaleX(1);
  background: var(--amber);
  height: 2px;
}

/* ---- 工具区 ---- */
.header-tools {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
}

.tool-link {
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--stone);
  text-decoration: none;
  padding-bottom: 2px;
  border-bottom: 1px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.tool-link:hover {
  color: var(--neon);
  border-bottom-color: var(--neon);
}

/* ---- 移动导航按钮 ---- */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: transparent;
  color: var(--cream);
  font-family: var(--font-sans);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
}

.nav-toggle:hover {
  border-color: var(--neon);
  color: var(--neon-soft);
}

.nav-toggle-bars {
  position: relative;
  width: 16px;
  height: 10px;
  flex: none;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 1.5px;
  background: currentColor;
  transition: transform 0.28s var(--ease), top 0.28s var(--ease);
}

.nav-toggle-bars::before { top: 0; }
.nav-toggle-bars::after { top: 8px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before {
  top: 4px;
  transform: rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after {
  top: 4px;
  transform: rotate(-45deg);
}

.nav-foot {
  display: none;
}

.nav-foot-note {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--stone);
  margin-bottom: 12px;
}

/* ================================ FOOTER ================================= */
.site-footer {
  position: relative;
  z-index: 1;
  margin-top: clamp(64px, 10vw, 120px);
  border-top: 1px solid var(--line-strong);
  background:
    linear-gradient(180deg, rgba(8, 38, 58, 0.72) 0%, rgba(4, 19, 31, 0.98) 62%),
    var(--ink);
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: linear-gradient(90deg, var(--amber), rgba(34, 224, 214, 0.6) 42%, transparent 88%);
  pointer-events: none;
}

.footer-frame {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding: clamp(40px, 6vw, 72px) var(--gutter) 0;
}

.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr) minmax(0, 0.9fr) minmax(0, 1.35fr);
  gap: clamp(24px, 4vw, 56px);
  padding-bottom: clamp(30px, 4vw, 52px);
  border-bottom: 1px dashed rgba(169, 183, 194, 0.2);
}

.footer-glyph {
  margin-bottom: 16px;
}

.footer-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--cream);
  line-height: 1.2;
}

.footer-summary {
  margin-top: 14px;
  max-width: 36ch;
  color: var(--stone);
  font-size: 0.9rem;
  line-height: 1.85;
}

.footer-brand-cta {
  margin-top: 20px;
}

.footer-head {
  margin-bottom: 14px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--neon);
}

.footer-nav ul {
  display: grid;
  gap: 10px;
}

.footer-nav a {
  position: relative;
  display: inline-block;
  color: rgba(244, 239, 230, 0.8);
  font-size: 0.9rem;
  text-decoration: none;
  transition: color 0.2s var(--ease), transform 0.2s var(--ease);
}

.footer-nav a::before {
  content: "";
  display: inline-block;
  width: 0;
  height: 1px;
  margin-right: 0;
  vertical-align: middle;
  background: var(--neon);
  transition: width 0.24s var(--ease), margin-right 0.24s var(--ease);
}

.footer-nav a:hover {
  color: var(--neon-soft);
}

.footer-nav a:hover::before {
  width: 12px;
  margin-right: 7px;
}

.footer-contact ul {
  display: grid;
  gap: 12px;
}

.footer-contact li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  color: rgba(244, 239, 230, 0.84);
  font-size: 0.88rem;
  line-height: 1.6;
}

.footer-contact-value {
  font-family: var(--font-mono);
  font-size: 0.84rem;
  letter-spacing: 0.02em;
  word-break: break-all;
}

.footer-contact-address {
  color: var(--stone);
  font-size: 0.84rem;
  line-height: 1.7;
}

.footer-note {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: rgba(169, 183, 194, 0.82);
  font-size: 0.78rem;
  line-height: 1.8;
}

.copy-btn {
  flex: none;
  padding: 3px 8px;
  border: 1px solid rgba(34, 224, 214, 0.4);
  border-radius: 2px;
  background: transparent;
  color: var(--neon);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s var(--ease), color 0.2s var(--ease),
              border-color 0.2s var(--ease);
}

.copy-btn:hover {
  background: rgba(34, 224, 214, 0.14);
}

.copy-btn[data-copied="true"] {
  border-color: var(--amber);
  background: rgba(255, 138, 61, 0.14);
  color: var(--amber);
}

.footer-rail {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 22px;
  padding: 20px 0 26px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  color: rgba(169, 183, 194, 0.8);
}

.footer-icp { color: rgba(169, 183, 194, 0.9); }

.footer-rail-rule {
  flex: 1 1 60px;
  min-width: 40px;
  height: 6px;
  background-image: repeating-linear-gradient(
    90deg,
    rgba(169, 183, 194, 0.34) 0 1px,
    transparent 1px 8px
  );
}

.footer-copy { color: rgba(169, 183, 194, 0.7); }

.footer-top-link {
  color: var(--neon);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.footer-top-link:hover {
  color: var(--neon-soft);
  border-bottom-color: var(--neon-soft);
}

/* ============================ Reveal motion ============================== */
html[data-js="on"] [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.62s var(--ease), transform 0.62s var(--ease);
}

html[data-js="on"] [data-reveal].is-in {
  opacity: 1;
  transform: none;
}

/* ============================== Responsive =============================== */
@media (max-width: 1080px) {
  .header-tools .tool-link { display: none; }
  .footer-top {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
  }
  .footer-contact { grid-column: 1 / -1; }
}

@media (max-width: 920px) {
  html { scroll-padding-top: 96px; }

  .header-rail { display: none; }

  .header-bar {
    padding: 12px 0 13px;
    gap: 12px;
  }

  .nav-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-left: 0;
    display: block;
    background: #061A29;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 26px 52px rgba(0, 0, 0, 0.55);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: max-height 0.4s var(--ease), opacity 0.26s var(--ease),
                visibility 0.4s var(--ease);
  }

  .site-nav[data-open] {
    max-height: min(78vh, 640px);
    overflow-y: auto;
    opacity: 1;
    visibility: visible;
  }

  .nav-list {
    counter-reset: nav;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 6px 20px 4px;
  }

  .nav-list li {
    counter-increment: nav;
    border-bottom: 1px solid rgba(169, 183, 194, 0.12);
  }

  .nav-list li:last-child { border-bottom: 0; }

  .nav-list a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 2px;
    font-size: 1.02rem;
    color: rgba(244, 239, 230, 0.86);
  }

  .nav-list a::before {
    content: "0" counter(nav);
    font-family: var(--font-mono);
    font-size: 0.66rem;
    letter-spacing: 0.1em;
    color: var(--neon);
    opacity: 0.8;
  }

  .nav-list a::after { display: none; }

  .nav-list a[aria-current="page"] {
    color: var(--neon-soft);
  }

  .nav-foot {
    display: block;
    padding: 16px 20px 22px;
    border-top: 1px solid rgba(169, 183, 194, 0.12);
  }

  .footer-top {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 30px 28px;
  }

  .footer-brand { grid-column: 1 / -1; }
  .footer-contact { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .header-tools { display: none; }
  .brand-sub { display: none; }
  .brand-name { font-size: 1.08rem; }
}

@media (max-width: 560px) {
  html { scroll-padding-top: 84px; }

  .grid--2,
  .grid--3,
  .grid--4 { grid-template-columns: 1fr; }

  .footer-top { grid-template-columns: 1fr; }

  .footer-rail {
    gap: 8px 16px;
    font-size: 0.66rem;
  }

  .footer-rail-rule { flex: 1 1 100%; order: 3; }
  .footer-top-link { order: 4; }
  .sec-title { font-size: clamp(22px, 6vw, 30px); }
}

/* ============================ Reduced motion ============================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  html[data-js="on"] [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  .panel:hover,
  .btn:hover {
    transform: none;
  }
}
