/* ==========================================================================
   PA視訊 · 共享站点样式 /assets/site.css
   1. Reset  2. Tokens  3. Typography  4. Layout  5. Components
   6. Header  7. Footer  8. Responsive  9. Reduced motion
   ========================================================================== */

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

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

body {
  margin: 0;
  min-height: 100vh;
  background-color: #071A2F;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

input, select, textarea { font: inherit; }

a { color: inherit; }

[hidden] { display: none !important; }

/* ---------- 2. Tokens ---------- */
:root {
  /* 色彩体系 */
  --ink: #071A2F;
  --ink-2: #0E2A47;
  --ink-3: #14385C;
  --paper: #FAF7EF;
  --orange: #FF6B2C;
  --aurora: #35E0D0;
  --amber: #F6B84A;
  --gray: #8FA3B8;
  --black: #101820;
  --teal: #5B7F8C;

  --line: rgba(143, 163, 184, 0.26);
  --line-strong: rgba(143, 163, 184, 0.48);
  --line-paper: rgba(16, 24, 32, 0.18);

  /* 硬阴影（现代粗野主义） */
  --shadow-hard: 6px 8px 0 var(--black);
  --shadow-hard-sm: 3px 4px 0 var(--black);
  --shadow-hard-dark: 6px 8px 0 rgba(0, 0, 0, 0.55);

  /* 字体 */
  --font-display: "Barlow Condensed", "Noto Sans SC", "Source Han Sans SC",
    "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "Roboto Mono", ui-monospace, SFMono-Regular,
    Menlo, Consolas, "Noto Sans Mono", monospace;

  /* 尺寸 */
  --wrap: 1240px;
  --gutter: 24px;
  --header-h: 76px;

  /* 状态 */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 3. Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: 0.005em;
  color: inherit;
  text-wrap: balance;
}

p { text-wrap: pretty; }

.display-1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(42px, 7.4vw, 92px);
  line-height: 0.98;
  letter-spacing: -0.01em;
}

.display-2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(32px, 4.8vw, 60px);
  line-height: 1.02;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(26px, 3vw, 40px);
  line-height: 1.12;
}

.lead {
  font-size: clamp(17px, 1.4vw, 19px);
  line-height: 1.72;
  color: #C9D6E2;
  max-width: 34em;
}

.prose {
  max-width: 68ch;
  line-height: 1.78;
  color: #D7E2EC;
}

.prose > * + * { margin-top: 1.1em; }

.prose h2, .prose h3 { margin-top: 1.8em; }

.prose a {
  color: var(--aurora);
  text-decoration: none;
  border-bottom: 1px solid rgba(53, 224, 208, 0.45);
}

.prose a:hover { border-bottom-color: var(--aurora); }

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--aurora);
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--orange);
  flex: none;
}

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

.section { padding-block: clamp(48px, 7vw, 88px); }

.section--ink { background: var(--ink-2); }

.section--paper {
  background: var(--paper);
  color: var(--black);
}

.section--paper .lead { color: #3B4756; }
.section--paper .prose { color: #101820; }
.section--paper .eyebrow { color: #0B6E66; }
.section--paper .eyebrow::before { background: var(--orange); }

.grid {
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1fr);
}

.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: 2px;
  border: 0;
  margin: 0;
  background: var(--line);
}

/* 图片容器基类：页面阶段放置 img / picture 即可 */
.media-frame {
  position: relative;
  display: block;
  margin: 0;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background:
    repeating-linear-gradient(135deg, rgba(143, 163, 184, 0.14) 0 2px, transparent 2px 12px),
    var(--ink-3);
  border: 2px solid var(--black);
  box-shadow: var(--shadow-hard);
}

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

.media-frame > img,
.media-frame > picture > img,
.media-frame > video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.section--paper .media-frame {
  border-color: var(--black);
  box-shadow: var(--shadow-hard);
}

.media-frame__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 8px 12px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  max-width: 100%;
}

/* ---------- 5. Components ---------- */
.skip-link {
  position: fixed;
  top: -96px;
  left: 16px;
  z-index: 400;
  padding: 12px 22px;
  background: var(--orange);
  color: var(--ink);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  border: 2px solid var(--black);
  border-radius: 10px;
  box-shadow: var(--shadow-hard-sm);
  transition: top 0.2s var(--ease);
}

