/* ============================================================
   澳门金手指官网 · 共享站点样式 /assets/site.css
   深墨黑 + 暗金 + 冷青 · 精密网格 · 锐利直角
   ============================================================ */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

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

ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }

/* ---------- 2. Tokens ---------- */
:root {
  --ink: #0B0C0E;
  --panel: #14161A;
  --gold: #C9A227;
  --gold-hi: #E8C04A;
  --amber: #D9772B;
  --cyan: #4FB6C6;
  --mist: #A7ADB5;
  --paper: #F2EFE6;
  --teal: #1C2A2E;
  --line: #3A3F46;
  --line-soft: rgba(58, 63, 70, 0.55);
  --dim: #6C737C;

  --rail-w: 88px;
  --bar-h: 64px;
  --edge: clamp(20px, 4vw, 64px);

  --font-head: "Noto Sans SC Heavy", "Source Han Sans SC Heavy", "Microsoft YaHei Bold", "PingFang SC", sans-serif;
  --font-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", serif;
  --font-body: "Noto Sans SC Regular", "Source Han Sans SC Regular", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --t-fast: 180ms;
  --t-mid: 240ms;
  --t-slow: 280ms;
}

/* ---------- 3. Base ---------- */
body {
  min-height: 100%;
  padding-top: var(--bar-h);
  background-color: var(--ink);
  background-image:
    radial-gradient(120% 90% at 92% -12%, rgba(201, 162, 39, 0.10), transparent 62%),
    radial-gradient(90% 70% at -6% 104%, rgba(79, 182, 198, 0.07), transparent 58%),
    linear-gradient(to right, rgba(58, 63, 70, 0.30) 1px, transparent 1px);
  background-size: auto, auto, var(--rail-w) 100%;
  background-repeat: no-repeat, no-repeat, repeat;
  color: var(--paper);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--gold); color: var(--ink); }

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  font-weight: 900;
  color: var(--paper);
  line-height: 1.15;
  letter-spacing: 0.01em;
}

h1 { font-size: clamp(2.5rem, 5.2vw, 4rem); line-height: 1.05; }
h2 { font-size: clamp(1.875rem, 3.2vw, 2.75rem); }
h3 { font-size: clamp(1.25rem, 1.8vw, 1.5rem); }
h4 { font-size: clamp(1.0625rem, 1.4vw, 1.125rem); line-height: 1.35; }

p { max-width: 72ch; }

a {
  color: var(--gold-hi);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color var(--t-fast) var(--ease);
}
a:hover { color: var(--paper); }

strong { color: var(--paper); font-weight: 700; }

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  box-shadow: 0 0 0 4px rgba(242, 239, 230, 0.18);
}

#main-content { display: block; scroll-margin-top: calc(var(--bar-h) + 16px); }

/* ---------- 4. Layout helpers ---------- */
.container {
  width: 100%;
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 var(--edge);
}
.container--wide { max-width: 1560px; }

.prose { max-width: 68ch; }
.prose p + p { margin-top: 1em; }

.grid { display: grid; gap: clamp(16px, 2.4vw, 32px); }
.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)); }

.mono {
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}
.text-mist { color: var(--mist); }
.text-cyan { color: var(--cyan); }
.text-gold { color: var(--gold-hi); }

