/* ============================================================
   ASHEN THRONE - SITE THEME (single source of truth)
   Loaded FIRST on EVERY page (marketing + hub + mint).
   Owns: fonts, design tokens, the shared site header, the
   shared site footer, and the shared button/eyebrow/title
   primitives. Page stylesheets (style.css, seo.css, mint.css,
   hub.css) hold page-specific layout ONLY and must not
   redeclare tokens or chrome.

   Type system (matches the GAME's declared identity in
   client/styles.css - the site is where these webfonts
   actually load):
     --font-display  Black Han Sans   hero wordmark, section titles
     --font-chrome   Rajdhani         nav, buttons, labels, headers
     --font-mono     JetBrains Mono   data: hashes, prices, terminal
     --font-body     system sans      long-form paragraphs

   Guard: scripts/verify-hub-shell.js (theme-first load order,
   header parity, token ownership).
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Black+Han+Sans&family=Cinzel:wght@500;600;700;800;900&family=Rajdhani:wght@500;600;700&family=JetBrains+Mono:wght@400;500;600;700;800&display=swap');

:root {
  /* Backgrounds */
  --bg:        #060610;
  --bg2:       #0a0a14;
  --bg3:       #0d1520;
  --panel:     #11141c;

  /* Borders */
  --border:    #1a2030;
  --border2:   #2a3040;

  /* Text */
  --text:      #e8e8ec;
  --text-dim:  #a8acb8;
  --text-mute: #6e7280;

  /* Brand & utility */
  --accent:    #4fc3f7;
  --gold:      #d4af37;
  --gold-hot:  #ffd700;
  --kinetic:   #ef5350;
  --electric:  #ff9800;
  --psionic:   #26c6da;
  --ok:        #66bb6a;
  --danger:    #c62828;

  /* Typography */
  --font-display: 'Black Han Sans', 'Arial Black', Impact, sans-serif;
  --font-brand:   'Cinzel', 'Trajan Pro', 'Times New Roman', serif;  /* regal wordmark + section titles */
  --font-chrome:  'Rajdhani', 'Arial Narrow', sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, 'SF Mono', Consolas, Menlo, monospace;
  --font-body:    -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;

  /* Layout */
  --section-padding: 96px 32px;
  --header-h: 58px;

  /* ── mint.css / hub.css alias vocabulary (same values) ── */
  --bg-darker:   #060610;
  --bg-dark:     #0a0a14;
  --bg-slot:     #0d1520;
  --bg-input:    #0d0d18;
  --bg-panel:    #11141c;
  --bg-panel-hover: #1a2235;

  --border-subtle: #1a2030;
  --border-steel:  #2a3040;
  --border-glow:   #4fc3f7;
  --border-gold:   #ffd700;

  --text-primary:   #e8e8ec;
  --text-secondary: #c8c8c8;
  --text-dim2:      #b0b0b0;
  --text-bright:    #ffffff;

  --accent-cyan:   #4fc3f7;
  --accent-red:    #ef5350;
  --accent-green:  #66bb6a;
  --accent-orange: #ff9800;
  --accent-gold:   #ffd700;
  --accent-purple: #e040fb;
  --accent-blue:   #42a5f5;

  --class-kinetic:  #ef5350;
  --class-electric: #ff9800;
  --class-psionic:  #26c6da;

  --rarity-common:    #888888;
  --rarity-rare:      #42a5f5;
  --rarity-epic:      #e040fb;
  --rarity-legendary: #ffd700;

  --font-xs:  9px;
  --font-sm: 10px;
  --font-md: 11px;
  --font-lg: 12px;
  --font-xl: 14px;

  --space-xs:  2px;
  --space-sm:  4px;
  --space-md:  8px;
  --space-lg: 12px;
  --space-xl: 16px;
  --space-2xl:24px;

  --radius-sm:  3px;
  --radius-md:  4px;
  --radius-lg:  6px;
  --radius-xl:  8px;
  --radius-pill:12px;

  --shadow-btn-inset: inset 0 1px 0 rgba(255,255,255,0.06), 0 1px 3px rgba(0,0,0,0.4);
  --glow-cyan:   0 0 12px rgba(79,195,247,0.35);
  --glow-gold:   0 0 12px rgba(255,215,0,0.35);

  --col-max: 1320px;
}