.skip-link:focus { top: 16px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 13px 24px;
  border: 2px solid var(--black);
  border-radius: 999px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-hard-sm);
  transition: transform 0.16s var(--ease), box-shadow 0.16s var(--ease),
    background-color 0.16s var(--ease), color 0.16s var(--ease),
    border-color 0.16s var(--ease);
}

.btn:hover {
  transform: translate(-2px, -2px);
  box-shadow: 5px 6px 0 var(--black);
}

.btn:active {
  transform: translate(1px, 1px);
  box-shadow: 1px 2px 0 var(--black);
}

.btn-primary {
  background: var(--orange);
  color: var(--ink);
}

.btn-primary:hover { background: #FF7F47; }

.btn-secondary {
  background: transparent;
  color: var(--paper);
  border-color: var(--paper);
  box-shadow: 3px 4px 0 rgba(250, 247, 239, 0.28);
}

.btn-secondary:hover {
  background: var(--paper);
  color: var(--ink);
  box-shadow: 5px 6px 0 rgba(250, 247, 239, 0.4);
}

.btn-ghost {
  background: transparent;
  color: var(--aurora);
  border-color: var(--aurora);
  box-shadow: 3px 4px 0 rgba(53, 224, 208, 0.24);
}

.btn-ghost:hover {
  background: var(--aurora);
  color: var(--ink);
  box-shadow: 5px 6px 0 rgba(53, 224, 208, 0.38);
}

.card {
  background: var(--ink-2);
  border: 2px solid var(--line);
  border-radius: 16px;
  padding: clamp(18px, 2.2vw, 26px);
  box-shadow: var(--shadow-hard-dark);
  transition: border-color 0.18s var(--ease), transform 0.18s var(--ease);
}

.card:hover {
  border-color: var(--aurora);
  transform: translateY(-3px);
}

.section--paper .card {
  background: #FFFFFF;
  border-color: var(--line-paper);
  color: var(--black);
  box-shadow: var(--shadow-hard);
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--amber);
  white-space: nowrap;
}

.tag--aurora { color: var(--aurora); }
.tag--orange { color: var(--orange); }

.breadcrumbs {
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 20px var(--gutter) 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--gray);
}

.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.breadcrumbs li + li::before {
  content: "/";
  margin-right: 8px;
  color: rgba(143, 163, 184, 0.6);
}

.breadcrumbs a {
  color: var(--gray);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.16s var(--ease), border-color 0.16s var(--ease);
}

.breadcrumbs a:hover {
  color: var(--aurora);
  border-bottom-color: var(--aurora);
}

.breadcrumbs [aria-current="page"] { color: var(--paper); }

/* 全局焦点态 */
:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- 6. Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  --progress: 0;
  background: linear-gradient(180deg, #071A2F 0%, #08203A 100%);
  border-bottom: 2px solid var(--line);
}

.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  transform: scaleX(var(--progress));
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--orange), var(--amber), var(--aurora));
  pointer-events: none;
}

.header-shell {
  position: relative;
  z-index: 140;
  display: flex;
  align-items: center;
  gap: 18px;
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: 14px var(--gutter);
  transition: padding 0.26s var(--ease);
}

.site-header[data-compact] .header-shell {
  padding-top: 7px;
  padding-bottom: 7px;
}

/* 品牌岛 */
.brand {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 0 0 auto;
  text-decoration: none;
  color: var(--paper);
}

.brand-mark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 25px;
  line-height: 1;
  letter-spacing: 0.01em;
  transition: color 0.16s var(--ease);
}

.brand-mark::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: 5px;
  vertical-align: super;
  background: var(--orange);
}

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

.brand-descriptor {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
  line-height: 1.3;
}

/* 悬浮胶囊导航 */
.nav-capsule {
  margin-left: auto;
  padding: 5px;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: rgba(250, 247, 239, 0.055);
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav-link {
  display: block;
  padding: 8px 15px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  color: #C6D5E3;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.16s var(--ease), color 0.16s var(--ease),
    box-shadow 0.16s var(--ease);
}

.nav-link:hover {
  background: var(--aurora);
  color: var(--ink);
}

.nav-link[aria-current="page"] {
  background: var(--paper);
  color: var(--ink);
  font-weight: 700;
  box-shadow: inset 0 0 0 2px var(--aurora);
}

/* 右侧工具组 */
.header-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 2px solid var(--line);
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 500;
  color: #C6D5E3;
  transition: border-color 0.16s var(--ease), color 0.16s var(--ease),
    background-color 0.16s var(--ease);
}

