/* Epic Entertainment — dark UI
   One theme: near-black wine surfaces, gold accents, glass bars, gold-edged cards. */

/* ================================================================ tokens */
:root {
  --bg: #0E0408;
  --bg-2: #12050B;
  --surface-1: #170710;
  --surface-2: #1F0A16;
  --surface-3: #2A0E1E;
  --line: rgba(255, 255, 255, 0.07);
  --line-strong: rgba(255, 255, 255, 0.12);
  --line-gold: rgba(255, 214, 102, 0.32);

  --text: #F3E9EC;
  --text-soft: #D6C4CA;
  --muted: #A88F98;
  --heading: #FFFFFF;

  --gold: #FFE566;
  --gold-2: #F5B941;
  --gold-soft: rgba(255, 229, 102, 0.08);
  --gold-glow: rgba(255, 210, 90, 0.35);
  --wine: #7A1335;
  --wine-glow: rgba(160, 24, 72, 0.45);
  --on-gold: #1A0710;

  --grad-gold: linear-gradient(135deg, #FFF0A3 0%, #FFE566 35%, #F5B941 100%);
  --grad-edge: linear-gradient(135deg, rgba(255, 229, 102, 0.45), rgba(255, 255, 255, 0.05) 38%, rgba(255, 255, 255, 0.03) 70%, rgba(194, 24, 91, 0.35));

  --shadow: 0 1px 2px rgba(0, 0, 0, 0.5), 0 12px 32px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 30px 90px rgba(0, 0, 0, 0.7);

  --font-ui: "Montserrat", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Bebas Neue", "Oswald", Impact, "Arial Narrow", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;

  --topbar-h: 64px;
  --sidebar-w: 280px;
  --rail-w: 220px;
  --content-w: 900px;
  --radius: 14px;
  --radius-sm: 10px;

  color-scheme: dark;
}

/* ================================================================== base */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--topbar-h) + 20px);
  background: var(--bg);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 600px at 100% -10%, rgba(122, 19, 53, 0.28), transparent 60%),
    radial-gradient(900px 500px at -10% 110%, rgba(122, 19, 53, 0.18), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body.modal-open, body.drawer-open { overflow: hidden; }

img, svg, canvas { display: block; max-width: 100%; }
.icon { flex: none; }

a { color: var(--gold); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3, h4 { color: var(--heading); line-height: 1.2; margin: 0; }
p { margin: 0 0 1em; }
code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  padding: 0.12em 0.42em;
  border-radius: 6px;
  background: var(--surface-3);
  border: 1px solid var(--line);
}
button { font: inherit; color: inherit; }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
::selection { background: rgba(255, 229, 102, 0.3); color: #fff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  padding: 10px 16px; border-radius: var(--radius-sm);
  background: var(--grad-gold); color: var(--on-gold); font-weight: 700;
}
.skip-link:focus { top: 12px; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }

.kbd {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 22px; height: 22px; padding: 0 6px;
  border-radius: 6px;
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  background: var(--surface-2);
  color: var(--muted);
  font-family: var(--font-mono); font-size: 11px; line-height: 1;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  margin: 0 0 14px;
  color: var(--gold);
  font-size: 12px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase;
}
.eyebrow::before {
  content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--grad-gold);
}
.eyebrow a { color: inherit; }
.lead { color: var(--muted); font-size: 17px; max-width: 680px; }

/* Thin scrollbars */
.sidebar, .rail, .search-results { scrollbar-width: thin; scrollbar-color: rgba(255, 229, 102, 0.18) transparent; }
.sidebar::-webkit-scrollbar, .rail::-webkit-scrollbar, .search-results::-webkit-scrollbar { width: 8px; }
.sidebar::-webkit-scrollbar-thumb, .rail::-webkit-scrollbar-thumb, .search-results::-webkit-scrollbar-thumb {
  background: rgba(255, 229, 102, 0.18); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box;
}

/* ============================================================== buttons */
.btn {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 18px;
  border-radius: 999px; border: 1px solid transparent;
  font-size: 14px; font-weight: 700; line-height: 1; white-space: nowrap;
  cursor: pointer; text-decoration: none;
  transition: transform 0.15s, box-shadow 0.2s, background-color 0.2s, border-color 0.2s, color 0.2s;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-sm { min-height: 36px; padding: 0 14px; font-size: 13px; }
.btn-lg { min-height: 52px; padding: 0 26px; font-size: 15px; }
.btn-primary {
  background: var(--grad-gold);
  color: var(--on-gold);
  box-shadow: 0 6px 22px -6px var(--gold-glow), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 30px -6px var(--gold-glow), inset 0 1px 0 rgba(255, 255, 255, 0.5); }
.btn-ghost {
  background: rgba(255, 255, 255, 0.03);
  color: var(--heading);
  border-color: var(--line-strong);
}
.btn-ghost:hover { border-color: var(--line-gold); background: var(--gold-soft); }

.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border-radius: 12px; border: 1px solid transparent;
  background: transparent; color: var(--muted);
  cursor: pointer; transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.icon-btn:hover { background: rgba(255, 255, 255, 0.05); border-color: var(--line); color: var(--heading); }

/* =========================================================== components */
.badge {
  display: inline-flex; align-items: center; height: 26px; padding: 0 11px;
  border-radius: 999px; border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-soft); font-size: 12px; font-weight: 600;
}
.badge-accent { color: var(--gold); border-color: var(--line-gold); background: var(--gold-soft); }

/* Gold-edged surface used by cards */
.guide-card, .feature, .step, .contact-card, .soon-card, .pager-card, .doc-meta, .faq details, .link-list a {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface-1), var(--surface-1)) padding-box,
    var(--grad-edge) border-box;
}

/* Three cards per row; two on tablets, one on phones (see responsive rules) */
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.guide-card {
  display: flex; flex-direction: column; overflow: hidden;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}
