/* Warrior Mind Science — site styles. One file, no build step. */

@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces-latin-full-normal.woff2") format("woff2-variations"),
       url("fonts/fraunces-latin-full-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces-latin-full-italic.woff2") format("woff2-variations"),
       url("fonts/fraunces-latin-full-italic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("fonts/inter-latin-wght-normal.woff2") format("woff2-variations"),
       url("fonts/inter-latin-wght-normal.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #13100c;          /* warm black */
  --bg-2: #1a1611;
  --bg-3: #221d16;
  --line: #3a3127;
  --line-soft: #2a241c;
  --text: #f1e9dc;
  --muted: #bdb19f;       /* 8.9:1 on --bg */
  --gold: #d0a94f;        /* 8.6:1 on --bg */
  --gold-hi: #e6c67c;
  --ink: #13100c;
  --warn-bg: #2a2114;
  --serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1120px;
  --gutter: 20px;
  --radius: 14px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

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

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

:focus-visible {
  outline: 3px solid var(--gold-hi);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 10;
  background: var(--gold); color: var(--ink); padding: 10px 16px;
  border-radius: 8px; font-weight: 600; text-decoration: none;
}
.skip-link:focus { top: 12px; }

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

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Type ---------- */
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 450;
  font-variation-settings: "SOFT" 30, "WONK" 0;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.35rem, 7.2vw, 4.4rem); font-variation-settings: "SOFT" 40, "WONK" 0, "opsz" 144; }
h2 { font-size: clamp(1.7rem, 4.4vw, 2.6rem); font-variation-settings: "SOFT" 30, "WONK" 0, "opsz" 96; }
h3 { font-size: 1.35rem; font-variation-settings: "SOFT" 20, "WONK" 0, "opsz" 36; }
p { margin: 0 0 1em; }
.lede { font-size: 1.18rem; color: var(--muted); max-width: 38em; }
.eyebrow {
  font-family: var(--sans); font-size: 0.78rem; font-weight: 600;
  letter-spacing: 0.16em; text-transform: uppercase; color: var(--gold);
  margin: 0 0 1rem;
}
.muted { color: var(--muted); }
.small { font-size: 0.9rem; }
em.gold, .gold { color: var(--gold); }

/* ---------- Header ---------- */
.site-header { border-bottom: 1px solid var(--line-soft); }
.site-header .wrap {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 10px 24px; padding-top: 16px; padding-bottom: 16px;
}
.brand {
  display: inline-flex; align-items: center; gap: 12px;
  color: var(--text); text-decoration: none;
  font-family: var(--serif); font-size: 1.2rem; font-weight: 500;
  font-variation-settings: "SOFT" 50, "opsz" 24; letter-spacing: 0.005em;
}
.brand svg { width: 38px; height: 38px; color: var(--gold); flex: none; }
.brand:hover { color: var(--gold-hi); }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px 22px; flex-wrap: wrap; align-items: center; }
.site-nav a { color: var(--text); text-decoration: none; font-size: 0.97rem; padding: 6px 0; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--gold-hi); }
.site-nav a[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--gold); text-underline-offset: 8px; }
.site-nav .nav-cta { border: 1px solid var(--gold); color: var(--gold-hi); padding: 7px 14px; border-radius: 999px; }
.site-nav .nav-cta:hover { background: var(--gold); color: var(--ink); }

