/* =====================================================================
   AnchorWorks — The Constraint Strategy · Living War Board (Brief 018)
   Brand: 70/15/10/5 · DM Serif Display + Inter · gold earned, never loud
   Tokens copied from the live site (Three/css/styles-kk.css) so the page
   is self-contained but pixel-consistent with myanchorworks.com.
   ===================================================================== */

/* ---------- Tokens ---------- */
:root {
  --ocean:      #1F2326;
  --ocean-2:    #23282b;
  --panel:      #181C1E;
  --charcoal:   #0F1214;
  --charcoal-2: #0a0c0d;
  --bone:       #EAE6DF;
  --gold:       #C6A66A;
  --gold-deep:  #a8884f;
  --gold-bright:#e3c98c;
  --steel:      #9AA1A6;

  --bone-dim:   rgba(234, 230, 223, 0.66);
  --bone-faint: rgba(234, 230, 223, 0.40);
  --hairline:   rgba(234, 230, 223, 0.10);
  --hairline-2: rgba(234, 230, 223, 0.06);
  --gold-glow:  rgba(198, 166, 106, 0.22);
  --gold-tint:  rgba(198, 166, 106, 0.08);
  --gold-line:  rgba(198, 166, 106, 0.30);
  --alarm:      #c0563f; /* warning lights only — used very sparingly */

  --serif: "DM Serif Display", Georgia, "Times New Roman", serif;
  --sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  --container: 1140px;
  --radius: 14px;
  --radius-lg: 22px;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --section-y: clamp(4rem, 9vw, 7rem);

  --fs-display: clamp(2.6rem, 6vw, 4.4rem);
  --fs-h2: clamp(1.9rem, 3.6vw, 2.8rem);
  --fs-h3: clamp(1.25rem, 2vw, 1.55rem);
  --fs-lead: clamp(1.05rem, 1.6vw, 1.25rem);
  --fs-body: clamp(.95rem, 1.2vw, 1.05rem);
  --fs-sm: .85rem;
  --fs-label: .72rem;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background: var(--ocean);
  color: var(--bone);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--gold-bright); text-decoration: none; }
b, strong { color: var(--bone); font-weight: 600; }

.container { width: min(var(--container), 92vw); margin-inline: auto; }

/* ---------- Grain plate ---------- */
.grain::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: url(assets/grain-tile.webp) repeat; opacity: .07; mix-blend-mode: overlay;
}
.grain { position: relative; }
.grain > * { position: relative; z-index: 1; }

/* ---------- Top strip ---------- */
.topstrip {
  position: sticky; top: 0; z-index: 50;
  background: rgba(15, 18, 20, .92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--hairline-2);
}
.topstrip__inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: .65rem 0; gap: 1rem;
}
.topstrip .mark { display: flex; align-items: center; gap: .6rem; }
.topstrip .mark img { height: 20px; width: auto; }
.topstrip .mark span {
  font-size: var(--fs-label); letter-spacing: .22em; text-transform: uppercase;
  color: var(--bone-faint); font-weight: 600;
}
.topstrip .asof {
  font-size: var(--fs-label); letter-spacing: .18em; text-transform: uppercase;
  color: var(--steel);
}
.topstrip .asof b { color: var(--gold); font-weight: 600; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(120% 80% at 50% -10%, rgba(198, 166, 106, .10), transparent 55%),
    linear-gradient(180deg, rgba(10, 12, 13, .82), rgba(15, 18, 20, .96)),
    var(--charcoal);
  padding: clamp(5rem, 11vw, 8.5rem) 0 clamp(3.5rem, 7vw, 5.5rem);
  text-align: center;
}
.hero__bg {
  position: absolute; inset: 0; background: url(assets/cover.jpg) center/cover no-repeat;
  opacity: .22; filter: saturate(.7) brightness(.7);
}
.hero__scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,12,13,.55), rgba(15,18,20,.94) 78%); }
.eyebrow {
  display: inline-block; font-size: var(--fs-label); font-weight: 600;
  letter-spacing: .3em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.1rem;
}
.hero h1 {
  font-family: var(--serif); font-weight: 400; font-size: var(--fs-display);
  line-height: 1.02; letter-spacing: -.5px; margin-bottom: 1.1rem;
}
h1 em, h2 em { font-style: italic; color: var(--gold-bright); }
.hero .lead {
  font-size: var(--fs-lead); color: var(--bone-dim); max-width: 62ch; margin: 0 auto 1rem;
}
.hero .intent {
  font-family: var(--serif); font-size: clamp(1.15rem, 2.1vw, 1.5rem); color: var(--bone);
  max-width: 34em; margin: 1.4rem auto 0;
}
.hero .intent b { color: var(--gold-bright); font-weight: 400; }

