
    :root {
      color-scheme: dark;
      --navy: #0f1b2d;
      --panel: #16253a;
      --panel-raised: #1b2d44;
      --line: #687d95;
      --paper: #f5f4ef;
      --muted: #c0cad6;
      --amber: #f2b134;
      --red: #ff786f;
      --ink: #0f1b2d;
      --focus: #ffe09a;
      --radius: 14px;
    }

    * { box-sizing: border-box; }

    html { background: var(--navy); scroll-behavior: smooth; }

    body {
      margin: 0;
      background: var(--navy);
      color: var(--paper);
      font: 16px/1.55 ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    }

    button, input { font: inherit; }

    button { cursor: pointer; }

    button:disabled { cursor: not-allowed; }

    a { color: var(--amber); text-underline-offset: .18em; }
    a:hover { text-decoration-thickness: 2px; }

    :focus-visible {
      outline: 3px solid var(--focus);
      outline-offset: 3px;
    }

    [hidden] { display: none !important; }

    .page {
      width: min(100% - 32px, 1200px);
      margin: 0 auto;
      padding: 28px 0 48px;
    }

    .masthead { max-width: 760px; margin: 0 0 24px; }
    .lab-nav { margin: -12px 0 10px; font-size: .9rem; font-weight: 700; }
    .lab-nav a { display: inline-flex; min-height: 44px; align-items: center; text-decoration: none; }
    .lab-nav a:hover { text-decoration: underline; }

    .eyebrow, .section-kicker {
      margin: 0 0 8px;
      color: var(--amber);
      font-size: .78rem;
      font-weight: 750;
      letter-spacing: .11em;
      text-transform: uppercase;
    }

    h1, h2, h3, p { margin-top: 0; }

    h1 {
      max-width: 17ch;
      margin-bottom: 12px;
      font-size: clamp(2rem, 5vw, 3.3rem);
      line-height: 1.05;
      letter-spacing: -.035em;
    }

    h2 { margin-bottom: 8px; font-size: 1.3rem; line-height: 1.2; }
    h3 { margin-bottom: 8px; font-size: 1.02rem; }

    .lede { max-width: 68ch; margin-bottom: 12px; font-size: 1.03rem; }
    .context-line { margin: 0; color: var(--muted); font-size: .93rem; }

    .layout {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
      gap: 18px;
      align-items: start;
    }

    .panel {
      min-width: 0;
      padding: 22px;
      border: 1px solid var(--line);
      border-radius: var(--radius);
      background: var(--panel);
    }

    .right-rail { display: grid; gap: 18px; min-width: 0; }
    .section-heading { margin-bottom: 15px; }
    .section-heading p:last-child { margin-bottom: 0; }
    .subtle { color: var(--muted); }
    .small { font-size: .88rem; }
    .source-ref { font-size: .78em; font-weight: 800; white-space: nowrap; }

    .intro-note {
      margin: 14px 0 18px;
      padding: 10px 12px;
      border-left: 3px solid var(--amber);
      color: var(--muted);
      background: var(--panel-raised);
      font-size: .9rem;
    }

    fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }

    legend {
      width: 100%;
      margin-bottom: 9px;
      font-weight: 750;
    }

    .legend-note { display: block; margin-top: 2px; color: var(--muted); font-size: .82rem; font-weight: 450; }
    .variable-list { display: grid; gap: 8px; }

    .variable-row {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(82px, .5fr);
      gap: 12px;
      min-height: 66px;
      align-items: center;
      padding: 8px 10px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--navy);
    }

    .variable-choice {
      display: flex;
      min-height: 48px;
      min-width: 0;
      align-items: center;
      gap: 10px;
      cursor: pointer;
    }

    .variable-choice input, .align-toggle input {
      flex: 0 0 auto;
      width: 22px;
      height: 22px;
      accent-color: var(--amber);
    }

    .var-copy { min-width: 0; }
    .var-name { display: block; font-weight: 750; line-height: 1.25; }
    .var-detail { display: block; color: var(--muted); font-size: .78rem; line-height: 1.3; }

    .cost-chip {
      display: inline-block;
      margin-top: 2px;
      color: var(--amber);
      font-size: .75rem;
      font-weight: 700;
    }

    .peak { min-width: 0; font-size: .75rem; }
    .peak-label { display: block; margin-bottom: 4px; color: var(--muted); line-height: 1.25; }

    .peak-track {
      position: relative;
      height: 8px;
      overflow: visible;
      border-radius: 99px;
      background: #33445b;
    }

    .peak-fill { display: block; height: 100%; border-radius: inherit; background: var(--amber); }
    .peak-limit {
      position: absolute;
      top: -3px;
      bottom: -3px;
      left: 55.56%;
      width: 2px;
      background: var(--paper);
    }

    .scale-note { display: flex; justify-content: space-between; gap: 8px; margin: 5px 0 0; color: var(--muted); font-size: .7rem; }

    .load-box {
      position: sticky;
      bottom: 10px;
      z-index: 2;
      box-shadow: 0 -10px 24px 4px var(--navy);
      margin-top: 16px;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--panel-raised);
    }

    .load-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
    .load-value { color: var(--amber); font-size: 1.1rem; font-weight: 800; white-space: nowrap; }

    .load-track {
      position: relative;
      height: 15px;
      margin: 8px 0 5px;
      overflow: visible;
      border-radius: 99px;
      background: #33445b;
    }

    .load-fill { display: block; height: 100%; border-radius: inherit; background: var(--amber); transition: width .18s ease; }
    .load-fill.is-over { background: var(--red); }
    .load-target {
      position: absolute;
      top: -4px;
      bottom: -4px;
      left: 80%;
      width: 2px;
      background: var(--paper);
    }

    .target-labels { display: flex; justify-content: space-between; color: var(--muted); font-size: .75rem; }
    .budget-error { margin: 9px 0 0; color: var(--red); font-weight: 750; }
    .load-note { margin: 8px 0 0; color: var(--muted); font-size: .8rem; }

    .align-toggle {
      display: flex;
      min-height: 56px;
      align-items: center;
      gap: 10px;
      margin-top: 15px;
      padding: 10px 12px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--navy);
      cursor: pointer;
    }

    .align-copy { display: block; font-weight: 700; line-height: 1.25; }
    .align-note { display: block; margin-top: 3px; color: var(--muted); font-size: .8rem; font-weight: 450; }

    .actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }

    .button {
      display: inline-flex;
      min-height: 48px;
      align-items: center;
      justify-content: center;
      padding: 10px 15px;
      border: 1px solid var(--amber);
      border-radius: 9px;
      color: var(--ink);
      background: var(--amber);
      font-weight: 800;
      text-align: center;
      line-height: 1.2;
    }

    .button.secondary { border-color: var(--line); color: var(--paper); background: var(--panel-raised); }
    .button:disabled { color: var(--paper); background: #27384e; border-color: var(--line); }

    .order-note {
      margin: 14px 0 0;
      padding: 10px 12px;
      border-radius: 9px;
      color: var(--muted);
      background: var(--panel-raised);
      font-size: .88rem;
    }

    .profile-note { margin: 0 0 14px; color: var(--muted); font-size: .9rem; }
    .flight-controls { display: flex; flex-wrap: wrap; gap: 9px; }
    .flight-controls .button { flex: 1 1 180px; }
    .run-help { min-height: 1.5em; margin: 9px 0 0; color: var(--muted); font-size: .82rem; }

    .timeline-wrap {
      margin-top: 17px;
      padding: 10px 10px 7px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--navy);
    }

    .timeline-title { margin: 0 0 2px; font-size: .82rem; font-weight: 750; }
    .timeline-svg { display: block; width: 100%; height: auto; color: var(--paper); }
    .timeline-caption { margin: 0; color: var(--muted); font-size: .76rem; }
    .timeline-line { stroke: #718096; stroke-width: 4; stroke-linecap: round; }
    .timeline-progress { stroke: var(--amber); stroke-width: 4; stroke-linecap: round; }
    .timeline-event { fill: var(--paper); stroke: var(--navy); stroke-width: 2; }
    .timeline-marker { fill: var(--amber); stroke: var(--navy); stroke-width: 3; }
    .timeline-label { fill: var(--paper); font: 12px/1.2 ui-sans-serif, system-ui, sans-serif; }

    .result-box {
      margin-top: 15px;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--panel-raised);
    }

    .result-box.is-failure { border-color: var(--red); }
    .result-title { margin: 0 0 5px; font-weight: 850; }
    .result-box.is-failure .result-title { color: var(--red); }
    .result-copy { margin: 0; color: var(--muted); }
    .event-list { display: grid; gap: 9px; margin: 12px 0 0; padding-left: 25px; }
    .event-list li { padding-left: 3px; }
    .event-list strong { color: var(--paper); }
    .data-cycle-note { margin: 13px 0 0; padding-top: 10px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
    .display-pacing { margin: 8px 0 0; color: var(--muted); font-size: .76rem; }

    .reveal-list { display: grid; gap: 12px; margin: 16px 0; padding: 0; list-style: none; counter-reset: reveal; }
    .reveal-list li {
      position: relative;
      min-height: 54px;
      padding: 12px 12px 12px 48px;
      border: 1px solid var(--line);
      border-radius: 10px;
      background: var(--navy);
      counter-increment: reveal;
    }

    .reveal-list li::before {
      content: counter(reveal);
      position: absolute;
      top: 12px;
      left: 12px;
      display: grid;
      width: 25px;
      height: 25px;
      place-items: center;
      border-radius: 50%;
      color: var(--ink);
      background: var(--amber);
      font-weight: 850;
      line-height: 1;
    }

    .source-register {
      margin-top: 18px;
      padding-top: 16px;
      border-top: 1px solid var(--line);
    }

    .source-list { display: grid; gap: 8px; margin: 10px 0 0; padding: 0; list-style: none; }
    .source-list li { color: var(--muted); font-size: .8rem; }
    .source-id { color: var(--paper); font-weight: 800; }
    .source-links { display: inline-flex; flex-wrap: wrap; gap: 8px; margin-left: 4px; }

    footer {
      max-width: 90ch;
      margin: 18px auto 0;
      padding: 13px 2px 0;
      border-top: 1px solid var(--line);
      color: var(--muted);
      font-size: .82rem;
    }

    .sr-only {
      position: absolute;
      width: 1px;
      height: 1px;
      padding: 0;
      margin: -1px;
      overflow: hidden;
      clip: rect(0, 0, 0, 0);
      white-space: nowrap;
      border: 0;
    }

    @media (max-width: 760px) {
      .page { width: min(100% - 24px, 620px); padding-top: 20px; }
      .layout { grid-template-columns: minmax(0, 1fr); gap: 12px; }
      .right-rail { gap: 12px; }
      .panel { padding: 17px; }
      .variable-row { grid-template-columns: minmax(0, 1fr) minmax(112px, .45fr); gap: 8px; padding: 8px; }
      .peak { font-size: .69rem; }
      .flight-controls .button { flex-basis: 100%; }
    }

    @media (max-width: 360px) {
      .page { width: min(100% - 18px, 620px); }
      .panel { padding: 13px; }
      .variable-row { grid-template-columns: minmax(0, 1fr) 86px; }
      .var-detail { font-size: .73rem; }
      .actions .button { flex: 1 1 100%; }
    }

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

.local-layout-1 {width:62%}