@media (max-width: 560px) {
  .site-nav { width: 100%; border-top: 1px solid var(--line-soft); padding-top: 8px; }
  .site-nav ul { justify-content: space-between; gap: 6px 12px; }
  .site-nav .nav-cta { padding: 5px 12px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px; border-radius: 999px;
  font: 600 1rem/1.2 var(--sans); text-decoration: none; cursor: pointer;
  border: 1px solid var(--gold); transition: background .15s, color .15s;
}
.btn-primary { background: var(--gold); color: var(--ink); }
.btn-primary:hover { background: var(--gold-hi); border-color: var(--gold-hi); color: var(--ink); }
.btn-ghost { background: transparent; color: var(--gold-hi); }
.btn-ghost:hover { background: var(--bg-3); color: var(--text); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

/* ---------- Sections ---------- */
.section { padding: 72px 0; border-top: 1px solid var(--line-soft); }
.section:first-of-type { border-top: 0; }
.section-head { max-width: 44em; margin-bottom: 36px; }
@media (min-width: 900px) { .section { padding: 104px 0; } }

/* ---------- Hero ---------- */
.hero { padding: 56px 0 72px; position: relative; overflow: hidden; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
.hero h1 .line2 { display: block; font-style: italic; color: var(--gold); font-weight: 400; font-variation-settings: "SOFT" 100, "WONK" 1, "opsz" 144; }
.hero-mark { color: var(--gold); width: min(64vw, 260px); height: auto; aspect-ratio: 1 / 1; margin: 0 auto; opacity: .95; }
@media (min-width: 900px) {
  .hero { padding: 96px 0 112px; }
  .hero .wrap { grid-template-columns: 1.35fr 0.65fr; }
  .hero-mark { width: 100%; max-width: 380px; }
}
@media (max-width: 899px) { .hero-mark { order: -1; width: 120px; margin: 0; } }

.page-hero { padding: 56px 0 24px; }
@media (min-width: 900px) { .page-hero { padding: 88px 0 32px; } }

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

.card {
  background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px; display: flex; flex-direction: column;
}
.card h3 { margin-bottom: 0.4em; }
.card p:last-child { margin-bottom: 0; }
.card .card-foot { margin-top: auto; padding-top: 18px; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; }
.card .num { font-family: var(--serif); font-style: italic; color: var(--gold); font-size: 1.05rem; margin: 0 0 14px; }
.meta { font-size: 0.85rem; color: var(--muted); letter-spacing: 0.02em; }
.ext::after { content: " \2197"; }

/* ---------- Signup ---------- */
.signup {
  background: linear-gradient(180deg, var(--bg-3), var(--bg-2));
  border: 1px solid var(--gold); border-radius: 20px; padding: 28px;
  display: grid; gap: 28px;
}
@media (min-width: 900px) { .signup { grid-template-columns: 1.1fr 0.9fr; padding: 48px; gap: 48px; align-items: center; } }
.signup h2 { margin-bottom: 0.3em; }
.ticks { list-style: none; padding: 0; margin: 18px 0 0; }
.ticks li { padding-left: 28px; position: relative; margin-bottom: 8px; }
.ticks li::before { content: ""; position: absolute; left: 4px; top: 0.62em; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--gold); }
.form label { display: block; font-weight: 600; margin-bottom: 8px; }
.form input[type="email"] {
  width: 100%; min-height: 52px; padding: 12px 16px; font: 1rem var(--sans);
  color: var(--text); background: var(--bg); border: 1px solid var(--muted); border-radius: 10px;
}
.form input[type="email"]::placeholder { color: #8f8574; }
.form input[type="email"]:focus-visible { outline: 3px solid var(--gold-hi); outline-offset: 2px; border-color: var(--gold); }
.consent { display: flex; gap: 12px; align-items: flex-start; margin: 16px 0 18px; font-size: 0.92rem; color: var(--muted); }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--gold); }
.consent label { font-weight: 400; margin: 0; }
.form .btn { width: 100%; }
.form .fine { font-size: 0.85rem; color: var(--muted); margin: 14px 0 0; }

/* ---------- Grades ---------- */
.grade { border-top: 3px solid var(--gold); }
.grade .tag {
  display: inline-block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 10px;
}
.grade:nth-child(2) { border-top-color: #b5945a; }
.grade:nth-child(3) { border-top-color: #8a7550; }

/* ---------- Notes ---------- */
.note {
  border-left: 3px solid var(--gold); background: var(--warn-bg);
  padding: 16px 20px; border-radius: 0 10px 10px 0; font-size: 0.95rem; color: var(--text);
}
.note p:last-child { margin-bottom: 0; }
.note strong { color: var(--gold-hi); }
.draft-banner {
  background: var(--warn-bg); border: 1px dashed var(--gold); color: var(--gold-hi);
  border-radius: 10px; padding: 12px 16px; font-weight: 600; margin: 0 0 28px;
}

/* ---------- Shop ---------- */
.product { gap: 0; }
.product .status {
  align-self: flex-start; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); margin-bottom: 14px;
}
.product .status.live { border-color: var(--gold); color: var(--gold-hi); }
.price { font-family: var(--serif); font-size: 2rem; line-height: 1; margin: 6px 0 16px; font-variation-settings: "opsz" 72; }
.price small { font-family: var(--sans); font-size: 0.85rem; color: var(--muted); margin-left: 6px; }
.product ul { padding-left: 1.15em; margin: 0 0 1em; }
.product li { margin-bottom: 6px; }
.product details { margin: 6px 0 4px; border-top: 1px solid var(--line-soft); padding-top: 12px; }
.product summary { cursor: pointer; color: var(--gold-hi); font-weight: 600; }
.product details[open] summary { margin-bottom: 10px; }
.featured-product { border-color: var(--gold); }
@media (min-width: 980px) { .product-wide { grid-column: span 2; } }
.later { border-style: dashed; background: transparent; }

/* ---------- Drill library ---------- */
.drill-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
@media (min-width: 760px) { .drill-list { grid-template-columns: repeat(2, 1fr); } }
.drill-list li { margin: 0; }
.drill-list .card { height: 100%; }
.drill-list h2 { font-size: 1.25rem; font-variation-settings: "SOFT" 20, "opsz" 36; margin-bottom: 0.4em; }

/* ---------- Photo slot ---------- */
.photo-slot {
  aspect-ratio: 4 / 5; border: 1px solid var(--line); border-radius: var(--radius);
  display: grid; place-items: center; text-align: center; padding: 24px; color: var(--muted);
  background: radial-gradient(circle at 50% 40%, var(--bg-3), var(--bg-2));
}
.photo-slot svg { width: 46%; height: auto; aspect-ratio: 1 / 1; color: var(--gold); opacity: .55; margin: 0 auto 14px; }
.photo-slot .photo-caption { margin: 0; font-family: var(--serif); font-style: italic; font-size: 1.05rem; color: var(--muted); letter-spacing: 0.01em; }

.split { display: grid; gap: 32px; align-items: center; }
@media (min-width: 900px) { .split { grid-template-columns: 0.8fr 1.2fr; gap: 64px; } }

/* ---------- Prose (about, legal) ---------- */
.prose { max-width: 44em; }
.prose h2 { font-size: clamp(1.45rem, 3.4vw, 1.9rem); margin-top: 1.8em; }
.prose h2:first-child { margin-top: 0; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: 0.4em; }

.legal-nav { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 24px; padding: 0; list-style: none; font-size: 0.95rem; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); background: #0e0c09; padding: 56px 0 40px; margin-top: 40px; font-size: 0.95rem; }
.footer-grid { display: grid; gap: 32px; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; } }
.site-footer h2 { font-family: var(--sans); font-size: 0.78rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); margin: 0 0 12px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer a { color: var(--text); text-decoration: none; }
.site-footer a:hover { color: var(--gold-hi); text-decoration: underline; }
.footer-legal { border-top: 1px solid var(--line-soft); margin-top: 40px; padding-top: 24px; color: var(--muted); font-size: 0.88rem; }
.footer-legal p { margin-bottom: 0.6em; }
.footer-legal address { font-style: normal; }
.prose .legal-nav { padding: 0; }

/* ---------- Evidence grade line (drill cards) ---------- */
.grade-line { font-size: 0.88rem; line-height: 1.5; color: var(--text); margin: 4px 0 0; padding-top: 12px; border-top: 1px solid var(--line-soft); }
.grade-line .grade-label {
  display: inline-block; margin-right: 6px; font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--gold);
}
.card .grade-line + .card-foot { padding-top: 16px; }
.nowrap { white-space: nowrap; }
