/* ============================================================
   EPIC UNDERDOGS — SITE STYLES
   Derived from the Brand Playbook v3.0 token system.
   Palette: obsidian ground + 5-step stakes ladder
   (Baseline grey / Confirmed green / In Play blue / Epic purple / Outsized orange)
   Type: Rajdhani (display) + Public Sans (body) + IBM Plex Mono (labels/data)
   ============================================================ */

:root {
  --obsidian: #0a0c14;
  --obsidian-raised: #12151f;
  --obsidian-card: #171b28;
  --frame: #2a3042;
  --frame-bright: #3c4359;
  --text: #e9ebf3;
  --text-soft: #9198b0;
  --text-faint: #5b6280;

  --baseline: #9d9d9d;
  --confirmed: #3fae4a;
  --in-play: #3d8ee0;
  --epic: #a869e8;
  --epic-bright: #c896ff;
  --outsized: #e08a2b;

  --radius-base: 4px;
  --radius-card: 6px;
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 40px;
  --space-5: 64px;

  --font-display: "Rajdhani", sans-serif;
  --font-body: "Public Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--obsidian);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

.wrap { max-width: 1100px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 640px) { .wrap { padding: 0 20px; } }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
  display: block;
}
.eyebrow.accent { color: var(--epic-bright); }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  text-wrap: balance;
  margin: 0;
  color: var(--text);
}
h1 { font-size: clamp(34px, 5vw, 52px); line-height: 1.08; }
h2 { font-size: clamp(24px, 3vw, 30px); line-height: 1.15; }
h3 { font-size: 18px; }
p { color: var(--text-soft); margin: 0; }
p.lede { max-width: 62ch; font-size: 16.5px; }

/* ---------- header / nav ---------- */
header.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(10,12,20,0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--frame);
}
.nav-row { display: flex; align-items: center; justify-content: space-between; padding: 16px 0; }
.lockup-mini { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.lockup-mini svg { width: 30px; height: 30px; flex: none; }
.lockup-mini .b-name { font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: 0.03em; text-transform: uppercase; color: var(--text); }
nav.site-nav { display: flex; gap: 26px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.08em; text-transform: uppercase; }
nav.site-nav a { text-decoration: none; color: var(--text-soft); padding: 4px 0; border-bottom: 2px solid transparent; }
nav.site-nav a:hover, nav.site-nav a[aria-current="page"] { color: var(--epic-bright); border-bottom-color: var(--epic); }
.nav-toggle { display: none; }
.nav-row { position: relative; }
@media (max-width: 720px) {
  nav.site-nav { display: none; }
  nav.site-nav.open {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--obsidian-card);
    border: 1px solid var(--frame);
    border-top: none;
    padding: 16px 20px;
    z-index: 30;
  }
  nav.site-nav.open a { padding: 10px 0; border-bottom: 1px solid var(--frame); }
  nav.site-nav.open a:last-child { border-bottom: none; }
  .nav-toggle { display: block; background: none; border: 1px solid var(--frame-bright); color: var(--text); font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; padding: 8px 14px; border-radius: var(--radius-base); cursor: pointer; }
}