/* ── zh-Hant (Traditional Chinese) font fallbacks ──────────────────────────
   The Latin display faces (Black Han Sans / Cinzel / Rajdhani) carry no CJK
   glyphs; give every stack a Noto TC fallback so translated text renders in a
   matching weight instead of the system default. The Noto stylesheet is
   loaded only when the locale is active: landing/i18n.js injects it at
   runtime (hub pages) and scripts/l10n-landing-bake.js bakes the <link> into
   landing/zh/index.html (data-i18n-fonts="zh-Hant" both ways). */
html[lang="zh-Hant"] {
  --font-display: 'Black Han Sans', 'Noto Sans TC', 'Arial Black', Impact, sans-serif;
  --font-brand:   'Cinzel', 'Noto Serif TC', 'Times New Roman', serif;
  --font-chrome:  'Rajdhani', 'Noto Sans TC', 'Arial Narrow', sans-serif;
  --font-body:    'Noto Sans TC', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
}

::selection { background: rgba(79, 195, 247, 0.28); color: #fff; }

:focus-visible {
  outline: 1px solid var(--accent);
  outline-offset: 2px;
}

/* ============================================================
   SITE HEADER - the ONE header, identical on every page.
   Marketing pages embed the markup statically (via
   _partials.py / index.html); hub pages render it with
   hub-nav.js (adds live session state). Structure:

   <header class="site-header" [data-current="events"]>
     <a class="site-brand" href="/">
       <span class="site-brand-badge">AT</span>
       <span class="site-brand-name">ASHEN THRONE</span>
     </a>
     <nav class="site-tabs">
       <a class="site-tab" href="/#why">WHY</a>
       <a class="site-tab" href="/events">EVENTS</a> …
     </nav>
     <div class="site-header-side">
       <a class="site-tab site-tab-account" href="/account">ACCOUNT</a>
       <a class="site-cta" href="https://play.ashenthr.one">▶ PLAY</a>
     </div>
   </header>
   ============================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 22px;
  height: var(--header-h);
  padding: 0 22px;
  background: rgba(6, 6, 16, 0.92);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header .site-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  flex-shrink: 0;
}

.site-brand-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: 1px solid var(--accent);
  border-radius: 3px;
  color: var(--accent);
  font-family: var(--font-display);
  font-size: 12px;
  line-height: 1;
  box-shadow: 0 0 10px rgba(79, 195, 247, 0.25);
}

.site-brand-name {
  font-family: var(--font-brand);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.2em;
  color: #fff;
  white-space: nowrap;
}

.site-tabs {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
  overflow-x: auto;
  scrollbar-width: none;
}
.site-tabs::-webkit-scrollbar { display: none; }

.site-header .site-tab {
  font-family: var(--font-chrome);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  padding: 6px 10px;
  border-radius: 3px;
  border: 1px solid transparent;
  white-space: nowrap;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.site-header .site-tab:hover { color: #fff; }
.site-header .site-tab.gold { color: var(--gold-hot); }
.site-header .site-tab.gold:hover { filter: brightness(1.18); }
.site-header .site-tab.is-current {
  color: var(--accent);
  border-color: var(--border2);
  background: rgba(79, 195, 247, 0.07);
}
.site-header .site-tab.hubnav-user { color: var(--gold-hot); }

.site-header-side {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.site-header .site-cta {
  font-family: var(--font-chrome);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 3px;
  padding: 7px 16px;
  text-decoration: none;
  white-space: nowrap;
  transition: filter 0.15s;
  box-shadow: 0 0 14px rgba(79, 195, 247, 0.25);
}
.site-header .site-cta:hover { filter: brightness(1.15); }

@media (max-width: 860px) {
  .site-header { gap: 12px; padding: 0 14px; }
  .site-header .site-tab { padding: 6px 7px; letter-spacing: 0.1em; }
  .site-header .site-tab.site-tab-secondary { display: none; }
  .site-brand-name { display: none; }
}

/* ============================================================
   SITE FOOTER - shared across marketing + hub pages.
   (Class names kept from the V2 partials so existing markup
   keeps working; styles live HERE now.)
   ============================================================ */

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg2);
  padding: 56px 32px 28px;
  font-family: var(--font-body);
}

