/* Page layouts. Everything here arranges the components of base.css; colours and sizes come from its tokens. */

.nowrap { white-space: nowrap; }
.unit { font: 400 var(--t-12)/16px var(--font); color: var(--text-3); letter-spacing: 0; }
.h-link { margin-left: auto; font: 400 var(--t-12)/16px var(--font); color: var(--text-3); display: inline-flex; align-items: center; gap: 2px; }
.h-link:hover { color: var(--text); }
.h-link .ico { width: 12px; height: 12px; }
.btnrow { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.headline .big, .big.num { font: 600 var(--t-24)/32px var(--font); letter-spacing: -.02em; }
.hl-range { display: grid; grid-template-columns: 110px auto; white-space: nowrap; align-items: center; gap: var(--s-3); margin: var(--s-1) 0; justify-content: start; }
.mini { display: grid; }
.mini li { display: flex; justify-content: space-between; align-items: center; gap: var(--s-3); padding: 6px 0; border-bottom: 1px solid var(--border); min-height: 32px; }
.mini li:last-child { border-bottom: 0; }
.mini a:hover, .links a:hover, .checks a:hover, .more-link:hover, .home-foot a:hover { text-decoration: underline; text-underline-offset: 2px; }
.mini li > :first-child { min-width: 0; }
.more-link { display: inline-flex; align-items: center; gap: 2px; color: var(--text-2); font-size: var(--t-12); margin-top: var(--s-2); }
.links { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-3); }
.links a { color: var(--text-2); }
.card.quiet { display: flex; align-items: center; gap: var(--s-3); color: var(--text-2); background: var(--bg-subtle); }
.card.quiet .ico { color: var(--text-3); }
.bars { display: grid; gap: 6px; }
.bar-row { display: grid; grid-template-columns: minmax(0, 150px) minmax(40px, 1fr) auto; gap: var(--s-3); align-items: center; font-size: var(--t-12); }
.bar-row > .num { min-width: 44px; text-align: right; color: var(--text-2); }
.bar { height: 8px; border-radius: 2px; background: var(--bg-inset); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--text-3); border-radius: 0 2px 2px 0; min-width: 1px; }
.bar.ours i { background: var(--accent); }
.bar.neg i { background: transparent; box-shadow: inset 0 0 0 1px var(--text-3); }
.drivers { display: grid; gap: var(--s-2); }
.drivers li { display: grid; grid-template-columns: minmax(0, 1fr) 56px 76px; gap: var(--s-1) var(--s-3); align-items: center; font-size: var(--t-12); }
.drivers .dl { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); align-items: center; line-height: 16px; }
.drivers .num { text-align: right; line-height: 16px; }
.drivers .num .faint { display: block; font-size: var(--t-11); white-space: nowrap; }
.ros { display: grid; grid-template-columns: auto minmax(48px, 1fr) auto; gap: var(--s-2); align-items: center; }
.ros .e { font-size: var(--t-11); color: var(--text-3); min-width: 24px; }
.ros .e:first-child { text-align: right; }
.ros .trk { position: relative; height: 4px; border-radius: 2px; background: var(--border-strong); }
.ros .trk i { position: absolute; top: -3px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 2.5px var(--text); }
.ros .trk i.solo { box-shadow: inset 0 0 0 2.5px var(--text-3); }
.ros-wrap { display: grid; grid-template-columns: 150px 64px; gap: var(--s-3); align-items: center; text-align: right; }
.state { display: inline-flex; align-items: center; gap: var(--s-2); white-space: nowrap; }
.tags { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); }
.bullets { margin-top: var(--s-2); display: grid; gap: var(--s-1); }
.bullets li { padding-left: var(--s-3); position: relative; color: var(--text-2); }
.bullets li::before { content: ''; position: absolute; left: 0; top: 9px; width: 4px; height: 1px; background: var(--text-3); }

/* ---------------------------------------------------------------- today */
.home { max-width: 1240px; }
.home-head { margin-bottom: var(--s-4); }
.hero { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--s-4); align-items: center; padding: var(--s-5); border: 1px solid var(--border); border-radius: var(--r-4); background: var(--bg-subtle); }
.hero-mark { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--ok-soft); color: var(--ok); }
.hero.due .hero-mark { background: var(--urgent-soft); color: var(--urgent); }
.hero-mark .ico { width: 20px; height: 20px; }
.hero h2 { font: 600 var(--t-20)/28px var(--font); letter-spacing: -.015em; }
.hero p { color: var(--text-2); margin-top: 2px; max-width: 70ch; }
.hero-stats { display: flex; gap: var(--s-2); }
.stat { display: grid; gap: 2px; min-width: 104px; padding: var(--s-2) var(--s-3); border-radius: var(--r-3); border: 1px solid var(--border); background: var(--bg); transition: border-color var(--fast); }
.stat:hover { border-color: var(--border-strong); }
.stat .n { font: 600 var(--t-20)/24px var(--font); letter-spacing: -.02em; color: var(--text-3); }
.stat.watch .n { color: var(--warn); } .stat.act .n { color: var(--urgent); }
.stat .l { font-size: var(--t-12); line-height: 16px; color: var(--text-2); }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-4); margin-top: var(--s-4); }
.metric { display: block; transition: border-color var(--fast); }
.metric:hover { border-color: var(--border-strong); }
.metric h3 .go { margin-left: auto; color: var(--text-3); opacity: 0; transition: opacity var(--fast); display: inline-flex; }
.metric:hover h3 .go { opacity: 1; }
.metric-body { min-height: 104px; margin-top: var(--s-2); display: grid; align-content: start; }
.mv { font: 600 var(--t-20)/28px var(--font); letter-spacing: -.02em; }
.mspark { margin: var(--s-2) 0; height: 36px; }
.mspark svg { width: 100%; height: 36px; display: block; }
.mfoot { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); align-items: center; justify-content: space-between; font-size: var(--t-12); color: var(--text-3); }
.home-cols { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: var(--s-5); align-items: start; }
.home-side { display: grid; gap: var(--s-4); margin-top: var(--s-6); }
.home-row { grid-template-columns: 16px minmax(0, 1fr) auto 150px 96px; }
.cal-row { grid-template-columns: 16px 104px minmax(0, 1fr) auto 104px; }
.cal-row > :last-child { text-align: right; }
.side h3 { color: var(--text); font-weight: 600; font-size: var(--t-13); }
.checks { display: grid; gap: var(--s-2); margin-top: var(--s-3); }
.checks li { display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: var(--s-2); align-items: start; color: var(--text-2); font-size: var(--t-12); line-height: 18px; }
.checks .ico { margin-top: 1px; }
.checks .ico.chg { color: var(--warn-mark); } .checks .ico.faint { color: var(--text-3); }
.big-quiet { font: 600 var(--t-16)/24px var(--font); margin-top: var(--s-2); }
.feed-head { margin-top: var(--s-2); font-weight: 500; }
.fresh { display: flex; align-items: baseline; gap: var(--s-2); margin-top: var(--s-2); }
.fresh .dot { align-self: center; }
.signs { display: grid; margin-top: var(--s-2); }
.signs li a { display: grid; grid-template-columns: 8px minmax(0, 1fr); gap: 0 var(--s-2); align-items: center; padding: 6px 0; border-bottom: 1px solid var(--border); }
.signs li:last-child a { border-bottom: 0; }
.signs .t { font-weight: 500; }
.signs .d { grid-column: 2; font-size: var(--t-12); color: var(--text-3); }
.signs a:hover .t { text-decoration: underline; text-underline-offset: 2px; }
.home-foot { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-2); align-items: center; margin-top: var(--s-6); padding-top: var(--s-4); border-top: 1px solid var(--border); }
.home-foot .ico { width: 14px; height: 14px; }
.home-foot a { color: var(--text-2); text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--border-strong); }