/* countdown chips */
.chips { display: flex; flex-wrap: wrap; gap: .7rem; justify-content: center; margin-top: 2.2rem; }
.chip {
  border: 1px solid var(--hairline); border-radius: 999px; padding: .5rem 1.1rem;
  background: rgba(24, 28, 30, .65); display: flex; align-items: baseline; gap: .55rem;
  font-size: var(--fs-sm);
}
.chip .k { font-size: var(--fs-label); letter-spacing: .18em; text-transform: uppercase; color: var(--bone-faint); font-weight: 600; }
.chip .v { font-family: var(--serif); font-size: 1.15rem; color: var(--gold-bright); }
.chip--now { border-color: var(--gold-line); box-shadow: 0 0 24px -8px var(--gold-glow); }
.chip--past .v { color: var(--steel); }

/* ---------- Sections ---------- */
.section { padding: var(--section-y) 0; position: relative; }
.section--alt { background: var(--panel); }
.section--deep { background: linear-gradient(180deg, var(--charcoal), var(--charcoal-2)); }
.section-head { max-width: 760px; margin-bottom: 2.6rem; }
.section-head h2 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h2); line-height: 1.06; margin-bottom: .8rem; }
.section-head .lead { color: var(--bone-dim); font-size: var(--fs-lead); }
.secnum { font-family: var(--serif); color: var(--gold); font-size: 1rem; letter-spacing: .06em; display: block; margin-bottom: .4rem; }
.rule { height: 1px; background: linear-gradient(90deg, var(--gold), transparent); max-width: 120px; margin: 1rem 0 1.4rem; }