/* ---------- 5. Typography accents ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--gold);
  flex: none;
}

.section-head {
  display: grid;
  gap: 12px;
  margin-bottom: 32px;
}

.tick-rule {
  height: 10px;
  border-bottom: 1px solid var(--line);
  background-image: repeating-linear-gradient(90deg, var(--line) 0 1px, transparent 1px 12px);
  background-repeat: repeat-x;
  background-position: bottom left;
  background-size: 12px 6px;
  opacity: 0.9;
}

/* ---------- 6. Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 26px;
  border: 1px solid var(--gold);
  border-radius: 0;
  background: transparent;
  color: var(--gold-hi);
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color var(--t-fast) var(--ease),
    border-color var(--t-fast) var(--ease),
    color var(--t-fast) var(--ease),
    transform var(--t-fast) var(--ease);
}
.btn:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--ink);
  transform: translateY(-2px);
}
.btn--solid { background: var(--gold); color: var(--ink); }
.btn--solid:hover { background: var(--gold-hi); border-color: var(--gold-hi); }
.btn--ghost { border-color: var(--line); color: var(--paper); }
.btn--ghost:hover {
  background: var(--panel);
  border-color: var(--gold);
  color: var(--gold-hi);
}
.btn--amber { border-color: var(--amber); color: var(--amber); }
.btn--amber:hover { background: var(--amber); border-color: var(--amber); color: var(--ink); }

/* ---------- 7. Breadcrumb / tags / panel ---------- */
.breadcrumb { padding: 28px 0 0; }
.breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--mist);
  max-width: none;
}
.breadcrumb__list li { display: flex; align-items: center; }
.breadcrumb__list li + li::before {
  content: "/";
  margin-right: 8px;
  color: var(--line);
}
.breadcrumb a { color: var(--mist); text-decoration: none; }
.breadcrumb a:hover { color: var(--gold-hi); }
.breadcrumb [aria-current="page"] { color: var(--paper); }

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--mist);
  white-space: nowrap;
}
.tag--gold { border-color: rgba(201, 162, 39, 0.55); color: var(--gold-hi); }
.tag--cyan { border-color: rgba(79, 182, 198, 0.5); color: var(--cyan); }
.tag--amber { border-color: rgba(217, 119, 43, 0.55); color: var(--amber); }

.panel {
  position: relative;
  padding: clamp(20px, 3vw, 32px);
  background: var(--panel);
  border: 1px solid var(--line);
  transition: border-color var(--t-mid) var(--ease), transform var(--t-mid) var(--ease);
}
.panel--teal { background: var(--teal); border-color: #2A3F45; }
.panel:hover { border-color: rgba(201, 162, 39, 0.6); transform: translateY(-4px); }

/* ---------- 8. Media frame base (页面阶段放置图片占位) ---------- */
.media-frame {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    linear-gradient(140deg, #14161A 0%, #1C2A2E 58%, #14161A 100%);
}
.media-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.95) contrast(1.02);
}
.media-frame--square { aspect-ratio: 1 / 1; }
.media-frame--tall { aspect-ratio: 3 / 4; }
.media-frame::before,
.media-frame::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border: 1px solid var(--gold);
  pointer-events: none;
}
.media-frame::before { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.media-frame::after { bottom: 0; right: 0; border-left: 0; border-top: 0; }
.media-frame__label {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 8px 12px;
  background: rgba(11, 12, 14, 0.84);
  border-top: 1px solid var(--gold);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--gold-hi);
}

/* ---------- 9. Skip link ---------- */
.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 200;
  padding: 10px 18px;
  background: var(--paper);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform var(--t-mid) var(--ease);
}
.skip-link:focus { transform: translateY(0); color: var(--ink); }

/* ---------- 10. Header : brand bar ---------- */
.site-header { position: relative; z-index: 60; }

.brandbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 20px;
  height: var(--bar-h);
  padding: 0 clamp(16px, 2.4vw, 32px);
  background: rgba(11, 12, 14, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
.brandbar::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, var(--gold) 0%, rgba(201, 162, 39, 0.25) 32%, transparent 62%);
  pointer-events: none;
}

.brandbar__brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  flex: none;
  color: var(--paper);
  text-decoration: none;
}
.brandbar__glyph {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--gold);
  flex: none;
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.brandbar__glyph svg { width: 19px; height: 19px; }
.brandbar__brand:hover .brandbar__glyph { color: var(--ink); background: var(--gold); border-color: var(--gold-hi); }