/* ---------------------------------------------------------------- actions inbox */
.inbox .rows + .rows { margin-top: var(--s-3); }
.act-row { grid-template-columns: 16px minmax(180px, 1fr) minmax(90px, 170px) 104px 176px 150px 104px; }
.act-row .t { display: flex; align-items: center; gap: 6px; }
.ackmark { display: inline-flex; color: var(--accent-text); }
.ackmark .ico { width: 12px; height: 12px; }
.c-due.soon { color: var(--urgent); }
.calm-note { display: grid; grid-template-columns: auto 1fr; gap: var(--s-3); align-items: center; padding: var(--s-3) var(--s-4); margin-bottom: var(--s-3); border-radius: var(--r-3); background: var(--ok-soft); color: var(--text-2); }
.calm-note .ico { color: var(--ok); width: 18px; height: 18px; }
.calm-note strong { color: var(--text); font-weight: 600; }
.local-note { display: flex; gap: var(--s-2); align-items: center; margin-top: var(--s-3); }
.local-note .ico { width: 14px; height: 14px; flex: none; }
.what { margin-top: var(--s-2); color: var(--text); font-size: var(--t-13); line-height: 20px; }
.why { display: grid; gap: var(--s-2); }
.why li { padding-left: var(--s-3); position: relative; }
.why li::before { content: ''; position: absolute; left: 0; top: 8px; width: 4px; height: 4px; border-radius: 50%; background: var(--text-3); }
.kv dd .unit { margin-left: 2px; }

/* ---------------------------------------------------------------- map */
.mapwrap { position: relative; height: 100%; min-height: 420px; background: var(--map-bg); overflow: hidden; }
.mapwrap > .mapbox, .mapwrap > .mapbox.maplibregl-map { position: absolute; inset: 0; }
.mapbox canvas:focus-visible { box-shadow: none; }
.map-panel, .map-legend, .map-time { position: absolute; z-index: 3; background: color-mix(in srgb, var(--bg-raised) 94%, transparent); backdrop-filter: blur(8px); border-radius: var(--r-3); box-shadow: var(--shadow-2); }
.map-panel { left: var(--s-3); top: var(--s-3); width: 264px; padding: var(--s-3); display: grid; gap: var(--s-3); }
.mp-row { display: grid; gap: 6px; }
.mp-row > label, .mp-row > div > label { font: 500 var(--t-11)/14px var(--font); color: var(--text-3); display: block; }
.mp-row > div > label { margin-bottom: 6px; }
.mp-row.two { grid-template-columns: 1fr auto; align-items: end; gap: var(--s-3); }
.mp-row .seg { display: flex; }
.mp-row .seg button { flex: 1; padding: 0 6px; }
.mp-list { display: grid; }
.mp-list button { display: flex; align-items: center; gap: var(--s-2); height: 28px; padding: 0 var(--s-1); border-radius: var(--r-1); text-align: left; color: var(--text-2); font-weight: 500; }
.mp-list button:hover { background: var(--bg-hover); color: var(--text); }
.mp-list button[aria-checked='true'] { color: var(--text); }
.radio { width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--border-strong); flex: none; }
[aria-checked='true'] > .radio { box-shadow: inset 0 0 0 4px var(--accent); }
.fbtn.wide { width: 100%; max-width: none; justify-content: space-between; }
.map-legend { left: var(--s-3); bottom: 92px; width: 264px; padding: var(--s-3); display: grid; gap: 6px; }
.lg-title { font: 600 var(--t-12)/16px var(--font); }
.lg-scale { display: flex; gap: 2px; }
.lg-scale .sw { flex: 1; height: 10px; border-radius: 2px; box-shadow: inset 0 0 0 1px var(--border); }
.lg-ticks { display: grid; font: 400 10px/12px var(--font); color: var(--text-3); font-variant-numeric: tabular-nums; margin: 0 calc(100% / 14); }
.lg-ticks.seven { grid-template-columns: repeat(6, 1fr); margin: 0; padding: 0 calc(100% / 14); }
.lg-ticks.seven span { text-align: center; transform: translateX(0); }
.lg-ticks.seven { grid-template-columns: repeat(6, 1fr); }
.lg-ticks.seven span { width: 100%; }
.lg-ticks.n6 { grid-template-columns: repeat(5, 1fr); margin: 0; padding: 0 calc(100% / 12); }
.lg-ticks.n5 { grid-template-columns: repeat(4, 1fr); margin: 0; padding: 0 10%; }
.lg-ticks.n4 { grid-template-columns: repeat(3, 1fr); margin: 0; padding: 0 12.5%; }
.lg-ticks.n3 { grid-template-columns: repeat(2, 1fr); margin: 0; padding: 0 16.6%; }
.lg-ticks.n2 { grid-template-columns: 1fr; margin: 0; }
.lg-ticks span { text-align: center; }
.lg-ends { display: flex; justify-content: space-between; font: 400 var(--t-11)/14px var(--font); color: var(--text-2); }
.lg-foot { display: flex; align-items: center; gap: var(--s-2); font-size: var(--t-11); color: var(--text-3); margin-top: 2px; }
.lg-foot .sw.nd { width: 10px; height: 10px; border-radius: 2px; box-shadow: inset 0 0 0 1px var(--border-strong); margin-left: auto; }
.map-legend .note { font-size: var(--t-11); line-height: 14px; }
.map-time { left: var(--s-3); right: var(--s-3); bottom: var(--s-3); height: 68px; padding: 0 var(--s-4) 0 var(--s-3); display: grid; grid-template-columns: auto 172px minmax(0, 1fr); gap: var(--s-3); align-items: center; }
.map-time .play { width: 32px; height: 32px; border-radius: 50%; background: var(--text); color: var(--bg); }
.map-time .play:hover { background: var(--text-2); color: var(--bg); }
.map-time .play .ico { fill: currentColor; stroke-width: 1; width: 14px; height: 14px; }
.mt-date { display: grid; line-height: 16px; }
.mt-date strong { font: 600 var(--t-14)/20px var(--font); }
.mt-date span { font-size: var(--t-11); }
.mt-track { position: relative; display: grid; gap: 0; align-self: center; }
.mt-hist { display: flex; align-items: flex-end; gap: 1px; height: 18px; padding: 0 7px; }
.mt-hist i { flex: 1; background: var(--border-strong); border-radius: 1px 1px 0 0; min-height: 1px; }
.mt-hist i.on { background: var(--accent); }
.mt-track input[type='range'] { -webkit-appearance: none; appearance: none; width: 100%; height: 14px; background: transparent; margin: 0; cursor: pointer; }
.mt-track input[type='range']::-webkit-slider-runnable-track { height: 2px; background: var(--border-strong); border-radius: 1px; }
.mt-track input[type='range']::-moz-range-track { height: 2px; background: var(--border-strong); border-radius: 1px; }
.mt-track input[type='range']::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; margin-top: -6px; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 3px var(--accent), 0 1px 3px rgba(0, 0, 0, .25); }
.mt-track input[type='range']::-moz-range-thumb { width: 14px; height: 14px; border: 0; border-radius: 50%; background: var(--bg); box-shadow: inset 0 0 0 3px var(--accent), 0 1px 3px rgba(0, 0, 0, .25); }
.mt-track input[type='range']:focus-visible { box-shadow: none; }
.mt-track input[type='range']:focus-visible::-webkit-slider-thumb { box-shadow: inset 0 0 0 3px var(--accent), 0 0 0 3px var(--accent-soft); }
.mt-axis { position: relative; display: flex; justify-content: space-between; font: 400 10px/12px var(--font); color: var(--text-3); padding: 0 7px; font-variant-numeric: tabular-nums; }
.mt-axis .mid { position: absolute; transform: translateX(4px); padding-left: 4px; border-left: 1px dashed var(--border-strong); }
.map-flag { position: absolute; z-index: 3; top: var(--s-3); left: 50%; transform: translateX(-50%); padding: 6px var(--s-3); border-radius: 14px; background: color-mix(in srgb, var(--bg-raised) 94%, transparent); box-shadow: var(--shadow-2); font-size: var(--t-12); color: var(--text-2); white-space: nowrap; max-width: calc(100% - 420px); overflow: hidden; text-overflow: ellipsis; display: flex; align-items: center; gap: var(--s-2); left: calc(50% + 110px); }
.map-flag .btn { height: 22px; padding: 0 6px; color: var(--accent-text); }
.area-mark { display: grid; justify-items: center; }
.area-label { display: grid; justify-items: center; padding: 0; background: none; border: 0; color: var(--text); font: 500 11px/13px var(--font); text-shadow: 0 0 2px var(--bg), 0 0 2px var(--bg), 0 0 3px var(--bg), 0 0 4px var(--bg); pointer-events: auto; cursor: pointer; white-space: nowrap; }
.area-label .an { display: none; font-weight: 500; color: var(--text); max-width: 150px; overflow: hidden; text-overflow: ellipsis; }
.area-label .af { font-weight: 600; }
.area-label.full .an { display: block; }
.area-label.full .af { color: var(--text-2); font-weight: 500; }
.area-label.quiet { opacity: 0; pointer-events: none; }
.area-label.quiet:focus-visible, .area-label.on { opacity: 1; }
.area-label.quiet:focus-visible .an, .area-label.on .an { display: block; }
.area-label:focus-visible { box-shadow: none; outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
.maplibregl-ctrl-top-right .maplibregl-ctrl { margin: 12px 12px 0 0; }
.maplibregl-ctrl-group { background: var(--bg-raised) !important; box-shadow: var(--shadow-2) !important; border-radius: var(--r-2) !important; overflow: hidden; }
.maplibregl-ctrl-group button { width: 28px !important; height: 28px !important; }
.maplibregl-ctrl-group button + button { border-top: 1px solid var(--border) !important; }
:root[data-theme='dark'] .maplibregl-ctrl-icon { filter: invert(1); }
.maplibregl-marker { z-index: 1; }

/* ---------------------------------------------------------------- supply */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); margin: var(--s-4) 0; }
.fact .mv { margin-top: var(--s-2); }
.fact h3 .chip { margin-left: auto; }
.fact .note { margin-top: var(--s-1); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.net { padding: var(--s-4) var(--s-4) var(--s-3); }
.net-scroll { overflow-x: auto; }
.netsvg { display: block; max-width: none; }
.netsvg .stage { font: 500 11px/1 var(--font); fill: var(--text-3); letter-spacing: .04em; text-transform: uppercase; }
.netsvg .nl { cursor: pointer; outline: none; }
.netsvg .nl .band { fill: none; stroke: var(--text-3); stroke-opacity: .42; transition: stroke-opacity var(--fast); }
.netsvg .nl .hit { fill: none; stroke: transparent; }
.netsvg .nl.assumed .band { stroke-opacity: .2; }
.netsvg .nl.frag .band { stroke: var(--warn-mark); stroke-opacity: .34; }
.netsvg .nl:hover .band, .netsvg .nl:focus-visible .band, .netsvg .nl.lit .band { stroke-opacity: .6; }
.netsvg .nl.on .band { stroke: var(--accent); stroke-opacity: .7; }
.netsvg.focus .nl:not(.lit) .band { stroke-opacity: .12; }
.netsvg .nn { cursor: pointer; outline: none; }
.netsvg .nn rect:not(.hit) { fill: var(--text); }
.netsvg .nn.frag rect:not(.hit) { fill: var(--warn-mark); }
.netsvg .nn.on rect:not(.hit) { fill: var(--accent); }
.netsvg .nn .hit { fill: transparent; }
.netsvg .nn:focus-visible .hit { stroke: var(--accent); stroke-width: 2; rx: 4; }
.netsvg .nlabel { font: 500 12px/15px var(--font); fill: var(--text); paint-order: stroke; stroke: var(--bg); stroke-width: 4px; stroke-linejoin: round; }
.netsvg .nlabel .sh { fill: var(--text-3); font-weight: 400; font-variant-numeric: tabular-nums; }
.netsvg .nn:hover .nlabel { text-decoration: underline; }
.legend .sw.frag { background: var(--warn-mark); width: 8px; height: 8px; }
.weak-row { grid-template-columns: 16px minmax(0, 1fr) 190px 96px; }
.sign-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: var(--s-4); }
.sign header { display: flex; gap: var(--s-2); align-items: flex-start; }
.sign header h3 { font: 600 var(--t-13)/20px var(--font); color: var(--text); margin-right: auto; }
.sign > .note { margin-top: 2px; }
.sign.raised { border-color: var(--warn-mark); }
.raised-note { margin-top: var(--s-3); padding: var(--s-2) var(--s-3); border-radius: var(--r-2); background: var(--warn-soft); color: var(--text); font-size: var(--t-12); line-height: 18px; }
.mia { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: var(--s-3); margin-top: var(--s-3); align-items: start; }
.mia p { color: var(--text-2); font-size: var(--t-12); line-height: 18px; }
.mia-k .chip { background: none; box-shadow: none; padding: 0; color: var(--text); }
.sign footer { margin-top: var(--s-3); padding-top: var(--s-3); border-top: 1px solid var(--border); }
.scen-list { display: grid; gap: var(--s-4); margin-top: var(--s-4); }
.scen header { display: flex; gap: var(--s-2); align-items: center; flex-wrap: wrap; }
.scen header h3 { font: 600 var(--t-14)/20px var(--font); color: var(--text); }
.scen-s { margin-top: var(--s-2); max-width: 86ch; color: var(--text-2); }
.scen-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-4); margin: var(--s-4) 0; padding: var(--s-4) 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.scen-stats > div { display: grid; gap: 2px; align-content: start; }
.scen-stats .k { font-size: var(--t-12); color: var(--text-3); }
.scen-as { margin-top: var(--s-4); max-width: 720px; }
.scen-as h4 { font: 500 var(--t-11)/16px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; margin-bottom: var(--s-1); }
.scen-as .note, .scen > .note { margin-top: var(--s-2); max-width: 86ch; }