/* ---------- buttons ---------- */
.btn {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  padding: 12px 24px;
  border-radius: var(--radius-base);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn.epic { background: linear-gradient(180deg, #b57bf0, #9350d6); color: #16081f; box-shadow: 0 0 20px rgba(168,105,232,0.4); }
.btn.epic:hover { box-shadow: 0 0 28px rgba(168,105,232,0.6); }
.btn.ghost { background: var(--obsidian-card); color: var(--text); border-color: var(--frame-bright); }
.btn.ghost:hover { border-color: var(--epic); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- hero ---------- */
.hero {
  position: relative;
  padding: var(--space-5) 0 var(--space-4);
  overflow: hidden;
  background: radial-gradient(ellipse 700px 340px at 12% 0%, rgba(168,105,232,0.16), transparent 70%), var(--obsidian);
  border-bottom: 1px solid var(--frame);
}
.hero .eyebrow { margin-bottom: 14px; }
.hero p.tag { max-width: 52ch; margin: 22px 0 30px; font-size: 17.5px; }
.stakes-strip { display: flex; height: 5px; width: 320px; max-width: 100%; border-radius: 4px; overflow: hidden; margin-bottom: 32px; }
.stakes-strip span { flex: 1; }

/* ---------- sections ---------- */
section { padding: var(--space-5) 0; border-bottom: 1px solid var(--frame); }
section:last-of-type { border-bottom: none; }
section > .eyebrow { margin-bottom: 10px; }
section > h2 { margin-bottom: 8px; }
section > p.lede { margin-bottom: var(--space-4); }

/* ---------- card grids ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
@media (max-width: 820px) { .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  border: 1px solid var(--frame);
  border-radius: var(--radius-card);
  background: var(--obsidian-card);
  padding: var(--space-3);
}
.card h3 { margin-bottom: 10px; }
.card p { font-size: 14.5px; }
.card .tag-mono { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--epic-bright); margin-bottom: 10px; display: block; }

/* ---------- stakes ladder (tiers) ---------- */
.tier-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
@media (max-width: 900px) { .tier-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .tier-grid { grid-template-columns: 1fr; } }
.tier-card { border: 1px solid var(--frame); border-radius: var(--radius-card); background: var(--obsidian-card); padding: var(--space-2); border-top: 3px solid var(--c); }
.tier-card .tier-name { font-family: var(--font-display); font-weight: 700; font-size: 15px; text-transform: uppercase; color: var(--c); }
.tier-card .scope { font-family: var(--font-mono); font-size: 11px; color: var(--text-faint); margin: 6px 0 12px; text-transform: uppercase; letter-spacing: 0.06em; }
.tier-card p { font-size: 13px; }

/* ---------- decision brief (case study card) ---------- */
.brief {
  border: 1px solid var(--epic);
  border-radius: var(--radius-card);
  background: linear-gradient(180deg, #1a1526, #120e1c);
  padding: var(--space-3);
  box-shadow: 0 0 24px rgba(168,105,232,0.15);
}
.brief .b-name { font-family: var(--font-display); font-weight: 700; font-size: 19px; color: var(--epic-bright); text-transform: uppercase; }
.brief .b-type { font-family: var(--font-mono); font-size: 11px; color: var(--text-faint); margin: 4px 0 14px; }
.brief .b-stat { display: flex; justify-content: space-between; font-family: var(--font-mono); font-size: 12.5px; color: var(--text-soft); padding: 4px 0; border-top: 1px solid var(--frame); }
.brief .b-stat:first-of-type { border-top: none; }
.brief .b-stat b { color: var(--text); font-weight: 600; }
.brief .b-flavor { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--frame); font-size: 12.5px; color: var(--text-faint); font-style: italic; }
.brief .placeholder-flag { display: inline-block; margin-top: 14px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--outsized); border: 1px solid var(--outsized); border-radius: 3px; padding: 3px 8px; }

/* ---------- table ---------- */
table.data { width: 100%; border-collapse: collapse; font-size: 14px; }
table.data th { text-align: left; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--frame); }
table.data td { padding: 12px; border-bottom: 1px solid var(--frame); color: var(--text-soft); vertical-align: top; }

/* ---------- form ---------- */
form.contact-form { display: flex; flex-direction: column; gap: 16px; max-width: 520px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-faint); }
.field input, .field select, .field textarea {
  background: var(--obsidian-card);
  border: 1px solid var(--frame-bright);
  border-radius: var(--radius-base);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14.5px;
  padding: 11px 14px;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--epic); outline-offset: 1px; }

/* ---------- badge ---------- */
.badge { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; padding: 6px 12px; border-radius: 3px; background: rgba(168,105,232,0.14); color: var(--epic-bright); border: 1px solid rgba(168,105,232,0.4); display: inline-block; }

/* ---------- footer ---------- */
footer.site-footer { padding: var(--space-4) 0 var(--space-5); }
.footer-row { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 24px; }
.footer-row .lockup-mini svg { width: 26px; height: 26px; }
.footer-links { display: flex; gap: 22px; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; }
.footer-links a { text-decoration: none; color: var(--text-soft); }
.footer-links a:hover { color: var(--epic-bright); }
footer .fine { margin-top: 26px; font-family: var(--font-mono); font-size: 11px; color: var(--text-faint); }

.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