/* ---------- The constraint statement ---------- */
.verdict {
  border-left: 2px solid var(--gold); padding: 1.2rem 0 1.2rem 1.8rem; margin: 0 0 2.2rem;
  font-family: var(--serif); font-size: clamp(1.3rem, 2.6vw, 1.9rem); line-height: 1.28; max-width: 30em;
}
.verdict b { color: var(--gold-bright); font-weight: 400; }
.tag {
  display: inline-block; font-size: var(--fs-label); font-weight: 700; letter-spacing: .22em;
  text-transform: uppercase; padding: .35rem .9rem; border-radius: 999px;
  border: 1px solid var(--gold-line); color: var(--gold-bright); background: var(--gold-tint);
}
.tag--alarm { border-color: rgba(192, 86, 63, .5); color: #d9836c; background: rgba(192, 86, 63, .08); }

/* stats row */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--hairline-2); border: 1px solid var(--hairline-2); border-radius: var(--radius); overflow: hidden; margin-top: 2rem; }
.stat { background: var(--ocean-2); padding: 1.4rem 1.2rem; }
.section--deep .stat, .section--alt .stat { background: rgba(31, 35, 38, .55); }
.stat .n { font-family: var(--serif); font-size: clamp(1.8rem, 3.4vw, 2.6rem); color: var(--gold-bright); line-height: 1; }
.stat .l { font-size: var(--fs-sm); color: var(--bone-faint); margin-top: .45rem; }
.stat--alarm .n { color: #d9836c; }

/* zero math */
.zeromath { display: grid; gap: .55rem; margin-top: 2rem; max-width: 640px; }
.zeromath div {
  display: flex; justify-content: space-between; gap: 1rem; font-size: var(--fs-body);
  color: var(--bone-dim); border-bottom: 1px dashed var(--hairline); padding-bottom: .55rem;
}
.zeromath div b { font-family: var(--serif); color: var(--gold-bright); font-weight: 400; white-space: nowrap; }

/* ---------- Pipeline ---------- */
.pipeviz { margin: 2.4rem 0 1rem; overflow-x: auto; padding-bottom: .5rem; }
.pipeviz svg { min-width: 860px; width: 100%; height: auto; display: block; }
.pipeviz .node-label { font-family: var(--sans); font-size: 12.5px; font-weight: 600; fill: var(--bone); letter-spacing: .04em; }
.pipeviz .node-sub { font-family: var(--sans); font-size: 10.5px; fill: var(--bone-faint); }
.pipeviz .node-cap { font-family: var(--serif); font-size: 15px; fill: var(--gold-bright); }
.pipeviz .valve-label { font-family: var(--sans); font-size: 10.5px; font-weight: 700; fill: #d9836c; letter-spacing: .14em; }

.flowline { stroke-dasharray: 6 7; animation: flow 1.6s linear infinite; }
@keyframes flow { to { stroke-dashoffset: -13; } }
.pulse { animation: pulse 2.2s var(--ease) infinite; transform-origin: center; }
@keyframes pulse { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }

/* pipeline table */
.ptable { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); margin-top: 1.6rem; }
.ptable th {
  text-align: left; font-size: var(--fs-label); letter-spacing: .18em; text-transform: uppercase;
  color: var(--bone-faint); font-weight: 600; padding: .7rem .9rem; border-bottom: 1px solid var(--hairline);
}
.ptable td { padding: .85rem .9rem; border-bottom: 1px solid var(--hairline-2); vertical-align: top; color: var(--bone-dim); }
.ptable td:first-child { color: var(--bone); font-weight: 600; white-space: nowrap; }
.ptable .zero { color: #d9836c; font-weight: 700; }
.ptable .ev { font-style: italic; color: var(--bone-faint); }
.tablewrap { overflow-x: auto; }
.ptable { min-width: 720px; }

/* constraint queue */
.queue { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-top: 2.4rem; }
.qcard { border: 1px solid var(--hairline); border-radius: var(--radius); padding: 1.2rem; background: rgba(24, 28, 30, .5); }
.qcard .qn { font-family: var(--serif); color: var(--gold); font-size: 1.4rem; }
.qcard h4 { font-size: var(--fs-body); margin: .5rem 0 .3rem; }
.qcard p { font-size: var(--fs-sm); color: var(--bone-faint); }

/* ---------- Five steps ---------- */
.steps { display: grid; gap: 1.1rem; counter-reset: step; margin-top: .6rem; }
.stepcard {
  display: grid; grid-template-columns: 72px 1fr; gap: 1.4rem; align-items: start;
  border: 1px solid var(--hairline); border-radius: var(--radius-lg);
  background: rgba(24, 28, 30, .5); padding: 1.6rem 1.7rem;
}
.stepcard .sn {
  font-family: var(--serif); font-size: 2.2rem; color: var(--gold); line-height: 1;
  border-right: 1px solid var(--hairline-2); padding-right: 1.1rem; height: 100%;
}
.stepcard h3 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h3); margin-bottom: .35rem; }
.stepcard h3 span { color: var(--bone-faint); font-family: var(--sans); font-size: var(--fs-sm); margin-left: .6rem; }
.stepcard p, .stepcard li { color: var(--bone-dim); font-size: var(--fs-body); }
.stepcard ul { list-style: none; margin-top: .6rem; display: grid; gap: .45rem; }
.stepcard li { padding-left: 1.3rem; position: relative; }
.stepcard li::before { content: "—"; position: absolute; left: 0; color: var(--gold); }

/* elevate mini-table */
.mini { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); margin-top: .9rem; }
.mini th { text-align: left; font-size: var(--fs-label); letter-spacing: .16em; text-transform: uppercase; color: var(--bone-faint); padding: .5rem .6rem; border-bottom: 1px solid var(--hairline); }
.mini td { padding: .6rem; border-bottom: 1px solid var(--hairline-2); color: var(--bone-dim); }
.mini td:first-child { color: var(--gold-bright); font-family: var(--serif); }

/* ---------- Moves ---------- */
.movegrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; margin-top: 2.2rem; }
.move {
  border: 1px solid var(--hairline); border-radius: var(--radius-lg); overflow: hidden;
  background: linear-gradient(180deg, rgba(35, 40, 43, .7), rgba(24, 28, 30, .7));
  display: flex; flex-direction: column;
}
.move__head { padding: 1.4rem 1.5rem 1rem; border-bottom: 1px solid var(--hairline-2); }
.move__head .mn { font-size: var(--fs-label); letter-spacing: .24em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.move__head h3 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h3); margin-top: .45rem; }
.move__body { padding: 1.1rem 1.5rem 1.5rem; display: grid; gap: .65rem; font-size: var(--fs-sm); color: var(--bone-dim); }
.move__body .kv { display: grid; grid-template-columns: 88px 1fr; gap: .6rem; }
.move__body .kv .k { color: var(--bone-faint); font-size: var(--fs-label); letter-spacing: .14em; text-transform: uppercase; font-weight: 600; padding-top: .15rem; }