/* ---------------------------------------------------------------- accuracy */
.acc-top { display: grid; grid-template-columns: 3fr 2fr; gap: var(--s-4); margin-top: var(--s-5); }
.acc-top h3 { color: var(--text); font-weight: 600; font-size: var(--t-13); }
.acc-top h3 .ico { color: var(--text-3); }
.acc-top p { margin-top: var(--s-2); color: var(--text-2); }
.acc-list { display: grid; gap: var(--s-4); margin-top: var(--s-3); }
.acc header { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; }
.acc header h3 { font: 600 var(--t-14)/20px var(--font); color: var(--text); }
.acc header .seg { margin-left: auto; }
.acc-body { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--s-6); margin-top: var(--s-4); }
.acc-col h4 { font: 500 var(--t-12)/16px var(--font); color: var(--text-2); margin-bottom: var(--s-3); }
.acc-col .note { margin-top: var(--s-3); }
.acc-col .bar-row { grid-template-columns: minmax(0, 190px) minmax(40px, 1fr) 44px; }
.dw { display: grid; gap: 2px; }
.dw-axis, .dw-row { display: grid; grid-template-columns: minmax(0, 180px) minmax(120px, 1fr) 150px; gap: var(--s-3); align-items: center; }
.dw-scale { display: flex; justify-content: space-between; font: 400 10px/12px var(--font); color: var(--text-3); }
.dw-row { min-height: 34px; font-size: var(--t-12); }
.dw-l { display: grid; min-width: 0; line-height: 16px; }
.dw-l .sub { font-size: var(--t-11); color: var(--text-3); }
.dw-t { position: relative; height: 34px; }
.dw-t .z { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--border-strong); }
.dw-t .w { position: absolute; top: 16px; height: 2px; background: var(--text-3); border-radius: 1px; }
.dw-t .p { position: absolute; top: 12px; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: var(--text-3); box-shadow: 0 0 0 2px var(--bg); }
.dw-row.good .w, .dw-row.good .p { background: var(--ok); }
.dw-row.bad .w, .dw-row.bad .p { background: var(--warn-mark); }
.dw-v { color: var(--text-2); font-variant-numeric: tabular-nums; }
.dw-row.good .dw-v, .dw-row.bad .dw-v { color: var(--text); font-weight: 500; }
.acc-legend { margin: 0 0 var(--s-2); }
.legend .sw.good { background: var(--ok); border-radius: 50%; } .legend .sw.bad { background: var(--warn-mark); border-radius: 50%; } .legend .sw.none { background: var(--text-3); border-radius: 50%; }
.fence { margin-top: var(--s-7); border: 1px dashed var(--synth); border-radius: var(--r-4); background: repeating-linear-gradient(135deg, transparent 0 10px, var(--synth-soft) 10px 11px); }
.fence > header { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--s-4); align-items: center; padding: var(--s-4); }
.fence h2 { font: 600 var(--t-14)/20px var(--font); }
.fence header p { color: var(--text-2); margin-top: 2px; max-width: 86ch; }
.fence-body { padding: 0 var(--s-4) var(--s-4); display: grid; gap: var(--s-4); }
.synth-block h4 { font: 500 var(--t-13)/20px var(--font); margin-bottom: var(--s-2); display: flex; gap: var(--s-2); align-items: center; }

