/* Loadmap site styles.
   Layout idea: calm white pages with a few deep navy bands. Big plain type, lots of room.
   The only bright color is the load heat (red and orange), used where a problem starts or shows.
   Colors, type and spacing come from the Loadmap design system. One look on purpose: the
   design system has a single light theme with navy bands, so the site does not switch themes. */
:root{
  /* light surfaces */
  --surface:#FFFFFF; --surface-raised:#F8FAFC; --surface-sunken:#F1F5F9;
  --rule:#E2E8F0; --rule-strong:#CBD5E1;
  --ink:#0F172A; --body:#334155; --muted:#64748B;
  /* navy bands */
  --night:#0F172A; --night-deep:#0C101F; --night-raised:#1E293B;
  --on-night:#F8FAFC; --on-night-muted:#94A3B8;
  /* load heat: the one accent */
  --load-hot:#F9423A; --load-red:#DC2626; --load-orange:#EA580C;
  --tint-cause:#FEF7F6; --tint-cause-border:#FED7D2;
  --tint-shows:#FFF7ED; --tint-shows-border:#FED7AA; --text-shows:#9A3412;
  --sev-intact:#16A34A;
  /* type */
  --sans:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  /* layout */
  --max:1120px; --radius:8px; --radius-xl:10px;
  color-scheme:light;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth;-webkit-text-size-adjust:100%}
body{margin:0;background:var(--surface);color:var(--body);font-family:var(--sans);font-size:18px;line-height:1.6;-webkit-font-smoothing:antialiased}
h1,h2,h3,p,ul,ol,figure,blockquote{margin:0}
ul,ol{padding:0;list-style:none}
h1,h2,h3{color:var(--ink);text-wrap:balance}
a{color:inherit}
img,svg{display:block;max-width:100%}
:focus-visible{outline:2px solid var(--load-hot);outline-offset:3px;border-radius:3px}

/* Every band's inner wrapper carries the side gutter. */
.wrap{max-width:var(--max);margin:0 auto;padding-left:max(24px,env(safe-area-inset-left,0px));padding-right:max(24px,env(safe-area-inset-right,0px))}

/* ---------- header ---------- */
.site-head{background:var(--night-deep);color:var(--on-night)}
.site-head .wrap{display:flex;align-items:center;justify-content:space-between;gap:12px 28px;flex-wrap:wrap;padding-block:14px}
.brand{display:block;flex:none}
.brand img{height:46px;width:auto;margin-left:-4px}
.site-nav{display:flex;align-items:center;gap:6px 26px;flex-wrap:wrap}
.site-nav a{font-size:.94rem;font-weight:600;text-decoration:none;color:var(--on-night-muted);padding:6px 0}
.site-nav a:hover,.site-nav a[aria-current="page"]{color:var(--on-night)}
.site-nav a.btn{color:var(--night-deep);padding:10px 16px}