.guide-card:hover { transform: translateY(-3px); box-shadow: var(--shadow), 0 0 0 1px var(--line-gold), 0 18px 40px -18px var(--gold-glow); }
.card-cover { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--surface-2); }
.card-cover img { width: 100%; height: 100%; object-fit: cover; object-position: top center; transition: transform 0.4s; }
.guide-card:hover .card-cover img { transform: scale(1.04); }
.card-cover-art {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 6px;
  height: 100%; padding: 20px 22px; overflow: hidden;
  background:
    radial-gradient(120% 120% at 100% 0%, rgba(255, 229, 102, 0.22), transparent 50%),
    radial-gradient(90% 90% at 0% 100%, var(--wine-glow), transparent 60%),
    linear-gradient(160deg, #2A0E1E, #12050B);
}
.card-cover-art::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: linear-gradient(to bottom, #000, transparent 85%);
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 85%);
}
.card-cover-art::after {
  content: ""; position: absolute; top: 14px; right: 14px; width: 120px; height: 62px;
  background: url("../img/logo.png") center / contain no-repeat;
  opacity: 0.9;
}
.card-cover-group, .card-cover-title { position: relative; z-index: 1; }
.card-cover-group { color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.card-cover-title { color: #fff; font-family: var(--font-display); font-size: 32px; letter-spacing: 0.02em; line-height: 1; }
.card-body { display: flex; flex: 1; flex-direction: column; padding: 20px 22px 22px; border-top: 1px solid var(--line); }
.card-group { margin: 0 0 6px; color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.card-title { font-size: 18px; font-weight: 700; margin-bottom: 8px; }
.card-title a { color: var(--heading); }
.card-title a:hover { color: var(--gold); text-decoration: none; }
.card-text { color: var(--muted); font-size: 14px; line-height: 1.6; margin-bottom: 14px; }
.card-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 0 0 18px; color: var(--muted); font-size: 12.5px; }
.card-link { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; color: var(--gold); font-size: 14px; font-weight: 700; transition: gap 0.15s; }
.card-link:hover { gap: 10px; text-decoration: none; }

.soon-card { max-width: 640px; padding: 36px 34px; border-radius: var(--radius); box-shadow: var(--shadow); }
.soon-card h2, .soon-card h3 { font-size: 22px; margin-bottom: 10px; }
.soon-card p { color: var(--muted); margin-bottom: 22px; }

.notice {
  padding: 16px 20px; margin: 0 0 24px;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: var(--surface-1); color: var(--text-soft);
}
.notice p:last-child { margin-bottom: 0; }
.notice-warn { border-color: rgba(255, 210, 122, 0.4); }
.notice .btn { margin-top: 4px; }

.link-list { list-style: none; margin: 36px 0 0; padding: 0; display: grid; gap: 10px; max-width: 580px; }
.link-list a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 14px 18px; border-radius: var(--radius-sm);
  color: var(--heading); font-weight: 600;
}
.link-list a:hover { text-decoration: none; box-shadow: 0 0 0 1px var(--line-gold); }
.link-list small { color: var(--muted); font-weight: 500; }

.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 300;
  padding: 11px 20px; border-radius: 999px;
  background: var(--grad-gold); color: var(--on-gold);
  font-size: 14px; font-weight: 700;
  box-shadow: var(--shadow-lg);
  opacity: 0; transform: translate(-50%, 14px); pointer-events: none;
  transition: opacity 0.2s, transform 0.2s;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* Brand */
.brand { display: inline-flex; align-items: center; gap: 10px; min-width: 0; color: var(--heading); text-decoration: none; }
.brand:hover { text-decoration: none; }
/* The logo is a wide wordmark (≈1.94:1): size it by height, width follows. */
.brand-logo { width: auto; height: 44px; filter: drop-shadow(0 4px 14px rgba(255, 60, 120, 0.25)); }
.site-header .brand-logo { height: 52px; }
.sidebar-head .brand-logo { height: 40px; }
.footer-about .brand-logo { height: 64px; }
.brand-name {
  font-family: var(--font-display); font-size: 26px; letter-spacing: 0.05em; line-height: 1;
  padding-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.brand-tag {
  display: inline-flex; align-items: center; height: 22px; padding: 0 8px;
  border-radius: 6px; border: 1px solid var(--line-gold); background: var(--gold-soft);
  color: var(--gold); font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
}

/* ====================================================== marketing site */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(14, 4, 8, 0.72);
  backdrop-filter: saturate(150%) blur(14px);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header-inner { position: relative; display: flex; align-items: center; gap: 24px; height: 72px; }
.site-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.site-nav > a:not(.btn) {
  padding: 8px 14px; border-radius: 999px;
  color: var(--muted); font-size: 14px; font-weight: 600;
  transition: color 0.15s, background-color 0.15s;
}
.site-nav > a:not(.btn):hover { color: var(--heading); background: rgba(255, 255, 255, 0.05); text-decoration: none; }
.site-nav > a[aria-current="page"] { color: var(--gold); background: var(--gold-soft); }
.site-nav-cta { margin-left: 10px; }
.site-header-actions { display: flex; align-items: center; gap: 4px; }
.site-menu-btn { display: none; }

.hero { position: relative; overflow: hidden; padding: 96px 0 104px; isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, #000 30%, transparent 75%);
}
.hero::after {
  content: ""; position: absolute; z-index: -1;
  top: -180px; right: -120px; width: 620px; height: 620px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 210, 90, 0.16), transparent 65%);
  filter: blur(10px);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.hero-title {
  margin: 0 0 22px;
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(52px, 7.4vw, 92px); letter-spacing: 0.01em; line-height: 0.93;
  color: var(--heading);
  background: linear-gradient(180deg, #FFFFFF 30%, #E8D3DA);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-lead { max-width: 560px; color: var(--muted); font-size: 18px; line-height: 1.65; margin-bottom: 34px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-stats {
  display: inline-flex; flex-wrap: wrap; gap: 0;
  margin: 48px 0 0; padding: 0; list-style: none;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}
.hero-stats li { display: flex; flex-direction: column; padding: 14px 26px; }
.hero-stats li + li { border-left: 1px solid var(--line); }
.hero-stats strong {
  font-family: var(--font-display); font-size: 38px; font-weight: 400; line-height: 1;
  background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-stats span { color: var(--muted); font-size: 12.5px; font-weight: 600; }

.hero-visual { position: relative; }
.hero-visual::before {
  content: ""; position: absolute; inset: 10% -6% -8% 6%; z-index: -1;
  border-radius: 30px; background: radial-gradient(closest-side, var(--wine-glow), transparent);
  filter: blur(30px);
}
.mock-window {
  overflow: hidden; border-radius: 18px;
  border: 1px solid transparent;
  background: linear-gradient(var(--surface-1), var(--surface-1)) padding-box, var(--grad-edge) border-box;
  box-shadow: var(--shadow-lg);
  transform: perspective(1400px) rotateY(-7deg) rotateX(3deg);
}
.mock-bar { display: flex; align-items: center; gap: 7px; height: 40px; padding: 0 16px; border-bottom: 1px solid var(--line); background: rgba(255, 255, 255, 0.02); }
.mock-bar span { width: 10px; height: 10px; border-radius: 50%; background: rgba(255, 255, 255, 0.14); }
.mock-bar span:first-child { background: #E0567A; }
.mock-bar span:nth-child(2) { background: var(--gold-2); }
.mock-bar em { margin-left: 10px; color: var(--muted); font-size: 12px; font-style: normal; font-weight: 600; }
.mock-body { display: grid; grid-template-columns: 30% 1fr; min-height: 340px; }
.mock-side { display: flex; flex-direction: column; gap: 13px; padding: 20px 16px; border-right: 1px solid var(--line); }
.mock-side i { display: block; height: 8px; width: 70%; border-radius: 4px; background: rgba(255, 255, 255, 0.09); }
.mock-side i.is-wide { width: 90%; }
.mock-side i.is-active { width: 82%; background: var(--grad-gold); box-shadow: 0 0 12px var(--gold-glow); }
.mock-main { padding: 20px 22px; min-width: 0; }
.mock-crumb { margin: 0 0 4px; color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.mock-title { margin: 0 0 16px; font-family: var(--font-display); font-size: 32px; line-height: 1; color: var(--heading); }
.mock-sections { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 8px; }
.mock-sections li {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px; border: 1px solid var(--line); border-radius: 9px;
  background: rgba(255, 255, 255, 0.025);
  font-size: 12.5px; font-weight: 600; color: var(--text-soft);
}
.mock-sections li:first-child { border-color: var(--line-gold); background: var(--gold-soft); color: var(--heading); }
.mock-sections span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.mock-sections b { flex: none; font-family: var(--font-mono); font-size: 11px; color: var(--gold); }
.mock-page {
  height: 72px; border-radius: 9px; border: 1px solid var(--line);
  background:
    linear-gradient(rgba(255, 255, 255, 0.1) 0 0) 14px 16px / 50% 8px no-repeat,
    linear-gradient(rgba(255, 255, 255, 0.07) 0 0) 14px 32px / 72% 8px no-repeat,
    linear-gradient(rgba(255, 255, 255, 0.07) 0 0) 14px 48px / 40% 8px no-repeat,
    rgba(255, 255, 255, 0.02);
}

.section { position: relative; padding: 96px 0; }
.section-tight { padding-top: 24px; }
.section-alt {
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.015) 20%, rgba(255, 255, 255, 0.015) 80%, transparent);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.mk-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 40px; }
.mk-head.is-center { justify-content: center; text-align: center; }
.mk-head.is-center .eyebrow { justify-content: center; }
.section-title {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(36px, 4.6vw, 54px); letter-spacing: 0.015em; line-height: 1;
  margin-bottom: 14px;
}
.section-lead { max-width: 620px; color: var(--muted); font-size: 17px; margin: 0; }

.feature-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.feature { padding: 28px; border-radius: var(--radius); transition: transform 0.2s, box-shadow 0.2s; }
.feature:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -20px var(--gold-glow); }
.feature h3 { font-size: 17px; margin: 18px 0 8px; }
.feature p { color: var(--muted); font-size: 14.5px; margin: 0; }
.feature-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 14px;
  background: linear-gradient(145deg, rgba(255, 229, 102, 0.18), rgba(255, 229, 102, 0.04));
  border: 1px solid var(--line-gold);
  color: var(--gold);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.steps { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin: 0; padding: 0; list-style: none; }
.step { padding: 30px 28px; border-radius: var(--radius); }
.step-num {
  display: block; margin-bottom: 14px;
  font-family: var(--font-display); font-size: 56px; line-height: 1;
  background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.step h3 { font-size: 18px; margin-bottom: 8px; }
.step p { color: var(--muted); font-size: 14.5px; margin: 0; }

.cta-band {
  position: relative; overflow: hidden;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px;
  padding: 52px 56px; border-radius: 24px;
  border: 1px solid transparent;
  background:
    radial-gradient(70% 140% at 100% 0%, rgba(255, 229, 102, 0.18), transparent 60%) padding-box,
    radial-gradient(60% 120% at 0% 100%, var(--wine-glow), transparent 60%) padding-box,
    linear-gradient(135deg, #2A0E1E, #14050C) padding-box,
    var(--grad-edge) border-box;
  box-shadow: var(--shadow-lg);
}
.cta-band .section-title { margin-bottom: 8px; }
.cta-band p { color: var(--text-soft); margin: 0; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.page-hero { position: relative; padding: 80px 0 28px; }
.page-hero.not-found { padding-bottom: 96px; }
.not-found-code {
  margin: 0;
  font-family: var(--font-display); font-size: clamp(110px, 20vw, 180px); line-height: 0.85;
  background: var(--grad-gold); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}

.contact-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; margin-bottom: 72px; }
.contact-card {
  display: flex; flex-direction: column; gap: 8px; padding: 28px;
  border-radius: var(--radius); color: var(--text);
  transition: transform 0.2s, box-shadow 0.2s;
}
.contact-card:hover { transform: translateY(-3px); text-decoration: none; box-shadow: 0 0 0 1px var(--line-gold), 0 18px 40px -18px var(--gold-glow); }
.contact-label { margin-top: 12px; color: var(--heading); font-size: 19px; font-weight: 700; }
.contact-text { color: var(--muted); font-size: 14px; }
.contact-value { color: var(--heading); font-weight: 600; font-size: 14px; word-break: break-all; }
.contact-card .card-link { margin-top: 10px; }

.faq { max-width: 780px; }
.faq .section-title { margin-bottom: 22px; }
.faq details { border-radius: var(--radius-sm); margin-bottom: 10px; overflow: hidden; }
.faq summary {
  position: relative; padding: 18px 52px 18px 22px;
  color: var(--heading); font-weight: 600; cursor: pointer; list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  color: var(--gold); font-size: 22px; font-weight: 500; line-height: 1;
}
.faq details[open] summary::after { content: "−"; }
.faq details[open] summary { border-bottom: 1px solid var(--line); }
.faq details p { margin: 0; padding: 16px 22px 20px; color: var(--muted); }

/* Ordering process: intro + flow on the left, timeline on the right */
.process { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 64px; align-items: start; }
.process-intro { position: sticky; top: 104px; }
.process-intro .section-lead { margin-bottom: 30px; }
.process-label { margin: 0 0 12px; color: var(--muted); font-size: 11.5px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.flow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 6px; margin: 0 0 32px; padding: 0; list-style: none; }
.flow li {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--text-soft); font-size: 13px; font-weight: 600;
}
.flow li:not(:last-child)::after { content: "→"; color: var(--gold); font-weight: 700; margin-left: 2px; }
.flow li::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
  background: var(--grad-gold); box-shadow: 0 0 8px var(--gold-glow);
}

.timeline { position: relative; margin: 0; padding: 0; list-style: none; display: grid; gap: 16px; }
.timeline::before {
  content: ""; position: absolute; top: 28px; bottom: 28px; left: 27px; width: 2px;
  background: linear-gradient(180deg, var(--gold), rgba(255, 229, 102, 0.1));
}
.timeline-step {
  position: relative; display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 20px; align-items: start;
}
.timeline-step > div {
  padding: 22px 24px; border-radius: var(--radius); border: 1px solid transparent;
  background: linear-gradient(var(--surface-1), var(--surface-1)) padding-box, var(--grad-edge) border-box;
  transition: transform 0.2s, box-shadow 0.2s;
}
.timeline-step:hover > div { transform: translateX(3px); box-shadow: 0 16px 36px -20px var(--gold-glow); }
.timeline-num {
  position: relative; z-index: 1; display: flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--grad-gold); color: var(--on-gold);
  font-family: var(--font-display); font-size: 28px; line-height: 1; padding-top: 3px;
  box-shadow: 0 0 0 6px var(--bg), 0 8px 24px -6px var(--gold-glow);
}
.timeline-step h3 { font-size: 18px; margin-bottom: 6px; }
.timeline-step p { color: var(--muted); font-size: 14.5px; margin: 0; }
.pay-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 0; padding: 0; list-style: none; }
.pay-chips li {
  display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px;
  border-radius: 8px; border: 1px solid var(--line-gold); background: var(--gold-soft);
  color: var(--heading); font-family: var(--font-mono); font-size: 13px; font-weight: 700;
}
.pay-chips small { color: var(--gold); font-size: 11px; font-weight: 600; }