/* ---------------------------------------------------------------- data, assumptions, limits */
.stat-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-4); }
.stat-card .mv { margin-top: var(--s-1); }
.days { display: grid; grid-template-columns: repeat(14, 6px); gap: 2px; }
.days i { height: 16px; border-radius: 1.5px; background: var(--bg-inset); }
.days i.ok { background: var(--ok); } .days i.same { background: var(--ok); opacity: .45; } .days i.bad { background: var(--urgent); } .days i.off { box-shadow: inset 0 0 0 1px var(--text-3); background: none; }
.lic { max-width: 180px; }
.credit { font-size: var(--t-12); line-height: 18px; color: var(--text-2); overflow-wrap: anywhere; }
.limits { max-width: 860px; }
.limit-list { display: grid; margin-top: var(--s-4); }
.limit-list li { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: var(--s-3); padding: var(--s-4) 0; border-bottom: 1px solid var(--border); }
.limit-list .n { color: var(--text-3); font: 500 var(--t-12)/22px var(--mono); }
.limit-list p { font-size: var(--t-14); line-height: 22px; }
.limit-links { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); margin-top: var(--s-5); }
.limit-links .card { display: grid; grid-template-columns: auto 1fr; gap: var(--s-3); align-items: start; transition: border-color var(--fast); }
.limit-links .card:hover { border-color: var(--border-strong); }
.limit-links .ico { color: var(--text-3); margin-top: 2px; }
.limit-links strong { display: block; font-weight: 600; }
.limit-links span { color: var(--text-2); font-size: var(--t-12); line-height: 16px; }

/* ---------------------------------------------------------------- calculator */
.calc-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: var(--s-4); align-items: start; margin-top: var(--s-5); }
.calc-form h3, .calc-res h3 { color: var(--text); font-weight: 600; font-size: var(--t-13); }
.calc-row { display: grid; grid-template-columns: minmax(0, 1fr) 270px 150px; gap: var(--s-4); align-items: center; padding: var(--s-3) 0; border-bottom: 1px solid var(--border); }
.calc-row:last-child { border-bottom: 0; padding-bottom: 0; }
.calc-row label { display: grid; }
.calc-row .t { font-weight: 500; }
.calc-row .d { font-size: var(--t-12); line-height: 16px; color: var(--text-3); }
.calc-in { display: grid; grid-template-columns: 1fr auto 1fr 36px; gap: var(--s-2); align-items: center; }
.calc-in .input { width: 100%; text-align: right; }
.calc-in .unit { font-size: var(--t-12); }
.calc-tag { display: grid; gap: 2px; justify-items: start; font-size: var(--t-12); }
.calc-tag .btn { height: 24px; padding: 0 6px; margin-left: -6px; }
.calc-res { position: sticky; top: var(--s-4); }
.res-head { font: 600 var(--t-20)/28px var(--font); letter-spacing: -.02em; margin: var(--s-2) 0 var(--s-1); }
.res-head.none { color: var(--text-3); }
.res-line { display: grid; gap: 2px; padding: var(--s-3) 0; border-top: 1px solid var(--border); }
.res-line .t { font-weight: 500; }
.res-line .d { font-size: var(--t-11); color: var(--text-3); }
.res-line .v { font-weight: 600; }
.res-line .need { font-size: var(--t-12); line-height: 16px; color: var(--text-3); }
.res-line.total .t { font-weight: 600; }
.calc-res > .note { margin-top: var(--s-2); }
.calc-res > .note:last-child { padding-top: var(--s-3); border-top: 1px solid var(--border); }