.tool-btn:hover,
.tool-btn[aria-expanded="true"] {
  border-color: var(--aurora);
  color: var(--aurora);
  background: rgba(53, 224, 208, 0.08);
}

.tool-icon {
  position: relative;
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-radius: 4px;
  flex: none;
}

.tool-icon::after {
  content: "";
  position: absolute;
  right: -5px;
  bottom: -5px;
  width: 6px;
  height: 2px;
  background: currentColor;
  transform: rotate(45deg);
}

.version-chip {
  display: inline-flex;
  align-items: center;
  padding: 7px 12px;
  border: 2px solid var(--black);
  border-radius: 8px;
  background: var(--amber);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  font-weight: 600;
  box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.55);
  transition: transform 0.16s var(--ease), box-shadow 0.16s var(--ease),
    background-color 0.16s var(--ease), color 0.16s var(--ease);
}

.version-chip:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 rgba(0, 0, 0, 0.6);
  background: var(--aurora);
}

.version-chip[data-copied] {
  background: var(--aurora);
  color: var(--ink);
  border-color: var(--ink);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 9px 15px;
  border: 2px solid var(--orange);
  border-radius: 999px;
  color: var(--orange);
  font-size: 13.5px;
  font-weight: 600;
  transition: background-color 0.16s var(--ease), color 0.16s var(--ease);
}

.nav-toggle:hover,
.nav-toggle[aria-expanded="true"] {
  background: var(--orange);
  color: var(--ink);
}

.nav-toggle-bars {
  position: relative;
  width: 16px;
  height: 2px;
  background: currentColor;
  flex: none;
  transition: background-color 0.16s var(--ease);
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 16px;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s var(--ease);
}

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

/* 栏目索引浮层 */
.index-panel {
  border-top: 2px solid var(--line);
  background: var(--ink-2);
  padding: 20px var(--gutter) 26px;
}

.index-panel-inner {
  display: grid;
  gap: 12px;
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
}

.index-title {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--amber);
}

.index-label {
  font-size: 13px;
  color: var(--gray);
}

.index-input {
  width: 100%;
  max-width: 420px;
  padding: 11px 16px;
  border: 2px solid var(--line-strong);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 14px;
  transition: border-color 0.16s var(--ease), box-shadow 0.16s var(--ease);
}

.index-input::placeholder { color: rgba(143, 163, 184, 0.85); }

.index-input:focus {
  border-color: var(--aurora);
  box-shadow: 0 0 0 3px rgba(53, 224, 208, 0.22);
  outline: none;
}

.index-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 10px;
}

.index-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border: 2px solid var(--line);
  border-radius: 10px;
  color: var(--paper);
  font-size: 14px;
  text-decoration: none;
  transition: border-color 0.16s var(--ease), color 0.16s var(--ease),
    background-color 0.16s var(--ease), transform 0.16s var(--ease);
}

.index-item:hover {
  border-color: var(--aurora);
  color: var(--aurora);
  background: rgba(53, 224, 208, 0.07);
  transform: translateY(-2px);
}

.index-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--amber);
}

.index-empty {
  font-size: 13.5px;
  color: var(--gray);
}

/* ---------- 7. Footer ---------- */
.site-footer {
  position: relative;
  overflow: hidden;
  background: var(--ink-2);
  color: var(--paper);
  border-top: 2px solid var(--ink);
}

.site-footer::before {
  content: "";
  display: block;
  height: 6px;
  background: linear-gradient(
    90deg,
    var(--orange) 0%,
    var(--orange) 20%,
    var(--amber) 20%,
    var(--amber) 32%,
    var(--aurora) 32%,
    var(--aurora) 44%,
    var(--ink-3) 44%,
    var(--ink-3) 100%
  );
}

.site-footer::after {
  content: "";
  position: absolute;
  top: 6px;
  left: 0;
  width: 88px;
  height: 2px;
  background: var(--aurora);
  box-shadow: 0 0 12px rgba(53, 224, 208, 0.8);
  animation: footerScan 9s linear infinite;
  pointer-events: none;
}

@keyframes footerScan {
  from { transform: translateX(-88px); }
  to { transform: translateX(100%); }
}

.footer-inner {
  position: relative;
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: clamp(40px, 5vw, 60px) var(--gutter) 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 36px 24px;
}

.footer-brand { grid-column: span 4; }

.footer-mark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(32px, 3.4vw, 44px);
  line-height: 1;
  letter-spacing: 0.01em;
}