.brandbar__text { display: block; }
.brandbar__name {
  display: block;
  font-family: var(--font-head);
  font-size: 17px;
  line-height: 1.1;
  letter-spacing: 0.06em;
  color: var(--paper);
}
.brandbar__line {
  display: block;
  margin-top: 3px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--mist);
}

.brandbar__status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: 12px;
  padding: 5px 12px;
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--mist);
  white-space: nowrap;
  max-width: none;
}
.brandbar__status .dot {
  width: 6px;
  height: 6px;
  flex: none;
  background: var(--cyan);
  box-shadow: 0 0 0 3px rgba(79, 182, 198, 0.18);
}

.brandbar__utils {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
}
.util-link {
  font-size: 13px;
  letter-spacing: 0.1em;
  color: var(--mist);
  text-decoration: none;
  padding: 6px 0;
  border-bottom: 1px solid transparent;
  transition: color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
}
.util-link:hover { color: var(--gold-hi); border-bottom-color: var(--gold); }

/* ---------- 11. Header : nav toggle ---------- */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 0;
  color: var(--paper);
  font-size: 13px;
  letter-spacing: 0.16em;
  cursor: pointer;
  transition: border-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.nav-toggle:hover { border-color: var(--gold); color: var(--gold-hi); }
.nav-toggle[aria-expanded="true"] { border-color: var(--gold); color: var(--gold-hi); background: rgba(201, 162, 39, 0.10); }
.nav-toggle__bars { display: grid; gap: 3px; width: 16px; }
.nav-toggle__bars span { display: block; height: 1px; background: currentColor; }
.nav-toggle__bars span:nth-child(2) { width: 70%; }
.nav-toggle__text { line-height: 1; }

/* ---------- 12. Header : reading progress ---------- */
.reading-progress {
  position: fixed;
  top: var(--bar-h);
  left: 0;
  right: 0;
  z-index: 59;
  height: 2px;
  background: rgba(58, 63, 70, 0.55);
  pointer-events: none;
}
.reading-progress__fill {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--gold) 0%, var(--gold-hi) 55%, var(--cyan) 100%);
}