/* ---------------------------------------------------------------- narrower screens */
@container view (max-width: 1060px) {
  .act-row { grid-template-columns: 16px minmax(160px, 1fr) 104px 176px 140px 100px; }
  .act-row .c-where { display: none; }
}
@container view (max-width: 860px) {
  .act-row { grid-template-columns: 16px minmax(0, 1fr) 176px 132px 96px; }
  .act-row .c-when { display: none; }
  .home-row { grid-template-columns: 16px minmax(0, 1fr) 132px 96px; }
  .home-row > :nth-child(3) { display: none; }
  .weak-row { grid-template-columns: 16px minmax(0, 1fr) 150px; }
  .weak-row > :nth-child(4) { display: none; }
  .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .acc-body { grid-template-columns: minmax(0, 1fr); gap: var(--s-5); }
  .acc-top { grid-template-columns: minmax(0, 1fr); }
  .scen-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container view (max-width: 1100px) {
  .calc-grid { grid-template-columns: minmax(0, 1fr); }
  .calc-res { position: static; }
  .home-cols { grid-template-columns: minmax(0, 1fr); }
  .home-side { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: var(--s-5); align-items: start; }
}
@container view (max-width: 720px) { .home-side { grid-template-columns: minmax(0, 1fr); } .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container view (max-width: 640px) {
  .facts { grid-template-columns: minmax(0, 1fr); }
  .act-row { grid-template-columns: 16px minmax(0, 1fr) 176px; }
  .act-row .c-pct, .act-row .c-ev { display: none; }
}
@media (max-width: 1180px) {
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-cols { grid-template-columns: minmax(0, 1fr); }
  .home-side { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: var(--s-5); align-items: start; }
  .calc-grid { grid-template-columns: minmax(0, 1fr); }
  .calc-res { position: static; }
  .acc-body { grid-template-columns: minmax(0, 1fr); gap: var(--s-5); }
  .scen-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .hero { grid-template-columns: auto minmax(0, 1fr); }
  .hero-stats { grid-column: 1 / -1; }
  .stat { flex: 1; min-width: 0; }
  .home-side, .facts, .stat-row, .limit-links, .acc-top { grid-template-columns: minmax(0, 1fr); }
  .stat-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .act-row { grid-template-columns: 16px minmax(0, 1fr) 120px 96px; }
  .act-row .c-when, .act-row .c-pct { display: none; }
  .home-row { grid-template-columns: 16px minmax(0, 1fr) 96px; }
  .home-row > :nth-child(3), .home-row > :nth-child(4) { display: none; }
  .cal-row { grid-template-columns: 16px 104px minmax(0, 1fr) 80px; }
  .cal-row > :nth-child(4) { display: none; }
  .calc-row { grid-template-columns: minmax(0, 1fr); gap: var(--s-2); }
  .map-panel, .map-legend { width: 232px; }
  .map-time { grid-template-columns: auto 132px minmax(0, 1fr); }
  .map-flag { display: none; }
  .dw-axis, .dw-row { grid-template-columns: minmax(0, 120px) minmax(80px, 1fr) 110px; }
}
@media (max-width: 760px) {
  .map-legend { display: none; }
  .metrics { grid-template-columns: minmax(0, 1fr); }
}

.row > .chip, .row > div > .chip, .c-ev .chip { justify-self: start; }
.row > .chip { width: max-content; }

.mline { font-size: var(--t-12); line-height: 20px; color: var(--text-3); display: flex; flex-wrap: wrap; align-items: center; gap: 0 4px; }
.mline .chip { margin-left: 2px; }
.mfoot { justify-content: flex-start; margin-top: var(--s-1); }
.mv .unit { white-space: normal; }
.chg-list { display: grid; margin-top: var(--s-2); }
.chg { border-bottom: 1px solid var(--border); }
.chg:last-child { border-bottom: 0; }
.chg summary { display: grid; grid-template-columns: 16px minmax(0, auto) minmax(0, 1fr) 12px; gap: var(--s-2); align-items: center; min-height: 36px; cursor: pointer; list-style: none; font-size: var(--t-12); }
.chg summary::-webkit-details-marker { display: none; }
.chg summary .t { font-weight: 500; color: var(--text); white-space: nowrap; }
.chg summary .chips { display: flex; gap: var(--s-1); overflow: hidden; justify-content: flex-end; min-width: 0; }
.chg summary .chips .chip { overflow: hidden; text-overflow: ellipsis; max-width: 130px; display: inline-block; line-height: 20px; flex: 0 1 auto; }
.chg summary .ico.chg { color: var(--warn-mark); }
.chg summary .chev { width: 12px; height: 12px; color: var(--text-3); transition: transform var(--fast); }
.chg[open] summary .chev { transform: rotate(90deg); }
.chg ul { display: grid; gap: var(--s-2); padding: 0 0 var(--s-3) 24px; }
.chg li { font-size: var(--t-12); line-height: 18px; color: var(--text-2); }
.chg li a:hover { text-decoration: underline; text-underline-offset: 2px; }

.verdicts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s-4); align-items: start; }
.vcol { display: grid; gap: var(--s-2); align-content: start; }
.vcol > h3 { font: 600 var(--t-12)/16px var(--font); display: flex; align-items: center; gap: var(--s-2); padding-bottom: var(--s-2); border-bottom: 2px solid var(--border-strong); }
.vcol.good > h3 { border-color: var(--ok); } .vcol.bad > h3 { border-color: var(--warn-mark); }
.vmark { width: 10px; height: 10px; flex: none; background: var(--text-3); border-radius: 50%; }
.vmark.good { background: var(--ok); } .vmark.bad { background: var(--warn-mark); border-radius: 2px; transform: rotate(45deg) scale(.85); }
.vcard { border: 1px solid var(--border); border-radius: var(--r-3); padding: var(--s-3); display: grid; gap: var(--s-1); background: var(--bg); }
.vt { font-size: var(--t-12); line-height: 16px; color: var(--text-2); }
.vh { font: 600 var(--t-16)/24px var(--font); letter-spacing: -.01em; }
.vcard p { font-size: var(--t-12); line-height: 18px; color: var(--text-2); }
.vfig { display: grid; gap: 2px; font-size: var(--t-12); color: var(--text-2); }
.vfoot { display: flex; flex-wrap: wrap; gap: var(--s-1); margin-top: var(--s-1); }
.vnone { padding: var(--s-2) 0; }
.legend .sw.bad, .dw-row.bad .p { border-radius: 2px; }
.dw-row.bad .p { transform: rotate(45deg) scale(.85); }
@container view (max-width: 1000px) { .verdicts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container view (max-width: 560px) { .verdicts { grid-template-columns: minmax(0, 1fr); } }
/* what is measured and what is assumed */
.cov { width: 100%; border-collapse: separate; border-spacing: 0; }
.cov th, .cov td { text-align: left; vertical-align: top; padding: var(--s-3); border-bottom: 1px solid var(--border); font-size: var(--t-12); line-height: 18px; }
.cov thead th { font: 500 var(--t-12)/16px var(--font); color: var(--text-2); background: var(--bg-subtle); white-space: nowrap; }
.cov tbody th { font: 600 var(--t-13)/20px var(--font); width: 150px; }
.cov tbody th span { display: block; font: 400 var(--t-12)/16px var(--font); color: var(--text-3); }
.cov td p { color: var(--text-2); margin-top: var(--s-1); }
.cov td .src { color: var(--text-3); font-size: var(--t-11); line-height: 16px; margin-top: var(--s-1); }
.cov tr:last-child th, .cov tr:last-child td { border-bottom: 0; }

/* ================================================================ shared work (backend integration) */
.page-head { margin-bottom: var(--s-5); }
.page-head .h-sub { max-width: 84ch; }
.h-sec .grow, .toolbar .grow { flex: 1; }
.h-sub-sec { font: 500 var(--t-12)/16px var(--font); color: var(--text-2); margin: var(--s-4) 0 var(--s-2); }
.empty.slim { padding: var(--s-5) var(--s-4); border: 1px dashed var(--border-strong); border-radius: var(--r-3); }
.callout.bad { background: var(--urgent-soft); border-color: transparent; }
.callout.bad .ico { color: var(--urgent); }
.callout + .toolbar, .draft-callout { margin-bottom: var(--s-3); }

/* inbox: comment count and assignee on a row; the shared triage block in the pane */
.act-row .t > .trunc { min-width: 0; }
.cmark { display: inline-flex; align-items: center; gap: 2px; color: var(--text-3); font-size: var(--t-11); font-weight: 400; }
.cmark .ico { width: 12px; height: 12px; }
.amark { display: inline-flex; margin-left: 2px; }
.row.pending { opacity: .7; }
.tri-grid { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: var(--s-2) var(--s-3); align-items: center; }
.tri-grid > div { display: flex; gap: var(--s-1); align-items: center; flex-wrap: wrap; }
.btn.assignee .avatar { margin-left: -2px; }

/* assumptions: the draft tray and the editor in the pane */
.draft-tray { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; padding: var(--s-2) var(--s-3); margin-bottom: var(--s-3); border-radius: var(--r-3); border: 1px solid var(--scn-soft); background: var(--scn-soft); }
.draft-tray .dt-mark { color: var(--scn-text); display: inline-flex; }
.draft-tray .dt-text { display: grid; flex: 1; min-width: 200px; line-height: 16px; }
.draft-tray .dt-text strong { font-weight: 600; }
.draftv { color: var(--scn-text); font-weight: 600; }
.draftv.out { color: var(--urgent); }
.try { display: grid; gap: var(--s-2); }
.try-slider { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: var(--s-2); align-items: center; }
.try-slider .e { font-size: var(--t-11); color: var(--text-3); }
.try-field { display: flex; gap: var(--s-2); align-items: center; }
.try-field .input { width: 120px; }
.flag { margin-top: var(--s-2); display: flex; flex-wrap: wrap; gap: 4px; align-items: center; min-height: 20px; }
.layers { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 2px; vertical-align: middle; }
.layers .sep { width: 12px; height: 12px; color: var(--text-3); }

/* scenarios */
.sc-title { display: flex; align-items: center; gap: var(--s-2); flex-wrap: wrap; }
.sc-title .h-page { margin-right: var(--s-1); }
.form { display: grid; gap: var(--s-3); max-width: 640px; }
.field { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: var(--s-3); align-items: start; }
.field .lbl { color: var(--text-2); font-size: var(--t-12); padding-top: 5px; }
.field .input { width: 100%; }
.field.check { grid-template-columns: auto 1fr; align-items: center; padding-left: 132px; }
.form-foot { display: flex; gap: var(--s-2); align-items: center; margin-top: var(--s-5); padding-top: var(--s-4); border-top: 1px solid var(--border); }
.form-foot .grow { flex: 1; }
.ov-tbl td.nw { overflow: visible; }
.ov-cell { display: inline-flex; gap: var(--s-2); align-items: center; }
.ov-in { width: 110px; }
.ov-row { grid-template-columns: 16px minmax(0, 1fr) auto 128px; }
.ov-row > .chip { justify-self: end; }
.progress { margin-bottom: var(--s-5); }
.progress.failed { border-color: var(--urgent); }
.pg-head { display: flex; justify-content: space-between; gap: var(--s-3); }
.pg-head strong { font-weight: 600; }
.pg-bar { height: 6px; border-radius: 3px; background: var(--bg-inset); margin: var(--s-3) 0; overflow: hidden; }
.pg-bar i { display: block; height: 100%; border-radius: 3px; background: var(--scn); transition: width var(--med) var(--ease); }
.progress.failed .pg-bar i { background: var(--urgent); }
.stages { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-4); margin-bottom: var(--s-2); }
.stages li { display: inline-flex; align-items: center; gap: 6px; font-size: var(--t-12); color: var(--text-3); }
.stages li.done { color: var(--text-2); }
.stages li.done .ico { color: var(--ok); }
.stages li.running { color: var(--text); font-weight: 500; }
.stages li.running .ico { color: var(--scn); animation: pulse 1.2s ease-in-out infinite; }
.stages .ico { width: 14px; height: 14px; }
@keyframes pulse { 50% { opacity: .35; } }

