/* Initiative. Tokens: printout paper, green-bar, ink, ribbon red (used only for initiative prints). */
:root {
  --paper: #fafbf7;
  --sheet: #ffffff;
  --tint: #f0f4ee;
  --bar: #e3eedf;
  --ink: #17202a;
  --muted: #4f5a55;
  --rule: #cbd5cc;
  --red: #c3262e;
  --focus: #1d4ed8;
  --radius: 4px;
  --gutter: 16px;
  --max: 1160px;
  --row: 26px;
  --font-display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --font-body: "Public Sans", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0e1412; --sheet: #121a16; --tint: #131b17; --bar: #1b2a21;
    --ink: #e8efe9; --muted: #aab8ae; --rule: #2f3f35; --red: #ff6f6f; --focus: #8ab4ff;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0e1412; --sheet: #121a16; --tint: #131b17; --bar: #1b2a21;
  --ink: #e8efe9; --muted: #aab8ae; --rule: #2f3f35; --red: #ff6f6f; --focus: #8ab4ff;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--font-body);
  -webkit-text-size-adjust: 100%;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
p { margin: 0; }
h1, h2 { font-family: var(--font-display); font-weight: 900; text-transform: uppercase; line-height: 0.9; margin: 0; }
h1 { font-size: clamp(3.75rem, 9vw, 7.5rem); letter-spacing: -0.005em; }
h2 { font-size: clamp(2.25rem, 4.6vw, 3.5rem); }
h3 { font: 700 1.15rem/1.3 var(--font-body); margin: 0; }
.mono { font-family: var(--font-mono); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.skip { position: absolute; left: var(--gutter); top: -60px; background: var(--ink); color: var(--paper); padding: 10px 14px; z-index: 10; }
.skip:focus { top: 12px; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 720px) { .wrap { padding: 0 32px; } }

/* Header */
.top { position: sticky; top: 0; z-index: 5; background: var(--paper); border-bottom: 1px solid var(--rule); }
.top-row { display: flex; align-items: center; justify-content: space-between; min-height: 60px; }
.brand { font: 900 1.6rem/1 var(--font-display); text-transform: uppercase; text-decoration: none; }
nav { display: flex; }
nav a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 12px; color: var(--muted); font-weight: 500; text-decoration: none; }
nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
nav .nav-apply { color: var(--ink); font-weight: 700; }
@media (max-width: 420px) { nav a:not(.nav-apply) { display: none; } }

/* Button: solid ink, inverts to an outline on hover */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 32px;
  background: var(--ink); color: var(--paper);
  border: 2px solid var(--ink); border-radius: var(--radius);
  font: 700 1rem var(--font-body); text-decoration: none; cursor: pointer;
}
.btn:hover { background: transparent; color: var(--ink); }
.btn[disabled] { opacity: 0.6; cursor: wait; }

/* Hero */
.hero { display: grid; gap: 48px; padding-top: 56px; padding-bottom: 80px; align-items: center; }
@media (min-width: 960px) { .hero { grid-template-columns: 1fr 1fr; gap: 56px; padding-top: 72px; } }
.lede { margin-top: 24px; max-width: 38ch; font-size: 1.2rem; color: var(--muted); }
.price-line { margin-top: 20px; font-weight: 600; }
.hero .btn { margin-top: 28px; }

/* Signature: the profile printed on green-bar paper with tractor-feed holes */
.sheet { margin: 0; }
.profile {
  --hole: radial-gradient(circle, var(--paper) 0 4px, var(--rule) 4px 5px, transparent 5.5px);
  position: relative;
  min-height: calc(var(--row) * 16);
  padding: 0 30px;
  background: var(--hole) left 8px top 0 / 14px calc(var(--row) * 2) repeat-y,
              var(--hole) right 8px top 0 / 14px calc(var(--row) * 2) repeat-y,
              var(--sheet);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  font: 500 15px var(--font-mono);
}
.row { display: grid; grid-template-columns: 4.6em 10ch 1fr; align-items: center; height: var(--row); padding: 0 10px; }
.row.bar { background: var(--bar); }
.px { color: var(--muted); font-size: 12px; }
.poc .px { color: var(--ink); font-weight: 600; }
.tpo { display: flex; height: 100%; align-items: center; }
.poc .tpo { box-shadow: inset 0 -2px 0 var(--ink); }
.l { width: 1ch; opacity: 0; animation: print 0.2s ease-out forwards; animation-delay: var(--delay); }
.single .l { color: var(--red); font-weight: 600; }
.ann {
  display: flex; align-items: center; height: 100%; padding-left: 10px;
  font: 500 12.5px/1.15 var(--font-body); color: var(--ink);
  opacity: 0; animation: print 0.4s ease-out forwards; animation-delay: var(--notes-delay);
}
.in-va .ann { border-left: 2px solid var(--ink); }
.single .ann { border-left: 2px solid var(--red); color: var(--red); font-weight: 600; }
@keyframes print { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .l, .ann { animation: none; opacity: 1; } }
.sheet figcaption { margin-top: 14px; font-size: 0.92rem; color: var(--muted); max-width: 60ch; }
.sheet figcaption .mono { font-size: 0.78rem; border: 1px solid var(--rule); padding: 1px 6px; margin-left: 4px; white-space: nowrap; }
@media (max-width: 520px) {
  .profile { padding: 0 22px; font-size: 13px; }
  .row { grid-template-columns: 4.4em 10ch 1fr; padding: 0 4px; }
  .ann { font-size: 11px; padding-left: 6px; }
}

