/* Latah Weather — the Palouse look. Colours come from the station's own drone photo:
   Moscow's dark wooded ridge (ink), the wheat (green), a canola field (yellow), the barns (red),
   and a June evening sky (blue). Fraunces for the almanac numbers, Figtree for everything else. */
@font-face { font-family: "Fraunces"; src: url("/fonts/fraunces-latin.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("/fonts/figtree-latin.woff2") format("woff2"); font-weight: 300 900; font-display: swap; }

:root {
  --bg: #F1F0E6; --bg-2: #E7E8DB; --surface: #FFFEF9; --surface-2: #F3F3EA;
  --ink: #12283A; --ink-2: #384C5A; --muted: #66767F; --line: #DCDFD1; --line-2: #E8E9DE;
  --field: #2E5232; --field-2: #4E7442; --canola: #D9D33B; --canola-ink: #6C6700; --barn: #B0452D; --sky: #2468B8; --sky-pale: #D3E5F5;
  --accent: var(--sky); --focus: #2468B8;
  --c-temp: #BC4B2A; --c-wind: #3B7646; --c-pres: #49698C; --c-rain: #2468B8;
  --ic-sun: #EFB03A; --ic-moon: #F1DB98; --ic-moon-edge: #C9A94A; --ic-cloud: #FFFFFF; --ic-cloud-edge: #8E9BA6;
  --ic-cloud2: #E4E8EA; --ic-cloud2-edge: #8E9BA6; --ic-storm: #7B8693; --ic-storm-edge: #56606C; --ic-rain: #2F7FD8;
  --ic-snow: #5A97DB; --ic-bolt: #F2CF35; --ic-bolt-edge: #9A7A00; --ic-fog: #98A4B0; --ic-wind: #5F8AA8; --ic-alert: #F2B12B; --ic-alert-edge: #8E5F07;
  --sev-warning: #B5352A; --sev-watch: #C4661B; --sev-advisory: #A4850B; --sev-statement: #2F68AE; --ok: #2F7A45;
  --radius: 20px; --shadow: 0 1px 0 rgba(18, 40, 58, .04), 0 10px 30px -18px rgba(18, 40, 58, .28);
  --rows: rgba(46, 82, 50, .045);
  --f-ui: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-display: "Fraunces", Georgia, "Times New Roman", serif;
  --tabbar: 66px; --tab-bg: #13283A;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0B1713; --bg-2: #0F1E19; --surface: #13231E; --surface-2: #1A2D27;
    --ink: #EFF0E6; --ink-2: #C6CFC4; --muted: #8E9F96; --line: #22372F; --line-2: #1B2E27;
    --field: #A2C98D; --field-2: #7FAE70; --canola: #E3DB58; --canola-ink: #E3DB58; --barn: #E68562; --sky: #8CC0F3; --sky-pale: #1D3346;
    --focus: #8CC0F3;
    --c-temp: #EE8C64; --c-wind: #86C58F; --c-pres: #A1BEDF; --c-rain: #7DB5F1;
    --ic-cloud: #DCE2E6; --ic-cloud-edge: #DCE2E6; --ic-cloud2: #9DA9B4; --ic-cloud2-edge: #9DA9B4; --ic-storm: #6B7684; --ic-storm-edge: #6B7684;
    --ic-snow: #FFFFFF; --ic-moon-edge: #F1DB98; --ic-fog: #A9B4BF;
    --sev-warning: #F06A5E; --sev-watch: #F19B4D; --sev-advisory: #E5C443; --sev-statement: #82ABE9; --ok: #66C68C;
    --shadow: 0 1px 0 rgba(0, 0, 0, .25), 0 12px 30px -16px rgba(0, 0, 0, .5);
    --rows: rgba(162, 201, 141, .035);
    --tab-bg: #0A1622;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; color: var(--ink); font: 400 15.5px/1.5 var(--f-ui); -webkit-font-smoothing: antialiased;
  /* faint drill rows, like the wheat in the photo */
  background: var(--bg) repeating-linear-gradient(-13deg, transparent 0 9px, var(--rows) 9px 10px); }
body.app { padding-bottom: calc(var(--tabbar) + env(safe-area-inset-bottom) + 16px); }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, summary:focus-visible, select:focus-visible, input:focus-visible, .hscroll:focus-visible { outline: 2.5px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--f-display); font-optical-sizing: auto; letter-spacing: -.005em; font-weight: 600; }
.muted { color: var(--muted); }
.fine { color: var(--muted); font-size: 12px; margin: 10px 0 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { max-width: 800px; margin: 0 auto; padding: 0 14px; }
.wrap.wide { max-width: 1180px; }
[hidden] { display: none !important; }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: calc(env(safe-area-inset-top) + 10px) max(16px, calc((100% - 800px) / 2 + 20px)) 10px;
  background: color-mix(in srgb, var(--bg) 97%, transparent); border-bottom: 1px solid var(--line-2); }
.brand { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; color: inherit; font-family: var(--f-display); font-size: 22px; line-height: 1; letter-spacing: -.01em; }
.brand .mark { width: 30px; height: 22px; flex: 0 0 auto; margin-right: 2px; }
.mark .m-sun { fill: var(--canola); } .mark .m-h1 { fill: var(--field-2); } .mark .m-h2 { fill: var(--field); }
.brand .b1 { font-weight: 700; font-variation-settings: "SOFT" 60, "WONK" 0; }
.brand .b2 { font-weight: 350; font-variation-settings: "SOFT" 100; margin-left: 4px; }
.brand .by { font: 600 11px/1 var(--f-ui); letter-spacing: .06em; text-transform: uppercase; margin-left: 8px; opacity: .8; }
.top-right { display: flex; align-items: center; gap: 10px; }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.live i { width: 8px; height: 8px; border-radius: 50%; background: #9AA3AF; }
.live i { position: relative; }
.live.on i { background: var(--canola); }
/* the ring only scales and fades: the compositor animates it without repainting the page */
.live.on i::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: rgba(217, 211, 59, .55); animation: pulse 2.4s ease-out infinite; will-change: transform, opacity; }
@keyframes pulse { 0% { transform: scale(1); opacity: .8; } 70%, 100% { transform: scale(3); opacity: 0; } }
.units-btn { display: inline-grid; place-items: center; min-width: 40px; height: 32px; padding: 0 9px; border-radius: 999px; border: 1.5px solid currentColor; color: inherit; text-decoration: none; font-weight: 700; font-size: 13px; }
.back { color: inherit; text-decoration: none; font-weight: 600; }
body[data-tab="now"] .topbar { position: absolute; left: 0; right: 0; background: transparent; border: 0; backdrop-filter: none; -webkit-backdrop-filter: none; color: #fff; text-shadow: 0 1px 10px rgba(5, 20, 40, .35); }
body[data-tab="now"] .topbar .mark .m-h1 { fill: rgba(255,255,255,.75); } body[data-tab="now"] .topbar .mark .m-h2 { fill: #fff; }

/* ---------- hero: the photo, a live sky, the land ---------- */
.hero { position: relative; overflow: hidden; color: #fff; height: 620px; height: clamp(500px, calc(100svh - 170px), 640px); container-type: size; isolation: isolate;
  background: #23402F center / cover no-repeat;
  --a: var(--am); --r: var(--rm); --t: 37cqh;
  --fw: max(100cqw, calc((100cqh - var(--t)) / (1 - var(--r)) * var(--a)), calc(var(--t) / var(--r) * var(--a)));
  --ft: calc(var(--t) - var(--r) * var(--fw) / var(--a));
  --ic-cloud: #fff; --ic-cloud-edge: rgba(255,255,255,.9); --ic-cloud2: #E6ECF1; --ic-cloud2-edge: #E6ECF1; --ic-storm: #C9D1DC; --ic-storm-edge: #C9D1DC; --ic-snow: #fff; --ic-moon-edge: #F1DB98; }
.scene { position: absolute; inset: 0; z-index: -1; }
.hero::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 170px; z-index: 1; pointer-events: none; opacity: .5; transition: opacity 1.5s;
  background: linear-gradient(180deg, rgba(10, 24, 40, .55), rgba(10, 24, 40, 0)); }
.hero:is(.fam-snow, .fam-fog, .fam-cloudy) { --scrim: 1; }
.hero:is(.fam-snow, .fam-fog, .fam-cloudy)::before { opacity: 1; }
.scene .frame { position: absolute; left: 50%; top: var(--ft); width: var(--fw); aspect-ratio: var(--a); transform: translateX(-50%); }
.scene .ph, .scene .ph img { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.ph-sky img { transition: opacity 1.5s, filter 1.5s; }
.ph-forest img { transition: filter 1.5s; filter: brightness(var(--lbt, 1)) brightness(var(--lbw, 1)) saturate(var(--lsw, 1)) contrast(var(--lc, 1)); }
.ph-land img { transition: filter 1.5s;
  filter: brightness(var(--lbt, 1)) brightness(var(--lbw, 1)) brightness(var(--lbs, 1)) saturate(var(--ls, 1)) saturate(var(--lsw, 1)) sepia(var(--lse, 0)) saturate(var(--ls2, 1)) hue-rotate(var(--lh, 0deg)) contrast(var(--lc, 1)) contrast(var(--lcs, 1)); }
/* everything that lives in the sky stops at the ridge */
.sky-tint, .stars, .clouds, .sun-glow { position: absolute; left: 0; right: 0; top: 0; height: calc(var(--t) + 4cqh); pointer-events: none; }
.sky-tint { opacity: 0; transition: opacity 1.5s, background 1.5s; }
.sun-glow { opacity: 0; }
.sun-up:is(.t-day, .t-sunrise, .t-sunset):is(.fam-clear, .fam-partly) .sun-glow { opacity: 1; }
.sun-up:is(.t-day, .t-sunrise, .t-sunset):is(.fam-cloudy, .fam-fog) .sun-glow { opacity: .3; }
.sun-glow::before { content: ""; position: absolute; left: calc(var(--sxf) * 100%); top: calc(var(--syf) * 100%); width: 300px; height: 300px; margin: -150px 0 0 -150px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 249, 225, .9) 0, rgba(255, 238, 190, .38) 12%, rgba(255, 230, 170, .1) 32%, rgba(255, 230, 170, 0) 60%); }
.lights i { position: absolute; left: var(--x); top: var(--my); width: calc(4px * var(--s) + 2px); height: calc(4px * var(--s) + 2px); border-radius: 50%; transform: translate(-50%, -50%);
  background: #FFD98A; box-shadow: 0 0 5px 2px rgba(255, 196, 96, .75), 0 0 16px 6px rgba(255, 170, 70, .25); opacity: 0; transition: opacity 2s; }
.t-night .lights i { opacity: .95; }
.t-dusk .lights i, .t-dawn .lights i { opacity: .55; }

/* time of day */
.t-sunrise .ph-sky img, .t-sunset .ph-sky img { filter: saturate(.75) brightness(.9); }
.t-sunrise .sky-tint { opacity: 1; background: linear-gradient(180deg, rgba(46, 70, 150, .3) 0%, rgba(214, 140, 170, .3) 42%, rgba(255, 184, 130, .72) 82%, rgba(255, 218, 160, .9) 100%); }
.t-sunset .sky-tint { opacity: 1; background: linear-gradient(180deg, rgba(36, 50, 118, .38) 0%, rgba(160, 96, 140, .3) 36%, rgba(255, 138, 72, .62) 74%, rgba(255, 182, 96, .92) 100%); }
.t-sunrise { --lbt: .86; }
.t-sunset { --lbt: .8; }
.t-sunrise .sun-glow::before, .t-sunset .sun-glow::before { width: 560px; height: 560px; margin: -280px 0 0 -280px;
  background: radial-gradient(circle, rgba(255, 240, 200, 1) 0, rgba(255, 200, 120, .6) 8%, rgba(255, 156, 84, .22) 28%, rgba(255, 140, 70, 0) 60%); }
.t-sunrise .haze, .t-sunset .haze { mix-blend-mode: screen; background: linear-gradient(180deg, transparent calc(var(--t) - 2cqh), rgba(255, 150, 70, .26) calc(var(--t) + 3cqh), rgba(255, 150, 70, 0) 72%); }
.t-dawn .sky-tint, .t-dusk .sky-tint { opacity: 1; background: linear-gradient(180deg, #152247 0%, #3D4581 38%, #946C93 70%, #E3A487 100%); }
.t-dawn .ph-sky img, .t-dusk .ph-sky img { opacity: .2; filter: saturate(.4); }
.t-dawn, .t-dusk { --lbt: .5; --lc: 1.05; }
.t-night .sky-tint { opacity: 1; background: linear-gradient(180deg, #030716 0%, #0A1631 55%, #1C2D52 100%); }
.t-night .ph-sky img { opacity: 0; }
.t-night { --lbt: .3; --lsw: .55; --lc: 1.1; }
/* moonlight: a cool lift on the fields */
.t-night .haze { mix-blend-mode: screen; background: linear-gradient(180deg, transparent calc(var(--t) - 2cqh), rgba(40, 62, 120, .5) calc(var(--t) + 2cqh), rgba(26, 40, 84, .32) 70%, rgba(20, 30, 60, .2)); }
.stars { opacity: 0;
  background-image: radial-gradient(circle, #fff .9px, transparent 1.5px), radial-gradient(circle, rgba(255,255,255,.85) .7px, transparent 1.2px), radial-gradient(circle, rgba(255,255,255,.6) .5px, transparent 1px), radial-gradient(circle, rgba(255,246,220,.9) 1.1px, transparent 1.8px), radial-gradient(circle, rgba(255,255,255,.5) .5px, transparent 1px);
  background-size: 131px 113px, 73px 61px, 41px 37px, 211px 173px, 29px 31px; background-position: 11px 7px, 37px 29px, 5px 17px, 80px 60px, 13px 3px;
  mask-image: linear-gradient(#000 45%, rgba(0,0,0,.4) 85%, transparent); -webkit-mask-image: linear-gradient(#000 45%, rgba(0,0,0,.4) 85%, transparent); }
.t-night:is(.fam-clear, .fam-partly) .stars { opacity: 1; animation: twinkle 6s ease-in-out infinite alternate; }
.t-dusk.fam-clear .stars, .t-dawn.fam-clear .stars { opacity: .35; }
@keyframes twinkle { from { opacity: .7; } to { opacity: 1; } }

/* weather */
.clouds i { position: absolute; display: block; opacity: 0; width: 300px; height: 104px; filter: blur(2.5px); transition: opacity 1.5s;
  --c: 255, 255, 255; --cs: 222, 230, 238;
  background: radial-gradient(closest-side, rgba(var(--c), .96), rgba(var(--c), 0)) 4% 78% / 42% 62% no-repeat,
    radial-gradient(closest-side, rgba(var(--c), .98), rgba(var(--c), 0)) 34% 22% / 44% 96% no-repeat,
    radial-gradient(closest-side, rgba(var(--c), .95), rgba(var(--c), 0)) 66% 40% / 40% 80% no-repeat,
    radial-gradient(closest-side, rgba(var(--c), .9), rgba(var(--c), 0)) 96% 80% / 34% 56% no-repeat,
    radial-gradient(closest-side, rgba(var(--cs), .9), rgba(var(--cs), 0)) 50% 100% / 92% 46% no-repeat;
  animation: drift 150s linear infinite; }
.clouds i:nth-child(1) { top: 12%; left: -20%; } .clouds i:nth-child(2) { top: 40%; left: 30%; animation-duration: 190s; animation-delay: -70s; transform: scale(.7); } .clouds i:nth-child(3) { top: 2%; left: 70%; animation-duration: 230s; animation-delay: -130s; transform: scale(1.25) scaleX(-1); }
.clouds i { animation-play-state: paused; }
.fam-partly .clouds i { opacity: .9; }
:is(.fam-partly, .fam-cloudy, .fam-rain, .fam-storm, .fam-snow) .clouds i { animation-play-state: running; }
:is(.t-sunrise, .t-sunset) .clouds i { --c: 255, 214, 186; --cs: 190, 132, 140; }
:is(.fam-cloudy, .fam-rain, .fam-storm, .fam-snow) .clouds i { opacity: .4; filter: blur(10px); --c: 236, 240, 245; --cs: 200, 208, 218; }
:is(.t-night, .t-dusk, .t-dawn) .clouds i { --c: 70, 82, 110; --cs: 40, 48, 70; }
:is(.t-night, .t-dusk, .t-dawn).fam-partly .clouds i { opacity: .55; }
@keyframes drift { from { translate: -40vw 0; } to { translate: 140vw 0; } }
.fam-cloudy .ph-sky img { filter: grayscale(.85) brightness(1.06); }
.fam-cloudy .sky-tint { opacity: .78; background: linear-gradient(180deg, #7F8E9D 0%, #A9B5C0 60%, #CBD2D8 100%); }
.fam-cloudy { --lbw: .86; --lsw: .8; }
.fam-rain .ph-sky img, .fam-storm .ph-sky img { filter: grayscale(1) brightness(.9); }
.fam-rain .sky-tint { opacity: .9; background: linear-gradient(180deg, #4F5C6D 0%, #758396 55%, #9AA6B3 100%); }
.fam-rain { --lbw: .72; --lsw: .72; }
.fam-storm .sky-tint { opacity: .95; background: linear-gradient(180deg, #232A37 0%, #3F4859 55%, #687384 100%); }
.fam-storm { --lbw: .55; --lsw: .7; }
.fam-snow .ph-sky img { filter: grayscale(1) brightness(1.1); }
.fam-snow .sky-tint { opacity: .88; background: linear-gradient(180deg, #9EAAB7 0%, #C7CFD8 60%, #E6EAEE 100%); }
.fam-snow { --lbw: 1.05; --lsw: .45; }
.fam-fog .sky-tint { opacity: .85; background: linear-gradient(180deg, #B8C0C6 0%, #D5DADD 100%); }
.fam-fog { --lsw: .55; --lbw: 1.02; }
:is(.t-night, .t-dusk, .t-dawn):is(.fam-cloudy, .fam-rain, .fam-storm, .fam-snow, .fam-fog) .sky-tint { opacity: 1; background: linear-gradient(180deg, #0F131A 0%, #1F252F 55%, #313945 100%); }
.wx, .haze, .bolt { position: absolute; inset: 0; pointer-events: none; }
.fam-rain .wx, .fam-storm .wx { background-image: repeating-linear-gradient(104deg, rgba(220, 232, 248, 0) 0 11px, rgba(220, 232, 248, .34) 11px 12px, rgba(220, 232, 248, 0) 12px 23px); background-size: 100% 46px; animation: rain .55s linear infinite;
  mask-image: linear-gradient(transparent, #000 20%, #000 80%, transparent); -webkit-mask-image: linear-gradient(transparent, #000 20%, #000 80%, transparent); }
@keyframes rain { from { background-position: 0 0; } to { background-position: -12px 46px; } }
.fam-snow .wx { background-image: radial-gradient(circle, #fff 2px, transparent 2.6px), radial-gradient(circle, rgba(255,255,255,.9) 1.4px, transparent 2px), radial-gradient(circle, rgba(255,255,255,.75) 1px, transparent 1.5px), radial-gradient(circle, rgba(255,255,255,.6) .8px, transparent 1.2px);
  background-size: 131px 149px, 89px 97px, 53px 61px, 37px 41px; background-position: 17px 23px, 61px 5px, 9px 37px, 23px 11px; animation: snow 14s linear infinite; }
@keyframes snow { from { background-position: 17px 23px, 61px 5px, 9px 37px, 23px 11px; } to { background-position: 148px 619px, 150px 684px, 62px 525px, 60px 421px; } }
.fam-fog .haze { background: linear-gradient(180deg, transparent 0, transparent calc(var(--t) - 8cqh), rgba(232, 236, 238, .8) calc(var(--t) + 6cqh), rgba(232, 236, 238, .35) 85%, rgba(232, 236, 238, .2)); }
.fam-snow .haze { background: linear-gradient(180deg, transparent calc(var(--t) - 2cqh), rgba(240, 244, 248, .35) calc(var(--t) + 8cqh), rgba(240, 244, 248, .15)); }
:is(.t-night, .t-dusk, .t-dawn):is(.fam-fog, .fam-snow) .haze { opacity: .3; }
.bolt { background: #fff; opacity: 0; }
.bolt.on { animation: bolt 1.1s ease-out; }
@keyframes bolt { 0% { opacity: 0; } 6% { opacity: .7; } 12% { opacity: .1; } 18% { opacity: .5; } 100% { opacity: 0; } }

/* the season colours the fields (the photo is a late-June evening; Moscow Mountain stays dark) */
.season-spring { --lbs: 1.08; --ls: 1.25; --lh: 6deg; }
.season-harvest { --lbs: 1.25; --ls: .8; --lse: .85; --ls2: 2.4; --lh: -8deg; --lcs: .95; }
.season-fall { --lbs: 1.3; --ls: .6; --lse: .9; --ls2: 1.8; --lh: -4deg; }
.season-late-fall { --lbs: 1.05; --ls: .5; --lse: .6; --ls2: 1.2; --lh: -14deg; }
.season-winter { --lbs: 1.3; --ls: .2; --lse: .1; --lcs: .85; }

/* text on the hero */
.hero-top { position: relative; z-index: 2; max-width: 800px; margin: 0 auto; padding: calc(env(safe-area-inset-top) + 66px) 20px 0; }
.place { margin: 0; font-weight: 700; font-size: 15px; letter-spacing: .02em; text-shadow: 0 1px 12px rgba(5, 20, 40, .35); }
.place .elev { font-weight: 500; opacity: .85; }
.hero-in { position: absolute; z-index: 2; left: 0; right: 0; bottom: 34px; max-width: 800px; margin: 0 auto; padding: 0 20px; display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; text-shadow: 0 2px 18px rgba(0, 12, 6, .45); }
.hero::after { content: ""; position: absolute; inset: auto 0 0 0; height: 46%; z-index: 1; background: linear-gradient(180deg, rgba(4, 16, 10, 0), rgba(4, 16, 10, .45)); pointer-events: none; }
.temp { margin: 0; font-family: var(--f-display); font-weight: 300; font-size: clamp(110px, 33vw, 168px); line-height: .82; letter-spacing: -.045em; font-variation-settings: "SOFT" 100, "WONK" 0, "opsz" 144; display: flex; align-items: flex-start; }
.temp .deg { font-size: .45em; font-weight: 300; margin: .04em 0 0 .02em; color: var(--canola); }
.temp.waiting { opacity: .6; }
.hero-side { padding-bottom: 6px; }
.cond { display: flex; align-items: center; gap: 8px; margin: 0; font-family: var(--f-display); font-size: 26px; font-weight: 500; font-variation-settings: "SOFT" 80; letter-spacing: -.01em; line-height: 1.1; }
.cond-ic { display: inline-flex; filter: drop-shadow(0 2px 6px rgba(0, 10, 20, .3)); }
.hilo { display: flex; flex-wrap: wrap; gap: 2px 12px; margin: 6px 0 0; font-size: 15px; font-weight: 500; opacity: .95; }
.hilo b { font-weight: 800; }
.fold { position: absolute; z-index: 3; left: 0; right: 0; bottom: -1px; width: 100%; height: 26px; display: block; }
.fold path { fill: var(--bg); }

/* ---------- story, banners, nudge ---------- */
.story { margin: 4px 0 16px; }
.story ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; }
.story li { font-size: 16.5px; line-height: 1.4; padding-left: 20px; position: relative; color: var(--ink-2); }
.story li::before { content: ""; position: absolute; left: 2px; top: .52em; width: 9px; height: 9px; border-radius: 50%; background: var(--field-2); }
.story li:first-child { color: var(--ink); font-weight: 700; }
.story li:first-child::before { background: var(--canola); box-shadow: 0 0 0 2px color-mix(in srgb, var(--canola) 35%, transparent); }
.announce { margin: 0 0 12px; padding: 12px 14px; border-radius: 14px; background: color-mix(in srgb, var(--canola) 22%, var(--surface)); border: 1px solid color-mix(in srgb, var(--canola) 55%, transparent); }
.announce.warn { background: color-mix(in srgb, var(--sev-watch) 14%, var(--surface)); border-color: color-mix(in srgb, var(--sev-watch) 40%, transparent); }
.announce p { margin: 0; }
.alert-banners { display: grid; gap: 8px; margin: 0 0 14px; }
.alert-banner { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; text-decoration: none; color: var(--ink); background: var(--surface); box-shadow: var(--shadow); border: 1px solid var(--line); border-left: 6px solid var(--sev-statement); }
.alert-banner b { display: block; font-size: 16px; }
.alert-banner small { color: var(--muted); }
.alert-banner .chev, .nudge .chev { margin-left: auto; font-style: normal; font-size: 24px; color: var(--muted); }
.lv-warning { border-left-color: var(--sev-warning) !important; } .lv-watch { border-left-color: var(--sev-watch) !important; }
.lv-advisory { border-left-color: var(--sev-advisory) !important; } .lv-statement { border-left-color: var(--sev-statement) !important; }
.nudge { display: flex; align-items: center; gap: 12px; margin: 0 0 16px; padding: 13px 15px; border-radius: 16px; text-decoration: none; color: #F4F3E8; background: linear-gradient(115deg, #13283A 0%, #1E3A4A 55%, #2E5232 130%); box-shadow: var(--shadow); }
.nudge b { display: block; font-family: var(--f-display); font-weight: 600; font-size: 17px; } .nudge small { opacity: .8; }
.nudge .chev { color: var(--canola); }
.nudge-ic svg { width: 26px; height: 26px; stroke: var(--canola); stroke-width: 1.8; fill: var(--canola); }
.nudge-ic svg path { fill: none; }

/* ---------- cards ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; margin: 0 0 14px; }
.card-h { margin: 0 0 10px; font-size: 20px; font-weight: 600; font-variation-settings: "SOFT" 50; display: flex; align-items: center; gap: 8px; }
.card-h svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.card-hrow { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 4px; }
.card-hrow .card-h { margin: 0; }

/* Next 48 hours */
.hourly { padding: 16px 0 12px; }
.hourly .card-h { padding: 0 16px; }
.hscroll { overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: thin; padding: 0 8px 4px; scroll-snap-type: x proximity; }
.hgrid { display: grid; grid-template-columns: repeat(var(--n), var(--cw)); grid-template-rows: auto 54px 40px 34px; width: max-content; }
.hc { grid-row: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 2px 0; scroll-snap-align: start; position: relative; }
.hc.newday::before { content: ""; position: absolute; left: 0; top: 0; bottom: -128px; border-left: 1px dashed var(--line); }
.h-time { font-size: 12.5px; color: var(--muted); font-weight: 600; white-space: nowrap; }
.h-time.strong { color: var(--field); font-weight: 800; }
.hc:first-child .h-time { color: var(--ink); font-weight: 800; }
.h-temp { font-family: var(--f-display); font-weight: 600; font-size: 18px; }
.hc.is-hi .h-temp { color: var(--c-temp); } .hc.is-lo .h-temp { color: var(--c-rain); }
.h-curve { grid-row: 2; grid-column: 1 / -1; display: block; }
.h-line { fill: none; stroke: var(--c-temp); stroke-width: 2; stroke-linecap: round; }
.h-area { fill: var(--c-temp); opacity: .1; }
.h-pop { grid-row: 3; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 2px; }
.h-pop i { width: 16px; background: var(--c-rain); border-radius: 4px 4px 0 0; opacity: .85; }
.h-pop span { font-size: 11px; color: var(--c-rain); font-weight: 700; min-height: 13px; }
.h-wind { grid-row: 4; display: flex; align-items: center; justify-content: center; gap: 3px; font-size: 12px; color: var(--muted); }
.arr { display: inline-block; width: 10px; height: 10px; transform: rotate(var(--d)); background: currentColor; clip-path: polygon(50% 0, 100% 100%, 50% 75%, 0 100%); }
.hkey { display: flex; gap: 16px; padding: 4px 16px 0; margin: 0; font-size: 12px; color: var(--muted); }
.hkey span { display: inline-flex; align-items: center; gap: 6px; }
.k-pop { display: inline-block; width: 10px; height: 10px; border-radius: 3px 3px 0 0; background: var(--c-rain); }

/* Conditions tiles */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0 0 14px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px; min-height: 168px; display: flex; flex-direction: column; position: relative; overflow: hidden; }
.tile h3 { margin: 0 0 6px; font: 800 11px/1.2 var(--f-ui); text-transform: uppercase; letter-spacing: .13em; color: var(--field); display: flex; align-items: center; gap: 6px; }
.tile h3::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--canola); }
.tile .big { margin: 2px 0 2px; font-family: var(--f-display); font-size: 38px; font-weight: 500; line-height: 1.02; letter-spacing: -.02em; font-variation-settings: "SOFT" 70, "opsz" 72; }
.tile .big small { font: 600 14px var(--f-ui); color: var(--muted); letter-spacing: 0; }
.tile .sub { margin: 4px 0 0; font-size: 13.5px; color: var(--ink-2); }
.tile .fine { margin-top: auto; padding-top: 6px; font-size: 11px; }
.tile .mini { margin: auto 0 0; padding-top: 8px; display: grid; gap: 2px; font-size: 13px; }
.tile .mini div { display: flex; justify-content: space-between; gap: 6px; }
.tile .mini dt { color: var(--muted); } .tile .mini dd { margin: 0; font-weight: 700; }
.tile.rain.is-raining { background: linear-gradient(180deg, color-mix(in srgb, var(--c-rain) 12%, var(--surface)), var(--surface)); }
.tile.ltg.is-active { background: linear-gradient(180deg, color-mix(in srgb, var(--canola) 30%, var(--surface)), var(--surface)); }
.tile.is-model .big { color: var(--ink-2); }

.compass { position: relative; width: 122px; max-width: 100%; aspect-ratio: 1; margin: 2px auto 4px; }
.compass svg { width: 100%; height: 100%; display: block; overflow: visible; }
.compass .ticks line { stroke: var(--line); stroke-width: 1.6; stroke-linecap: round; } .compass .ticks line.major { stroke: var(--muted); stroke-width: 2; }
.compass text { font: 800 8.5px var(--f-ui); fill: var(--muted); text-anchor: middle; } .compass .nlab { fill: var(--barn); }
.compass .needle { transform-origin: 50px 50px; transform: rotate(var(--dir)); transition: transform 1.6s cubic-bezier(.25, .8, .3, 1); }
.compass .shaft { stroke: var(--c-wind); stroke-width: 1.6; stroke-dasharray: 2 3; opacity: .5; }
.compass .head { fill: var(--c-wind); } .compass .tail { fill: var(--c-wind); opacity: .55; }
.compass-c { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; line-height: 1; }
.compass-c b { font: 500 28px var(--f-display); letter-spacing: -.02em; }
.compass-c span { font-size: 11px; color: var(--muted); font-weight: 600; }

.spark { position: relative; height: 34px; margin-top: auto; }
.spark svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.spark path { fill: none; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linecap: round; stroke-linejoin: round; }
.spark .dot { position: absolute; width: 8px; height: 8px; border-radius: 50%; transform: translate(-50%, -50%); box-shadow: 0 0 0 2px var(--surface); }

.sunarc { width: 100%; max-width: 160px; display: block; margin: 0 auto; overflow: visible; }
.sunarc .arc { fill: none; stroke: var(--line); stroke-width: 1.6; stroke-dasharray: 3 3; }
.sunarc .arc-done { fill: none; stroke: var(--ic-sun); stroke-width: 2.2; }
.sunarc .horizon { stroke: var(--field-2); stroke-width: 1.4; }
.sunarc .sun-dot { fill: var(--ic-sun); stroke: var(--surface); stroke-width: 2; }
.sunrow { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 2px 10px; margin: 4px 0 0; font-weight: 700; font-size: 13.5px; }
.moonrow { display: flex; align-items: center; gap: 10px; margin: auto 0 0; padding-top: 10px; border-top: 1px solid var(--line-2); }
.moonrow p { margin: 0; font-size: 13.5px; line-height: 1.3; }
.moon-dark { fill: color-mix(in srgb, var(--ink) 14%, var(--surface)); }
.moon-lit { fill: #F3E1A6; }
@media (prefers-color-scheme: dark) { .moon-dark { fill: #2A3B37; } .moon-lit { fill: #F4E5B2; } }

.uv-meter, .aq-meter { position: relative; height: 8px; border-radius: 4px; margin: 8px 0 4px; }
.uv-meter { background: linear-gradient(90deg, #6CB94A 0 27%, #E8D23B 27% 54%, #EE9A2B 54% 73%, #D9493A 73% 91%, #8E52AE 91%); }
.aq-meter { display: grid; grid-template-columns: 50fr 50fr 50fr 50fr 100fr; }
.aq-meter i:nth-child(6) { display: none; }
.aq-meter i { display: block; height: 8px; } .aq-meter i:first-child { border-radius: 4px 0 0 4px; } .aq-meter i:nth-child(5) { border-radius: 0 4px 4px 0; }
.aq1 { background: #5CB65A; } .aq2 { background: #E6CF3A; } .aq3 { background: #EE8A2B; } .aq4 { background: #D9473A; } .aq5 { background: #8A4CA6; } .aq6 { background: #7E2335; }
.uv-meter b, .aq-meter b { position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; background: var(--surface); border: 3px solid var(--ink); }

/* Past 24 hours */
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line-2); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; color: var(--muted); font: 700 13px var(--f-ui); padding: 6px 12px; border-radius: 999px; cursor: pointer; }
.seg button[aria-selected="true"] { background: var(--ink); color: var(--bg); }
.seg-panels > [data-segp]:not(.on) { display: none; }
.chart { margin: 0; }
.chart .plot { position: relative; height: var(--h, 160px); margin: 22px 46px 28px 36px; }
.chart .plot > svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.chart .grid { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart .line { fill: none; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { opacity: .1; }
.chart .ytick { position: absolute; right: calc(100% + 7px); transform: translateY(-50%); font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.chart .xtick { position: absolute; top: calc(100% + 7px); transform: translateX(-50%); font-size: 11px; color: var(--muted); white-space: nowrap; }
.chart .dl { position: absolute; transform: translate(-50%, -150%); font-size: 12px; font-weight: 700; color: var(--ink-2); white-space: nowrap; pointer-events: none; }
.chart .dl.lo { transform: translate(-50%, 45%); }
.chart .dl.lo.up { transform: translate(-50%, -150%); }
.chart .dl.now { left: calc(100% + 9px); transform: translateY(-50%); color: var(--ink); font-weight: 800; }
.chart .dot { position: absolute; width: 9px; height: 9px; border-radius: 50%; transform: translate(-50%, -50%); box-shadow: 0 0 0 2px var(--surface); pointer-events: none; }
.chart .xhair { position: absolute; top: 0; bottom: 0; width: 1px; background: var(--ink-2); opacity: .35; pointer-events: none; }
.chart .tip { position: absolute; top: -10px; transform: translate(-50%, -100%); background: var(--ink); color: var(--bg); border-radius: 8px; padding: 4px 8px; font-size: 12px; white-space: nowrap; pointer-events: none; z-index: 2; }
.chart .tip b { font-size: 14px; }
.line-chart .plot { touch-action: pan-y; cursor: crosshair; }
.col-chart .col { position: absolute; bottom: 0; border-radius: 4px 4px 0 0; }
.chart-cap { font-size: 13px; color: var(--muted); margin: -8px 0 0; text-align: center; }
.chart-empty { color: var(--muted); font-size: 14px; padding: 30px 0; text-align: center; }

/* Almanac: like the back pages of an old farm almanac */
.alm-cols { display: grid; gap: 14px; }
.alm { margin: 0; }
.alm h3 { margin: 0 0 6px; font: 800 11px/1.2 var(--f-ui); text-transform: uppercase; letter-spacing: .13em; color: var(--field); }
.alm h3 small { text-transform: none; letter-spacing: 0; font-weight: 500; color: var(--muted); }
.alm-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 7px 0; border-bottom: 1px dotted var(--line); }
.alm-row:last-child { border: 0; }
.alm-row dt { color: var(--ink-2); } .alm-row dd { margin: 0; font-family: var(--f-display); font-weight: 600; font-size: 17px; text-align: right; }
.alm-row dd small { font-family: var(--f-ui); font-size: 12.5px; font-weight: 500; color: var(--muted); }

/* 10-day */
.mini-now { display: flex; align-items: center; gap: 10px; margin: 14px 0; font-size: 15px; }
.mini-now b { font: 500 30px var(--f-display); letter-spacing: -.02em; }
.mini-now .muted { margin-left: auto; font-size: 13px; }
.days { list-style: none; margin: 0; padding: 0; }
.day { border-bottom: 1px solid var(--line-2); }
.day:last-child { border: 0; }
.day summary { list-style: none; display: grid; grid-template-columns: 58px 36px 50px 34px 1fr 36px; align-items: center; gap: 8px; padding: 9px 2px; cursor: pointer; }
.day summary::-webkit-details-marker { display: none; }
.d-name { font-weight: 800; }
.day.today .d-name { color: var(--field); }
.d-ic { display: flex; }
.d-pop { display: inline-flex; align-items: center; gap: 2px; font-size: 12.5px; color: var(--c-rain); font-weight: 700; }
.d-lo { color: var(--muted); text-align: right; font-family: var(--f-display); font-size: 17px; }
.d-hi { font-family: var(--f-display); font-weight: 600; font-size: 17px; }
.range { position: relative; height: 7px; border-radius: 4px; background: var(--surface-2); }
.range i { position: absolute; top: 0; bottom: 0; border-radius: 4px; }
.range b { position: absolute; top: 50%; width: 11px; height: 11px; margin: -5.5px 0 0 -5.5px; border-radius: 50%; background: var(--surface); border: 2.5px solid var(--ink); }
.d-detail { padding: 0 4px 12px; font-size: 14px; }
.d-detail p { margin: 0 0 8px; }
.d-hours { display: flex; gap: 6px; overflow-x: auto; padding: 4px 0 8px; }
.d-hours div { flex: 0 0 auto; min-width: 50px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 4px; border-radius: 10px; background: var(--surface-2); font-size: 12px; }
.d-hours b { font-size: 14px; } .d-hours small { color: var(--c-rain); font-weight: 700; min-height: 14px; }

/* Forecasters' notes */
.afd h3 { margin: 14px 0 4px; font-size: 16px; }
.afd p, .afd li { font-size: 14.5px; color: var(--ink-2); }
.afd ul { padding-left: 18px; }
details.more summary { cursor: pointer; color: var(--accent); font-weight: 700; margin: 8px 0; }

/* Radar */
.radar-wrap { position: relative; margin: 14px 0; }
.radar-map { height: calc(100svh - var(--tabbar) - 150px); min-height: 380px; border-radius: var(--radius); overflow: hidden; background: var(--surface-2); box-shadow: var(--shadow); border: 1px solid var(--line); }
.radar-ui { position: absolute; left: 12px; right: 12px; bottom: 48px; max-width: 560px; margin: 0 auto; display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 999px; background: var(--surface); box-shadow: var(--shadow); z-index: 2; }
.r-play { border: 0; width: 34px; height: 34px; border-radius: 50%; background: var(--ink); color: var(--canola); font-size: 14px; cursor: pointer; flex: 0 0 auto; }
.radar-ui input[type=range] { flex: 1; accent-color: var(--field-2); }
.r-time { font-weight: 700; font-size: 13px; min-width: 76px; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.radar-legend { position: absolute; top: 12px; left: 12px; z-index: 2; display: flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; font-size: 11px; font-weight: 600; background: color-mix(in srgb, var(--surface) 90%, transparent); }
.radar-legend i { width: 90px; height: 7px; border-radius: 4px; background: linear-gradient(90deg, #50C878, #2E8B57, #F4D03F, #F39C12, #E74C3C, #C0398E); }
.radar-note { margin: 8px 4px 0; }

/* Alerts tab */
.no-alerts .ok-row { display: flex; gap: 14px; align-items: center; }
.ok-ic { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--field-2) 18%, var(--surface)); color: var(--field); font-weight: 900; font-size: 20px; }
.no-alerts .card-h { margin: 0; } .no-alerts p { margin: 2px 0 0; }
.alert { border-left: 6px solid var(--sev-statement); }
.alert h2 { display: flex; gap: 8px; align-items: center; margin: 0 0 4px; font-size: 19px; }
.more-link { font-weight: 700; text-decoration: none; }
.notify .steps { padding-left: 20px; } .notify .steps li { margin: 6px 0; }
.notify .steps svg { width: 20px; height: 20px; vertical-align: -4px; fill: none; stroke: var(--accent); stroke-width: 1.8; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 0 18px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 700 14.5px var(--f-ui); cursor: pointer; text-decoration: none; }
.btn.primary { background: var(--ink); border-color: var(--ink); color: var(--canola); }
.btn.ghost { background: transparent; }
.btn.small { min-height: 32px; padding: 0 12px; font-size: 13px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; }
.notify [data-ns="off"] { margin-bottom: 18px; }
.prefs fieldset { border: 0; margin: 0 0 14px; padding: 0; }
.prefs legend { font: 800 11px/1.2 var(--f-ui); text-transform: uppercase; letter-spacing: .13em; color: var(--field); margin: 0 0 4px; padding: 0; }
.prefs .row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.prefs .row > span { font-size: 15px; } .prefs .row small { display: block; color: var(--muted); font-size: 12.5px; }
.prefs select, .prefs input[type=time] { font: 600 14px var(--f-ui); color: var(--ink); background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 7px 8px; }
.sw input { appearance: none; -webkit-appearance: none; flex: 0 0 auto; width: 48px; height: 28px; border-radius: 999px; background: var(--line); position: relative; cursor: pointer; transition: background .2s; margin: 0; }
.sw input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.sw input:checked { background: var(--field-2); } .sw input:checked::after { transform: translateX(20px); }
.saved { min-height: 18px; margin: 4px 0 0; font-size: 13px; color: var(--ok); font-weight: 600; }
.ok-line { color: var(--ok); font-weight: 700; margin: 0 0 6px; }
.ltg-list { list-style: none; margin: 8px 0 0; padding: 0; }
.ltg-list li { display: grid; grid-template-columns: 1fr 1fr auto; gap: 8px; padding: 7px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; }

/* ---------- tab bar: the skyline from the photo along its top ---------- */
.tabs { position: fixed; z-index: 40; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(4, 1fr); height: calc(var(--tabbar) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: var(--tab-bg); }
.tabs .ridge { position: absolute; left: 0; right: 0; bottom: calc(100% - 1px); width: 100%; height: 13px; display: block; pointer-events: none; }
.tabs .ridge path { fill: var(--tab-bg); }
.tabs a { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-decoration: none; color: #A9B6BF; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; }
.tabs svg:not(.ridge) { width: 25px; height: 25px; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; fill: currentColor; }
.tabs svg:not(.ridge) path, .tabs svg:not(.ridge) rect { fill: none; }
.tabs a.active { color: #F4F3E8; }
.tabs a.active::after { content: ""; position: absolute; top: 7px; width: 22px; height: 3px; border-radius: 2px; background: var(--canola); }
.badge { position: absolute; top: 9px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--barn); color: #fff; font-size: 11px; line-height: 18px; text-align: center; }
/* Panels: CSS alone shows the one in the address (#forecast…), Now by default; JS then takes over. */
.panel { display: none; scroll-margin-top: 400px; }
/* without JavaScript, the links jump to sections; with it, only the active tab shows */
body:not(.js) #now.panel, body:not(.js) .panel:target { display: block; }
body:not(.js) main:has(.panel:target:not(#now)) #now.panel { display: none; }
body.js .panel.active { display: block; }

/* ---------- footer ---------- */
.foot { max-width: 800px; margin: 30px auto 0; padding: 0 18px 24px; font-size: 12.5px; color: var(--muted); }
.foot a { color: inherit; }
.foot-brand { color: var(--ink-2); font-size: 14px; font-family: var(--f-display); }
.foot-links { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.foot-links a { color: var(--field); font-weight: 700; text-decoration: none; }
.sim-note { color: var(--sev-watch); }
.ver { opacity: .6; font-size: 11px; }

/* ---------- sub pages, admin ---------- */
.page-main { padding-top: 18px; padding-bottom: 40px; }
.topbar.solid { position: sticky; }
.prose h1 { font-size: 30px; margin: 4px 0 12px; } .prose h2 { font-size: 20px; margin: 22px 0 6px; }
.prose p, .prose li { color: var(--ink-2); }
.photo-band { position: relative; margin: -16px -16px 18px; height: 180px; border-radius: var(--radius) var(--radius) 0 0; overflow: hidden; background: #2B4733; }
.photo-band figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 16px 9px; color: #fff; font-size: 12.5px; font-weight: 600; line-height: 1.35; text-shadow: 0 1px 6px rgba(0, 10, 6, .5); background: linear-gradient(180deg, rgba(6, 18, 12, 0), rgba(6, 18, 12, .6)); }
.photo-band img { width: 100%; height: 100%; object-fit: cover; object-position: center 40%; display: block; }
@media (min-width: 700px) { .photo-band { height: 240px; } }
.alert-full h1 { display: flex; gap: 10px; align-items: center; font-size: 26px; margin: 0 0 10px; }
.alert-full { border-left: 6px solid var(--sev-statement); }
.alert-meta { display: grid; gap: 6px; margin: 0 0 14px; } .alert-meta div { display: flex; gap: 10px; } .alert-meta dt { color: var(--muted); min-width: 80px; } .alert-meta dd { margin: 0; font-weight: 700; }
.lead { font-weight: 700; }
.pill { display: inline-block; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 13px; }
.code { width: 100%; min-height: 64px; font: 12px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; padding: 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); resize: vertical; margin: 4px 0 8px; }
.embed-preview { padding: 14px; border-radius: 14px; background: repeating-linear-gradient(-13deg, var(--surface-2) 0 9px, var(--bg-2) 9px 10px); margin: 8px 0; }
.builder-opts { display: flex; flex-wrap: wrap; gap: 12px; }
.builder-opts select, .stack input, .stack textarea, .stack select, .login input { font: 600 15px var(--f-ui); color: var(--ink); background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; width: 100%; }
.builder-opts label { display: grid; gap: 4px; font-size: 13px; font-weight: 700; color: var(--muted); }
.stack { display: grid; gap: 12px; } .stack label { display: grid; gap: 4px; font-size: 13px; font-weight: 700; color: var(--ink-2); }
.stack label.inline, label.inline { display: flex; align-items: center; gap: 8px; font-weight: 600; } label.inline input { width: auto; }
.stack fieldset { border: 1px solid var(--line-2); border-radius: 12px; padding: 12px; display: grid; gap: 10px; }
.stack legend { font-weight: 800; padding: 0 6px; }
.row3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.login { max-width: 380px; margin: 40px auto; display: grid; gap: 12px; }
.login h1 { margin: 0; font-size: 24px; } .login label { display: grid; gap: 4px; font-weight: 700; font-size: 13px; }
.err { color: var(--sev-warning); font-weight: 700; } .flash { padding: 10px 14px; border-radius: 12px; background: color-mix(in srgb, var(--canola) 25%, var(--surface)); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.stat-grid div { padding: 10px; border-radius: 12px; background: var(--surface-2); display: grid; gap: 2px; } .stat-grid small { color: var(--muted); }
.st.ok { color: var(--ok); font-weight: 700; } .st.bad { color: var(--sev-warning); font-weight: 700; }
.big-num { font: 500 38px var(--f-display); margin: 0; } .big-num small { font: 500 14px var(--f-ui); color: var(--muted); }
.inline-form { margin: 0; display: inline; }
.tbl { width: 100%; border-collapse: collapse; font-size: 13px; } .tbl th, .tbl td { text-align: left; padding: 7px 6px; border-bottom: 1px solid var(--line-2); vertical-align: top; } .tbl th { color: var(--muted); font-weight: 700; }

/* ---------- larger screens ---------- */
@media (min-width: 700px) {
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .alm-cols { grid-template-columns: 1fr 1fr; gap: 28px; }
  .tabs { left: 50%; right: auto; bottom: 16px; transform: translateX(-50%); width: 440px; height: 62px; padding: 0 6px; border-radius: 999px; box-shadow: 0 14px 34px rgba(5, 15, 25, .3); }
  .tabs .ridge { display: none; }
  .tabs a { flex-direction: row; gap: 7px; font-size: 13px; }
  .tabs a.active::after { top: auto; bottom: 8px; }
  .tabs svg:not(.ridge) { width: 21px; height: 21px; }
  .badge { position: static; }
  body.app { padding-bottom: 104px; }
  .day summary { grid-template-columns: 74px 40px 56px 40px 1fr 42px; }
}
@media (min-width: 900px) {
  .hero { height: clamp(480px, calc(100svh - 150px), 660px); --a: var(--ad); --r: var(--rd); --t: 50cqh; }
  .lights i { top: var(--dy); }
  .hero-in { bottom: 40px; padding: 0 24px; }
  .hero-top { padding-left: 24px; padding-right: 24px; }
}
@media (min-width: 1000px) { .radar-map { height: calc(100vh - 220px); } }
@media (prefers-reduced-motion: reduce) { .clouds i, .stars, .wx, .live.on i::after { animation: none !important; } .bolt.on { animation: none; } }