/* ---------- 13. Header : vertical rail nav (desktop) ---------- */
.railnav {
  position: fixed;
  top: var(--bar-h);
  left: 0;
  bottom: 0;
  z-index: 55;
  width: var(--rail-w);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px 0;
  background: linear-gradient(180deg, #0F1114 0%, #0B0C0E 100%);
  border-right: 1px solid var(--line);
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.railnav__list { display: flex; flex-direction: column; gap: 2px; }

.railnav__link {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 76px;
  padding: 14px 6px 16px;
  color: var(--mist);
  text-decoration: none;
  border-top: 1px solid transparent;
  border-bottom: 1px solid transparent;
  transition: color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.railnav__link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 3px;
  height: 0;
  transform: translateY(-50%);
  background: var(--gold);
  transition: height var(--t-mid) var(--ease), background-color var(--t-fast) var(--ease);
}
.railnav__link:hover {
  color: var(--paper);
  background: rgba(20, 22, 26, 0.92);
}
.railnav__link:hover::before { height: 62%; }
.railnav__link:hover .railnav__num { color: var(--gold); }

.railnav__num {
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.14em;
  line-height: 1;
  color: var(--line);
  transition: color var(--t-fast) var(--ease);
}
.railnav__label {
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.2em;
  line-height: 1;
}

.railnav__link[aria-current="page"] {
  color: var(--gold-hi);
  background: linear-gradient(90deg, rgba(201, 162, 39, 0.16), transparent 78%);
}
.railnav__link[aria-current="page"]::before { height: 100%; }
.railnav__link[aria-current="page"] .railnav__num { color: var(--gold); }

.railnav__link--feedback { color: var(--paper); }
.railnav__link--feedback .railnav__num { color: var(--cyan); }
.railnav__link--feedback::after {
  content: "";
  position: absolute;
  top: 10px;
  right: 12px;
  width: 5px;
  height: 5px;
  background: var(--cyan);
  box-shadow: 0 0 0 3px rgba(79, 182, 198, 0.18);
}
.railnav__link--feedback:hover::after { background: var(--gold-hi); box-shadow: 0 0 0 3px rgba(232, 192, 74, 0.22); }

.railnav__foot {
  align-self: center;
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  color: #5A6068;
  writing-mode: vertical-rl;
  text-orientation: upright;
  white-space: nowrap;
  max-width: none;
}

/* ---------- 14. Header : scrim & mobile feedback bar ---------- */
.nav-scrim {
  position: fixed;
  inset: 0;
  z-index: 65;
  background: rgba(6, 7, 9, 0.72);
  backdrop-filter: blur(2px);
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--t-slow) var(--ease), visibility var(--t-slow) linear;
}
.nav-scrim[data-open] { opacity: 1; visibility: visible; }

.feedback-rail { display: none; }

body.no-scroll { overflow: hidden; }

/* ---------- 15. Footer ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  margin-top: clamp(56px, 8vw, 96px);
  padding: clamp(48px, 6vw, 72px) var(--edge) 0;
  background: linear-gradient(180deg, #0B0C0E 0%, #0E1013 45%, #0B0C0E 100%);
  border-top: 1px solid var(--line);
}
.site-footer::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: min(420px, 62%);
  height: 1px;
  background: linear-gradient(90deg, var(--gold), rgba(201, 162, 39, 0.15) 60%, transparent);
}

.footer__inner {
  max-width: 1320px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 48px 40px;
  padding-bottom: clamp(36px, 5vw, 56px);
}

.footer__brand-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--paper);
  text-decoration: none;
}
.footer__glyph {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  color: var(--gold);
  flex: none;
  transition: color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.footer__glyph svg { width: 20px; height: 20px; }
.footer__brand-link:hover .footer__glyph { color: var(--ink); background: var(--gold); }
.footer__brandname {
  font-family: var(--font-head);
  font-size: 19px;
  letter-spacing: 0.05em;
}
.footer__tagline {
  margin-top: 18px;
  font-family: var(--font-serif);
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: 0.1em;
  color: var(--gold-hi);
  max-width: 20ch;
}

.footer__meta {
  margin-top: 24px;
  display: grid;
  gap: 12px;
  max-width: 360px;
}
.footer__meta-row {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 12px;
  align-items: baseline;
}
.footer__meta dt {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--dim);
}
.footer__meta dd {
  font-size: 13px;
  line-height: 1.6;
  color: var(--mist);
  word-break: break-word;
  max-width: none;
}
.footer__meta dd.is-mono {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--paper);
}
.footer__note {
  margin-top: 20px;
  font-size: 12px;
  line-height: 1.75;
  color: #7D848D;
  max-width: 40ch;
}

.footer__col-title {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.2em;
  line-height: 1.4;
  color: var(--gold);
  margin-bottom: 18px;
  text-transform: uppercase;
}
.footer__links { display: grid; gap: 12px; }
.footer__link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  letter-spacing: 0.04em;
  color: var(--mist);
  text-decoration: none;
  transition: color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.footer__link::before {
  content: "";
  width: 12px;
  height: 1px;
  flex: none;
  background: var(--line);
  transition: width var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.footer__link:hover { color: var(--paper); transform: translateX(2px); }
.footer__link:hover::before { width: 20px; background: var(--gold); }

.footer__base {
  max-width: 1320px;
  margin: 0 auto;
  padding: 22px 0 30px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
}
.footer__legal {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--mist);
  max-width: none;
}
.footer__copy {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--dim);
  max-width: none;
}

/* ---------- 16. Back to top ---------- */
.to-top {
  position: fixed;
  right: 20px;
  bottom: 74px;
  z-index: 57;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(20, 22, 26, 0.94);
  border: 1px solid var(--line);
  border-radius: 0;
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition:
    opacity var(--t-mid) var(--ease),
    transform var(--t-mid) var(--ease),
    visibility var(--t-mid) linear,
    border-color var(--t-fast) var(--ease),
    color var(--t-fast) var(--ease);
}
.to-top[data-visible] { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { border-color: var(--gold); color: var(--gold-hi); }

/* ---------- 17. Responsive ---------- */
@media (min-width: 1200px) {
  body { padding-left: var(--rail-w); }
  .reading-progress { left: var(--rail-w); }
  .to-top { right: 32px; bottom: 32px; }
}

@media (max-width: 1199px) {
  .nav-toggle { display: inline-flex; }

  .railnav {
    top: 0;
    bottom: 0;
    width: min(320px, 86vw);
    padding: calc(var(--bar-h) + 18px) 0 24px;
    justify-content: flex-start;
    gap: 8px;
    background: #0B0C0E;
    border-right: 1px solid var(--gold);
    z-index: 70;
    transform: translateX(-102%);
    visibility: hidden;
    transition: transform var(--t-slow) var(--ease), visibility var(--t-slow) linear;
  }
  .railnav[data-open] {
    transform: translateX(0);
    visibility: visible;
  }

  .railnav__list { gap: 0; }
  .railnav__link {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 14px;
    min-height: 0;
    padding: 16px 24px;
    border-top: 0;
    border-bottom: 1px solid var(--line-soft);
  }
  .railnav__link::before {
    top: 0;
    bottom: 0;
    left: 0;
    width: 3px;
    height: auto;
    transform: none;
    background: transparent;
  }
  .railnav__link:hover::before { height: auto; background: var(--gold); }
  .railnav__link[aria-current="page"] { background: rgba(201, 162, 39, 0.10); }
  .railnav__link[aria-current="page"]::before { height: auto; background: var(--gold); }
  .railnav__label {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 16px;
    letter-spacing: 0.1em;
  }
  .railnav__num { font-size: 11px; letter-spacing: 0.12em; }
  .railnav__link--feedback::after { top: 50%; right: 24px; transform: translateY(-50%); }
  .railnav__foot {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    align-self: flex-start;
    margin: 22px 24px 0;
    font-size: 10px;
  }

  .feedback-rail {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 58;
    height: 52px;
    padding: 0 16px;
    background: var(--teal);
    border-top: 1px solid var(--gold);
    color: var(--paper);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-decoration: none;
    transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
  }
  .feedback-rail:hover { background: #223439; color: var(--gold-hi); }
  .feedback-rail__dot {
    width: 6px;
    height: 6px;
    flex: none;
    background: var(--cyan);
    box-shadow: 0 0 0 3px rgba(79, 182, 198, 0.18);
  }

  body { padding-bottom: 52px; }

  .footer__inner { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer__brand { grid-column: 1 / -1; }
}

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

@media (max-width: 767px) {
  .brandbar { gap: 12px; }
  .brandbar__utils { display: none; }
  .nav-toggle { margin-left: auto; }
  .brandbar__name { font-size: 15px; }
  .brandbar__line { font-size: 9px; letter-spacing: 0.12em; }
  .brandbar__glyph { width: 30px; height: 30px; }
  .brandbar__glyph svg { width: 17px; height: 17px; }

  h1 { font-size: clamp(2.25rem, 9vw, 2.75rem); }
  h2 { font-size: clamp(1.625rem, 6.4vw, 2rem); }

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

  .footer__inner { grid-template-columns: 1fr; gap: 36px; }
  .footer__meta-row { grid-template-columns: 68px 1fr; }
  .footer__base { justify-content: flex-start; }
  .footer__copy { text-align: left; }
  .to-top { right: 14px; bottom: 66px; }
}

/* ---------- 18. 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;
  }
  .btn:hover,
  .panel:hover,
  .footer__link:hover,
  .to-top { transform: none; }
}