/* compare: run pickers, counts, the per-product strip, typed rows */
.pickers .fbtn { max-width: 320px; }
.fbtn.pick-run.scn { border-color: var(--scn); background: var(--scn-soft); }
.ab-legend { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-5); color: var(--text-2); font-size: var(--t-12); margin-bottom: var(--s-4); }
.ab-legend b { font-weight: 600; color: var(--text); }
.scn-note { display: flex; gap: var(--s-2); align-items: center; padding: var(--s-2) var(--s-3); border-radius: var(--r-3); background: var(--scn-soft); color: var(--scn-text); margin-bottom: var(--s-3); font-size: var(--t-12); }
.scn-note strong { font-weight: 600; }
.dcounts { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border: 1px solid var(--border); border-radius: var(--r-3); overflow: hidden; }
.dc { display: grid; gap: 2px; padding: var(--s-3) var(--s-4); border-left: 1px solid var(--border); }
.dc:first-child { border-left: 0; }
.dc .n { font: 600 var(--t-20)/28px var(--font); letter-spacing: -.01em; }
.dc .l { color: var(--text-3); font-size: var(--t-12); }
.dstrip { display: grid; gap: 2px; border: 1px solid var(--border); border-radius: var(--r-3); padding: var(--s-2) var(--s-3); }
.ds { display: grid; grid-template-columns: minmax(120px, 200px) minmax(120px, 1fr) 76px 132px; gap: var(--s-3); align-items: center; min-height: 28px; }
.ds-l { font-weight: 500; }
.ds-bar { position: relative; height: 10px; }
.ds-bar .mid { position: absolute; left: 50%; top: -3px; bottom: -3px; width: 1px; background: var(--border-strong); }
.ds-bar .v { position: absolute; top: 1px; height: 8px; border-radius: 2px; }
.ds-bar .v.up { background: var(--div-6); }
.ds-bar .v.down { background: var(--div-2); }
.ds-v { text-align: right; font-weight: 500; }
.ds-ab { font-size: var(--t-12); }
.drows .drow { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; gap: var(--s-3); align-items: center; min-height: 40px; padding: 6px var(--s-3); border-bottom: 1px solid var(--border); }
.drows .drow:last-child { border-bottom: 0; }
.drows a.drow:hover { background: var(--bg-hover); }
.drow .dk { width: 20px; height: 20px; border-radius: var(--r-1); display: grid; place-items: center; background: var(--bg-inset); color: var(--text-2); }
.drow .dk .ico { width: 12px; height: 12px; }
.drow.add .dk { color: var(--ok); background: var(--ok-soft); }
.drow.del .dk { color: var(--urgent); background: var(--urgent-soft); }
.drow .dk.up { color: var(--div-7); } .drow .dk.down { color: var(--div-1); }
.drow .dt { display: grid; font-weight: 500; }
.drow .dt .d { font-weight: 400; color: var(--text-3); font-size: var(--t-12); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.drow .chips { display: flex; gap: var(--s-1); align-items: center; flex-wrap: wrap; justify-content: flex-end; }
@container view (max-width: 900px) { .dcounts { grid-template-columns: repeat(3, minmax(0, 1fr)); } .dc:nth-child(4) { border-left: 0; } .dc:nth-child(n+4) { border-top: 1px solid var(--border); } .ds { grid-template-columns: 110px minmax(80px, 1fr) 70px; } .ds-ab { display: none; } }

/* history */
.hist-metrics { margin: 0 0 var(--s-2); }
.history .tbl td .dot { vertical-align: 1px; }

/* activity */
.act-day + .act-day .h-sec { margin-top: var(--s-5); }
.feed { padding: 0; }
.feed li { list-style: none; }
.feed-row { grid-template-columns: 20px 20px minmax(0, 1fr) auto; min-height: 40px; cursor: default; }
a.feed-row { cursor: pointer; }
div.feed-row:hover { background: none; }
.feed-row .fk { color: var(--text-3); display: inline-flex; }
.feed-row .fk .ico { width: 14px; height: 14px; }
.feed-row .ft { min-width: 0; overflow-wrap: anywhere; }
.feed li:last-child .row { border-bottom: 0; }

/* members and settings */
.invite { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; padding: var(--s-3) var(--s-4); border: 1px solid var(--border); border-radius: var(--r-3); background: var(--bg-subtle); }
.invite .lbl { font-weight: 500; margin-right: var(--s-2); }
.invite .input { width: 280px; }
.invite .err { flex-basis: 100%; margin: 0; }
.who { display: inline-flex; gap: var(--s-2); align-items: center; min-width: 0; }
.kv.roles { grid-template-columns: 96px minmax(0, 1fr); max-width: 720px; color: var(--text-2); }
.role-btn:disabled { opacity: .7; cursor: default; }
.settings section + section { margin-top: var(--s-2); }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: var(--s-4); padding: var(--s-3) var(--s-4); border: 1px solid var(--border); border-radius: var(--r-3); margin-bottom: var(--s-3); max-width: 760px; }
.set-row .t { font-weight: 500; }
.settings .kv { max-width: 760px; }
.rule-row { grid-template-columns: 28px minmax(0, 1fr) auto 28px; cursor: default; }
.rule-row:hover { background: none; }
.settings .rows { max-width: 760px; }
.rule-form { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; max-width: 760px; }
.rule-form .inline { display: inline-flex; align-items: center; gap: 6px; font-size: var(--t-12); }
.rule-form .full { flex-basis: 100%; }

/* ================================================================ the beginner path (docs/PRODUCT.md) */
/* sidebar: the three questions, then "More" */
.sb-more { display: flex; align-items: center; gap: 6px; width: 100%; height: 28px; padding: 0 var(--s-2); border-radius: var(--r-2); color: var(--text-3); font: 500 var(--t-12)/16px var(--font); }
.sb-more:hover { background: var(--bg-hover); color: var(--text); }
.sb-more .chev { width: 12px; height: 12px; transition: transform var(--fast); }
.sb-more[aria-expanded='true'] .chev { transform: rotate(90deg); }
.sb-group.sb-moregroup { margin-top: var(--s-4); }
.sb-group.sb-moregroup ul { margin-top: 2px; }
@media (max-width: 1180px) { .sb-more span { display: none; } .sb-more { justify-content: center; padding: 0; } }