.covenant {
  margin-top: 2.4rem; border: 1px solid var(--gold-line); border-radius: var(--radius-lg);
  background: var(--gold-tint); padding: 2rem 2.2rem; text-align: center;
}
.covenant .k { font-size: var(--fs-label); letter-spacing: .3em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.covenant p { font-family: var(--serif); font-size: clamp(1.25rem, 2.4vw, 1.7rem); margin-top: .7rem; line-height: 1.3; }

/* ---------- Don't-do ---------- */
.parkgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-top: 2.2rem; }
.park {
  border: 1px dashed var(--hairline); border-radius: var(--radius); padding: 1.2rem 1.3rem;
  background: rgba(15, 18, 20, .35);
}
.park .tag { margin-bottom: .7rem; }
.park h4 { font-size: var(--fs-body); color: var(--bone-dim); margin-bottom: .3rem; }
.park p { font-size: var(--fs-sm); color: var(--bone-faint); }

/* ---------- Gates timeline ---------- */
.timeline { position: relative; margin: 3.2rem 0 2.6rem; }
.timeline__track { position: absolute; left: 0; right: 0; top: 9px; height: 2px; background: var(--hairline); }
.timeline__fill { position: absolute; left: 0; top: 9px; height: 2px; background: linear-gradient(90deg, var(--gold-deep), var(--gold)); width: 0; transition: width 1.2s var(--ease); }
.timeline__today {
  position: absolute; top: -7px; width: 2px; height: 34px; background: var(--gold-bright);
  box-shadow: 0 0 18px -2px var(--gold-glow);
}
.timeline__today::after {
  content: "TODAY"; position: absolute; top: -1.4rem; left: 50%; transform: translateX(-50%);
  font-size: var(--fs-label); letter-spacing: .2em; color: var(--gold-bright); font-weight: 700;
}
.timeline__stops { display: grid; grid-template-columns: repeat(5, 1fr); gap: .8rem; }
.stop { padding-top: 2rem; position: relative; }
.stop::before {
  content: ""; position: absolute; top: 3px; left: 0; width: 14px; height: 14px; border-radius: 50%;
  background: var(--ocean); border: 2px solid var(--steel);
}
.stop--gate::before { border-color: var(--gold); }
.stop--done::before { background: var(--gold); border-color: var(--gold); }
.stop .d { font-size: var(--fs-label); letter-spacing: .18em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.stop h4 { font-family: var(--serif); font-weight: 400; font-size: 1.1rem; margin: .3rem 0 .35rem; }
.stop p { font-size: var(--fs-sm); color: var(--bone-faint); max-width: 24ch; }

.gatecards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; margin-top: 1.4rem; }
.gate { border: 1px solid var(--hairline); border-radius: var(--radius-lg); padding: 1.5rem 1.6rem; background: rgba(24, 28, 30, .55); }
.gate .k { font-size: var(--fs-label); letter-spacing: .24em; text-transform: uppercase; color: var(--gold); font-weight: 700; }
.gate h3 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h3); margin: .4rem 0 .5rem; }
.gate p { font-size: var(--fs-sm); color: var(--bone-dim); }
.gate .fallback { margin-top: .8rem; padding-top: .8rem; border-top: 1px dashed var(--hairline-2); color: var(--bone-faint); font-size: var(--fs-sm); }
.gate .fallback b { color: var(--steel); font-size: var(--fs-label); letter-spacing: .14em; text-transform: uppercase; }

