/* ══════════════════════════════════════════════════════════════
   KEYSTONE AIC
   One stylesheet, three pages. No build step, no dependencies.

   COLOR RULE: orange is structural punctuation, not decoration.
   Roughly three uses per page, maximum. It marks the keystone in
   the arch, the rule above an eyebrow, and one emphasis per page.
   If a fourth orange thing appears, one of them is wrong.
   ══════════════════════════════════════════════════════════════ */

:root{
  --blue:#1f3d7a;
  --blue-ink:#152a54;
  --green:#5aa832;      /* graphics only — too light for text on paper */
  --green-ink:#3f7519;  /* the same green, darkened to clear AA as text */
  --orange:#e8871e;
  --paper:#f7f5ef;
  --paper-2:#efece3;
  --line:#d9d4c7;
  --ink:#1a1c22;
  --muted:#5c6070;

  --serif:"Iowan Old Style","Palatino Linotype",Palatino,Georgia,serif;
  --mono:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;

  /* Header height and logo height move together, and the anchor offset
     is derived from them. Change these two and nothing else. */
  --header-h:120px;
  --logo-h:76px;
}

/* The header is sticky, so anything jumped to via #hash must clear it. */
[id]{scroll-margin-top:calc(var(--header-h) + 16px)}

*{box-sizing:border-box;margin:0;padding:0}
html{scroll-behavior:smooth;background:var(--paper)}

body{
  background:var(--paper);
  color:var(--ink);
  font-family:var(--serif);
  font-size:18px;
  line-height:1.5;
  -webkit-font-smoothing:antialiased;
  min-height:100vh;
  display:flex;
  flex-direction:column;
}

.wrap{max-width:1120px;margin:0 auto;padding:0 28px;width:100%}
.wrap--narrow{max-width:720px}

/* Reading pages centre their single column vertically; the floor does not. */
main{flex:1}
main.centred{display:flex;align-items:center;padding:60px 0}

a{color:inherit}

:focus-visible{
  outline:2px solid var(--orange);
  outline-offset:3px;
  border-radius:2px;
}

/* Present to screen readers and the document outline, invisible on screen. */
.sr-only{
  position:absolute;width:1px;height:1px;overflow:hidden;
  clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap;
}

.skip{
  position:absolute;left:-9999px;top:0;z-index:100;
  background:var(--blue);color:#fff;
  font-family:var(--mono);font-size:13px;letter-spacing:.08em;
  padding:12px 18px;text-decoration:none;
}
.skip:focus{left:8px;top:8px}

/* ── Header ──────────────────────────────────────────────────── */

header{
  border-bottom:1px solid var(--line);
  background:rgba(247,245,239,.9);
  backdrop-filter:blur(6px);
  position:sticky;top:0;z-index:50;
}
.bar{
  display:flex;align-items:center;justify-content:space-between;gap:20px;
  height:var(--header-h);max-width:1120px;margin:0 auto;padding:0 28px;
}
/* The logo file carries the wordmark, so the brand link is the image alone.
   Height drives it; width follows the 330:189 aspect on its own. */
.brand{display:flex;align-items:center;text-decoration:none;flex:none}
.brand .mark{height:var(--logo-h);width:auto;display:block}

nav{display:flex;gap:26px}
nav a{
  text-decoration:none;color:var(--muted);
  font-family:var(--mono);font-size:12px;letter-spacing:.14em;text-transform:uppercase;
}
nav a:hover{color:var(--blue)}
nav a[aria-current]{color:var(--blue)}

@media(max-width:640px){
  :root{--header-h:96px;--logo-h:58px}
  .bar{padding:0 18px;gap:14px}
  nav{gap:16px}
  nav a{font-size:11px;letter-spacing:.1em}
}
/* Below this the logo and the nav start fighting for the bar. */
@media(max-width:430px){
  :root{--header-h:84px;--logo-h:50px}
  .bar{padding:0 14px;gap:10px}
  nav{gap:11px}
  nav a{font-size:10px;letter-spacing:.05em}
}

/* ── Shared type ─────────────────────────────────────────────── */

.eyebrow{
  font-family:var(--mono);font-size:12px;letter-spacing:.24em;text-transform:uppercase;
  color:var(--green-ink);
  display:flex;align-items:center;gap:10px;margin-bottom:26px;
}
/* The accent mark, taken from the logo. The two orange marks flanking AIC
   are long acute triangles, not rules: the top edge runs flat, the bottom
   edge slopes, and the blunt end faces the word while the point aims away
   from it. Measured off the lockup at roughly 29:1 length to thickness;
   held nearer 12:1 here so the point survives a 1x screen.
   Point left, blunt end against the text — the logo's left-hand mark. */