.footer-mark::after {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-left: 6px;
  vertical-align: super;
  background: var(--orange);
}

.footer-descriptor {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gray);
}

.footer-line {
  margin-top: 16px;
  font-size: 14.5px;
  line-height: 1.7;
  color: #B9CAD9;
  max-width: 22em;
}

.footer-quick { grid-column: span 3; }

.footer-contact { grid-column: span 5; }

.footer-heading {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 14px;
}

.quick-list {
  display: grid;
  gap: 8px;
}

.quick-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  font-size: 13.5px;
  color: #D5E1EC;
  text-decoration: none;
  transition: border-color 0.16s var(--ease), color 0.16s var(--ease),
    background-color 0.16s var(--ease);
}

.quick-link:hover {
  border-color: var(--amber);
  color: var(--amber);
  background: rgba(246, 184, 74, 0.08);
}

.quick-num {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--amber);
}

.contact-list {
  display: grid;
  gap: 10px;
}

.contact-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 10px;
  align-items: baseline;
  font-size: 14px;
  color: #D5E1EC;
}

.contact-row dt {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--gray);
}

.contact-row dd { word-break: break-word; }

.contact-row .mono { color: var(--aurora); }

.contact-note {
  margin-top: 14px;
  font-size: 12.5px;
  line-height: 1.72;
  color: var(--gray);
  max-width: 34em;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px 24px;
  margin-top: 38px;
  padding-top: 30px;
  border-top: 2px solid var(--line);
}

.footer-list {
  display: grid;
  gap: 9px;
}

.footer-link {
  font-size: 14px;
  color: #C6D5E3;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.16s var(--ease), border-color 0.16s var(--ease);
}

.footer-link:hover {
  color: var(--aurora);
  border-bottom-color: var(--aurora);
}

.version-chip--footer {
  display: inline-flex;
  margin-top: 2px;
}

.footer-version-note {
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.7;
  color: var(--gray);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  margin-top: 34px;
  padding-top: 20px;
  border-top: 2px solid var(--line);
}

.footer-legal {
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--gray);
  line-height: 1.7;
}

.footer-legal--mono { color: rgba(143, 163, 184, 0.72); }

/* ---------- 8. Responsive ---------- */
@media (max-width: 1100px) {
  .brand-descriptor { display: none; }
  .nav-link { padding: 8px 11px; font-size: 13.5px; }
  .tool-btn .tool-label { display: none; }
  .tool-btn { padding: 9px 11px; }
}

@media (max-width: 1024px) {
  .footer-brand { grid-column: span 12; }
  .footer-quick { grid-column: span 5; }
  .footer-contact { grid-column: span 7; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

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

  .header-shell { padding: 12px var(--gutter); gap: 12px; }
  .site-header[data-compact] .header-shell {
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .brand-mark { font-size: 22px; }

  .nav-toggle { display: inline-flex; }

  .nav-capsule {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    margin: 0;
    padding: 96px var(--gutter) 40px;
    border: 0;
    border-radius: 0;
    background: var(--ink);
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-10px);
    transition: opacity 0.22s var(--ease), transform 0.22s var(--ease),
      visibility 0.22s;
    z-index: 130;
  }

  .nav-capsule[data-open] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .nav-link {
    padding: 16px 18px;
    font-size: 19px;
    font-weight: 600;
    color: var(--paper);
    background: var(--ink-2);
    border: 2px solid var(--line);
    border-radius: 12px;
  }

  .nav-link[aria-current="page"] {
    background: var(--paper);
    color: var(--ink);
    border-color: var(--paper);
    box-shadow: inset 0 0 0 3px var(--aurora);
  }

  .index-list { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}

@media (max-width: 720px) {
  :root { --gutter: 18px; }

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

  .footer-quick,
  .footer-contact { grid-column: span 12; }
  .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .media-frame { box-shadow: 4px 5px 0 var(--black); }

  .breadcrumbs { padding-top: 16px; }
}

@media (max-width: 560px) {
  .version-chip { display: none; }
  .footer-bottom { flex-direction: column; align-items: flex-start; }
  .contact-row { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .contact-row dt { margin-top: 6px; }
  .footer-links { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 9. 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;
    scroll-behavior: auto !important;
  }

  .site-footer::after { display: none; }

  .btn:hover,
  .card:hover,
  .index-item:hover,
  .version-chip:hover {
    transform: none;
  }
}