/* ---------- buttons ---------- */
.btn{display:inline-flex;align-items:center;justify-content:center;font:600 1rem/1 var(--sans);text-decoration:none;border-radius:var(--radius);padding:15px 22px;border:1px solid transparent;cursor:pointer;white-space:nowrap}
.btn.light{background:var(--on-night);color:var(--night-deep)}
.btn.light:hover{background:#fff}
.btn.ghost-night{border-color:#3b4763;color:var(--on-night);background:transparent}
.btn.ghost-night:hover{border-color:var(--on-night-muted)}
.btn.dark{background:var(--ink);color:#fff}
.btn.dark:hover{background:#1E293B}
.btn.ghost{border-color:var(--rule-strong);color:var(--ink);background:transparent}
.btn.ghost:hover{border-color:var(--muted)}
.actions{display:flex;gap:12px;flex-wrap:wrap;align-items:center}
.aside-note{font-size:.92rem;color:var(--muted)}
.night .aside-note{color:var(--on-night-muted)}

/* ---------- bands ---------- */
.band{padding-block:clamp(56px,8vw,104px)}
.band.sunken{background:var(--surface-sunken)}
.band.night{background:var(--night);color:var(--on-night-muted)}
.band.night h1,.band.night h2,.band.night h3{color:var(--on-night)}
.band.tight{padding-block:clamp(40px,5vw,64px)}
.eyebrow{font:700 .72rem/1.3 var(--sans);letter-spacing:.14em;text-transform:uppercase;color:var(--load-red)}
.night .eyebrow{color:var(--load-hot)}
h2{font-size:clamp(1.8rem,3.6vw,2.7rem);line-height:1.12;font-weight:700;letter-spacing:-.02em}
h3{font-size:1.12rem;line-height:1.3;font-weight:700}
.lead{font-size:clamp(1.12rem,1.6vw,1.3rem);line-height:1.55}
.prose{display:flex;flex-direction:column;gap:18px;max-width:62ch}
.prose.wide{max-width:70ch}
.stack{display:flex;flex-direction:column;gap:18px}
.stack.lg{gap:36px}
.split{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:clamp(32px,6vw,84px);align-items:center}
.split.top{align-items:start}
.split > *{min-width:0}
.textlink{font-weight:600;color:var(--ink);text-decoration:underline;text-decoration-color:var(--load-hot);text-decoration-thickness:2px;text-underline-offset:5px}
.night .textlink{color:var(--on-night)}
.textlink:hover{text-decoration-color:currentColor}

/* ---------- home hero ---------- */
.hero{position:relative;background:var(--night-deep);color:var(--on-night);overflow:hidden}
.hero .wrap{position:relative;z-index:2;pointer-events:none;padding-block:clamp(56px,9vw,120px) clamp(64px,10vw,132px)}
.hero-copy{pointer-events:auto;max-width:min(560px,50%);display:flex;flex-direction:column;gap:26px}
.hero h1{color:var(--on-night);font-size:clamp(2.5rem,5.6vw,4.3rem);line-height:1.04;font-weight:700;letter-spacing:-.03em}
.hero h1 span{display:block}
.hero .lead{color:var(--on-night-muted);max-width:30em}
.hero .lead strong{color:var(--on-night);font-weight:600}
/* The heat field: a dense field of cells in five layer bands. Strain starts on the bottom layer and climbs.
   Drawn on a canvas by site.js. Each layer's name appears beside it when the strain reaches it. */
.field{position:absolute;z-index:1;top:0;right:0;bottom:0;width:min(50%,760px)}
.field canvas{position:absolute;inset:0;width:100%;height:100%}
.field .names{position:absolute;left:0;top:0;bottom:0;width:30%;pointer-events:none}
.field .names span{position:absolute;left:0;transform:translateY(-50%);display:flex;align-items:center;font:700 .7rem/1.2 var(--sans);letter-spacing:.12em;text-transform:uppercase;color:var(--on-night-muted);opacity:.55;transition:opacity .9s ease,color .9s ease;padding-right:12px;max-width:100%;box-sizing:border-box}
.field .names span.on{opacity:1;color:#FDBA74}
/* Each layer name explains itself on hover, tap, or keyboard focus. The words are the one-liners from How it works. */
.field .names span{pointer-events:auto;cursor:help}
.field .names span:hover,.field .names span:focus{opacity:1;outline:none;z-index:3}
.field .names span:focus-visible{text-decoration:underline dotted;text-underline-offset:4px}
.field .names span::after{content:attr(data-tip);position:absolute;left:0;top:calc(100% + 8px);width:min(260px,62vw);background:var(--on-night);color:var(--night-deep);font:400 .85rem/1.45 var(--sans);letter-spacing:0;text-transform:none;padding:10px 12px;border-radius:8px;box-shadow:0 8px 24px rgba(0,0,0,.35);opacity:0;visibility:hidden;transition:opacity .2s ease;pointer-events:none}
.field .names span:hover::after,.field .names span:focus::after{opacity:1;visibility:visible}
/* The name of the picture, with a tooltip saying what it is. Hover or focus shows it; on touch, a tap on the name opens the walkthrough. */
.field-label{position:absolute;left:0;top:0;z-index:2;transform:translateY(-100%)}   /* the chart's title: site.js sets it just above the first row, in line with the layer names */
.field-label a{display:inline-flex;align-items:center;gap:6px;font:700 .82rem/1 var(--sans);letter-spacing:.12em;text-transform:uppercase;color:var(--on-night);text-decoration:none;padding:6px 0}
.field-label a:hover,.field-label a:focus-visible{color:#FDBA74}
.field-label i{display:inline-grid;place-items:center;width:15px;height:15px;border:1px solid currentColor;border-radius:50%;font:700 9px/1 var(--sans);font-style:normal;letter-spacing:0}
.field-label .tip{position:absolute;left:0;bottom:calc(100% + 6px);width:min(300px,70vw);background:var(--on-night);color:var(--night-deep);font:400 .85rem/1.45 var(--sans);padding:10px 12px;border-radius:8px;box-shadow:0 8px 24px rgba(0,0,0,.35);opacity:0;visibility:hidden;transition:opacity .2s ease;pointer-events:none}
.field-label a:hover + .tip,.field-label a:focus-visible + .tip,.field-label:hover .tip{opacity:1;visibility:visible}

/* ---------- page hero (inner pages) ---------- */
.page-hero{background:var(--night);color:var(--on-night-muted)}
.page-hero .wrap{padding-block:clamp(48px,7vw,88px);display:flex;flex-direction:column;gap:20px}
.page-hero h1{color:var(--on-night);font-size:clamp(2.1rem,4.6vw,3.4rem);line-height:1.08;font-weight:700;letter-spacing:-.025em;max-width:18em}
.page-hero .lead{max-width:38em}

/* ---------- the snapback chart ---------- */
.chart-card{border:1px solid var(--rule);border-radius:var(--radius-xl);background:var(--surface);padding:22px 22px 14px}
.chart-card figcaption{font-size:.9rem;color:var(--muted);padding-top:10px}
.chart text{font-family:var(--sans);font-size:14px;fill:var(--muted)}
.chart .note{font-weight:700;fill:var(--ink);font-size:15px}
.chart .gridline{stroke:var(--rule);stroke-width:1}
.chart .baseline{stroke:var(--rule-strong);stroke-width:1.5;stroke-dasharray:5 6}
.chart .run{fill:none;stroke-width:5;stroke-linecap:round;stroke-linejoin:round}
.chart.draw .run{stroke-dasharray:1;animation:draw 2.2s ease-in-out both}
.chart.draw .late{animation:show .4s ease 2s both}
@keyframes draw{from{stroke-dashoffset:1}to{stroke-dashoffset:0}}
@keyframes show{from{opacity:0}to{opacity:1}}

/* ---------- the layer explorer ---------- */
.explorer{display:grid;grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr);gap:clamp(24px,4vw,48px);align-items:start}
.explorer > *{min-width:0}
.picks{display:flex;flex-direction:column;gap:10px}
.pick{appearance:none;text-align:left;font:inherit;color:var(--body);background:var(--surface);border:1px solid var(--rule);border-radius:var(--radius-xl);padding:16px 18px;cursor:pointer;display:flex;flex-direction:column;gap:3px}
.pick:hover{border-color:var(--muted)}
.pick b{font-size:1.08rem;line-height:1.3;color:var(--ink)}
.pick small{font-size:.86rem;color:var(--muted)}
.pick[aria-pressed="true"]{border-color:var(--ink);box-shadow:0 0 0 1px var(--ink) inset}
.case{background:var(--surface);border:1px solid var(--rule);border-radius:var(--radius-xl);padding:clamp(18px,3vw,28px);display:flex;flex-direction:column;gap:18px}
.case .story{font-size:1.02rem}
.layers{display:flex;flex-direction:column;gap:6px}
.layer{display:flex;justify-content:space-between;align-items:center;gap:10px 14px;flex-wrap:wrap;border:1px solid var(--rule);border-radius:6px;padding:10px 14px;font-weight:600;font-size:.98rem;color:var(--ink);background:var(--surface-raised);transition:background-color .3s ease,border-color .3s ease}
.layer .flag{font:700 .68rem/1.2 var(--sans);letter-spacing:.1em;text-transform:uppercase}
.layer.shows{background:var(--tint-shows);border-color:var(--tint-shows-border);border-left:4px solid var(--load-orange)}
.layer.shows .flag{color:var(--text-shows)}
.layer.cause{background:var(--tint-cause);border-color:var(--tint-cause-border);border-left:4px solid var(--load-hot)}
.layer.cause .flag{color:var(--load-red)}
.why{display:flex;flex-direction:column;gap:12px;font-size:1rem}
.why b{color:var(--ink)}
.fine{font-size:.84rem;color:var(--muted)}

/* ---------- lists of things you get ---------- */
.gets{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 clamp(32px,6vw,84px)}
.gets li{padding-block:22px;border-top:1px solid var(--rule);display:flex;flex-direction:column;gap:6px;min-width:0}
.night .gets li{border-color:#2a3550}
.findings{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:clamp(24px,4vw,56px)}
.findings li{display:flex;flex-direction:column;gap:8px;min-width:0}
.findings .who{font:700 .72rem/1.3 var(--sans);letter-spacing:.12em;text-transform:uppercase;color:var(--muted)}
.findings p{font-size:1.2rem;line-height:1.45;color:var(--ink)}

/* ---------- steps (how it works) ---------- */
.steps{display:flex;flex-direction:column}
.step{display:grid;grid-template-columns:72px minmax(0,1fr);gap:8px 24px;padding-block:clamp(28px,4vw,44px);border-top:1px solid var(--rule)}
.step:last-child{border-bottom:1px solid var(--rule)}
.step .num{font-size:2.2rem;line-height:1;font-weight:700;color:var(--rule-strong);font-variant-numeric:tabular-nums}
.step .stack{max-width:64ch}
.switches{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;max-width:560px}
.switches li{border:1px solid var(--rule);border-radius:6px;padding:9px 12px;font-size:.94rem;font-weight:600;color:var(--ink);background:var(--surface-raised)}
.bridge-list{display:flex;flex-direction:column;gap:6px;max-width:640px}
.bridge-list li{display:grid;grid-template-columns:minmax(0,220px) minmax(0,1fr);gap:4px 16px;border:1px solid var(--rule);border-radius:6px;padding:10px 14px;background:var(--surface-raised);font-size:.96rem}
.bridge-list b{color:var(--ink)}
.callout{background:var(--tint-shows);border:1px solid var(--tint-shows-border);border-left:4px solid var(--load-orange);border-radius:6px;padding:18px 20px;color:var(--text-shows);display:flex;flex-direction:column;gap:8px;max-width:64ch}
.callout h3{color:var(--text-shows)}

/* ---------- embedded walkthroughs ---------- */
.embed{border:1px solid var(--rule);border-radius:var(--radius-xl);overflow:hidden;background:#0b1020}
.embed iframe{display:block;width:100%;height:800px;border:0}

/* ---------- pull quote ---------- */
.pull{font-size:clamp(1.5rem,3vw,2.2rem);line-height:1.3;font-weight:600;letter-spacing:-.015em;color:var(--on-night);max-width:26em}
.pull-by{font-size:.95rem;color:var(--on-night-muted)}

/* ---------- closing call ---------- */
.talk h2{font-size:clamp(2rem,4.4vw,3.3rem);max-width:16em}
.contact{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.address{font-size:1.15rem;font-weight:600;color:var(--on-night);user-select:all;-webkit-user-select:all}
.copy{appearance:none;font:600 .86rem/1 var(--sans);color:var(--on-night);background:transparent;border:1px solid #3b4763;border-radius:6px;padding:9px 12px;cursor:pointer}
.copy:hover{border-color:var(--on-night-muted)}

/* ---------- footer ---------- */
.site-foot{background:var(--night-deep);color:var(--on-night-muted);font-size:.9rem}
.site-foot .wrap{padding-block:40px 44px;display:flex;justify-content:space-between;align-items:flex-end;gap:28px;flex-wrap:wrap}
.site-foot .lock{display:flex;flex-direction:column;gap:4px}
.site-foot .lock img{height:60px;width:auto;margin-left:-6px}
.site-foot .tagline{color:var(--on-night);font-size:1.02rem;padding-left:1px}
.site-foot nav{display:flex;gap:8px 22px;flex-wrap:wrap}
.site-foot a{text-decoration:none}
.site-foot a:hover{color:var(--on-night)}
.site-foot .by{flex-basis:100%;border-top:1px solid #222c45;padding-top:18px}

/* ---------- The Load: the blog ---------- */
.page-hero .eyebrow a{color:inherit;text-decoration:none}
.page-hero .eyebrow a:hover{text-decoration:underline}
.post-meta{font-size:.92rem;color:var(--muted)}
.page-hero .post-meta{color:var(--on-night-muted)}
.series-links{display:flex;gap:8px 22px;flex-wrap:wrap;font-size:.95rem;font-weight:600}
.series-links a{color:var(--on-night);text-decoration:underline;text-decoration-color:var(--load-hot);text-decoration-thickness:2px;text-underline-offset:5px}
.series + .series{border-top:1px solid var(--rule)}
.post-list{display:flex;flex-direction:column}
.post-list li{padding-block:22px;border-top:1px solid var(--rule);display:flex;flex-direction:column;gap:6px;max-width:74ch;min-width:0}
.post-list a{text-decoration:none}
.post-list h3{font-size:1.3rem;line-height:1.25}
.post-list a:hover h3{text-decoration:underline;text-decoration-color:var(--load-hot);text-decoration-thickness:2px;text-underline-offset:5px}
.post-list .excerpt{display:-webkit-box;-webkit-line-clamp:3;line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
.post-list.cols{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0 clamp(24px,4vw,48px)}
.post{max-width:68ch;display:flex;flex-direction:column;gap:20px;font-size:1.08rem;line-height:1.7;color:var(--body)}
.post h2{font-size:1.6rem;margin-top:14px}
.post h3,.post h4{font-size:1.2rem;margin-top:8px}
.post strong{color:var(--ink)}
.post a{color:var(--ink);text-decoration:underline;text-decoration-color:var(--load-hot);text-decoration-thickness:2px;text-underline-offset:4px}
.post ul,.post ol{display:flex;flex-direction:column;gap:8px;padding-left:1.4em}
.post ul{list-style:disc}
.post ol{list-style:decimal}
.post blockquote{border-left:4px solid var(--load-hot);padding:4px 0 4px 22px;font-size:1.3rem;line-height:1.45;font-weight:600;color:var(--ink)}
.post hr{border:0;border-top:1px solid var(--rule);width:100%}
.post-nav{max-width:68ch;display:flex;flex-direction:column;gap:14px;align-items:flex-start;margin-top:44px;padding-top:26px;border-top:1px solid var(--rule)}

/* ---------- phones and small tablets ---------- */
@media (max-width:860px){
  body{font-size:17px}
  .wrap{padding-left:max(18px,env(safe-area-inset-left,0px));padding-right:max(18px,env(safe-area-inset-right,0px))}
  .split,.explorer{grid-template-columns:minmax(0,1fr)}
  .gets,.findings,.post-list.cols{grid-template-columns:minmax(0,1fr)}
  .hero .wrap{padding-block:44px 0}
  .hero-copy{padding-bottom:36px}
  .hero-copy{max-width:none}
  .field{position:relative;width:auto;height:300px;margin:0 18px 40px}
  .field-label a{font-size:.7rem}
  .field .names span{font-size:.6rem;letter-spacing:.08em}
  .field-tag{font-size:.62rem;padding:5px 7px}
  .site-nav{gap:4px 18px}
  .site-nav a{font-size:.9rem}
  .step{grid-template-columns:minmax(0,1fr)}
  .bridge-list li{grid-template-columns:minmax(0,1fr)}
  .embed iframe{height:1180px}
  .brand img{height:40px}
}
@media (max-width:420px){
  .switches{grid-template-columns:minmax(0,1fr)}
  .site-nav a.btn{display:none}
}
@media (prefers-reduced-motion:reduce){
  html{scroll-behavior:auto}
  .field .names span{transition:none}
  .chart.draw .run,.chart.draw .late{animation:none}
  .chart.draw .run{stroke-dasharray:none}
}