/* the section skeleton: question, answer, visual, list, go deeper */
.q-head { margin-bottom: var(--s-5); max-width: 880px; }
.q-title { font: 600 var(--t-24)/32px var(--font); letter-spacing: -.02em; }
.answer { font: 400 var(--t-16)/26px var(--font); color: var(--text); margin-top: var(--s-2); }
.answer .chip { vertical-align: 2px; }
.deeper { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: var(--s-2); }
.deep-link { display: grid; grid-template-columns: 20px minmax(0, 1fr) 16px; gap: var(--s-3); align-items: center; padding: var(--s-3); border: 1px solid var(--border); border-radius: var(--r-3); color: var(--text-2); }
.deep-link:hover { border-color: var(--border-strong); background: var(--bg-hover); }
.deep-link > span { display: grid; gap: 2px; min-width: 0; }
.deep-link strong { color: var(--text); font-weight: 500; }
.deep-link .faint { font-size: var(--t-12); line-height: 16px; }
.deep-link > .ico:last-child { color: var(--text-3); }
.q-list { margin-top: var(--s-2); }

/* Today: three answers */
.today { max-width: 960px; }
.today-head { margin-bottom: var(--s-5); }
.answers { display: grid; gap: var(--s-3); }
.ans { display: grid; grid-template-columns: 40px minmax(0, 1fr) 20px; gap: var(--s-4); align-items: center; padding: var(--s-5); border: 1px solid var(--border); border-radius: var(--r-4); background: var(--bg); transition: border-color var(--fast), background var(--fast); }
.ans:hover { border-color: var(--border-strong); background: var(--bg-subtle); }
.ans-icon { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-inset); color: var(--text-2); }
.ans-icon .ico { width: 20px; height: 20px; }
.ans-label { font: 500 var(--t-12)/16px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.ans-text { font: 500 var(--t-20)/28px var(--font); letter-spacing: -.01em; margin-top: 4px; }
.ans-text .chip { vertical-align: 3px; }
.ans-sub { color: var(--text-2); margin-top: 6px; }
.ans-go { color: var(--text-3); }
.quiet { margin-top: var(--s-5); display: grid; gap: var(--s-2); }
.quiet-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; color: var(--text-3); font-size: var(--t-12); }
.quiet-line .ico { width: 14px; height: 14px; }
.quiet-line a { color: var(--text-2); text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--border-strong); }
.quiet-line a:hover { color: var(--text); }

/* Demand */
.demand-mapbox { position: relative; height: min(520px, 62vh); min-height: 380px; border: 1px solid var(--border); border-radius: var(--r-4); overflow: hidden; margin-bottom: var(--s-5); }
.demand-mapbox > .mapwrap { height: 100%; min-height: 0; }
.demand-mapbox .map-legend { top: var(--s-3); bottom: auto; }
.top-row { grid-template-columns: 20px minmax(0, 1fr) auto 96px; }
.dirmark { display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: var(--r-1); }
.dirmark .ico { width: 12px; height: 12px; }
.dirmark.up { color: var(--div-7); background: color-mix(in srgb, var(--div-6) 18%, transparent); }
.dirmark.down { color: var(--div-1); background: color-mix(in srgb, var(--div-2) 18%, transparent); }
.big-pct { text-align: right; font-weight: 500; }
.big-pct .small { font-size: var(--t-11); font-weight: 400; }

/* Supply */
.sp-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: var(--s-4); margin-bottom: var(--s-5); }
.sp-card { display: grid; gap: var(--s-4); align-content: start; }
.sp-head h3 { font: 600 var(--t-16)/24px var(--font); }
.sp-sentence { color: var(--text-2); margin-top: 2px; }
.sp-label { display: flex; align-items: center; gap: var(--s-2); font: 500 var(--t-11)/16px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; margin-bottom: var(--s-2); }
.sp-label .chip { text-transform: none; letter-spacing: 0; }
.origin-bar { display: flex; height: 14px; border-radius: 4px; overflow: hidden; background: var(--bg-inset); gap: 1px; }
.origin-bar .seg { display: block; height: 100%; min-width: 2px; }
.seg.s0, .sw.s0 { background: var(--seq-6); } .seg.s1, .sw.s1 { background: var(--seq-5); } .seg.s2, .sw.s2 { background: var(--seq-4); }
.seg.s3, .sw.s3 { background: var(--seq-3); } .seg.s4, .sw.s4, .seg.s5, .sw.s5 { background: var(--seq-2); }
.seg.home, .sw.home { background: var(--text-3); }
.origin-legend { display: flex; flex-wrap: wrap; gap: 4px var(--s-3); margin-top: var(--s-2); font-size: var(--t-12); color: var(--text-2); }
.origin-legend li { display: inline-flex; align-items: center; gap: 6px; }
.origin-legend .sw { width: 8px; height: 8px; border-radius: 2px; display: inline-block; }
.origin-legend .num { color: var(--text); font-weight: 500; }
.weak-list { display: grid; gap: var(--s-2); color: var(--text-2); font-size: var(--t-12); line-height: 18px; }
.weak-list strong { color: var(--text); font-weight: 500; }
.sign-list { display: grid; gap: 4px; font-size: var(--t-12); }
.sign-list li { display: grid; grid-template-columns: 8px minmax(0, 1fr) auto; gap: var(--s-2); align-items: center; }
.whatif-btn { width: 100%; justify-content: flex-start; height: auto; min-height: 36px; padding: 6px var(--s-3); white-space: normal; text-align: left; border-color: var(--scn); color: var(--scn-text); background: var(--scn-soft); font-size: var(--t-13); }
.whatif-btn:hover { background: color-mix(in srgb, var(--scn) 18%, transparent); }
.mini-tbl td, .mini-tbl th { white-space: normal; }

/* the welcome */
.dialog.welcome { width: min(640px, calc(100vw - 32px)); max-height: 86vh; }
.wl-kicker { color: var(--text-3); font-size: var(--t-12); margin-bottom: var(--s-2); }
.welcome h2 { font: 600 var(--t-24)/32px var(--font); letter-spacing: -.02em; margin-bottom: var(--s-2); }
.wl-qs { display: grid; gap: var(--s-2); margin: var(--s-4) 0; }
.wl-q { display: grid; grid-template-columns: 20px 32px minmax(0, 1fr) 16px; gap: var(--s-3); align-items: center; padding: var(--s-3) var(--s-4); border: 1px solid var(--border); border-radius: var(--r-3); text-align: left; }
.wl-q:hover { border-color: var(--accent); background: var(--accent-soft); }
.wl-n { color: var(--text-3); font: 600 var(--t-14)/20px var(--font); }
.wl-ic { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--bg-inset); color: var(--text-2); }
.wl-t { display: grid; gap: 2px; }
.wl-t strong { font: 600 var(--t-14)/20px var(--font); }
.wl-t span { color: var(--text-2); font-size: var(--t-12); line-height: 16px; }
.wl-tours { padding: var(--s-3) var(--s-4); border-radius: var(--r-3); background: var(--bg-subtle); display: grid; gap: var(--s-2); }
.wl-tour-h { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: center; }
.wl-tour-h .ico { color: var(--accent); }
.wl-tour-list { display: flex; flex-wrap: wrap; gap: var(--s-2); }