.eyebrow::before{
  content:"";flex:none;width:34px;height:3px;background:var(--orange);
  clip-path:polygon(0 0,100% 0,100% 100%);
}

h1{
  font-size:clamp(36px,6vw,68px);line-height:1.02;font-weight:800;
  color:var(--blue-ink);letter-spacing:-.017em;max-width:15ch;
}
/* The one underlined word per page. This is orange use #2 — the same mark
   as the eyebrow, run the length of the word. The flat edge sits on the
   bottom here rather than the top: an underline needs a stable line to
   rest on, and letting the taper happen above it keeps the mark clear of
   the descenders at the tail of the word. */
h1 .hot{position:relative;white-space:nowrap;color:var(--blue)}
h1 .hot::after{
  content:"";position:absolute;left:0;right:0;bottom:-.04em;
  height:.17em;background:var(--orange);
  clip-path:polygon(0 0,0 100%,100% 100%);
}

.sub{margin-top:24px;font-size:20px;color:var(--muted);max-width:48ch;line-height:1.55}
.sub b{color:var(--ink);font-weight:600}

/* ── Footer ──────────────────────────────────────────────────── */

footer{border-top:1px solid var(--line);padding:22px 0 42px;margin-top:20px}
.foot-row{
  display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;
  max-width:1120px;margin:0 auto;padding:0 28px;
}
.foot-row .c,.foot-row .applied{font-family:var(--mono);font-size:11px}
.foot-row .c{letter-spacing:.08em;color:var(--muted)}
.foot-row .applied{letter-spacing:.14em;text-transform:uppercase;color:var(--green-ink)}

/* ══ THE FLOOR (index) ═══════════════════════════════════════ */

.hero{padding:60px 0 26px}

.invite{
  margin-top:34px;padding-top:26px;border-top:1px solid var(--line);
  display:flex;align-items:baseline;justify-content:space-between;gap:26px;flex-wrap:wrap;
}
.invite .lead{
  font-size:26px;color:var(--blue-ink);font-weight:800;
  max-width:20ch;line-height:1.2;letter-spacing:-.01em;
}
.invite .lead .drive{color:var(--green-ink)}
.invite .note{
  font-size:14.5px;color:var(--muted);font-family:var(--mono);
  letter-spacing:.01em;max-width:36ch;line-height:1.6;
}

