:root {
  color-scheme: light;
  --ink: #0a2429;
  --deep: #06191f;
  --deep-2: #0c3034;
  --teal: #0d7772;
  --teal-2: #14a38f;
  --lime: #c7f459;
  --mint: #50ddbd;
  --sky: #5bb8f5;
  --sun: #ffbf4b;
  --rose: #ff7068;
  --paper: #f1f5ef;
  --white: #fffefa;
  --line: #d5e0d6;
  --muted: #607173;
  --soft: #e8efe7;
  --shadow: 0 18px 55px rgba(12, 52, 51, .09);
  --shadow-strong: 0 24px 70px rgba(5, 35, 38, .17);
  --radius: 24px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 92px; }
body { margin: 0; overflow-x: hidden; background: var(--paper); color: var(--ink); font-family: "DM Sans", ui-sans-serif, system-ui, sans-serif; }
button, input, select, textarea { font: inherit; }
button, a, summary, label { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
button { position: relative; overflow: hidden; }
.hidden { display: none !important; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.skip-link { position: fixed; z-index: 200; top: 8px; left: 8px; transform: translateY(-150%); padding: 12px 16px; border-radius: 10px; color: var(--deep); background: var(--lime); font-weight: 800; }
.skip-link:focus { transform: translateY(0); }

select, textarea, input[type="text"] { width: 100%; min-height: 44px; border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; color: var(--ink); background: var(--white); outline: none; }
select:focus, textarea:focus, input:focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid rgba(80, 221, 189, .46); outline-offset: 3px; }

.ambient { position: fixed; z-index: -1; border-radius: 999px; pointer-events: none; }
.ambient-one { width: 42rem; height: 42rem; right: -21rem; top: 11rem; background: radial-gradient(circle, rgba(80, 221, 189, .2), transparent 68%); }
.ambient-two { width: 34rem; height: 34rem; left: -20rem; bottom: 3rem; background: radial-gradient(circle, rgba(199, 244, 89, .17), transparent 69%); }

.topbar { position: sticky; top: 0; z-index: 60; min-height: 74px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 24px; padding: 0 max(22px, calc((100vw - 1680px) / 2)); color: #f3fff9; background: rgba(6, 25, 31, .95); border-bottom: 1px solid rgba(255, 255, 255, .1); backdrop-filter: blur(18px); }
.brand { display: inline-flex; align-items: center; gap: 11px; min-height: 44px; text-decoration: none; }
.brand > span:last-child { display: grid; }
.brand b { font-family: Manrope, sans-serif; font-size: 1rem; line-height: 1.1; }
.brand small { margin-top: 3px; color: #abc1bd; font-size: .65rem; letter-spacing: .08em; text-transform: uppercase; }
.brand-mark { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; color: var(--deep); background: linear-gradient(145deg, #d7ff7a, var(--lime)); font: 800 .84rem/1 Manrope, sans-serif; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5), 0 8px 24px rgba(199, 244, 89, .13); }
.brand-mark span { margin: 0 1px; font-size: .6em; transform: translateY(-.45em); }
.topbar nav { min-width: 0; display: flex; align-items: center; justify-content: center; gap: clamp(8px, 1.25vw, 23px); }
.topbar nav a { min-height: 44px; display: inline-flex; align-items: center; flex: 0 0 auto; color: #d7e7e3; text-decoration: none; font-size: clamp(.67rem, .72vw, .78rem); font-weight: 700; white-space: nowrap; }
.topbar nav a:hover { color: var(--lime); }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
.walkthrough-trigger, .mobile-controls-button { min-height: 44px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 11px; padding: 9px 12px; color: white; background: rgba(255, 255, 255, .06); font-weight: 800; cursor: pointer; }
.walkthrough-trigger:hover { color: var(--deep); background: var(--lime); }
.mobile-controls-button { display: none; }

.page-shell { width: min(1680px, 100%); margin: 0 auto; display: grid; grid-template-columns: 310px minmax(0, 1fr); gap: 24px; padding: 24px; }
.content { min-width: 0; }
.sidebar { position: sticky; top: 98px; align-self: start; max-height: calc(100vh - 122px); overflow-y: auto; padding: 22px; border-radius: var(--radius); color: #eefcf8; background: radial-gradient(circle at 15% 0, rgba(80, 221, 189, .13), transparent 28%), linear-gradient(155deg, var(--deep), #0b3437 70%, #0a4842); box-shadow: var(--shadow-strong); scrollbar-width: thin; scrollbar-color: #315657 transparent; }
.sidebar-heading, .section-kicker, .subheading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.live-dot, .section-kicker { color: #c5d8d3; font-size: .69rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
.live-dot i { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 99px; background: var(--lime); box-shadow: 0 0 0 5px rgba(199, 244, 89, .12); }
.icon-button { display: none; width: 44px; height: 44px; padding: 0; border: 0; color: white; background: transparent; font-size: 1.75rem; cursor: pointer; }
.scenario-chip { display: grid; gap: 4px; margin: 18px 0 2px; padding: 12px; border: 1px solid rgba(255, 255, 255, .11); border-radius: 12px; background: rgba(255, 255, 255, .055); }
.scenario-chip span { color: #a9c1bc; font-size: .67rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; }
.scenario-chip strong { overflow-wrap: anywhere; color: var(--lime); font: 800 .77rem Manrope, sans-serif; }
.control-label, .weight-stack label { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 18px 0 7px; font-size: .81rem; font-weight: 700; }
.toggle-row { min-height: 44px; display: flex; align-items: flex-start; gap: 11px; margin-top: 17px; padding: 5px 0; cursor: pointer; }
.toggle-row input { flex: 0 0 auto; width: 20px; height: 20px; margin-top: 2px; accent-color: var(--lime); }
.toggle-row span { display: grid; }
.toggle-row b { font-size: .8rem; }
.toggle-row small { margin-top: 3px; color: #a9c1bc; font-size: .7rem; line-height: 1.35; }
.preset-stack, .weight-stack, .scenario-manager, .export-card { margin-top: 22px; padding-top: 19px; border-top: 1px solid rgba(255, 255, 255, .14); }
.preset-grid { display: grid; grid-template-columns: 1fr; gap: 7px; margin-top: 12px; }
.preset-grid button, .scenario-preset-row button, .suggested-questions button { min-height: 44px; border: 1px solid rgba(255, 255, 255, .13); border-radius: 10px; padding: 9px 11px; color: #e6f5f1; background: rgba(255, 255, 255, .06); text-align: left; font-size: .76rem; font-weight: 800; cursor: pointer; }
.preset-grid button.active, .preset-grid button:hover { color: var(--deep); background: var(--lime); }
.weight-stack p, .export-card p { margin: 8px 0 0; color: #a9c1bc; font-size: .71rem; line-height: 1.5; }
.weight-stack output { min-width: 42px; padding: 3px 7px; border-radius: 99px; color: var(--deep); background: var(--lime); text-align: center; }
input[type="range"] { width: 100%; height: 28px; margin: -3px 0 2px; accent-color: var(--lime); cursor: pointer; }
.scenario-field { display: grid; gap: 7px; margin-top: 13px; color: #d9ebe6; font-size: .73rem; font-weight: 800; }
.scenario-action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 9px; }
.scenario-action-grid button { min-height: 44px; border: 1px solid rgba(255, 255, 255, .14); border-radius: 10px; padding: 9px; color: #e9f8f4; background: rgba(255, 255, 255, .07); text-align: center; font-size: .71rem; font-weight: 800; cursor: pointer; }
.scenario-action-grid button:hover:not(:disabled) { background: rgba(255, 255, 255, .14); }
.scenario-action-grid .button-primary { border-color: var(--lime); color: var(--deep); background: var(--lime); }
.scenario-action-grid .scenario-copy { grid-column: 1 / -1; }
.scenario-action-grid .danger-button { border-color: rgba(255, 112, 104, .55); color: #ffd0cb; }
.scenario-action-grid button:disabled { cursor: not-allowed; opacity: .46; }
.scenario-manager-status { margin: 10px 0 0; color: #a9c1bc; font-size: .68rem; line-height: 1.45; }
.export-grid { display: grid; gap: 8px; margin-top: 12px; }
.export-grid button { min-height: 44px; border: 1px solid rgba(255, 255, 255, .13); border-radius: 11px; padding: 10px 12px; color: #e9f8f4; background: rgba(255, 255, 255, .07); text-align: left; font-weight: 700; cursor: pointer; }
.export-grid button:hover { transform: translateY(-1px); background: rgba(255, 255, 255, .13); }
.export-grid button span { display: inline-grid; place-items: center; min-width: 40px; margin-right: 7px; border-radius: 7px; padding: 4px; color: var(--deep); background: var(--lime); font-size: .65rem; }

.eyebrow { margin: 0 0 11px; color: var(--lime); font-size: .71rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.eyebrow.dark { color: var(--teal); }
.hero { position: relative; min-height: 540px; display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(295px, .65fr); align-items: center; gap: clamp(26px, 4vw, 56px); overflow: hidden; padding: clamp(34px, 5vw, 72px); border-radius: 32px; color: white; background: radial-gradient(circle at 80% 20%, rgba(80, 221, 189, .22), transparent 27%), linear-gradient(132deg, #06191f 0%, #0b3639 58%, #11685d 100%); box-shadow: var(--shadow-strong); }
.hero::before { content: ""; position: absolute; width: 410px; height: 410px; right: -125px; bottom: -220px; border: 1px solid rgba(199, 244, 89, .22); border-radius: 50%; box-shadow: 0 0 0 55px rgba(199, 244, 89, .04), 0 0 0 110px rgba(199, 244, 89, .025); }
.hero-copy { position: relative; z-index: 1; }
.hero h1 { max-width: 850px; margin: 0; font: 800 clamp(2.9rem, 4.7vw, 5rem)/1 Manrope, sans-serif; letter-spacing: -.055em; }
.hero h1 em { color: var(--lime); font-style: normal; }
.hero-lede { max-width: 760px; margin: 21px 0 0; color: #d1e4df; font-size: clamp(.98rem, 1.25vw, 1.13rem); line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.button-primary, .button-quiet { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 12px; padding: 11px 17px; text-decoration: none; font-weight: 800; cursor: pointer; }
.button-primary { color: var(--deep) !important; background: var(--lime) !important; }
.button-primary:hover { background: #d5ff73 !important; }
.button-quiet { color: #e8f7f3; border: 1px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .06); }
.hero-signal { position: relative; z-index: 1; display: grid; justify-items: center; padding: 25px; border: 1px solid rgba(255, 255, 255, .15); border-radius: 25px; background: rgba(1, 20, 23, .36); backdrop-filter: blur(14px); }
.hero-signal > p { justify-self: start; margin: 0 0 11px; color: #b9d1cc; font-size: .71rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.signal-orbit { width: 160px; height: 160px; display: grid; place-content: center; border: 1px solid rgba(199, 244, 89, .35); border-radius: 50%; text-align: center; box-shadow: inset 0 0 0 15px rgba(199, 244, 89, .035), 0 0 50px rgba(80, 221, 189, .09); }
.signal-orbit span { color: var(--lime); font: 800 3rem/1 Manrope, sans-serif; }
.signal-orbit small { max-width: 110px; color: #bfd4cf; line-height: 1.25; }
.signal-flow { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 7px; margin: 21px 0; color: #d7e9e5; font-size: .62rem; }
.signal-flow i { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--mint), transparent); }
.hero-signal > small { color: #a7bfba; text-align: center; line-height: 1.45; }

.trust-strip { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px; margin: 18px 0; padding: 13px 16px; border: 1px solid #ead79f; border-radius: 16px; background: #fff8e6; }
.trust-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: #775400; background: #ffe3a0; font-weight: 800; }
.trust-strip div:nth-child(2) { display: grid; }
.trust-strip strong { font-size: .88rem; }
.trust-strip span { color: #756b53; font-size: .75rem; }
.trust-strip button { min-height: 44px; border: 0; padding: 9px; color: #5d4b19; background: transparent; font-size: .76rem; font-weight: 800; text-decoration: underline; cursor: pointer; }
.metrics, .portfolio-metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; margin: 18px 0; }
.metrics article, .portfolio-metrics article, .panel { border: 1px solid rgba(211, 224, 213, .92); background: rgba(255, 254, 250, .9); box-shadow: var(--shadow); backdrop-filter: blur(10px); }
.metrics article, .portfolio-metrics article { min-width: 0; padding: 18px; border-radius: 17px; }
.metrics span, .portfolio-metrics span { color: var(--muted); font-size: .75rem; font-weight: 700; }
.metrics strong, .portfolio-metrics strong { display: block; margin: 5px 0 2px; font: 800 1.75rem/1.15 Manrope, sans-serif; }
.metrics small, .portfolio-metrics small { color: #82908f; font-size: .66rem; }
.metrics .metric-code { overflow-wrap: anywhere; color: var(--teal); font-size: clamp(.8rem, 1.15vw, 1.08rem); }

.panel { margin-top: 18px; padding: clamp(18px, 2vw, 28px); border-radius: var(--radius); }
.panel h2, .method-sources h2 { margin: 0; font: 800 clamp(1.35rem, 2vw, 1.9rem)/1.18 Manrope, sans-serif; letter-spacing: -.03em; }
.panel h3 { font-family: Manrope, sans-serif; }
.panel p { color: var(--muted); }
.panel-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 17px; }
.panel-heading.compact { align-items: center; }
.panel-heading p { max-width: 730px; margin: 7px 0 0; font-size: .86rem; line-height: 1.55; }
.map-tools { flex: 0 0 min(570px, 51%); display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(165px, .75fr); gap: 10px; }
.route-search label, .layer-search label, .ask-panel label { display: block; margin-bottom: 6px; color: var(--muted); font-size: .71rem; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }

.map-frame { position: relative; overflow: hidden; border: 1px solid #c5d4cc; border-radius: 18px; background: #cbd8d2; isolation: isolate; }
#map { width: 100%; height: clamp(470px, 65svh, 650px); min-height: 0; }
#map .mapboxgl-canvas { margin: 0 !important; max-height: none !important; }
.mapboxgl-ctrl-group { border-radius: 10px !important; overflow: hidden; }
.mapboxgl-ctrl-group button { width: 38px; height: 38px; }
.mapboxgl-popup-content { border-radius: 14px !important; padding: 13px 15px !important; box-shadow: 0 10px 30px rgba(5, 30, 32, .16) !important; }
.map-popup { max-width: 240px; }
.map-popup b { display: block; margin-bottom: 4px; font-family: Manrope, sans-serif; }
.map-popup span { display: block; color: var(--muted); font-size: .75rem; line-height: 1.45; }
.map-legend { position: absolute; z-index: 3; left: 13px; bottom: 30px; max-width: calc(100% - 26px); display: flex; flex-wrap: wrap; gap: 9px; padding: 8px 10px; border-radius: 10px; color: white; background: rgba(6, 25, 31, .9); font-size: .65rem; backdrop-filter: blur(8px); }
.map-legend span { display: flex; align-items: center; gap: 5px; }
.map-legend i { width: 9px; height: 9px; border-radius: 50%; }
.road-status { position: absolute; z-index: 3; top: 12px; left: 12px; max-width: calc(100% - 78px); display: flex; align-items: center; gap: 8px; padding: 9px 13px; border-radius: 999px; color: white; background: rgba(6, 25, 31, .91); font-size: .72rem; font-weight: 700; box-shadow: 0 8px 22px rgba(5, 26, 29, .18); }
.road-status.success { background: rgba(11, 105, 87, .94); }
.road-status.warning { background: rgba(126, 86, 19, .94); }
.road-status.error { background: rgba(145, 57, 47, .94); }
.road-status i { width: 8px; height: 8px; flex: 0 0 auto; border-radius: 50%; background: var(--lime); animation: pulse 1.2s infinite; }
.road-status.success i, .road-status.warning i, .road-status.error i { animation: none; }
.map-footnote { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 4px 0; color: var(--muted); font-size: .68rem; }
.line-sample { width: 24px; display: inline-block; vertical-align: middle; border-top: 3px solid var(--teal); }
.line-sample.dashed { border-top-style: dashed; }
@keyframes pulse { 50% { opacity: .35; transform: scale(.72); } }

.route-identity { display: grid; grid-template-columns: minmax(250px, .7fr) minmax(0, 1.3fr); gap: 25px; align-items: end; margin: 6px 0 19px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.route-identity h3 { margin: 0; font: 800 clamp(1.45rem, 2.2vw, 2.1rem)/1.15 Manrope, sans-serif; }
.route-identity p { margin: 7px 0 0; }
.route-rationale { align-self: center; line-height: 1.6; }
.pill, .scenario-id { display: inline-flex; align-items: center; width: fit-content; max-width: 100%; border-radius: 999px; padding: 6px 10px; color: #0b6259; background: #dbf5e9; font-size: .67rem; font-weight: 800; overflow-wrap: anywhere; }
.scenario-id { color: #d4ff84; background: var(--deep); font-family: ui-monospace, SFMono-Regular, Consolas, monospace; }
.decision-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.decision-summary article { min-width: 0; display: flex; flex-direction: column; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: linear-gradient(145deg, #fbfcf8, #edf4ea); }
.decision-summary article:first-child { color: white; border-color: transparent; background: linear-gradient(145deg, #073136, #0c6158); }
.decision-summary span { color: var(--muted); font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.decision-summary article:first-child span, .decision-summary article:first-child small { color: #bdd2cd; }
.decision-summary strong { margin: 12px 0 7px; overflow-wrap: anywhere; font: 800 clamp(1.1rem, 1.7vw, 1.55rem)/1.15 Manrope, sans-serif; text-transform: capitalize; }
.decision-summary article:first-child strong { color: var(--lime); }
.decision-summary small { margin-top: auto; color: var(--muted); line-height: 1.4; }
.evidence-signal-details { margin-top: 11px; overflow: hidden; background: rgba(248, 250, 246, .9); }
.evidence-signal-details > summary { color: var(--ink); background: #e9f0e6; }
.evidence-signal-details > summary b { padding: 5px 8px; border-radius: 999px; color: #0b6259; background: #d4f2e4; }
.evidence-signal-body { padding: 12px; }
.lens-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.lens-card { min-width: 0; min-height: 168px; display: flex; flex-direction: column; justify-content: space-between; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: linear-gradient(145deg, #fbfcf8, #f0f5ed); }
.lens-card.accent-lime { color: white; border-color: transparent; background: linear-gradient(145deg, #073136, #0c6158); }
.lens-card > div { display: flex; justify-content: space-between; gap: 8px; }
.lens-card span { color: var(--muted); font-size: .73rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.lens-card.accent-lime span { color: #c6d9d4; }
.lens-card b { align-self: start; max-width: 56%; padding: 4px 6px; border-radius: 7px; color: #1c6a61; background: #daf1e6; font-size: .56rem; letter-spacing: .05em; text-align: right; }
.lens-card strong { display: block; margin: 16px 0 7px; overflow-wrap: anywhere; font: 800 clamp(1.25rem, 2vw, 2rem)/1.05 Manrope, sans-serif; }
.lens-card.accent-lime strong { color: var(--lime); }
.lens-card p { margin: 0; font-size: .72rem; line-height: 1.42; }
.lens-card.accent-lime p { color: #bcd2cd; }
.claim-badge, .lens-card b { display: inline-flex; align-items: center; justify-content: center; width: fit-content; padding: 5px 8px; border: 1px solid transparent; border-radius: 999px; font-size: .58rem; font-weight: 800; letter-spacing: .055em; line-height: 1; text-transform: uppercase; }
.claim-badge[data-status="VERIFIED"], .lens-card b[data-status="VERIFIED"] { color: #075442; border-color: #74d8b1; background: #d7f7e7; }
.claim-badge[data-status="OBSERVED"], .lens-card b[data-status="OBSERVED"] { color: #07566e; border-color: #82cce5; background: #dff4fb; }
.claim-badge[data-status="DERIVED"], .lens-card b[data-status="DERIVED"] { color: #3f4b74; border-color: #b7c1e4; background: #edf0fb; }
.claim-badge[data-status="ML_ESTIMATED"], .lens-card b[data-status="ML_ESTIMATED"] { color: #5b3478; border-color: #c9a8e1; background: #f3e9fb; }
.claim-badge[data-status="PROXY"], .lens-card b[data-status="PROXY"] { color: #76570c; border-color: #e7c25e; background: #fff5d7; }
.claim-badge[data-status="SCENARIO"], .lens-card b[data-status="SCENARIO"] { color: #78460c; border-color: #efb263; background: #fff0dc; }
.claim-badge[data-status="NEUTRAL_PRIOR"], .lens-card b[data-status="NEUTRAL_PRIOR"] { color: #5f6265; border-color: #c7cbce; background: #f1f2f2; }
.claim-badge[data-status="MISSING"], .lens-card b[data-status="MISSING"] { color: #822f2b; border-color: #e7aaa6; background: #fde9e7; }
.lens-card.accent-lime b { color: #093d37; border-color: rgba(199, 244, 89, .65); background: var(--lime); }
.climate-context, .validation-evidence { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; gap: 12px; margin-top: 13px; padding: 15px 17px; border: 1px solid var(--line); border-radius: 15px; background: #f7faf5; color: var(--muted); font-size: .78rem; line-height: 1.55; }
.climate-context strong, .validation-evidence strong { color: var(--ink); }
.validation-evidence a { font-weight: 800; }
.feasibility-panel { background: linear-gradient(145deg, #fffefa, #eef6ed); }
.feasibility-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.feasibility-grid article { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; padding: 17px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.78); }
.feasibility-grid article > span { color: var(--muted); font-size: .7rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.feasibility-grid strong { grid-column: 1 / -1; overflow-wrap: anywhere; font: 800 clamp(1.25rem, 2vw, 1.9rem)/1.1 Manrope, sans-serif; }
.feasibility-grid small { grid-column: 1 / -1; color: var(--muted); line-height: 1.45; }
.model-restraint { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 20px; margin-top: 12px; padding: 17px; border-radius: 16px; color: white; background: var(--deep); }
.model-restraint h3 { margin: 0 0 5px; }
.model-restraint p:last-child { margin: 0; color: #bdd2cd; line-height: 1.5; }
.decision-change { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 22px; margin-top: 13px; padding: 19px; border-radius: 16px; background: #edf3ea; }
.decision-change h3 { margin: 0; font-size: 1.1rem; }
.decision-change p:last-child { margin: 6px 0 0; line-height: 1.55; }
.rank-range { display: grid; grid-template-columns: repeat(3, minmax(80px, 1fr)); gap: 7px; }
.rank-range span { padding: 11px; border: 1px solid var(--line); border-radius: 11px; color: var(--muted); background: var(--white); font-size: .66rem; }
.rank-range b { display: block; margin-top: 3px; color: var(--ink); font: 800 1rem Manrope, sans-serif; }

.scenario-preset-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 13px; }
.scenario-preset-row button { color: var(--ink); border-color: var(--line); background: #f7faf5; text-align: center; }
.scenario-preset-row button.active, .scenario-preset-row button:hover { border-color: var(--teal); color: white; background: var(--teal); }
.scenario-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.scenario-card { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #f8faf6; }
.weight-bars { display: grid; gap: 11px; }
.weight-bar-label { display: flex; justify-content: space-between; gap: 10px; margin-bottom: 5px; font-size: .75rem; font-weight: 800; }
.weight-track { height: 10px; overflow: hidden; border-radius: 999px; background: #e5ebe3; }
.weight-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--teal), var(--mint), var(--lime)); }
.comparison-summary { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.comparison-summary > div { min-width: 0; padding: 11px; border-radius: 11px; background: #eaf1e7; }
.comparison-summary span { display: block; color: var(--muted); font-size: .67rem; }
.comparison-summary strong { display: block; margin-top: 4px; overflow-wrap: anywhere; font: 800 1rem Manrope, sans-serif; }

.portfolio-builder { display: grid; grid-template-columns: repeat(3, minmax(145px, 1fr)) auto; align-items: end; gap: 10px; padding: 15px; border-radius: 16px; background: var(--deep); }
.portfolio-builder label { display: grid; gap: 6px; color: #bed2ce; font-size: .68rem; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.portfolio-builder select { color: var(--ink); text-transform: none; letter-spacing: 0; }
.portfolio-builder button { min-width: 150px; }
.portfolio-metrics { margin: 11px 0; }
.portfolio-metrics strong { font-size: clamp(1.15rem, 1.8vw, 1.55rem); }
.portfolio-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, .75fr); gap: 12px; }
.portfolio-grid > article { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 16px; background: #f8faf6; }
.portfolio-grid h3 { margin: 0; }
.portfolio-list { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 13px; }
.portfolio-item { min-width: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 9px; padding: 10px; border-radius: 11px; background: #e9f0e6; }
.portfolio-item > b { color: var(--teal); font: 800 .75rem Manrope, sans-serif; }
.portfolio-item button { min-width: 0; min-height: 44px; border: 0; padding: 0; color: var(--ink); background: transparent; text-align: left; font-weight: 800; cursor: pointer; }
.portfolio-item small { display: block; margin-top: 3px; color: var(--muted); font-weight: 500; }
.portfolio-item > span { font-weight: 800; }
.constraint-card { background: linear-gradient(145deg, #e9f2e6, #f9fbf6) !important; }
.constraint-card h4 { margin: 18px 0 7px; }
.constraint-card p, .constraint-card li { color: var(--muted); font-size: .78rem; line-height: 1.5; }
.constraint-card ul { margin: 0; padding-left: 18px; }
.delta-group { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.delta-group > div { padding: 10px; border-radius: 10px; background: rgba(255, 255, 255, .75); }
.delta-group b { display: block; margin-bottom: 4px; font-size: .7rem; text-transform: uppercase; }
.delta-group span { color: var(--muted); font-size: .72rem; line-height: 1.4; }
.near-selection { margin-top: 12px; padding: 10px; border-radius: 10px; background: rgba(255, 255, 255, .75); }
.near-selection > b { font-size: .7rem; text-transform: uppercase; }
.near-selection ul { margin: 7px 0 0; padding-left: 18px; color: var(--muted); font-size: .7rem; line-height: 1.45; }
.portfolio-alert { padding: 14px; border: 1px solid #e4bd62; border-radius: 12px; color: #67480b; background: #fff6dd; }
.portfolio-alert strong { display: block; margin-bottom: 4px; color: #4d3608; }
.action-queue { margin-top: 17px; padding-top: 17px; border-top: 1px solid var(--line); }
.subheading h3 { margin: 0; }
.subheading .eyebrow { margin-bottom: 4px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; min-width: 920px; border-collapse: separate; border-spacing: 0; }
th, td { padding: 12px 9px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
th { color: #6c7c7b; font-size: .65rem; letter-spacing: .08em; text-transform: uppercase; }
td { font-size: .78rem; }
tbody tr { transition: background .18s ease; }
tbody tr:hover, tbody tr.selected-row { background: #eef9ef; }
.route-table-button { min-height: 44px; border: 0; padding: 2px 0; color: var(--ink); background: transparent; text-align: left; font-weight: 800; cursor: pointer; }
.route-table-button small { display: block; margin-top: 3px; color: var(--muted); font-weight: 500; }
.mobile-route-cards { display: none; }

.evidence-grid { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(330px, .92fr); gap: 18px; }
.evidence-queue { display: grid; gap: 8px; margin-top: 15px; }
.evidence-item { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 11px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #f7faf5; }
.evidence-item > b { min-width: 38px; color: var(--teal); font: 800 .78rem Manrope, sans-serif; }
.evidence-item button { min-height: 44px; border: 0; padding: 0; color: var(--ink); background: transparent; text-align: left; font-weight: 800; cursor: pointer; }
.evidence-item small { display: block; margin-top: 3px; color: var(--muted); font-weight: 500; line-height: 1.35; }
.evidence-item > span { color: #8a5e0b; font-size: .65rem; font-weight: 800; text-align: right; }
.evidence-item > span b, .evidence-item > span small { display: block; }
.evidence-item > span small { margin-top: 3px; color: var(--muted); font-weight: 700; }
.ask-panel { color: white; background: radial-gradient(circle at 90% 0, rgba(80, 221, 189, .18), transparent 33%), linear-gradient(145deg, var(--deep), #104947); }
.ask-panel .eyebrow { color: var(--lime); }
.ask-panel h2 { color: white; }
.ask-panel > p { color: #bdd2cd; line-height: 1.55; }
.ask-panel label { color: #b8cec9; }
.ask-panel textarea { resize: vertical; min-height: 112px; }
.ask-panel > .button-primary { width: 100%; margin: 10px 0; }
.suggested-questions { display: flex; flex-wrap: wrap; gap: 7px; margin: 13px 0; }
.suggested-questions button { text-align: center; }
.answer { min-height: 54px; margin-top: 12px; color: #f5fffc; font-size: .88rem; font-weight: 500; line-height: 1.65; }
.ask-panel .answer p { margin: 0; color: #f5fffc; }

.method-sources { display: grid; grid-template-columns: minmax(250px, .38fr) minmax(0, .62fr); gap: clamp(24px, 5vw, 70px); margin: 62px 0 30px; padding: clamp(25px, 4vw, 54px); border-radius: 29px; background: #e5ede3; }
.method-intro > p:last-child { color: var(--muted); line-height: 1.6; }
.accordion-stack { display: grid; gap: 9px; }
details { border: 1px solid #cbd8ca; border-radius: 14px; background: rgba(255, 254, 250, .78); }
summary { min-height: 56px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 18px; cursor: pointer; list-style: none; font: 700 .9rem Manrope, sans-serif; }
summary::-webkit-details-marker { display: none; }
summary span { display: flex; align-items: center; gap: 12px; }
summary b { color: var(--teal); font-size: .65rem; letter-spacing: .08em; }
summary i { font-size: 1.3rem; font-style: normal; transition: transform .2s ease; }
details[open] summary i { transform: rotate(45deg); }
.accordion-content { padding: 0 18px 18px 49px; color: var(--muted); font-size: .84rem; line-height: 1.65; }
.accordion-content p, .accordion-content ol { margin: 0; }
.accordion-content ol { padding-left: 19px; }
.accordion-content li + li { margin-top: 6px; }
.method-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.method-grid p, .source-health > div { padding: 11px; border-radius: 10px; background: rgba(229, 237, 227, .75); }
.method-grid strong, .source-health strong { display: block; color: var(--ink); }
.source-health { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.template-download { display: inline-flex; margin-top: 12px; padding: 11px 16px; border-radius: 999px; background: var(--navy); color: #fff; font-weight: 800; text-decoration: none; }
.template-download:hover, .template-download:focus-visible { background: var(--blue); color: #fff; }

footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 28px 6px 12px; border-top: 1px solid var(--line); }
.footer-brand { color: var(--ink); }
.footer-brand small { color: var(--muted); }
footer p { color: var(--muted); font-size: .73rem; }
footer a { font-weight: 700; }

.controls-backdrop { display: none; }
.walkthrough-panel { position: fixed; z-index: 210; right: 22px; bottom: 22px; width: min(470px, calc(100vw - 28px)); padding: 20px; border: 1px solid rgba(199, 244, 89, .22); border-radius: 20px; color: white; background: linear-gradient(145deg, rgba(6, 25, 31, .985), rgba(12, 72, 67, .985)); box-shadow: 0 30px 80px rgba(4, 29, 31, .42); backdrop-filter: blur(18px); }
.walkthrough-progress { display: flex; justify-content: space-between; gap: 10px; color: var(--lime); font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .09em; }
.walkthrough-track { height: 4px; margin-top: 10px; overflow: hidden; border-radius: 99px; background: rgba(255, 255, 255, .12); }
.walkthrough-track i { display: block; width: 6.67%; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--lime), #78ecdb); transition: width .3s ease; }
.walkthrough-panel h2 { margin: 13px 0 7px; font: 800 1.25rem Manrope, sans-serif; }
.walkthrough-panel > p { min-height: 2.65rem; margin: 0; color: #d6e6e2; font-size: .84rem; line-height: 1.55; }
.walkthrough-status { display: flex; flex-wrap: wrap; align-items: center; gap: 7px 13px; margin-top: 12px; color: #a9c9c2; font-size: .68rem; font-weight: 700; }
.walkthrough-status span:first-child { display: inline-flex; align-items: center; gap: 6px; color: #dff7ef; }
.walkthrough-status i { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 4px rgba(199, 244, 89, .12); animation: voicePulse 1s ease-in-out infinite alternate; }
.walkthrough-status .muted i { background: #8aa29c; box-shadow: none; animation: none; }
.walkthrough-actions { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 15px; }
.walkthrough-actions button { min-height: 42px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 10px; padding: 8px 11px; color: white; background: rgba(255, 255, 255, .07); font-size: .74rem; font-weight: 800; cursor: pointer; }
.walkthrough-actions button:hover, .walkthrough-actions button:focus-visible { border-color: rgba(199, 244, 89, .58); background: rgba(199, 244, 89, .11); }
.walkthrough-actions .button-primary { margin-left: auto; color: #092426; background: var(--lime); }
.tour-focus { position: relative; z-index: 2; outline: 4px solid rgba(199, 244, 89, .9) !important; outline-offset: 6px; animation: tourGlow 1s ease-in-out infinite alternate; }
.tour-cursor { --cursor-x: -90px; --cursor-y: -90px; position: fixed; z-index: 230; top: 0; left: 0; width: 23px; height: 29px; opacity: 0; pointer-events: none; transform: translate3d(var(--cursor-x), var(--cursor-y), 0); filter: drop-shadow(0 4px 5px rgba(0, 20, 22, .45)); transition: opacity .18s ease; }
.tour-cursor.visible, .tour-cursor.invite { opacity: 1; }
.tour-cursor::before { position: absolute; inset: 0; content: ""; border: 2px solid #092426; background: #fff; clip-path: polygon(0 0, 0 92%, 27% 67%, 43% 100%, 58% 92%, 42% 61%, 78% 61%); }
.tour-cursor::after { position: absolute; z-index: -1; top: -15px; left: -15px; width: 48px; height: 48px; border: 2px solid rgba(199, 244, 89, .88); border-radius: 50%; content: ""; background: rgba(199, 244, 89, .13); box-shadow: 0 0 0 8px rgba(199, 244, 89, .07); animation: cursorHalo 1s ease-in-out infinite alternate; }
.tour-cursor.clicking::after { animation: cursorClick .32s ease-out; }
.tour-cursor span { position: absolute; top: 35px; left: 10px; width: max-content; max-width: min(260px, 65vw); padding: 6px 9px; border: 1px solid rgba(255, 255, 255, .15); border-radius: 8px; color: #fff; background: rgba(6, 25, 31, .94); box-shadow: 0 8px 24px rgba(4, 29, 31, .24); font: 700 .68rem DM Sans, sans-serif; opacity: 0; transform: translateY(-3px); transition: opacity .15s ease, transform .15s ease; }
.tour-cursor.label-left span { right: 8px; left: auto; }
.tour-cursor.label-up span { top: auto; bottom: 35px; }
.tour-cursor.has-label span { opacity: 1; transform: translateY(0); }
.tour-cursor.invite span { border-color: rgba(199, 244, 89, .48); color: #092426; background: var(--lime); }
.template-links { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.tour-choice-menu { position: fixed; z-index: 225; max-height: min(310px, 55vh); overflow: hidden; border: 1px solid rgba(199, 244, 89, .46); border-radius: 14px; color: #ecfff8; background: rgba(6, 31, 35, .985); box-shadow: 0 24px 54px rgba(2, 22, 25, .42); transform-origin: top center; animation: tourMenuDrop .22s cubic-bezier(.2,.8,.25,1) both; }
.tour-choice-menu.opens-up { transform-origin: bottom center; animation-name: tourMenuRise; }
.tour-choice-menu > span { display: block; padding: 9px 12px 7px; color: #9ec8bf; font-size: .64rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.tour-choice-menu > div { display: grid; gap: 3px; max-height: 255px; overflow: hidden; padding: 0 6px 7px; }
.tour-choice-option { min-height: 38px; display: flex; align-items: center; gap: 9px; overflow: hidden; border: 1px solid transparent; border-radius: 9px; padding: 7px 9px; color: #e9f7f3; background: rgba(255, 255, 255, .045); font-size: .7rem; font-weight: 700; line-height: 1.25; text-overflow: ellipsis; white-space: nowrap; }
.tour-choice-option::before { width: 7px; height: 7px; flex: 0 0 auto; border: 1px solid #7aa098; border-radius: 50%; content: ""; }
.tour-choice-option.selected, .tour-choice-option.choosing { border-color: rgba(199, 244, 89, .7); color: #102b2a; background: var(--lime); }
.tour-choice-option.selected::before, .tour-choice-option.choosing::before { border-color: #0a2827; background: #0a2827; box-shadow: 0 0 0 3px rgba(10, 40, 39, .14); }
.tour-choice-menu.closing { opacity: 0; transform: translateY(-5px) scale(.97); transition: opacity .16s ease, transform .16s ease; }
body.tour-running .walkthrough-trigger, body.tour-running #startWalkthroughHero { pointer-events: none; opacity: .58; }
@keyframes tourGlow { to { box-shadow: 0 0 0 10px rgba(199, 244, 89, .14), var(--shadow); } }
@keyframes cursorHalo { to { transform: scale(1.16); opacity: .74; } }
@keyframes cursorClick { 50% { transform: scale(.54); background: rgba(199, 244, 89, .38); } }
@keyframes voicePulse { to { opacity: .55; transform: scale(.82); } }
@keyframes tourMenuDrop { from { opacity: 0; transform: translateY(-10px) scale(.96); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes tourMenuRise { from { opacity: 0; transform: translateY(10px) scale(.96); } to { opacity: 1; transform: translateY(0) scale(1); } }
.click-ripple { position: absolute; z-index: 5; width: 14px; height: 14px; border-radius: 50%; background: rgba(255, 255, 255, .65); pointer-events: none; transform: translate(-50%, -50%) scale(0); animation: clickRipple .55s ease-out forwards; }
@keyframes clickRipple { to { transform: translate(-50%, -50%) scale(10); opacity: 0; } }

@media (max-width: 1360px) {
  .page-shell { grid-template-columns: 278px minmax(0, 1fr); gap: 18px; padding: 18px; }
  .topbar { gap: 14px; }
  .topbar nav { gap: 10px; }
  .topbar nav a { font-size: .68rem; }
  .hero { grid-template-columns: minmax(0, 1fr) 290px; padding: 48px; }
  .lens-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lens-card { min-height: 145px; }
  .map-heading { display: grid; }
  .map-tools { width: 100%; max-width: 720px; }
}

@media (max-width: 1080px) {
  html { scroll-padding-top: 132px; }
  .topbar { grid-template-columns: auto 1fr auto; min-height: 64px; padding: 8px 16px 0; }
  .topbar nav { grid-column: 1 / -1; order: 3; width: calc(100% + 32px); margin-left: -16px; justify-content: flex-start; overflow-x: auto; padding: 0 16px; scrollbar-width: none; }
  .topbar nav::-webkit-scrollbar { display: none; }
  .topbar nav a { min-height: 44px; font-size: .72rem; }
  .hero { grid-template-columns: 1fr; }
  .hero-signal { display: none; }
  .portfolio-grid, .evidence-grid { grid-template-columns: 1fr; }
}

@media (max-width: 900px) {
  .mobile-controls-button { display: block; }
  .page-shell { display: block; padding: 12px; }
  .sidebar { position: fixed; z-index: 90; top: 0; left: 0; bottom: auto; width: min(370px, 92vw); height: 100vh; height: 100dvh; max-height: 100dvh; overflow-y: auto; overscroll-behavior: contain; border-radius: 0 22px 22px 0; transform: translateX(-105%); transition: transform .25s ease; }
  body.controls-open { overflow: hidden; }
  body.controls-open .sidebar { transform: translateX(0); }
  .icon-button { display: grid; place-items: center; }
  .controls-backdrop { position: fixed; z-index: 80; inset: 0; width: 100%; height: 100%; border: 0; background: rgba(0, 16, 19, .5); backdrop-filter: blur(3px); }
  body.controls-open .controls-backdrop { display: block; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .route-identity, .decision-change, .method-sources { grid-template-columns: 1fr; }
  .decision-summary { grid-template-columns: 1fr; }
  .portfolio-builder { grid-template-columns: repeat(3, 1fr); }
  .portfolio-builder button { grid-column: 1 / -1; }
  .method-sources { margin-top: 42px; padding: 24px 18px; }
  .feasibility-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .topbar { column-gap: 8px; }
  .brand small { display: none; }
  .topbar-actions { gap: 5px; }
  .walkthrough-trigger { display: block; min-height: 40px; padding: 8px 9px; font-size: .68rem; white-space: nowrap; }
  .topbar nav { max-width: 100vw; }
  .hero { min-height: 0; padding: 31px 21px; border-radius: 23px; }
  .hero h1 { font-size: clamp(2.25rem, 12vw, 3.35rem); }
  .hero-lede { font-size: .93rem; }
  .hero-actions { display: grid; }
  .trust-strip { grid-template-columns: auto minmax(0, 1fr); }
  .trust-strip button { grid-column: 2; justify-self: start; padding-left: 0; }
  .panel { padding: 16px; border-radius: 19px; }
  .panel-heading { display: grid; grid-template-columns: 1fr; }
  .map-tools { grid-template-columns: 1fr; }
  #map { height: clamp(360px, 56svh, 500px); }
  .mapboxgl-ctrl-group button { width: 44px; height: 44px; }
  .map-legend { right: 9px; left: 9px; bottom: 30px; justify-content: center; }
  .road-status { top: 9px; left: 9px; max-width: calc(100% - 68px); border-radius: 13px; font-size: .67rem; }
  .map-footnote { display: grid; }
  .lens-grid, .scenario-grid, .portfolio-list { grid-template-columns: 1fr; }
  .feasibility-grid { grid-template-columns: 1fr; }
  .climate-context, .validation-evidence, .model-restraint { grid-template-columns: 1fr; }
  .lens-card { min-height: 132px; }
  .decision-change { padding: 15px; }
  .rank-range { grid-template-columns: repeat(3, 1fr); }
  .portfolio-builder { grid-template-columns: 1fr; }
  .portfolio-builder button { grid-column: auto; }
  .portfolio-metrics { grid-template-columns: repeat(2, 1fr); }
  .comparison-summary { grid-template-columns: 1fr; }
  .table-wrap { display: none; }
  .mobile-route-cards { display: grid; gap: 8px; margin-top: 12px; }
  .mobile-route-card { width: 100%; min-height: 76px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 13px; padding: 11px; color: var(--ink); background: #f8faf6; text-align: left; cursor: pointer; }
  .mobile-route-card.selected { border-color: var(--teal); background: #e9f6ed; }
  .mobile-route-card > b { color: var(--teal); }
  .mobile-route-card strong { overflow-wrap: anywhere; font-size: .82rem; }
  .mobile-route-card small { display: block; margin-top: 3px; color: var(--muted); font-weight: 500; }
  .mobile-route-card > span { font-weight: 800; }
  .method-grid, .source-health { grid-template-columns: 1fr; }
  .accordion-content { padding-left: 18px; }
  summary { padding: 14px; font-size: .81rem; }
  footer { display: grid; }
  body.tour-running { scroll-padding-bottom: 46svh; }
  body.tour-running.controls-open .sidebar { padding-bottom: calc(22px + min(43svh, 244px)); }
  .walkthrough-panel { right: 0; bottom: 0; left: 0; width: 100%; max-height: min(46svh, 280px); overflow-y: auto; padding: 13px 12px max(11px, env(safe-area-inset-bottom)); border-radius: 19px 19px 0 0; }
  .walkthrough-panel h2 { margin: 8px 0 4px; font-size: 1.02rem; }
  .walkthrough-panel > p { min-height: 0; display: -webkit-box; overflow: hidden; font-size: .76rem; line-height: 1.38; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
  .walkthrough-track { margin-top: 6px; }
  .walkthrough-status { min-width: 0; gap: 5px 10px; margin-top: 8px; }
  .walkthrough-status span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .walkthrough-status span:last-child { max-width: 100%; }
  .walkthrough-actions { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin-top: 9px; }
  .walkthrough-actions button { min-width: 0; min-height: 40px; padding: 7px 4px; font-size: .68rem; }
  .walkthrough-actions button:nth-child(-n + 3) { grid-column: span 2; }
  .walkthrough-actions button:nth-child(n + 4) { grid-column: span 3; }
  .walkthrough-actions .button-primary { margin-left: 0; }
  .tour-focus { outline-width: 3px !important; outline-offset: 3px; }
  .tour-cursor { width: 20px; height: 25px; }
  .tour-cursor::after { top: -11px; left: -11px; width: 39px; height: 39px; }
  .tour-cursor span { max-width: min(210px, 58vw); font-size: .64rem; }
  .tour-choice-menu { max-height: 210px; }
}

@media (max-width: 430px) {
  .topbar { padding-inline: 12px; }
  .topbar nav { width: calc(100% + 24px); margin-left: -12px; padding-inline: 12px; }
  .brand-mark { width: 38px; height: 38px; }
  .mobile-controls-button { padding-inline: 10px; }
  .metrics, .portfolio-metrics { gap: 8px; }
  .metrics article, .portfolio-metrics article { padding: 13px; }
  .metrics strong { font-size: 1.35rem; }
  .metrics small { display: none; }
  .rank-range { gap: 5px; }
  .rank-range span { padding: 9px 7px; }
  .delta-group { grid-template-columns: 1fr; }
  .evidence-item { grid-template-columns: auto minmax(0, 1fr); }
  .evidence-item > span { grid-column: 2; text-align: left; }
  .walkthrough-panel { max-height: min(43svh, 244px); }
  .walkthrough-panel > p { -webkit-line-clamp: 2; }
  .walkthrough-progress { font-size: .63rem; }
  .walkthrough-status { font-size: .62rem; }
  .walkthrough-status span:last-child { display: none; }
}

@media (max-width: 360px), (max-height: 620px) and (max-width: 700px) {
  .walkthrough-panel { max-height: min(42svh, 232px); padding-top: 10px; }
  .walkthrough-panel h2 { font-size: .94rem; }
  .walkthrough-actions button { min-height: 38px; font-size: .64rem; }
}

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