/* Hazmat shipping papers explainer: a truck cab seen from above with five places for the papers. Hero, film, course
   offer and return banner reuse spring-brakes.css (.sbp-*); this file styles only .hp-*. The script sets the stage's
   data-mode (driving, away), data-spot (door, reach, seat, sleeper, glovebox), data-stack (top, buried) and
   data-verdict (pass, warn, fail), moves the papers and writes the readouts. Without script the picture shows the
   papers legally in the door pouch while driving. Every SVG text label is at least 11.5px in the 360-wide viewBox. */
.hp-page{--hp-go:#31d67b;--hp-no:#ef4444;--hp-warn:#fbbf24;--hp-console:#151b20}
.hp-page .sbp-hero-grid.is-no-film{grid-template-columns:minmax(0,1fr)}
.hp-demo{padding-block:64px 72px;background:var(--paper)}
.hp-demo-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);grid-template-areas:"head head" "stage panel";gap:24px 40px;align-items:start}
.hp-head{grid-area:head}
.hp-stage{grid-area:stage;margin:0;padding:10px;border-radius:16px;background:linear-gradient(170deg,#222a30,#0d1114 80%);box-shadow:0 30px 60px -34px rgb(0 0 0/.75),inset 0 1px 0 rgb(255 255 255/.06)}
.hp-svg{display:block;width:100%;height:auto;border-radius:10px;background:#10161a}
.hp-panel{grid-area:panel;display:grid;gap:14px;min-width:0}

/* the HUD: where you are and how many legal spots you found; script on */
.hp-hud{display:none;align-items:center;gap:6px;flex-wrap:wrap;padding:0 2px 10px}
.hp-stage.is-js .hp-hud{display:flex}
.hp-chip{display:inline-flex;align-items:center;gap:7px;margin:0;padding:6px 10px 6px 8px;border-radius:8px;background:#080b0d;box-shadow:inset 0 0 0 1px rgb(255 255 255/.09);font-size:13px;line-height:1;white-space:nowrap}
.hp-chip i{flex:none;width:9px;height:9px;border-radius:50%;background:#8f9a9d}
.hp-chip span{color:#a9b3b8;font-weight:600}
.hp-chip b{color:#e8eef0;font-weight:800}
.hp-stage[data-mode="away"] .hp-chip-mode i{background:var(--hp-warn)}
.hp-chip-score i{background:var(--hp-go)}

/* the cab */
.hp-cab{fill:#1c2329;stroke:#59636a;stroke-width:1.6}
.hp-glass{fill:#1e3a4a;stroke:#6ed2ff;stroke-opacity:.4;stroke-width:1}
.hp-dash{fill:#262f35;stroke:#3a4246;stroke-width:1}
.hp-seat{fill:#2f383e;stroke:#4a545a;stroke-width:1.2}
.hp-bunk{fill:#232b31;stroke:#4a545a;stroke-width:1.2;stroke-dasharray:5 4}
.hp-wheel{fill:none;stroke:#8f9a9d;stroke-width:4}
.hp-pouch{fill:#3a4246;stroke:#8f9a9d;stroke-width:1}
.hp-spot{fill:transparent;stroke:#8f9a9d;stroke-opacity:.35;stroke-width:1.4;stroke-dasharray:4 3;transition:stroke .2s,fill .2s}
.hp-label{fill:#d3dade;font-size:11.5px;font-weight:800;letter-spacing:.03em;text-transform:uppercase;paint-order:stroke;stroke:#10161a;stroke-width:2.6px;stroke-linejoin:round}
.hp-mid{text-anchor:middle}

/* the picked spot takes the verdict color */
.hp-stage[data-spot="door"] [data-hp-zone="door"],.hp-stage[data-spot="reach"] [data-hp-zone="reach"],.hp-stage[data-spot="seat"] [data-hp-zone="seat"],.hp-stage[data-spot="sleeper"] [data-hp-zone="sleeper"],.hp-stage[data-spot="glovebox"] [data-hp-zone="glovebox"]{stroke-opacity:1;stroke-width:2.4;stroke-dasharray:none;stroke:var(--hp-go);fill:rgb(49 214 123/.12)}
.hp-stage[data-verdict="fail"][data-spot="door"] [data-hp-zone="door"],.hp-stage[data-verdict="fail"][data-spot="reach"] [data-hp-zone="reach"],.hp-stage[data-verdict="fail"][data-spot="seat"] [data-hp-zone="seat"],.hp-stage[data-verdict="fail"][data-spot="sleeper"] [data-hp-zone="sleeper"],.hp-stage[data-verdict="fail"][data-spot="glovebox"] [data-hp-zone="glovebox"]{stroke:var(--hp-no);fill:rgb(239 68 68/.14)}
.hp-stage[data-verdict="warn"][data-spot="door"] [data-hp-zone="door"],.hp-stage[data-verdict="warn"][data-spot="reach"] [data-hp-zone="reach"],.hp-stage[data-verdict="warn"][data-spot="seat"] [data-hp-zone="seat"]{stroke:var(--hp-warn);fill:rgb(251 191 36/.14)}

/* the papers */
.hp-papers{transition:transform .25s ease-out}
.hp-ring{fill:none;stroke:var(--hp-go);stroke-width:3}
.hp-stage[data-verdict="fail"] .hp-ring{stroke:var(--hp-no)}
.hp-stage[data-verdict="warn"] .hp-ring{stroke:var(--hp-warn)}
.hp-sheet{fill:#f4f1e8;stroke:#6b767b;stroke-width:1}
.hp-sheet-back{fill:#d9d4c5}
.hp-lines{fill:none;stroke:#59636a;stroke-width:1.4}
.hp-flag{fill:var(--hp-no)}
.hp-bills{display:none;fill:#b9c3c8;stroke:#59636a;stroke-width:1}
.hp-stage[data-stack="buried"] .hp-flag{display:none}
.hp-stage[data-stack="buried"] .hp-bills{display:inline}

/* the verdict card */
.hp-card{fill:#080b0d;fill-opacity:.9;stroke:var(--hp-go);stroke-width:1.4}
.hp-stage[data-verdict="fail"] .hp-card{stroke:var(--hp-no)}
.hp-stage[data-verdict="warn"] .hp-card{stroke:var(--hp-warn)}
.hp-verdict{fill:#fff;font-size:13px;font-weight:800}

/* controls: one dark console, every button the same dark face and white text, amber when active or focused */
.hp-controls[hidden]{display:none}
.hp-controls{display:grid;gap:12px;padding:14px;border-radius:16px;background:linear-gradient(180deg,#232b31,var(--hp-console));box-shadow:0 18px 40px -28px rgb(0 0 0/.8),inset 0 1px 0 rgb(255 255 255/.07);color:#e8eef0}
.hp-btn{position:relative;display:flex;align-items:center;gap:12px;min-width:0;min-height:48px;padding:10px 12px;border:0;border-radius:12px;background:linear-gradient(180deg,#303a41,#1b2227);box-shadow:inset 0 1px 0 rgb(255 255 255/.1),0 3px 0 #06090b,0 8px 16px -10px rgb(0 0 0/.7);color:#fff;font:inherit;font-size:15px;font-weight:700;line-height:1.2;text-align:left;cursor:pointer;transition:transform .08s,box-shadow .12s,background .12s}
.hp-btn:hover{background:linear-gradient(180deg,#38434b,#20282d)}
.hp-btn:active{transform:translateY(2px);box-shadow:inset 0 1px 0 rgb(255 255 255/.06),0 1px 0 #06090b}
.hp-btn[aria-pressed="true"]{transform:translateY(2px);box-shadow:inset 0 0 0 2px var(--sbp-amber,#ffb400),0 1px 0 #06090b}
.hp-btn:focus-visible{outline:3px solid var(--sbp-amber,#ffb400);outline-offset:3px}
.hp-name{display:grid;gap:3px;min-width:0}
.hp-name small{color:#a9b3b8;font-size:13px;font-weight:600}
.hp-group{display:grid;gap:6px}
.hp-label-row{margin:0;color:#a9b3b8;font-size:13px;font-weight:800;letter-spacing:.08em;text-transform:uppercase}
.hp-row{display:grid;gap:6px}
.hp-row-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.hp-btn-seg{justify-content:center;padding:8px 6px;text-align:center}
.hp-reset{justify-self:start;gap:8px;min-height:44px;padding:8px 16px 8px 12px}
.hp-reset-icon{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.hp-status{display:block;min-height:7.3em;padding:12px 14px 12px 16px;border-left:5px solid var(--hp-go);border-radius:0 10px 10px 0;background:var(--white,#fffffc);color:var(--ink);font-size:16px;font-weight:600;line-height:1.45}
.hp-text{margin:0;max-width:40em;color:var(--ink);font-size:17px;line-height:1.6}
.hp-text strong{display:block;margin-bottom:2px;font-weight:700}

@media (min-width:761px){
  .hp-page .sbp-film-frame.is-wide{aspect-ratio:auto;padding-bottom:58px;background:#0b0d0f}
  .hp-page .sbp-film-frame.is-wide video{aspect-ratio:16/9;width:100%;height:auto}
  .hp-page .sbp-film-frame.is-wide .sbp-play{bottom:58px}
  .hp-page .sbp-film-frame.is-wide .sbp-sound-on{left:12px;right:auto;top:auto;bottom:10px}
  .hp-page .sbp-film-frame.is-wide .sbp-pause{right:12px;top:auto;bottom:10px}
}
@media (max-width:900px){
  .hp-demo-grid{grid-template-columns:minmax(0,1fr);grid-template-areas:"head" "stage" "panel";gap:16px}
}
@media (max-width:760px){
  .hp-demo{padding-block:36px 44px}
  .hp-stage{margin-inline:-8px;padding:8px 6px 6px;border-radius:14px}
  .hp-svg{border-radius:8px}
  .hp-hud{gap:4px;padding:0 0 6px}
  .hp-chip{padding:4px 6px 4px 5px;font-size:11px;gap:4px}
  .hp-chip i{width:8px;height:8px}
  .hp-panel{gap:10px}
  .hp-controls{gap:10px;margin-inline:-8px;padding:12px 10px}
  .hp-btn{padding:8px 9px;gap:8px;font-size:14px}
  .hp-btn-seg{padding:8px 4px}
  .hp-name small{font-size:12px}
  .hp-status{min-height:8.8em;padding:10px 12px;font-size:15px}
  .hp-text{font-size:16px}
}
@media (prefers-reduced-motion:reduce){
  .hp-page .hp-demo *{transition:none!important;animation:none!important}
}