/* ============================================== guides page: filter + pages */
.page-docs .content { max-width: 1180px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; }
.filter-chip {
  display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px;
  border-radius: 999px; border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03);
  color: var(--text-soft); font-size: 13.5px; font-weight: 600;
  transition: border-color 0.15s, background-color 0.15s, color 0.15s;
}
.filter-chip span {
  display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 20px; padding: 0 6px;
  border-radius: 999px; background: rgba(255, 255, 255, 0.07); color: var(--muted); font-size: 11.5px;
}
.filter-chip:hover { border-color: var(--line-gold); color: var(--heading); text-decoration: none; }
.filter-chip[aria-current="page"] { border-color: var(--gold); background: var(--gold-soft); color: var(--gold); }
.filter-chip[aria-current="page"] span { background: var(--gold); color: var(--on-gold); }
.results-count { margin: 22px 0 16px; color: var(--muted); font-size: 13.5px; }

.pagination { margin-top: 40px; }
.pagination ul { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px; margin: 0; padding: 0; list-style: none; }
.pg-num, .pg-step, .pg-gap {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-width: 40px; height: 40px; padding: 0 12px; border-radius: 10px;
  font-size: 14px; font-weight: 600; color: var(--text-soft);
}
.pg-num, .pg-step { border: 1px solid var(--line-strong); background: rgba(255, 255, 255, 0.03); }
a.pg-num:hover, a.pg-step:hover { border-color: var(--line-gold); color: var(--gold); text-decoration: none; }
.pg-num.is-current { border-color: var(--gold); background: var(--grad-gold); color: var(--on-gold); box-shadow: 0 6px 18px -8px var(--gold-glow); }
.pg-step.is-disabled { opacity: 0.35; }
.pg-gap { min-width: 24px; padding: 0; color: var(--muted); }