.order {
  margin-top: 2.4rem; display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem;
}
.ordercard { border: 1px solid var(--hairline); border-radius: var(--radius-lg); padding: 1.6rem 1.7rem; background: rgba(15, 18, 20, .4); }
.ordercard h4 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h3); margin-bottom: .5rem; }
.ordercard p { font-size: var(--fs-body); color: var(--bone-dim); }
.funnelnums { display: flex; align-items: center; gap: .9rem; margin-top: 1rem; font-family: var(--serif); color: var(--gold-bright); font-size: 1.5rem; }
.funnelnums span { color: var(--bone-faint); font-family: var(--sans); font-size: var(--fs-sm); }
.funnelnums .arr { color: var(--gold); }

/* ---------- Scorecard & ritual ---------- */
.duo { display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.2rem; align-items: start; margin-top: 2.2rem; }
.scorebox { border: 1px solid var(--hairline); border-radius: var(--radius-lg); overflow: hidden; }
.scorebox table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.scorebox th { text-align: left; font-size: var(--fs-label); letter-spacing: .16em; text-transform: uppercase; color: var(--bone-faint); font-weight: 600; padding: .8rem 1.1rem; background: rgba(15, 18, 20, .6); border-bottom: 1px solid var(--hairline); }
.scorebox td { padding: .8rem 1.1rem; border-bottom: 1px solid var(--hairline-2); color: var(--bone-dim); }
.scorebox td.v { font-family: var(--serif); color: var(--gold-bright); white-space: nowrap; }
.scorebox tr:last-child td { border-bottom: 0; }

.ritual { counter-reset: r; display: grid; gap: .9rem; }
.ritual li {
  list-style: none; counter-increment: r; position: relative; padding-left: 2.6rem;
  color: var(--bone-dim); font-size: var(--fs-body);
}
.ritual li::before {
  content: counter(r); position: absolute; left: 0; top: .1rem; width: 1.7rem; height: 1.7rem;
  border-radius: 50%; border: 1px solid var(--gold-line); color: var(--gold-bright);
  font-family: var(--serif); display: grid; place-items: center; font-size: .95rem;
}
.ritual li b { color: var(--bone); }

.question {
  margin-top: 2.8rem; text-align: center; padding: 2.6rem 1.4rem;
  border-top: 1px solid var(--hairline-2); border-bottom: 1px solid var(--hairline-2);
}
.question p { font-family: var(--serif); font-size: clamp(1.4rem, 3vw, 2.1rem); line-height: 1.25; max-width: 26em; margin-inline: auto; }
.question p em { color: var(--gold-bright); }

/* ---------- Footer ---------- */
.remap { text-align: center; max-width: 640px; margin-inline: auto; }
.remap h2 { font-family: var(--serif); font-weight: 400; font-size: var(--fs-h2); margin-bottom: .8rem; }
.remap p { color: var(--bone-dim); font-size: var(--fs-lead); }
.versionchip {
  display: inline-flex; gap: .8rem; align-items: center; margin-top: 2.2rem;
  border: 1px solid var(--hairline); border-radius: 999px; padding: .55rem 1.3rem;
  font-size: var(--fs-label); letter-spacing: .18em; text-transform: uppercase; color: var(--bone-faint);
}
.versionchip b { color: var(--gold); font-weight: 600; }
.site-footer { border-top: 1px solid var(--hairline-2); padding: 2.2rem 0 2.6rem; text-align: center; }
.site-footer img { height: 26px; margin: 0 auto .8rem; width: auto; }
.site-footer p { font-size: var(--fs-label); letter-spacing: .2em; text-transform: uppercase; color: var(--bone-faint); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .flowline, .pulse { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .stats, .queue, .parkgrid { grid-template-columns: repeat(2, 1fr); }
  .movegrid, .gatecards { grid-template-columns: 1fr; }
  .duo, .order { grid-template-columns: 1fr; }
  .timeline__stops { grid-template-columns: repeat(2, 1fr); row-gap: 1.6rem; }
  .timeline__track, .timeline__fill, .timeline__today { display: none; }
  .stepcard { grid-template-columns: 1fr; }
  .stepcard .sn { border-right: 0; border-bottom: 1px solid var(--hairline-2); padding: 0 0 .6rem; height: auto; }
}
@media (max-width: 560px) {
  .stats, .queue, .parkgrid, .timeline__stops { grid-template-columns: 1fr; }
  .topstrip .asof { display: none; }
}

/* ---------- Print ---------- */
@media print {
  .topstrip { position: static; }
  .reveal { opacity: 1; transform: none; }
  body { background: #fff; }
}