/* Section rhythm */
.block { padding: 88px 0; }
.tint { background: var(--tint); border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.sub { margin-top: 14px; max-width: 58ch; color: var(--muted); }
p.note { margin-top: 24px; color: var(--muted); font-size: 0.95rem; }
.big { font-size: 1.25rem; font-weight: 600; margin: 20px 0; }
.split { display: grid; gap: 32px; }
@media (min-width: 880px) { .split { grid-template-columns: 1fr 1.6fr; gap: 64px; align-items: start; } }

.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; color: var(--muted); }
.ticks li { position: relative; padding-left: 22px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: 0.8em; width: 12px; height: 2px; background: var(--ink); }
.ticks strong { color: var(--ink); }

/* Program: 12-week ruler with checkpoint weeks filled */
.ruler { display: grid; grid-template-columns: repeat(12, 1fr); margin-top: 48px; border-top: 2px solid var(--ink); }
.ruler span { padding-top: 8px; border-left: 1px solid var(--rule); font: 500 12px var(--font-mono); color: var(--muted); text-align: center; }
.ruler span:first-child { border-left-color: var(--ink); }
.ruler .cp { background: var(--ink); color: var(--paper); padding-bottom: 6px; font-weight: 600; }
.phases { list-style: none; margin: 32px 0 0; padding: 0; display: grid; gap: 40px; }
@media (min-width: 880px) { .phases { grid-template-columns: repeat(3, 1fr); gap: 32px; } }
.phases li { display: flex; flex-direction: column; gap: 10px; color: var(--muted); }
.phases h3 { color: var(--ink); font: 900 2rem/1 var(--font-display); text-transform: uppercase; }
.label { font-size: 0.8rem; }
.done { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--rule); color: var(--ink); }
.done .mono { display: block; font-size: 0.75rem; color: var(--muted); }

/* Your week: schedule by clock time */
.schedule { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.schedule li { display: grid; grid-template-columns: 9.5em 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--rule); color: var(--muted); }
.schedule .mono { font-size: 0.85rem; color: var(--ink); padding-top: 2px; }
.schedule strong { color: var(--ink); }
@media (max-width: 520px) { .schedule li { grid-template-columns: 1fr; gap: 4px; } }

/* Proof */
.proof { display: grid; gap: 40px; }
@media (min-width: 960px) { .proof { grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: center; } }
.shot { margin: 0; }
.shot img { width: 100%; border: 1px solid var(--rule); border-radius: var(--radius); background: #fff; }
.shot figcaption { margin-top: 10px; font-size: 0.9rem; color: var(--muted); }

.fit { display: grid; gap: 32px; }
@media (min-width: 640px) { .fit { grid-template-columns: 1fr 1fr; } }
.fit h3 { margin-bottom: 16px; }

/* Price ledger on green-bar rows */
.ledger { width: 100%; margin-top: 40px; border-collapse: collapse; border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.ledger th, .ledger td { text-align: left; vertical-align: top; padding: 18px 16px; }
.ledger thead th { font: 500 0.78rem var(--font-mono); color: var(--muted); padding-top: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--rule); }
.ledger tbody tr:nth-child(odd) { background: var(--bar); }
.ledger tbody th { font-weight: 700; width: 26%; }
.ledger tbody th .mono { display: block; font-size: 0.78rem; font-weight: 500; color: var(--muted); }
.ledger td.mono { font-size: 1.5rem; font-weight: 600; white-space: nowrap; width: 20%; }
.ledger td:last-child { color: var(--muted); }
@media (max-width: 640px) {
  .ledger thead { display: none; }
  .ledger tr { display: grid; grid-template-columns: 1fr auto; padding: 16px; gap: 6px 16px; }
  .ledger th, .ledger td { padding: 0; width: auto; }
  .ledger td:last-child { grid-column: 1 / -1; }
}

/* Form */
.form { display: grid; gap: 20px; }
.form .btn { justify-self: start; }
.field { display: grid; gap: 8px; }
.field label { font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 48px; padding: 10px 14px;
  font: 400 1rem var(--font-body); color: var(--ink);
  background: var(--sheet); border: 1px solid var(--muted); border-radius: var(--radius);
}
.field textarea { resize: vertical; }
.field [aria-invalid="true"] { border: 2px solid var(--red); }
.check { grid-template-columns: 24px 1fr; align-items: start; gap: 12px; }
.check input { width: 24px; min-height: 24px; height: 24px; margin: 2px 0 0; accent-color: var(--ink); }
.check label { font-weight: 400; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.status { min-height: 1.6em; font-weight: 600; }
.status[data-state="error"] { color: var(--red); }

/* Footer */
.foot { padding-top: 40px; padding-bottom: 48px; display: grid; gap: 12px; color: var(--muted); font-size: 0.9rem; }
.foot strong { color: var(--ink); }