/* ======================================= guide page: order-process popup */
.rail-promo {
  margin-bottom: 16px; padding: 18px 16px;
  border-radius: var(--radius); border: 1px solid transparent;
  background:
    radial-gradient(120% 100% at 100% 0%, rgba(255, 229, 102, 0.14), transparent 60%) padding-box,
    linear-gradient(var(--surface-1), var(--surface-1)) padding-box,
    var(--grad-edge) border-box;
}
.rail-promo-title { margin: 0 0 6px; color: var(--heading); font-size: 14px; font-weight: 700; }
.rail-promo p:not(.rail-promo-title) { margin: 0 0 14px; color: var(--muted); font-size: 12.5px; line-height: 1.55; }
.rail-promo .btn { width: 100%; white-space: normal; text-align: center; line-height: 1.25; padding-top: 8px; padding-bottom: 8px; }
.show-without-rail { display: none; }

.modal {
  width: min(760px, calc(100% - 32px)); max-height: calc(100vh - 48px); max-height: calc(100dvh - 48px);
  margin: auto; padding: 0; border: 0; background: transparent; color: var(--text); overflow: visible;
}
.modal::backdrop { background: rgba(6, 1, 3, 0.75); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.modal[open] { animation: modal-in 0.2s ease-out; }
@keyframes modal-in { from { opacity: 0; transform: translateY(12px) scale(0.98); } to { opacity: 1; transform: none; } }
.modal-inner {
  display: flex; flex-direction: column; max-height: inherit; overflow: hidden;
  border-radius: 20px; border: 1px solid transparent;
  background: linear-gradient(var(--bg-2), var(--bg-2)) padding-box, var(--grad-edge) border-box;
  box-shadow: var(--shadow-lg), 0 0 90px -20px var(--wine-glow);
}
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 24px 24px 16px 28px; border-bottom: 1px solid var(--line); }
.modal-head .eyebrow { margin-bottom: 8px; }
.modal-title { font-family: var(--font-display); font-weight: 400; font-size: 38px; line-height: 1; letter-spacing: 0.015em; }
.modal-body { flex: 1; overflow-y: auto; padding: 22px 28px 8px; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: rgba(255, 229, 102, 0.18) transparent; }
.modal-body .flow { margin-bottom: 24px; }
.modal-body .timeline { gap: 12px; padding-bottom: 16px; }
.modal-body .timeline-step > div { padding: 16px 18px; }
.modal-body .timeline-step:hover > div { transform: none; }
.modal-body .timeline-num { box-shadow: 0 0 0 6px var(--bg-2), 0 8px 24px -6px var(--gold-glow); }
.modal-foot { display: flex; flex-wrap: wrap; gap: 10px; padding: 16px 28px 22px; border-top: 1px solid var(--line); background: rgba(255, 255, 255, 0.015); }