.floor{padding:22px 0 30px}
.floor-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:18px}
@media(max-width:860px){.floor-grid{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.floor-grid{grid-template-columns:1fr}}

/* ── One station ─────────────────────────────────────────────
   Self-contained. To take a station live, swap only its own
   <article>: change .soon/live state and turn the .drive-btn
   <button> into an <a href="stations/<slug>.html">. Nothing
   outside the article needs to change.
   ──────────────────────────────────────────────────────────── */

.station{
  background:#fff;border:1px solid var(--line);border-radius:5px;overflow:hidden;
  display:flex;flex-direction:column;
  transition:box-shadow .25s ease,transform .25s ease;
}
.station:hover{box-shadow:0 18px 40px -24px rgba(21,42,84,.55);transform:translateY(-3px)}

.screen{
  height:152px;position:relative;overflow:hidden;
  background:linear-gradient(160deg,var(--blue-ink),var(--blue));
}
.screen .tag,.screen .live{
  position:absolute;top:12px;font-family:var(--mono);font-size:10px;z-index:3;
}
.screen .tag{left:14px;letter-spacing:.16em;text-transform:uppercase;color:rgba(255,255,255,.72)}
.screen .live{
  right:14px;letter-spacing:.12em;color:#fff;
  display:flex;align-items:center;gap:6px;
}
.screen .live::before{
  content:"";width:7px;height:7px;border-radius:50%;
  background:var(--green);animation:blip 1.8s infinite;
}
@keyframes blip{
  0%{box-shadow:0 0 0 0 rgba(90,168,50,.55)}
  70%{box-shadow:0 0 0 7px rgba(90,168,50,0)}
  100%{box-shadow:0 0 0 0 rgba(90,168,50,0)}
}

/* Each screen shows a few lines of that station's own output. The numbers
   are illustrative, not live — the point is that the card reads as a system
   with a shape, not as six copies of the same abstract graphic. One row per
   screen is the one that wants attention; it carries the orange. */
.viz{
  position:absolute;inset:35px 15px 13px;
  display:flex;flex-direction:column;
  font-family:var(--mono);font-size:10px;line-height:1.4;
  color:rgba(255,255,255,.6);
}
.viz .row{
  display:flex;align-items:baseline;gap:9px;
  padding:4px 0;border-bottom:1px solid rgba(255,255,255,.1);
}
.viz .row:last-of-type{border-bottom:0}
.viz .k{
  flex:1;min-width:0;color:rgba(255,255,255,.86);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.viz .v{flex:none;color:#fff;font-variant-numeric:tabular-nums;letter-spacing:.02em}
.viz .rank,.viz .st{flex:none;color:rgba(255,255,255,.42);font-variant-numeric:tabular-nums}
.viz .st{width:2ch;letter-spacing:.06em}
.viz .s{flex:none;font-size:9px;letter-spacing:.07em;text-transform:uppercase}
.viz .s.ok{color:rgba(126,193,86,.95)}
.viz .s.due{color:var(--orange)}
.viz .row--hot{border-bottom-color:rgba(232,124,26,.45)}
.viz .row--hot .k{color:#fff}
.viz .note{
  margin-top:auto;padding-top:6px;font-size:9px;letter-spacing:.07em;
  text-transform:uppercase;color:rgba(255,255,255,.4);
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}

/* Per-Mile reports one number, so its screen is a readout, not a table. */
.viz--metric{justify-content:center}
.viz--metric .cap{
  font-size:9px;letter-spacing:.09em;text-transform:uppercase;color:rgba(255,255,255,.45);
}
.viz--metric .metric{display:flex;align-items:baseline;gap:10px;margin-top:4px}
.viz--metric .n{font-size:27px;color:#fff;letter-spacing:-.02em;font-variant-numeric:tabular-nums}
.viz--metric .d{color:rgba(126,193,86,.95);font-size:10px}
.viz--metric .spark{display:flex;align-items:flex-end;gap:4px;height:24px;margin-top:10px}
.viz--metric .spark i{flex:1;min-width:0;background:rgba(255,255,255,.22);border-radius:1px}
.viz--metric .spark i.k{background:var(--orange)}

/* The bespoke slot is deliberately unfilled — that is the whole idea. */
.viz--slot{
  align-items:center;justify-content:center;gap:3px;
  border:1px dashed rgba(255,255,255,.28);border-radius:4px;
}
.viz--slot .plus{font-size:19px;color:rgba(255,255,255,.5);line-height:1}
.viz--slot .cap{font-size:9px;letter-spacing:.12em;text-transform:uppercase;color:rgba(255,255,255,.45)}

.station:hover .viz .row{animation:slidein .45s ease both}
.station:hover .viz .row:nth-of-type(2){animation-delay:.06s}
.station:hover .viz .row:nth-of-type(3){animation-delay:.12s}
.station:hover .viz--metric .spark i{animation:rise .5s ease both}
@keyframes slidein{from{opacity:0;transform:translateX(8px)}to{opacity:1;transform:none}}
@keyframes rise{from{opacity:.3;transform:scaleY(.4);transform-origin:bottom}to{opacity:1;transform:none}}

.station .body{padding:20px 20px 22px;display:flex;flex-direction:column;flex:1}
.problem{
  font-family:var(--mono);font-size:11px;letter-spacing:.05em;text-transform:uppercase;
  color:var(--green-ink);margin-bottom:9px;line-height:1.4;
}
.station h3{
  font-size:20px;color:var(--blue-ink);line-height:1.15;
  margin-bottom:8px;font-weight:800;letter-spacing:-.01em;
}
.what{font-size:14.5px;color:var(--muted);line-height:1.5;margin-bottom:18px}
.station .foot{margin-top:auto;display:flex;align-items:center;justify-content:space-between;gap:10px}

.drive-btn{
  font-family:var(--mono);font-size:12px;letter-spacing:.08em;text-transform:uppercase;
  color:var(--blue);background:none;border:1px solid var(--blue);
  padding:9px 15px;border-radius:3px;cursor:pointer;text-decoration:none;
  transition:background .18s ease,color .18s ease;
}
.drive-btn:hover{background:var(--blue);color:#fff}
.drive-btn--bespoke{border-color:var(--orange);color:var(--orange)}
.drive-btn--bespoke:hover{background:var(--orange);color:#fff}

.lever{font-family:var(--mono);font-size:10px;letter-spacing:.1em;color:var(--muted);text-transform:uppercase}
.lever b{color:var(--ink);font-weight:600}

/* Not yet on the floor. */
.station.soon{opacity:.72}
.station.soon .screen{background:linear-gradient(160deg,#3a4358,#4c566e);filter:saturate(.5)}
.station.soon .live{color:rgba(255,255,255,.55)}
.station.soon .live::before{background:rgba(255,255,255,.4);animation:none}
.station.soon .drive-btn{border-color:var(--muted);color:var(--muted);cursor:default}
.station.soon .drive-btn:hover{background:none;color:var(--muted)}
.station.soon .drive-btn--bespoke{border-color:var(--orange);color:var(--orange);cursor:pointer}
.station.soon .drive-btn--bespoke:hover{background:var(--orange);color:#fff}

/* The quiet identity strip at the bottom of the floor. Not a funnel.
   It sits *inside* .wrap rather than on it, so its rule lines up with the
   one above the invite and its text keeps the page's side padding. */
.who-strip{
  border-top:1px solid var(--line);padding:34px 0 24px;margin-top:14px;
  display:flex;justify-content:space-between;align-items:flex-start;gap:40px;flex-wrap:wrap;
}
.who-strip .role{
  font-family:var(--mono);font-size:11px;letter-spacing:.2em;text-transform:uppercase;
  color:var(--green-ink);margin-bottom:10px;
}
.who-strip h2{font-size:26px;color:var(--blue-ink);font-weight:800;letter-spacing:-.01em;line-height:1.12}
.who-strip .l2{font-size:17px;color:var(--blue);font-weight:700;margin-top:3px}
.who-strip .l3{font-size:13px;color:var(--muted);margin-top:5px;font-family:var(--mono);letter-spacing:.08em}
.who-strip .say{max-width:40ch;font-size:16px;color:var(--ink);line-height:1.58}

/* The inline link style: blue with an orange underline. Orange use #3. */
.tie{color:var(--blue);text-decoration:none;border-bottom:1.5px solid var(--orange);padding-bottom:1px;font-weight:600}
.tie:hover{color:var(--blue-ink)}

/* Navigation inside prose, not emphasis. Used on the floor's identity strip,
   where the bespoke button has already spent the page's orange. */
.tie--quiet{border-bottom-color:var(--line)}
.tie--quiet:hover{border-bottom-color:var(--orange)}

/* ══ WHO ═════════════════════════════════════════════════════ */

.top{padding:76px 0 8px}
.top h1{font-size:clamp(33px,5.2vw,56px);line-height:1.06;max-width:18ch}

.name-block{margin-top:28px;display:flex;align-items:center;gap:18px}
.name-block .dot{
  width:52px;height:52px;border-radius:50%;flex:none;position:relative;overflow:hidden;
  background:linear-gradient(150deg,var(--blue),var(--blue-ink));
}
.name-block .dot::after{
  content:"";position:absolute;top:14px;left:14px;
  width:10px;height:10px;border-radius:50%;background:var(--orange);
}
.name-block h2{font-size:22px;color:var(--blue-ink);font-weight:800;letter-spacing:-.01em;line-height:1.1}
.name-block .r{font-size:13px;color:var(--muted);font-family:var(--mono);letter-spacing:.06em;margin-top:3px}

.story{padding:38px 0 26px}
.story p{margin-bottom:22px;font-size:19px;line-height:1.68;color:var(--ink)}
.story .em{color:var(--blue-ink);font-weight:600}
.story .lede{font-size:23px;line-height:1.5;color:var(--blue-ink);margin-bottom:30px}

.quote{border-left:3px solid var(--orange);padding:4px 0 4px 22px;margin:26px 0}
.quote p{font-size:18px;line-height:1.5;color:var(--blue-ink);font-style:italic;margin-bottom:8px}
.quote figcaption{font-family:var(--mono);font-size:12px;letter-spacing:.04em;color:var(--muted)}

.close{padding:38px 0 20px;border-top:1px solid var(--line)}
.close p{font-size:20px;line-height:1.6;color:var(--blue-ink);margin-bottom:22px}
.back{
  display:inline-block;margin-top:8px;font-family:var(--mono);font-size:12px;
  letter-spacing:.1em;text-transform:uppercase;color:var(--blue);text-decoration:none;
}
.back:hover{color:var(--blue-ink)}

/* ══ CONTACT ═════════════════════════════════════════════════ */

.contact h1{font-size:clamp(34px,5.6vw,60px);line-height:1.04}
.contact .sub{font-size:21px;max-width:44ch}

.dl{
  margin-top:40px;display:inline-flex;align-items:center;gap:12px;
  text-decoration:none;background:var(--blue);color:#fff;
  font-family:var(--mono);font-size:13px;letter-spacing:.1em;text-transform:uppercase;
  padding:16px 26px;border-radius:4px;transition:background .18s ease;
}
.dl:hover{background:var(--blue-ink)}
.dl svg{width:15px;height:15px;flex:none}
.dlnote{margin-top:14px;font-family:var(--mono);font-size:12px;letter-spacing:.03em;color:var(--muted)}

/* Plain text, deliberately not a mailto. They can type it. */
.addr{margin-top:56px;font-family:var(--mono);font-size:15px;color:var(--blue-ink);letter-spacing:.04em}

/* ══ Motion ══════════════════════════════════════════════════ */

@media(prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  *,*::before,*::after{
    animation-duration:.001ms !important;
    animation-iteration-count:1 !important;
    transition-duration:.001ms !important;
  }
  .station:hover{transform:none}
}
