/* IMF suite - "Toy Box" identity (taste profile 2026-10-16).
   Bright studio tray, matte model-kit molecules, chunky keycap controls.
   Deliberately NOT Unit 1b paper/riso or Rate Laws graph-paper.
   Space Grotesk + Space Mono. Red = δ+, yellow = δ− is reserved for charge meaning;
   chrome never uses those two colours. */

:root{
  --tray:#ffffff;
  --field:#eef1f6;
  --field-2:#e6eaf1;
  --ink:#1d2433;
  --ink-soft:#3d4658;
  --dim:#5b6474;
  --faint:#596274;
  --accent:#4152d9;
  --accent-soft:#e7eaff;
  --delta-pos:#e8264f;
  --delta-neg:#ffc21a;
  --line:rgba(29,36,51,0.12);
  --line-strong:#1d2433;
  --key-drop:0 3px 0 #1d2433;
  --radius:12px;
  --radius-lg:22px;

  --font-display:'Space Grotesk',Helvetica,sans-serif;
  --font-body:'Space Grotesk',Helvetica,sans-serif;
  --font-mono:'Space Mono',ui-monospace,monospace;
}

*,*::before,*::after{box-sizing:border-box;margin:0;padding:0;}
html{font-size:16px;-webkit-text-size-adjust:100%;}
body{
  background:radial-gradient(1200px 520px at 50% -10%, #ffffff, var(--field) 60%, var(--field-2));
  background-attachment:fixed;
  color:var(--ink);
  font-family:var(--font-body);
  font-size:1.05rem;
  min-height:100vh;
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
}

.hub,.module-wrap{
  max-width:1280px;
  margin:0 auto;
  padding:1.5rem 1.4rem 3.5rem;
}

.top-nav{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  flex-wrap:wrap;
  margin-bottom:1.25rem;
  padding-bottom:0.85rem;
  border-bottom:1px solid var(--line);
}
.back-link{
  color:var(--ink-soft);
  text-decoration:none;
  font-size:0.92rem;
  font-weight:700;
}
.back-link:hover{color:var(--accent);}
.back-link:focus-visible,
.room-switch a:focus-visible,
.path a:focus-visible,
.btn:focus-visible,
select:focus-visible{
  outline:3px solid var(--accent);
  outline-offset:3px;
}
.mod-meta{
  font-family:var(--font-mono);
  font-size:0.78rem;
  font-weight:700;
  color:var(--dim);
}

.hub-header{margin-bottom:2rem;}
.unit-tag{
  display:inline-block;
  font-family:var(--font-mono);
  font-size:0.78rem;
  font-weight:700;
  color:var(--dim);
  margin-bottom:0.55rem;
  letter-spacing:0.04em;
  text-transform:uppercase;
}
.hub-header h1,
.sandbox-lead h1,
.stub-panel h1{
  font-family:var(--font-display);
  font-weight:700;
  font-size:clamp(2.2rem,5vw,3.4rem);
  line-height:1;
  letter-spacing:-0.03em;
  margin-bottom:0.6rem;
}
.subtitle,.sandbox-lead p,.stub-panel p{
  color:var(--ink-soft);
}
.suggest{
  margin-top:0.9rem;
  font-family:var(--font-mono);
  font-size:0.8rem;
  color:var(--dim);
}

.path{
  list-style:none;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:1.1rem;
}
.path li{display:flex;}
/* square room tiles; the title and teaser sit at the bottom, like a label on a box */
.path a{
  display:flex;
  flex-direction:column;
  width:100%;
  aspect-ratio:1;
  padding:1.3rem 1.35rem;
  text-decoration:none;
  color:inherit;
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:16px;
  box-shadow:0 4px 0 var(--ink);
  transition:transform 0.08s, box-shadow 0.08s;
}
.path a:hover{transform:translateY(-1px);box-shadow:0 5px 0 var(--ink);}
.path a:active{transform:translateY(4px);box-shadow:0 0 0 var(--ink);}
.mod-head{
  display:flex;
  justify-content:flex-end;
  align-items:baseline;
  gap:1rem;
  margin-bottom:0.25rem;
}
.mod-num{
  font-family:var(--font-mono);
  font-size:0.76rem;
  font-weight:700;
  color:var(--accent);
}
.mod-go{
  font-family:var(--font-mono);
  font-size:0.76rem;
  font-weight:700;
  color:var(--dim);
}
/* tile: room tag, then title + teaser (top-aligned across tiles), Open pinned to the bottom */
.path .mod-num{display:block;}
.path .mod-title{margin:0.6rem 0 0.55rem;font-size:1.9rem;line-height:1.1;}
.path .mod-teaser{line-height:1.5;}
.path .mod-go{
  margin-top:auto;
  align-self:flex-start;
  padding:0.35rem 0.75rem;
  border:2px solid var(--line-strong);
  border-radius:999px;
  color:var(--ink);
}
.path a:hover .mod-go{background:var(--accent-soft);}

/* -- hub tile animations: a small looping picture fills the space between teaser and Open -- */
.hub-anim-defs{position:absolute;width:0;height:0;overflow:hidden;}
.path .mod-anim{position:relative;display:block;flex:1 1 0;min-height:90px;margin:0.4rem 0 0.6rem;}
.hub-anim{position:absolute;inset:0;width:100%;height:100%;overflow:visible;}
.hub-anim .ga-delta{font-family:var(--font-mono);font-size:13px;font-weight:700;fill:var(--ink);text-anchor:middle;}
.hub-anim .ga-e{fill:var(--ink);}

/* Guide: HCl, 12 s loop in three beats */
.anim-guide .ga-p1{animation:ga-p1 12s infinite;}
.anim-guide .ga-p2{animation:ga-p2 12s infinite;}
.anim-guide .ga-p3{animation:ga-p3 12s infinite;}
@keyframes ga-p1{0%,28%{opacity:1}33%,95%{opacity:0}100%{opacity:1}}
@keyframes ga-p2{0%,30%{opacity:0}35%,61%{opacity:1}66%,100%{opacity:0}}
@keyframes ga-p3{0%,63%{opacity:0}68%,95%{opacity:1}100%{opacity:0}}

/* Sandbox: two CH4 drift in until the clouds touch, then drift apart */
.anim-sandbox .sa-left{animation:sa-left 6s ease-in-out infinite;}
.anim-sandbox .sa-right{animation:sa-right 6s ease-in-out infinite;}
.anim-sandbox .sa-spin{animation:sa-spin 4.5s ease-in-out infinite alternate;}
.anim-sandbox .sa-spin-b{animation-duration:3.7s;animation-delay:-1.4s;}
@keyframes sa-left{0%,8%{transform:translateX(0)}42%,58%{transform:translateX(30px)}92%,100%{transform:translateX(0)}}
@keyframes sa-right{0%,8%{transform:translateX(0)}42%,58%{transform:translateX(-30px)}92%,100%{transform:translateX(0)}}
@keyframes sa-spin{from{transform:rotate(-14deg)}to{transform:rotate(14deg)}}

/* Lab: sealed jar of water, 10 s loop: warm plate → evaporate, cool plate → condense */
.anim-lab .la-plate{animation:la-plate 10s infinite;}
.anim-lab .la-jig{animation:la-jig 0.9s ease-in-out infinite alternate;}
.anim-lab .la-jig:nth-of-type(2n){animation-duration:1.1s;animation-delay:-0.4s;}
.anim-lab .la-jig:nth-of-type(3n){animation-duration:0.8s;animation-delay:-0.7s;}
.anim-lab .la-up-1{animation:la-up-1 10s ease-in-out infinite;}
.anim-lab .la-up-2{animation:la-up-2 10s ease-in-out infinite;}
.anim-lab .la-up-3{animation:la-up-3 10s ease-in-out infinite;}
@keyframes la-plate{0%,45%{fill:#f08a4b}52%,92%{fill:#7fa3f5}100%{fill:#f08a4b}}
@keyframes la-jig{from{transform:translate(-0.8px,0.6px)}to{transform:translate(0.8px,-0.6px)}}
@keyframes la-up-1{
  0%,10%{transform:translate(0,0)}
  22%{transform:translate(-14px,-36px)}
  34%{transform:translate(-30px,-60px)}
  46%{transform:translate(-8px,-52px)}
  58%{transform:translate(6px,-58px)}
  72%{transform:translate(2px,-26px)}
  82%,100%{transform:translate(0,0)}
}
@keyframes la-up-2{
  0%,16%{transform:translate(0,0)}
  28%{transform:translate(12px,-40px)}
  40%{transform:translate(-4px,-64px)}
  52%{transform:translate(22px,-50px)}
  64%{transform:translate(10px,-56px)}
  78%{transform:translate(-2px,-22px)}
  88%,100%{transform:translate(0,0)}
}
@keyframes la-up-3{
  0%,20%{transform:translate(0,0)}
  32%{transform:translate(-20px,-30px)}
  42%{transform:translate(-40px,-50px)}
  54%{transform:translate(-56px,-40px)}
  66%{transform:translate(-30px,-46px)}
  80%{transform:translate(-8px,-18px)}
  90%,100%{transform:translate(0,0)}
}
.mod-title{
  display:block;
  font-family:var(--font-display);
  font-size:1.45rem;
  font-weight:700;
  letter-spacing:-0.02em;
  margin-bottom:0.3rem;
}
.mod-teaser{
  display:block;
  color:var(--ink-soft);
  font-size:0.98rem;
}

.room-switch{
  display:flex;
  flex-wrap:wrap;
  gap:0.3rem;
  margin-bottom:1.4rem;
  padding:0.3rem;
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:14px;
  width:fit-content;
}
.room-switch a{
  text-decoration:none;
  color:var(--ink-soft);
  font-size:0.85rem;
  font-weight:700;
  padding:0.42rem 0.9rem;
  border-radius:9px;
}
.room-switch a:hover{color:var(--ink);background:var(--field);}
.room-switch a[aria-current="page"]{
  color:#ffffff;
  background:var(--ink);
}

.stub-panel{
  padding:1.4rem 1.3rem;
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:var(--radius-lg);
}
.stub-kicker{
  font-family:var(--font-mono);
  font-size:0.75rem;
  font-weight:700;
  color:var(--dim);
  margin-bottom:0.4rem;
  text-transform:uppercase;
  letter-spacing:0.04em;
}

.colophon{
  margin-top:2.4rem;
  font-family:var(--font-mono);
  font-size:0.76rem;
  color:var(--faint);
}

.sandbox-layout{display:flex;flex-direction:column;gap:1.1rem;}
.sandbox-lead h1{margin:0.2rem 0 0.5rem;}
.controls-row{
  display:flex;
  flex-wrap:wrap;
  gap:0.75rem 0.9rem;
  align-items:flex-end;
}
.field{display:flex;flex-direction:column;gap:0.35rem;min-width:10rem;}
.field label{
  font-family:var(--font-mono);
  font-size:0.72rem;
  font-weight:700;
  color:var(--dim);
}
.field select{
  font-family:var(--font-body);
  font-size:0.95rem;
  font-weight:500;
  color:var(--ink);
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:var(--radius);
  box-shadow:var(--key-drop);
  padding:0.55rem 0.75rem;
  min-height:2.6rem;
}
.btn-row{display:flex;flex-wrap:wrap;gap:0.55rem;align-items:center;}
.btn{
  font-family:var(--font-body);
  font-size:0.92rem;
  font-weight:700;
  border:2px solid var(--line-strong);
  background:var(--tray);
  color:var(--ink);
  padding:0.58rem 1rem;
  cursor:pointer;
  border-radius:var(--radius);
  box-shadow:var(--key-drop);
  transition:transform 0.08s, box-shadow 0.08s, background 0.12s;
}
.btn:hover{background:var(--accent-soft);}
.btn:active{transform:translateY(3px);box-shadow:0 0 0 var(--ink);}
.btn.primary{background:var(--ink);color:#ffffff;}
.btn.primary:hover{background:#2c3547;}
.btn[aria-pressed="true"]{background:var(--ink);color:#ffffff;transform:translateY(3px);box-shadow:0 0 0 var(--ink);}

.stage-wrap{
  border:2px solid var(--line-strong);
  border-radius:var(--radius-lg);
  overflow:hidden;
  background:var(--tray);
  box-shadow:0 18px 40px -18px rgba(29,36,51,0.35);
  line-height:0;
}
.stage-wrap canvas{
  display:block;
  width:100%;
  height:min(56vh,460px);
  touch-action:none;
  cursor:grab;
}
.stage-wrap canvas:active{cursor:grabbing;}
.hud-quiet{
  font-family:var(--font-mono);
  font-size:0.8rem;
  color:var(--dim);
}

/* -- Guide (Apple-style scroll pacing; sticky demo) -- */
.guide-wrap{max-width:1280px;}
.guide-hero{
  margin-bottom:1.4rem;
  max-width:64rem;
}
.guide-hero h1{
  font-family:var(--font-display);
  font-weight:700;
  font-size:clamp(2.2rem,5vw,3.4rem);
  line-height:1;
  letter-spacing:-0.03em;
  margin:0.2rem 0 0.65rem;
}
.guide-hero p{color:var(--ink-soft);margin-bottom:0.65rem;}
.guide-hero-note{
  font-family:var(--font-mono);
  font-size:0.8rem;
  color:var(--dim);
  margin-bottom:0 !important;
}

.guide-toc{
  display:flex;
  flex-wrap:wrap;
  gap:0.35rem;
  margin-bottom:1.6rem;
}
.guide-toc a{
  font-family:var(--font-mono);
  font-size:0.72rem;
  font-weight:700;
  text-decoration:none;
  color:var(--ink-soft);
  padding:0.35rem 0.65rem;
  border:2px solid var(--line-strong);
  border-radius:999px;
  background:var(--tray);
}
.guide-toc a:hover{color:var(--ink);background:var(--accent-soft);}
.guide-toc a:focus-visible{
  outline:3px solid var(--accent);
  outline-offset:3px;
}

.guide-layout{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(280px,400px);
  gap:1.6rem 1.8rem;
  align-items:start;
}
.guide-rail{display:flex;flex-direction:column;gap:0;}
.guide-beat{
  padding:2.8rem 0 3.2rem;
  border-top:1px solid var(--line);
  scroll-margin-top:1.2rem;
  min-height:42vh;
}
.guide-beat:first-child{border-top:none;padding-top:0.4rem;}
.guide-beat.is-active .beat-kicker{color:var(--accent);}
.beat-kicker{
  font-family:var(--font-mono);
  font-size:0.74rem;
  font-weight:700;
  color:var(--dim);
  text-transform:uppercase;
  letter-spacing:0.04em;
  margin-bottom:0.45rem;
}
.guide-beat h2{
  font-family:var(--font-display);
  font-size:clamp(1.55rem,3vw,2.05rem);
  font-weight:700;
  letter-spacing:-0.03em;
  line-height:1.15;
  margin-bottom:0.75rem;
}
.guide-beat p{
  color:var(--ink-soft);
  margin-bottom:0.75rem;
  max-width:38rem;
}
.guide-beat a{color:var(--accent);font-weight:700;}
.beat-drivers{
  list-style:none;
  margin:1rem 0 0;
  padding:0;
  display:flex;
  flex-direction:column;
  gap:0.45rem;
}
.beat-drivers li{
  font-size:0.95rem;
  color:var(--ink-soft);
  padding-left:0.85rem;
  border-left:3px solid var(--accent-soft);
}
.beat-drivers strong{color:var(--ink);font-weight:700;}
.beat-aside{
  margin-top:1rem !important;
  font-family:var(--font-mono);
  font-size:0.78rem !important;
  color:var(--dim) !important;
}
.strength-order{
  font-family:var(--font-mono) !important;
  font-size:0.86rem !important;
  font-weight:700;
  color:var(--ink) !important;
  line-height:1.55;
}

.guide-stage-panel{
  position:sticky;
  top:1rem;
  padding:0.9rem;
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:var(--radius-lg);
  box-shadow:0 4px 0 var(--ink);
}
.guide-stage-head{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  align-items:baseline;
  gap:0.4rem 0.8rem;
  margin-bottom:0.65rem;
}
.force-badge{
  font-family:var(--font-mono);
  font-size:0.78rem;
  font-weight:700;
  color:var(--ink);
}
.pair-formulas{
  font-family:var(--font-mono);
  font-size:0.74rem;
  color:var(--dim);
}
.guide-stage-wrap{
  margin-bottom:0.75rem;
  box-shadow:none;
}
/* The stage body is one fixed height for every beat so the sticky panel never jumps.
   Controls sit at its foot; on intro beats they fade out and the canvas grows into their space. */
.guide-stage-panel{--stage-h:min(46vh,360px);}
.guide-stage-body{
  position:relative;
  height:calc(var(--stage-h) + 4px + 0.75rem + var(--controls-h,160px));
}
/* Sequenced: leaving intro, the canvas shrinks and then controls fade in;
   entering intro, controls fade out and then the canvas grows */
.guide-stage-wrap canvas{
  height:var(--stage-h);
  transition:height 0.3s ease;
}
.guide-stage-panel.is-intro .guide-stage-wrap canvas{
  height:calc(var(--stage-h) + 0.75rem + var(--controls-h,160px));
  transition:height 0.3s ease 0.15s;
}
#guideControls{
  position:absolute;
  left:0;
  right:0;
  bottom:0;
}
.guide-stage-controls{margin-bottom:0.45rem;}
.guide-stage-panel .hud-quiet{min-height:1.55em;margin-top:0.55rem;}
.alt-pair-row{margin-top:0.55rem;}
/* Hidden controls keep their space and fade instead of collapsing */
#guideControls,
.alt-pair-row{
  transition:opacity 0.25s ease 0.25s, visibility 0s linear 0s;
}
.guide-stage-panel.is-intro #guideControls,
.alt-pair-row.is-off{
  opacity:0;
  visibility:hidden;
  transition:opacity 0.15s ease, visibility 0s linear 0.15s;
}
.force-badge,
.pair-formulas{transition:opacity 0.14s ease;}
.force-badge.is-swapping,
.pair-formulas.is-swapping{opacity:0;}
.guide-beat-end{padding-bottom:4rem;}

/* -- Learn mode: text hidden, the stage fills the screen for live teaching.
   Beats stay in the page as even, invisible spacers so scrolling still steps through them. -- */
.top-nav-end{display:flex;align-items:center;gap:0.9rem;flex-wrap:wrap;}
.learn-controls{display:flex;align-items:center;gap:0.45rem;}
.learn-toggle{
  display:inline-flex;
  align-items:center;
  gap:0.5rem;
  padding:0.35rem 0.75rem 0.35rem 0.4rem;
  font-family:var(--font-mono);
  font-size:0.78rem;
  font-weight:700;
  color:var(--ink);
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:999px;
  cursor:pointer;
}
.learn-toggle:hover{background:var(--accent-soft);}
.learn-toggle:focus-visible{outline:3px solid var(--accent);outline-offset:3px;}
.learn-switch{
  position:relative;
  width:2.1rem;
  height:1.15rem;
  border-radius:999px;
  background:var(--field-2);
  border:2px solid var(--line-strong);
  transition:background 0.15s ease;
}
.learn-switch::after{
  content:'';
  position:absolute;
  top:1px;
  left:1px;
  width:calc(1.15rem - 6px);
  height:calc(1.15rem - 6px);
  border-radius:50%;
  background:var(--ink);
  transition:transform 0.15s ease, background 0.15s ease;
}
.learn-toggle[aria-pressed="true"] .learn-switch{background:var(--accent);}
.learn-toggle[aria-pressed="true"] .learn-switch::after{transform:translateX(0.95rem);background:#ffffff;}
.learn-step{display:none;padding:0.2rem 0.7rem;font-size:1.05rem;line-height:1.2;}

body.learn-mode .learn-step{display:inline-flex;}
body.learn-mode .top-nav{
  position:fixed;
  top:0;
  left:0;
  right:0;
  z-index:20;
  height:3.6rem;
  margin:0;
  padding:0 0.75rem;
  border:0;
  justify-content:flex-end;
}
body.learn-mode .back-link,
body.learn-mode .mod-meta,
body.learn-mode .room-switch,
body.learn-mode .guide-hero,
body.learn-mode .guide-toc{display:none;}
body.learn-mode .guide-layout{display:block;}
body.learn-mode .guide-rail{padding-bottom:60vh;}
body.learn-mode .guide-beat{
  height:60vh;
  min-height:0;
  padding:0;
  border:0;
  overflow:hidden;
  visibility:hidden;
}
body.learn-mode .guide-stage-panel{
  position:fixed;
  top:3.6rem;
  left:0.75rem;
  right:0.75rem;
  z-index:10;
  /* panel = viewport minus bar and margin; the canvas takes what's left after padding, borders and controls */
  --stage-h:calc(100vh - 4.35rem - 1.8rem - 8px - 0.75rem - var(--controls-h,160px));
}
@supports (height:100dvh){
  body.learn-mode .guide-stage-panel{
    --stage-h:calc(100dvh - 4.35rem - 1.8rem - 8px - 0.75rem - var(--controls-h,160px));
  }
}
body.learn-mode .guide-stage-head{display:none;}
/* Presentation view: the section title is a menu of every section (assets/section-jump.js) */
body.learn-mode .guide-stage-head.has-jump{display:flex;}
body.learn-mode .jump-badge{
  display:inline-flex;align-items:center;gap:0.5rem;cursor:pointer;user-select:none;
  padding:0.3rem 0.75rem;border:2px solid var(--line-strong);border-radius:999px;background:var(--tray);
  box-shadow:0 2px 0 var(--ink);
}
body.learn-mode .jump-badge::after{content:"▾";font-size:0.9em;color:var(--dim);}
body.learn-mode .jump-badge:hover{background:var(--accent-soft);}
body.learn-mode .jump-badge:focus-visible{outline:3px solid var(--accent);outline-offset:2px;}
body.learn-mode .jump-badge[aria-expanded="true"]{background:var(--accent-soft);}
.jump-menu{
  position:fixed;z-index:60;min-width:16rem;max-width:min(30rem,calc(100vw - 16px));overflow:auto;
  padding:0.4rem;background:var(--tray);border:2px solid var(--line-strong);border-radius:var(--radius);
  box-shadow:0 4px 0 var(--ink),0 12px 30px rgba(29,36,51,0.18);
}
.jump-group{margin:0.55rem 0.5rem 0.2rem;font-size:0.82rem;font-weight:700;color:var(--dim);}
.jump-group:first-child{margin-top:0.2rem;}
.jump-item{
  display:block;width:100%;text-align:left;font:inherit;font-size:0.98rem;line-height:1.3;color:var(--ink);
  padding:0.4rem 0.6rem;border:0;border-radius:8px;background:none;cursor:pointer;
}
.jump-item:hover,.jump-item:focus-visible{background:var(--accent-soft);outline:none;}
.jump-item.is-current{background:var(--accent-soft);box-shadow:inset 3px 0 0 var(--accent);font-weight:700;}
.jump-item sub,.jump-item sup{line-height:0;}
body.learn-mode .guide-stage-panel .hud-quiet{visibility:hidden;}

@media (max-width:860px){
  .path{grid-template-columns:1fr;}
  .path a{aspect-ratio:auto;}
  .path .mod-go{margin-top:1rem;}
  .path .mod-anim{flex:none;height:150px;}
  .guide-layout{grid-template-columns:1fr;}
  .guide-stage-panel{
    position:relative;
    top:auto;
    order:-1;
  }
  .guide-beat{padding:1.6rem 0 1.8rem;}
}

@media (prefers-reduced-motion: reduce){
  .btn,.path a,
  #guideControls,.alt-pair-row,.guide-stage-wrap canvas,
  .force-badge,.pair-formulas{transition:none !important;}
  /* tile animations hold a still frame: Guide on the cloud, Lab on the cooling plate */
  .hub-anim *{animation:none !important;}
  .anim-guide .ga-p1,.anim-guide .ga-p2{opacity:0;}
  .anim-lab .la-plate{fill:#7fa3f5;}
}

/* -- Heat (sealed jar + gauges) -- */
.heat-power{min-width:16rem;flex:1 1 16rem;max-width:24rem;}
.heat-power output{color:var(--ink);}
.heat-power input[type="range"]{width:100%;accent-color:var(--ink);height:2.2rem;}
.heat-power input[type="range"]:focus-visible{outline:3px solid var(--accent);outline-offset:3px;}
.heat-power-ends{
  display:flex;justify-content:space-between;
  font-family:var(--font-mono);font-size:0.7rem;color:var(--dim);margin-top:-0.3rem;
}
.heat-main{display:grid;grid-template-columns:minmax(0,1fr) 15rem;gap:1rem;align-items:stretch;}
.heat-stage canvas{height:min(64vh,560px);cursor:default;}
.heat-gauges{display:flex;flex-direction:column;gap:0.75rem;}
.gauge,.heat-curve{
  background:var(--tray);
  border:2px solid var(--line-strong);
  border-radius:var(--radius);
  box-shadow:var(--key-drop);
  padding:0.7rem 0.9rem 0.8rem;
}
.gauge-label{
  font-family:var(--font-mono);font-size:0.72rem;font-weight:700;color:var(--dim);
  text-transform:uppercase;letter-spacing:0.04em;margin-bottom:0.2rem;
}
.gauge-read{font-family:var(--font-mono);font-weight:700;font-size:2rem;line-height:1.1;font-variant-numeric:tabular-nums;}
.gauge-read small{font-size:0.9rem;color:var(--ink-soft);}
.gauge-sub{font-family:var(--font-mono);font-size:0.8rem;color:var(--dim);min-height:1.2em;}
.gauge-state{font-weight:700;font-size:1.35rem;line-height:1.2;}
.thermo{height:10px;border-radius:5px;background:var(--field-2);margin-top:0.5rem;overflow:hidden;}
.thermo-fill{height:100%;background:var(--ink);border-radius:5px;transition:width 0.1s linear;}
.dial{display:block;width:100%;max-width:11rem;margin:0.1rem auto 0;}
.heat-curve canvas{display:block;width:100%;height:170px;}
@media (max-width:860px){
  .heat-main{grid-template-columns:1fr;}
  .heat-gauges{display:grid;grid-template-columns:repeat(auto-fit,minmax(10rem,1fr));}
}
@media (prefers-reduced-motion: reduce){
  .thermo-fill{transition:none;}
}