/* =================================================================== footer */
.site-footer {
  position: relative;
  padding: 64px 0 0;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.015), transparent 40%), var(--bg-2);
  color: var(--muted); font-size: 14px;
}
.site-footer::before {
  content: ""; position: absolute; top: -1px; left: 50%; width: min(600px, 80%); height: 1px; transform: translateX(-50%);
  background: linear-gradient(90deg, transparent, var(--gold), transparent); opacity: 0.6;
}
.footer-grid { display: grid; grid-template-columns: 2fr repeat(3, minmax(0, 1fr)); gap: 36px; }
.footer-about p { max-width: 340px; margin: 16px 0 0; }
.footer-title { margin: 0 0 14px; color: var(--heading); font-size: 12px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-col a { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-weight: 500; transition: color 0.15s; }
.footer-col a:hover { color: var(--gold); text-decoration: none; }
.footer-bottom { margin-top: 48px; padding-top: 22px; padding-bottom: 30px; border-top: 1px solid var(--line); font-size: 13px; }
.footer-bottom p { margin: 0; }

/* ============================================================ docs: top bar */
.topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; gap: 16px;
  height: var(--topbar-h); padding: 0 20px;
  background: rgba(14, 4, 8, 0.75);
  backdrop-filter: saturate(150%) blur(14px);
  -webkit-backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.menu-btn { display: none; margin-left: -6px; }
.topbar > .brand { flex: none; min-width: calc(var(--sidebar-w) - 36px); }
.search-trigger {
  display: flex; align-items: center; gap: 10px;
  width: 100%; max-width: 440px; height: 42px; padding: 0 8px 0 14px;
  border-radius: 12px; border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted); font-size: 14px; cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s;
}
.search-trigger:hover { border-color: var(--line-gold); color: var(--text); box-shadow: 0 0 0 4px var(--gold-soft); }
.search-trigger-text { flex: 1; text-align: left; }
.search-trigger-keys { display: inline-flex; gap: 4px; }
.topbar-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.topbar-link {
  padding: 8px 12px; border-radius: 999px;
  color: var(--muted); font-size: 14px; font-weight: 600; white-space: nowrap;
}
.topbar-link:hover { color: var(--heading); background: rgba(255, 255, 255, 0.05); text-decoration: none; }

/* ============================================================== docs: layout */
.layout { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr) var(--rail-w); align-items: start; }
.layout.no-rail { grid-template-columns: var(--sidebar-w) minmax(0, 1fr); }

.sidebar {
  position: sticky; top: var(--topbar-h);
  height: calc(100vh - var(--topbar-h)); height: calc(100dvh - var(--topbar-h));
  overflow-y: auto; overscroll-behavior: contain;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 40%), var(--bg-2);
  border-right: 1px solid var(--line);
}
.sidebar-head { display: none; }
.sidebar-backdrop { display: none; }

.main-col { display: flex; flex-direction: column; min-width: 0; min-height: calc(100vh - var(--topbar-h)); }
.content { flex: 1; width: 100%; max-width: calc(var(--content-w) + 96px); margin: 0 auto; padding: 44px 48px 72px; }
.content:focus { outline: none; }
.docs .site-footer .container { padding: 0 48px; }

.rail {
  position: sticky; top: var(--topbar-h);
  height: calc(100vh - var(--topbar-h)); height: calc(100dvh - var(--topbar-h));
  overflow-y: auto; padding: 44px 20px 24px 4px;
}

/* ============================================================= docs: sidebar */
.sidebar-nav { padding: 22px 14px 40px; }
.nav-home {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 16px; padding: 10px 12px;
  border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-soft); font-size: 14px; font-weight: 600;
}
.nav-home:hover { color: var(--heading); border-color: var(--line-strong); text-decoration: none; }
.nav-home.is-active { color: var(--gold); border-color: var(--line-gold); background: var(--gold-soft); }

.nav-group + .nav-group { margin-top: 12px; }
.nav-group-toggle {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; padding: 8px 12px; border: 0; border-radius: 8px;
  background: transparent; color: var(--muted);
  font-size: 11.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  text-align: left; cursor: pointer;
}
.nav-group-toggle:hover { color: var(--heading); }
.nav-group-toggle .icon { transition: transform 0.2s; }
.nav-group-toggle[aria-expanded="true"] .icon { transform: rotate(90deg); }
.nav-group.is-current .nav-group-toggle { color: var(--heading); }

.nav-list, .nav-sections { list-style: none; margin: 0; padding: 0; }
.nav-list { margin: 4px 0 6px; }
.nav-link {
  display: block; margin: 1px 0 1px 10px; padding: 7px 12px;
  border-left: 2px solid var(--line); border-radius: 0 8px 8px 0;
  color: var(--muted); font-size: 14px; line-height: 1.45;
  transition: color 0.15s, border-color 0.15s, background-color 0.15s;
}
.nav-link:hover { color: var(--heading); border-left-color: var(--line-strong); background: rgba(255, 255, 255, 0.03); text-decoration: none; }
.nav-link.is-active {
  color: var(--gold); font-weight: 600;
  border-left-color: var(--gold);
  background: linear-gradient(90deg, rgba(255, 229, 102, 0.12), transparent);
}
.nav-sections { margin: 4px 0 8px 22px; border-left: 1px solid var(--line); }
.nav-sections a {
  display: block; margin-left: -1px; padding: 5px 12px 5px 16px;
  border-left: 2px solid transparent;
  color: var(--muted); font-size: 13px; line-height: 1.45;
}
.nav-sections .level-2 a { padding-left: 30px; font-size: 12.5px; }
.nav-sections a:hover { color: var(--heading); text-decoration: none; }
.nav-sections a.is-active { color: var(--gold); border-left-color: var(--gold); }