/* the tour */
.tour-ring { position: fixed; z-index: 64; border-radius: var(--r-3); box-shadow: 0 0 0 2px var(--accent), 0 0 0 9999px rgba(10, 11, 14, .32); pointer-events: none; transition: left var(--fast), top var(--fast), width var(--fast), height var(--fast); }
.tour-card { position: fixed; z-index: 65; background: var(--bg-raised); border-radius: var(--r-4); box-shadow: var(--shadow-2); padding: var(--s-4); display: grid; gap: var(--s-2); }
.tc-top { display: flex; justify-content: space-between; align-items: center; margin: -4px -4px 0 0; }
.tc-count { color: var(--text-3); font-size: var(--t-12); font-variant-numeric: tabular-nums; }
.tc-title { font: 600 var(--t-16)/24px var(--font); }
.tc-body { color: var(--text-2); }
.tc-foot { display: flex; justify-content: space-between; margin-top: var(--s-2); }
.run-banner.tour { background: var(--accent-soft); }
.run-banner.tour .rb-tag { background: var(--accent); color: var(--text-inv); }
.weak-list li { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.seg.lens button { display: inline-flex; align-items: center; gap: 6px; } .seg.lens .ico { width: 14px; height: 14px; }
/* a decision card: the six answers at a glance */
.row.act-card { display: block; padding: var(--s-3) var(--s-4); }
.ac-top { display: flex; align-items: center; gap: var(--s-2); min-width: 0; }
.ac-top .t { font-weight: 600; flex: 0 1 auto; }
.ac-top .ac-ev { margin-left: auto; }
.six { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-2) var(--s-5); margin-top: var(--s-3); padding-left: 24px; }
.six-c { display: grid; gap: 2px; min-width: 0; }
.six-k { font: 500 var(--t-11)/14px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.six-v { color: var(--text); font-size: var(--t-13); line-height: 18px; overflow-wrap: anywhere; }
.six-v .soon { color: var(--urgent); }
@container view (max-width: 760px) { .six { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-left: 0; } }
/* a ready-made what-if */
.wi-result { display: grid; gap: var(--s-3); margin-bottom: var(--s-5); }
.wi-figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-4); }
.wi-figs > div { display: grid; gap: 2px; }
.wi-figs .l { font: 500 var(--t-11)/16px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.wi-figs .v { font: 600 var(--t-20)/28px var(--font); }
.wi-figs .faint { font-size: var(--t-12); }
.ready-row { grid-template-columns: 16px minmax(0, 1fr) 16px; }
/* order adjustments: one card per date, open by default as a list; the lines underneath on demand */
.rows-h.static { cursor: default; }
.rows-h.static .note { margin-left: var(--s-2); }
.adj { border-bottom: 1px solid var(--border); }
.adj:last-child { border-bottom: 0; }
.adj-h { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto auto 16px; gap: var(--s-3); align-items: center; width: 100%; padding: var(--s-3) var(--s-4); text-align: left; }
.adj-h:hover { background: var(--bg-hover); }
.adj-h .chev { color: var(--text-3); transition: transform var(--fast); }
.adj-h[aria-expanded='true'] .chev { transform: rotate(90deg); }
.adj-date { font-weight: 600; }
.adj-main { display: grid; min-width: 0; }
.adj-what { font-weight: 500; }
.adj-why { color: var(--text-3); font-size: var(--t-12); }
.adj-by { color: var(--text-2); font-size: var(--t-12); text-align: right; }
.adj-by.soon { color: var(--text); font-weight: 500; }
.adj.dim .adj-what { color: var(--text-2); font-weight: 400; }
.adj > .row { padding-left: calc(var(--s-4) + 96px); background: var(--bg-subtle); }
@container view (max-width: 900px) { .adj-h { grid-template-columns: 80px minmax(0, 1fr) 16px; } .adj-h .adj-date { grid-row: 1 / span 3; } .adj-h .adj-main { grid-column: 2; } .adj-h .adj-by, .adj-h .adj-chips, .adj-h > .chip { grid-column: 2; justify-self: start; text-align: left; } .adj-h > .chev { grid-column: 3; grid-row: 1; } .adj > .row { padding-left: var(--s-4); } }
.sign-list li { grid-template-columns: 8px minmax(0, 1fr); align-items: start; row-gap: 0; }
.sign-list .dot { margin-top: 5px; }
.sign-list .sg-t { color: var(--text); }
.sign-list .sg-v { grid-column: 2; color: var(--text-3); }
.sign-list .sg-v.raised { color: var(--warn); }
/* track record: the plain verdict first, details on demand */
.verdict-top { display: grid; gap: var(--s-2); margin: var(--s-4) 0 var(--s-2); font-size: var(--t-14); line-height: 22px; max-width: 980px; }
.verdict-top strong { font-weight: 600; }
.vmore summary { cursor: pointer; color: var(--text-3); font-size: var(--t-12); margin-top: var(--s-2); }
.acc-detail > summary { cursor: pointer; list-style: revert; }
.menu.wrap-items .menu-item .trunc { white-space: normal; } .menu.wrap-items .menu-item { align-items: flex-start; } .wl-scope { margin-top: 6px; }
.wi-headline { font: 500 var(--t-16)/24px var(--font); }
.answer .answer-2 { color: var(--text-2); }
.answer .answer-3, .ans-quiet { display: block; color: var(--text-3); font-size: var(--t-13); margin-top: 2px; }
.adj-more { display: flex; align-items: center; gap: 6px; width: 100%; padding: var(--s-2) var(--s-4); color: var(--text-2); font-size: var(--t-12); font-weight: 500; }
.adj-more:hover { background: var(--bg-hover); color: var(--text); }
.adj-more .ico { width: 12px; height: 12px; }
.adj-by strong { font-weight: 600; color: var(--text); }
/* the lines inside an opened order adjustment: what, for when, decide by, evidence; no column runs into the next */
.adj > .act-row { grid-template-columns: 16px minmax(0, 1fr) minmax(150px, max-content) minmax(190px, max-content) 104px; column-gap: var(--s-4); }
.adj > .act-row .c-where, .adj > .act-row .c-pct { display: none; }
.adj > .act-row .c-when, .adj > .act-row .c-due { white-space: nowrap; }
@container view (max-width: 900px) { .adj > .act-row { grid-template-columns: 16px minmax(0, 1fr) minmax(170px, max-content); } .adj > .act-row .c-when, .adj > .act-row .c-ev { display: none; } }
.adj-chips { display: inline-flex; gap: 4px; align-items: center; }
.adj-qty { display: block; color: var(--text-2); font-size: var(--t-12); margin-top: 2px; }
.pane-details > summary { cursor: pointer; color: var(--text-3); font-size: var(--t-12); }
.pane-details[open] > summary { margin-bottom: var(--s-2); }
.weak-list li { display: block; -webkit-line-clamp: unset; overflow: visible; }
/* the try-a-what-if form: each field with its label above, never run together */
.try-form { display: flex; flex-wrap: wrap; gap: var(--s-3) var(--s-4); align-items: flex-end; margin-top: var(--s-3); }
.try-form .tf { display: grid; gap: 4px; }
.try-form .tf .lbl { font: 500 var(--t-11)/14px var(--font); color: var(--text-3); text-transform: uppercase; letter-spacing: .05em; }
.try-form .tf-inline { display: inline-flex; gap: 6px; align-items: center; }
.try-form select.input { min-width: 200px; }
.try-form > .note { align-self: center; }
.try-form > .err { flex-basis: 100%; }
.try-card { margin-bottom: var(--s-5); }
.wi-lead { font: 600 var(--t-16)/24px var(--font); } .wi-lead-2 { font-weight: 400; color: var(--text-2); } .live-card { margin-bottom: var(--s-5); }
.map-flag { white-space: normal; max-width: min(560px, calc(100% - 340px)); text-align: center; line-height: 18px; }
.mt-axis .mid { transform: translateX(-100%); padding-right: 6px; white-space: nowrap; }
.top-row .d { white-space: normal; }
.qty-list { display: grid; gap: 4px; font-size: var(--t-12); color: var(--text-2); }
.adj-qtys { padding: var(--s-2) var(--s-4) var(--s-3) calc(var(--s-4) + 96px); background: var(--bg-subtle); border-top: 1px solid var(--border); }
@container view (max-width: 900px) { .adj-qtys { padding-left: var(--s-4); } }