.site-footer-grid {
  max-width: 1080px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 36px;
}
@media (max-width: 900px) {
  .site-footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .site-footer-grid { grid-template-columns: 1fr; }
}

.site-footer-brand-name {
  font-family: var(--font-brand);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 0.16em;
  color: #fff;
  margin-bottom: 10px;
}

.site-footer-brand-tagline {
  font-size: 13px;
  color: var(--text-dim);
  line-height: 1.65;
  margin: 0 0 14px;
  max-width: 320px;
}

.site-footer-press a {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--accent);
  text-decoration: none;
}
.site-footer-press a:hover { text-decoration: underline; }

.site-footer-coltitle {
  font-family: var(--font-chrome);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-mute);
  margin-bottom: 14px;
}

.site-footer .footer-link {
  display: block;
  font-family: var(--font-chrome);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  text-decoration: none;
  padding: 3.5px 0;
  transition: color 0.15s;
}
.site-footer .footer-link:hover { color: #fff; }
.site-footer .footer-link.gold { color: var(--gold-hot); }

.site-footer-legal {
  max-width: 1080px;
  margin: 44px auto 0;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--text-mute);
}
.site-footer-legal .sep { color: var(--border2); }
.site-footer-legal .footer-link { display: inline; padding: 0; font-family: var(--font-mono); font-size: 10px; }
.site-footer-legal-spacer { flex: 1; }
.site-footer-legal .online { color: var(--ok); }

/* ============================================================
   SHARED PRIMITIVES
   ============================================================ */

.eyebrow {
  font-family: var(--font-chrome);
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 0.34em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.eyebrow.gold  { color: var(--gold-hot); }
.eyebrow.kinetic { color: var(--kinetic); }

.section-title {
  font-family: var(--font-brand);
  font-size: clamp(30px, 4.2vw, 48px);
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin: 0;
  line-height: 1.08;
  text-align: center;
}

.section-lead {
  max-width: 620px;
  margin: 20px auto 0;
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.7;
  text-align: center;
  font-family: var(--font-body);
}

.section-header {
  text-align: center;
  margin-bottom: 56px;
}

/* Buttons - marketing API (.btn/.btn-*). Hub/mint pages use the
   .btn--* variants defined in mint.css, retokened to the same
   chrome font so both families render identically. */
.btn {
  display: inline-block;
  padding: 11px 22px;
  font-family: var(--font-chrome);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: 3px;
  border: 1px solid transparent;
  transition: filter 0.15s, transform 0.15s, box-shadow 0.15s;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { filter: brightness(1.18); }

.btn-primary-solid {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
  box-shadow: 0 0 18px rgba(79, 195, 247, 0.3);
}

.btn-ghost {
  border-color: var(--border2);
  color: var(--text);
  background: rgba(10, 10, 20, 0.5);
}
.btn-ghost:hover { border-color: var(--accent); color: #fff; }

.btn-gold {
  background: var(--gold-hot);
  border-color: var(--gold-hot);
  color: #131103;
  box-shadow: var(--glow-gold);
}

.btn-lg { padding: 14px 28px; font-size: 15px; }
.btn-sm { padding: 7px 14px;  font-size: 12px; }