/* ================================================================ docs: rail */
.rail-title { margin: 0 0 12px; color: var(--heading); font-size: 11.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.toc { list-style: none; margin: 0 0 24px; padding: 0; border-left: 1px solid var(--line); }
.toc a {
  display: block; margin-left: -1px; padding: 5px 0 5px 14px;
  border-left: 2px solid transparent;
  color: var(--muted); font-size: 13px; line-height: 1.45;
  transition: color 0.15s, border-color 0.15s;
}
.toc .level-2 a { padding-left: 26px; font-size: 12.5px; }
.toc a:hover { color: var(--heading); text-decoration: none; }
.toc a.is-active { color: var(--gold); border-left-color: var(--gold); font-weight: 600; }
.rail-actions {
  display: grid; gap: 4px; padding: 8px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.02);
}
.rail-action {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px;
  border: 0; border-radius: 8px; background: transparent;
  color: var(--text-soft); font-size: 13px; font-weight: 600; text-align: left; cursor: pointer;
}
.rail-action:hover { background: var(--gold-soft); color: var(--gold); text-decoration: none; }

/* ============================================================ docs: content */
.page-title {
  font-family: var(--font-display); font-weight: 400;
  font-size: clamp(42px, 6vw, 64px); letter-spacing: 0.015em; line-height: 0.98;
  color: var(--heading);
}
.breadcrumb ol {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  margin: 0 0 18px; padding: 0; list-style: none;
  color: var(--muted); font-size: 13px; font-weight: 500;
}
.breadcrumb li + li::before { content: "/"; margin-right: 6px; opacity: 0.5; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--gold); }
.breadcrumb [aria-current] { color: var(--text-soft); }

.doc-header { padding-bottom: 28px; margin-bottom: 8px; border-bottom: 1px solid var(--line); }
.doc-header .page-title { margin-bottom: 16px; }
.doc-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.doc-intro { color: var(--text-soft); font-size: 17px; max-width: 720px; }
.doc-intro p:last-child { margin-bottom: 0; }
.doc-meta {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 26px 0 0; border-radius: var(--radius); overflow: hidden;
}
.doc-meta > div { padding: 14px 18px; }
.doc-meta > div + div { border-left: 1px solid var(--line); }
.doc-meta dt { margin-bottom: 3px; color: var(--muted); font-size: 10.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.doc-meta dd { margin: 0; color: var(--heading); font-size: 14.5px; font-weight: 600; }
.doc-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

.docs-group { margin-top: 36px; margin-bottom: 8px; }
.group-title {
  display: flex; align-items: center; gap: 12px;
  font-size: 20px; font-weight: 700; margin-bottom: 18px;
  scroll-margin-top: calc(var(--topbar-h) + 20px);
}
.group-title::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, var(--line-strong), transparent); }

.doc-section { padding-top: 6px; }
.doc-section + .doc-section, .doc-lead + .doc-section { border-top: 1px solid var(--line); }
.doc-section.level-2 { border-top-style: dashed; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 30px 0 18px; }
.section-heading {
  position: relative; display: flex; align-items: baseline; gap: 10px;
  margin: 0; font-size: 24px; font-weight: 700;
  scroll-margin-top: calc(var(--topbar-h) + 24px);
}
h3.section-heading { font-size: 19px; }
.anchor { color: var(--muted); font-weight: 500; opacity: 0; padding: 0 4px; border-radius: 4px; transition: opacity 0.15s, color 0.15s; }
.section-heading:hover .anchor, .anchor:focus-visible { opacity: 1; }
.anchor:hover { color: var(--gold); text-decoration: none; }
@media (hover: none) { .anchor { opacity: 0.6; } }
.page-badge {
  flex: none; display: inline-flex; align-items: center; height: 26px; padding: 0 10px;
  border-radius: 7px; border: 1px solid var(--line-gold); background: var(--gold-soft);
  color: var(--gold); font-family: var(--font-mono); font-size: 12px; font-weight: 600; white-space: nowrap;
}
.doc-lead { padding-top: 28px; }

/* Page figures */
.page { margin: 0 0 30px; scroll-margin-top: calc(var(--topbar-h) + 20px); }
.page-frame {
  position: relative; display: block; width: 100%; padding: 0;
  aspect-ratio: 16 / 9; overflow: hidden;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: #FFFFFF;
  box-shadow: var(--shadow);
  cursor: zoom-in;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.page-frame:hover { border-color: var(--line-gold); box-shadow: var(--shadow), 0 0 0 4px var(--gold-soft); }
.page-canvas { display: block; width: 100%; height: 100%; object-fit: contain; }
.page-status {
  position: absolute; inset: 0; display: none;
  align-items: center; justify-content: center;
  color: var(--muted); font-size: 13px; font-weight: 600;
}
.js .page:not(.is-loaded) .page-frame { background: var(--surface-1); }
.js .page:not(.is-loaded) .page-frame::before,
.doc-skeleton {
  background: linear-gradient(100deg, rgba(255, 255, 255, 0.02) 30%, rgba(255, 229, 102, 0.08) 50%, rgba(255, 255, 255, 0.02) 70%);
  background-size: 200% 100%;
  animation: shimmer 1.4s linear infinite;
}
.js .page:not(.is-loaded) .page-frame::before { content: ""; position: absolute; inset: 0; }
.js .page:not(.is-loaded) .page-canvas { opacity: 0; }
.js .page:not(.is-loaded) .page-status { display: flex; }
.js .page.is-loaded .page-canvas { opacity: 1; transition: opacity 0.3s; }
.page.is-error .page-frame::before { animation: none; }
.page.is-error .page-status { color: #FF9AA8; }
@keyframes shimmer { from { background-position: 100% 0; } to { background-position: -100% 0; } }

.page-caption { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 4px 0; color: var(--muted); font-size: 12.5px; font-weight: 500; }
.page-retry {
  display: none; padding: 4px 12px; border: 1px solid var(--line-strong); border-radius: 999px;
  background: transparent; color: var(--text); font-size: 12px; font-weight: 600; cursor: pointer;
}
.page-retry:hover { border-color: var(--gold); color: var(--gold); }
.page.is-error .page-retry { display: inline-block; }

.doc-loading { display: grid; gap: 12px; margin: 28px 0 24px; color: var(--muted); font-size: 14px; }
.doc-skeleton { display: block; aspect-ratio: 16 / 9; border: 1px solid var(--line); border-radius: var(--radius); }
.doc-loading-text { color: var(--text-soft); font-weight: 600; font-variant-numeric: tabular-nums; }
.doc-loading-note { color: var(--muted); font-size: 13px; }

/* Prev / next */
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 56px; padding-top: 32px; border-top: 1px solid var(--line); }
.pager-card {
  display: flex; flex-direction: column; gap: 4px; padding: 20px 22px;
  border-radius: var(--radius); color: var(--text);
  transition: transform 0.2s, box-shadow 0.2s;
}
.pager-card:hover { text-decoration: none; transform: translateY(-2px); box-shadow: 0 0 0 1px var(--line-gold), 0 16px 36px -18px var(--gold-glow); }
.pager-next { grid-column: 2; text-align: right; align-items: flex-end; }
.pager-label { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; }
.pager-title { color: var(--heading); font-size: 16px; font-weight: 700; }
.pager-card:hover .pager-title { color: var(--gold); }
.pager-group { color: var(--muted); font-size: 13px; }

/* ================================================================ search */
.search-modal { position: fixed; inset: 0; z-index: 150; display: flex; justify-content: center; align-items: flex-start; padding: 11vh 16px 16px; }
.search-backdrop { position: absolute; inset: 0; background: rgba(6, 1, 3, 0.72); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.search-panel {
  position: relative; display: flex; flex-direction: column;
  width: 100%; max-width: 660px; max-height: min(640px, 78vh); overflow: hidden;
  border-radius: 18px; border: 1px solid transparent;
  background: linear-gradient(var(--surface-1), var(--surface-1)) padding-box, var(--grad-edge) border-box;
  box-shadow: var(--shadow-lg), 0 0 80px -20px var(--wine-glow);
}
.search-head { display: flex; align-items: center; gap: 12px; padding: 0 14px 0 20px; border-bottom: 1px solid var(--line); color: var(--gold); }
.search-input {
  flex: 1; min-width: 0; height: 60px; border: 0; background: transparent;
  color: var(--heading); font: inherit; font-size: 16px;
}
.search-input::placeholder { color: var(--muted); }
.search-input:focus-visible { outline: none; }
.search-input::-webkit-search-cancel-button { display: none; }
.search-esc { border: 0; background: transparent; padding: 0; cursor: pointer; }
.search-results { flex: 1; overflow-y: auto; padding: 8px; overscroll-behavior: contain; }
.sr-group + .sr-group { margin-top: 8px; }
.sr-group-title {
  display: flex; justify-content: space-between; gap: 12px; padding: 10px 12px 6px;
  color: var(--gold); font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
}
.sr-group-title small { color: var(--muted); font-weight: 500; letter-spacing: 0; text-transform: none; }
.sr-list { list-style: none; margin: 0; padding: 0; }
.sr-item a { display: flex; align-items: flex-start; gap: 12px; padding: 11px 12px; border-radius: 12px; color: var(--text); text-decoration: none; border: 1px solid transparent; }
.sr-item .icon { margin-top: 3px; color: var(--muted); }
.sr-item.is-active a { background: var(--gold-soft); border-color: var(--line-gold); }
.sr-item.is-active .icon { color: var(--gold); }
.sr-text { display: flex; flex-direction: column; min-width: 0; }
.sr-title { color: var(--heading); font-size: 14.5px; font-weight: 600; line-height: 1.4; }
.sr-sub { color: var(--muted); font-size: 13px; line-height: 1.45; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.search-results mark { background: rgba(255, 229, 102, 0.22); color: #fff; border-radius: 3px; padding: 0 1px; }
.sr-empty { padding: 36px 16px; color: var(--muted); text-align: center; font-size: 14px; }
.search-foot { display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 11px 18px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; background: rgba(255, 255, 255, 0.015); }
.search-foot span { display: inline-flex; align-items: center; gap: 4px; }

/* ============================================================== lightbox */
.lightbox { position: fixed; inset: 0; z-index: 200; display: flex; flex-direction: column; background: rgba(8, 2, 5, 0.97); color: var(--text); }
.lb-top { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 8px 12px 8px 20px; border-bottom: 1px solid var(--line); }
.lb-count { flex: none; font-weight: 700; font-size: 14px; color: var(--gold); }
.lb-caption { flex: 1; min-width: 0; overflow: hidden; color: var(--muted); font-size: 13px; white-space: nowrap; text-overflow: ellipsis; }
.lb-tools { display: flex; align-items: center; gap: 4px; }
.lb-zoom-label { min-width: 48px; text-align: center; font-size: 12px; font-variant-numeric: tabular-nums; color: var(--muted); }
.lb-stage { position: relative; flex: 1; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; }
.lb-stage.is-dragging { cursor: grabbing; }
.lb-img {
  position: absolute; top: 50%; left: 50%;
  max-width: calc(100% - 32px); max-height: calc(100% - 32px); width: auto; height: auto;
  background: #fff; border-radius: 6px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  transform-origin: center center; will-change: transform; -webkit-user-drag: none;
}
.lb-img.is-animating { transition: transform 0.2s ease-out; }
.lb-spinner {
  position: absolute; top: 50%; left: 50%; width: 38px; height: 38px; margin: -19px 0 0 -19px;
  border: 3px solid rgba(255, 229, 102, 0.18); border-top-color: var(--gold); border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.lb-nav {
  position: absolute; top: 50%; z-index: 2; width: 50px; height: 50px; margin-top: -25px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--line-strong); border-radius: 50%;
  background: rgba(23, 7, 16, 0.85); color: var(--text); cursor: pointer;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.lb-nav:hover { color: var(--gold); border-color: var(--gold); }
.lb-nav[disabled] { opacity: 0.3; cursor: default; }
.lb-prev { left: 18px; }
.lb-next { right: 18px; }
.lb-hint {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%);
  padding: 7px 16px; border-radius: 999px; border: 1px solid var(--line);
  background: rgba(23, 7, 16, 0.85); color: var(--muted); font-size: 12px; pointer-events: none; white-space: nowrap;
}

/* ============================================================ responsive */
@media (max-width: 1199.98px) {
  .layout, .layout.no-rail { grid-template-columns: var(--sidebar-w) minmax(0, 1fr); }
  .rail { display: none; }
  .show-without-rail { display: inline-flex; }
}

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

@media (max-width: 1023.98px) {
  .hero-grid { grid-template-columns: 1fr; gap: 56px; }
  .process { grid-template-columns: 1fr; gap: 40px; }
  .process-intro { position: static; }
  .mock-window { transform: none; }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .doc-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .doc-meta > div:nth-child(3) { border-left: 0; }
  .doc-meta > div:nth-child(n + 3) { border-top: 1px solid var(--line); }
  .topbar-link { display: none; }
}

@media (max-width: 899.98px) {
  .layout, .layout.no-rail { grid-template-columns: minmax(0, 1fr); }
  .menu-btn { display: inline-flex; }
  .topbar { gap: 10px; padding: 0 12px; }
  .topbar > .brand { min-width: 0; flex: 0 1 auto; }

  .sidebar {
    position: fixed; top: 0; left: 0; bottom: 0; z-index: 120;
    width: min(86vw, 320px); height: 100%;
    background: var(--bg-2);
    border-right: 1px solid var(--line-strong);
    box-shadow: var(--shadow-lg);
    transform: translateX(-102%); visibility: hidden;
    transition: transform 0.25s ease, visibility 0s linear 0.25s;
  }
  .sidebar.is-open { transform: none; visibility: visible; transition: transform 0.25s ease, visibility 0s; }
  .sidebar-head {
    position: sticky; top: 0; z-index: 1;
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    height: var(--topbar-h); padding: 0 10px 0 16px;
    background: var(--bg-2); border-bottom: 1px solid var(--line);
  }
  .sidebar-head .brand-name { font-size: 22px; }
  .sidebar-nav { padding-top: 16px; }
  .sidebar-backdrop {
    position: fixed; inset: 0; z-index: 110; display: block;
    background: rgba(6, 1, 3, 0.7); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
    opacity: 0; transition: opacity 0.25s;
  }
  .sidebar-backdrop.is-visible { opacity: 1; }

  .content { padding: 30px 16px 56px; }
  .docs .site-footer .container { padding: 0 16px; }

  .site-menu-btn { display: inline-flex; }
  .site-nav {
    position: absolute; top: 72px; left: 0; right: 0;
    display: none; flex-direction: column; align-items: stretch; gap: 4px;
    padding: 12px 16px 20px;
    background: rgba(18, 5, 11, 0.98);
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
  }
  .site-nav.is-open { display: flex; }
  .site-nav > a:not(.btn) { padding: 12px 14px; font-size: 15px; border-radius: 10px; }
  .site-nav-cta { margin: 8px 0 0; }
  .site-header-actions { margin-left: auto; }
  .steps { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .brand-name { font-size: 22px; }
  .brand-tag { display: none; }
  .site-header .brand-logo { height: 44px; }
  .brand-logo { height: 38px; }

  .search-trigger { width: 42px; flex: none; margin-left: auto; padding: 0; justify-content: center; }
  .search-trigger-text, .search-trigger .search-trigger-keys { display: none; }
  .topbar-actions { margin-left: 0; gap: 2px; }
  .topbar-download { width: 40px; padding: 0; }
  .topbar-download span { display: none; }

  .hero { padding: 56px 0 64px; }
  .hero-lead { font-size: 16px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .hero-stats { display: flex; }
  .hero-stats li { flex: 1; padding: 12px 16px; }
  .mock-body { grid-template-columns: 1fr; }
  .mock-side { display: none; }
  .section { padding: 64px 0; }
  .mk-head { flex-direction: column; align-items: flex-start; }
  .mk-head.is-center { align-items: center; }
  .feature-grid, .footer-grid, .card-grid { grid-template-columns: 1fr; }
  .cta-band { padding: 34px 24px; }
  .process-intro .btn { width: 100%; }
  .modal { width: 100%; max-height: 100dvh; height: 100dvh; margin: 0; max-width: none; }
  .modal-inner { height: 100%; border-radius: 0; }
  .modal-head { padding: 18px 16px 14px 20px; }
  .modal-title { font-size: 30px; }
  .modal-body { padding: 18px 16px 4px; }
  .modal-foot { padding: 14px 16px 18px; }
  .modal-foot .btn { flex: 1 1 100%; }
  .pg-step span { display: none; }
  .timeline::before { left: 19px; }
  .timeline-step { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
  .timeline-num { width: 40px; height: 40px; font-size: 22px; }
  .timeline-step > div { padding: 18px; }
  .cta-actions, .cta-actions .btn { width: 100%; }

  .section-head { flex-direction: column; align-items: flex-start; gap: 8px; }
  .section-heading { font-size: 21px; }
  .page { margin-bottom: 22px; }
  .page-frame { border-radius: var(--radius-sm); }
  .pager { grid-template-columns: 1fr; }
  .pager-next { grid-column: 1; }

  .search-modal { padding: 0; align-items: stretch; }
  .search-panel { max-width: none; max-height: none; height: 100%; border-radius: 0; }
  .search-foot { display: none; }

  .lb-zoom-label, .lb-hint { display: none; }
  .lb-nav { width: 42px; height: 42px; margin-top: -21px; }
  .lb-prev { left: 8px; }
  .lb-next { right: 8px; }
  .lb-top { padding-left: 12px; }
}

@media (max-width: 380px) {
  .topbar .brand-name { display: none; }
}

/* ======================================================= reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ================================================================= print */
@media print {
  body { background: #fff; color: #000; }
  .topbar, .site-header, .sidebar, .rail, .site-footer, .pager, .page-caption, .anchor, .search-modal, .toast, .doc-actions { display: none !important; }
  .layout, .layout.no-rail { display: block; }
  .content { max-width: none; padding: 0; }
  .page { break-inside: avoid; }
  .page-frame { box-shadow: none; }
}
