/* American Regulators USA Storm Tracker: radar-first layout (ar-layout.js adds body.arx).
   The map owns the screen; everything else is one panel (Details, Layers, Alerts, More) that is a
   right-hand drawer on desktop (pinnable) and a bottom sheet on phones. Only one panel is open. */

body.arx{--arx-top:84px;--arx-drawer:400px;--arx-sheet:0px;--arx-overlay:0px;--arx-bg:#0b1624;--arx-panel:#101f30;--arx-line:#294057;--arx-ink:#eef5fb;--arx-muted:#a7bacb;--arx-gold:#e7a932;--arx-obs:#2f8fd8;--arx-fc:#a46be0;overflow:hidden;height:100dvh;overscroll-behavior:none}
body.arx *{scrollbar-width:thin}

/* ---------------------------------------------------------------- header: one compact row */
body.arx header.site-header{display:block;padding:0;position:relative;z-index:1300;background:#101f30;border-bottom:1px solid var(--arx-line)}
body.arx .header-brandline{display:none!important}
body.arx .arx-top{display:flex;align-items:center;gap:.6rem;min-height:52px;padding:6px 12px}
body.arx .arx-brand{display:flex;align-items:center;gap:.55rem;min-width:0;text-decoration:none;color:inherit;flex:0 1 auto}
body.arx .arx-brand .arx-badge{width:38px;height:38px;border-radius:50%;overflow:hidden;flex:none;position:relative;background:#fff}
body.arx .arx-brand .arx-badge img{position:absolute;width:59px;height:auto;left:50%;top:50%;transform:translate(-50%,-50%)}
body.arx .arx-brand h1{margin:0;display:flex;flex-direction:column;line-height:1.05;font-size:.95rem;letter-spacing:.04em;min-width:0}
body.arx .arx-brand h1 .org-name{font-size:.95rem;white-space:nowrap}
body.arx .arx-brand h1 .tracker-name{font-size:.72rem;color:#ffcc6a;letter-spacing:.12em}
body.arx .arx-chips{display:flex;align-items:center;gap:.45rem;min-width:0;flex:1 1 auto;justify-content:center}
body.arx .arx-chip{display:inline-flex;align-items:center;gap:.4rem;min-height:40px;max-width:100%;padding:.35rem .7rem;border-radius:999px;border:1px solid #45637b;background:#172d42;color:var(--arx-ink);font:inherit;font-size:.88rem;cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body.arx .arx-chip:hover{background:#244963}
body.arx .arx-chip .t{overflow:hidden;text-overflow:ellipsis}
body.arx #arx-warn[data-state="none"]{border-color:#3e7a56;background:#15301f}
body.arx #arx-warn[data-state="active"]{border-color:#ff5862;background:#4a1820;color:#ffd7da;font-weight:700}
body.arx #arx-warn[data-state="watch"]{border-color:#f2a33a;background:#3d2a10;color:#ffe2b8;font-weight:700}
body.arx #arx-warn[data-state="error"]{border-color:#9aa6b2;background:#2a3038;color:#e3e8ee}
body.arx .arx-actions{display:flex;gap:.4rem;flex:none}
body.arx .arx-btn{display:inline-flex;align-items:center;justify-content:center;gap:.35rem;min-height:44px;min-width:44px;padding:.4rem .75rem;border-radius:10px;border:1px solid #45637b;background:#172d42;color:#fff;font:inherit;font-size:.92rem;cursor:pointer;white-space:nowrap}
body.arx .arx-btn:hover{background:#244963}
body.arx .arx-btn[hidden],body.arx .arx-chip[hidden]{display:none!important}
body.arx .arx-btn[aria-expanded="true"],body.arx .arx-btn[aria-pressed="true"]{background:#1b4b55;border-color:#5fc5c1}
body.arx .arx-btn svg{width:20px;height:20px;flex:none}
body.arx .arx-btn:focus-visible,body.arx .arx-chip:focus-visible{outline:3px solid #ffc351;outline-offset:2px}
body.arx .emergency-banner{display:block;width:100%;margin:0;border:0;border-top:1px solid #983140;border-radius:0;padding:4px 12px;font-size:.86rem;line-height:1.35;text-align:center;letter-spacing:.01em}

/* ---------------------------------------------------------------- main: map + panel */
body.arx main{display:grid!important;grid-template-columns:minmax(0,1fr);height:calc(100dvh - var(--arx-top));min-height:0!important;position:relative}
body.arx.arx-pinned main{grid-template-columns:minmax(0,1fr) var(--arx-drawer)}
body.arx .map-wrap{position:relative!important;display:block!important;height:100%!important;min-height:0!important;overflow:hidden}
body.arx #map{position:absolute!important;inset:0;height:100%!important;min-height:0!important;width:100%}
body.arx .bar,body.arx .map-utility,body.arx .map-readouts,body.arx .prep-wrn{display:none!important}

/* map tools: search + My Location (top-left), Layers + fullscreen (top-right, under zoom) */
body.arx .arx-tools{position:absolute;top:10px;left:10px;right:64px;z-index:1000;display:flex;flex-direction:column;gap:8px;pointer-events:none;max-width:560px}
body.arx .arx-tools>*{pointer-events:auto}
body.arx .arx-searchrow{display:flex;gap:6px;align-items:stretch}
body.arx .arx-search{position:relative;flex:1 1 auto;min-width:0;display:flex}
body.arx .arx-search input{flex:1 1 auto;min-width:0;min-height:44px;padding:.5rem .75rem;border-radius:10px 0 0 10px;border:1px solid #45637b;border-right:0;background:#0f2233;color:#fff;font:inherit;font-size:16px}
body.arx .arx-search input::placeholder{color:#9fb3c4}
body.arx .arx-search button{min-height:44px;padding:0 .8rem;border-radius:0 10px 10px 0;border:1px solid #45637b;background:#172d42;color:#fff;font:inherit;cursor:pointer}
body.arx .arx-results{position:absolute;top:calc(100% + 4px);left:0;right:0;margin:0;padding:4px;list-style:none;background:#0f2233;border:1px solid #45637b;border-radius:10px;box-shadow:0 10px 30px #000a;max-height:min(50vh,var(--arx-results-max,320px));overflow:auto;overscroll-behavior:contain;z-index:5}
body.arx .arx-results[hidden]{display:none}
body.arx .arx-results li{padding:.65rem .7rem;border-radius:8px;cursor:pointer;min-height:44px;display:flex;flex-direction:column;justify-content:center}
body.arx .arx-results li small{color:var(--arx-muted)}
body.arx .arx-results li[aria-selected="true"],body.arx .arx-results li:hover{background:#244963}
body.arx .arx-results .arx-empty{cursor:default;color:var(--arx-muted)}
body.arx .arx-mytools{display:flex;gap:6px}
body.arx #arx-locate{background:var(--arx-gold);color:#14202c;border:0;font-weight:700}
body.arx .arx-note{background:#0f2233ee;border:1px solid #35536d;border-radius:10px;padding:.5rem .7rem;font-size:.88rem;line-height:1.4;box-shadow:0 6px 20px #0008}
body.arx .arx-note[hidden]{display:none}
body.arx .arx-note .row{display:flex;flex-wrap:wrap;align-items:center;gap:.4rem .6rem}
body.arx .arx-note button{min-height:36px;padding:.25rem .6rem;border-radius:8px;border:1px solid #45637b;background:#172d42;color:#fff;font:inherit;font-size:.85rem;cursor:pointer}
body.arx .arx-note details summary{cursor:pointer;color:#ffcc6a;margin-top:.25rem}
body.arx .arx-note .x{margin-left:auto;background:transparent;border:0;min-width:36px}
body.arx .arx-right{position:absolute;right:10px;top:110px;z-index:1000;display:flex;flex-direction:column;gap:6px;align-items:flex-end}
body.arx .leaflet-top.leaflet-right .leaflet-control-zoom{margin-top:10px;margin-right:10px}
body.arx .leaflet-control-zoom a{width:44px!important;height:44px!important;line-height:44px!important;font-size:20px}

/* first-visit and install cards float over the map instead of pushing it down */
body.arx .ar-card{position:relative;border:1px solid #35536d;border-radius:12px;background:#13283cf2;box-shadow:0 10px 30px #000a;padding:.7rem .85rem}

/* ---------------------------------------------------------------- playback bar (inside the map) */
body.arx .radar-loop-control{position:absolute!important;z-index:1000;left:12px!important;right:calc(12px + var(--arx-overlay))!important;bottom:calc(12px + var(--arx-sheet) + env(safe-area-inset-bottom))!important;transform:none!important;width:auto!important;max-width:620px;margin:0 auto;display:grid!important;grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:"btns track latest" "frame frame frame";align-items:center;gap:6px 10px;padding:8px 10px!important;border-radius:14px;max-height:none!important;overflow:visible!important;transition:bottom .18s ease}
body.arx .radar-loop-control[hidden]{display:none!important}
body.arx .radar-loop-title,body.arx .radar-model-note,body.arx #radar-loop-status{display:none!important}
body.arx .radar-loop-actions{grid-area:btns;display:flex!important;gap:6px;width:auto!important}
body.arx .radar-loop-actions button{min-width:44px;min-height:44px!important;padding:0 .55rem!important;font-size:1rem!important}
body.arx #radar-loop-stop{grid-area:latest}
body.arx .radar-loop-track{grid-area:track;min-width:0}
body.arx #radar-loop-range{width:100%;height:44px;margin:0;background:transparent;-webkit-appearance:none;appearance:none;cursor:pointer}
body.arx #radar-loop-range::-webkit-slider-runnable-track{height:6px;border-radius:3px;background:linear-gradient(90deg,var(--arx-obs) 0 66.6%,var(--arx-fc) 66.6% 100%)}
body.arx #radar-loop-range::-moz-range-track{height:6px;border-radius:3px;background:linear-gradient(90deg,var(--arx-obs) 0 66.6%,var(--arx-fc) 66.6% 100%)}
body.arx #radar-loop-range::-webkit-slider-thumb{-webkit-appearance:none;width:24px;height:24px;margin-top:-9px;border-radius:50%;background:#fff;border:3px solid #0b1624;box-shadow:0 0 0 1px #fff}
body.arx #radar-loop-range::-moz-range-thumb{width:20px;height:20px;border-radius:50%;background:#fff;border:3px solid #0b1624}
body.arx #radar-loop-range:focus-visible{outline:3px solid #ffc351;outline-offset:2px;border-radius:6px}
body.arx .radar-loop-endpoints{display:flex;justify-content:space-between;font-size:.72rem;color:var(--arx-muted)}
body.arx .arx-frame{grid-area:frame;display:flex;flex-wrap:wrap;align-items:center;gap:.35rem .6rem;font-size:.86rem;min-height:22px}
body.arx .arx-frame .kind{display:inline-block;padding:.05rem .45rem;border-radius:6px;font-size:.72rem;font-weight:800;letter-spacing:.06em}
body.arx .arx-frame .kind.obs{background:#123a5c;color:#bfe1ff;border:1px solid var(--arx-obs)}
body.arx .arx-frame .kind.fc{background:#35205a;color:#ecd9ff;border:1px dashed var(--arx-fc)}
body.arx .arx-frame .kind.bad{background:#40262a;color:#ffd0d4;border:1px solid #d86a74}
body.arx .arx-frame .state{color:var(--arx-muted)}
body.arx .radar-loop-control.is-forecast{border-color:var(--arx-fc)!important;box-shadow:0 0 0 1px var(--arx-fc),0 8px 28px #000b}

/* ---------------------------------------------------------------- the panel */
body.arx aside.panel{display:none;flex-direction:column;padding:0!important;background:var(--arx-panel);border-left:1px solid var(--arx-line);overflow:hidden!important;min-height:0;z-index:1200}
body.arx.arx-open aside.panel{display:flex}
body.arx .arx-phead{display:flex;align-items:center;gap:.4rem;padding:8px 10px 8px 14px;border-bottom:1px solid var(--arx-line);flex:none}
body.arx .arx-phead h2{margin:0;font-size:1.05rem;flex:1 1 auto;min-width:0}
body.arx .arx-handle{display:none}
body.arx .arx-pbody{flex:1 1 auto;overflow:auto;overscroll-behavior:contain;padding:12px 14px calc(16px + env(safe-area-inset-bottom));-webkit-overflow-scrolling:touch}
body.arx .arx-view[hidden]{display:none}
body.arx .arx-tabs{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:4px;margin:0 0 12px;position:sticky;top:-12px;background:var(--arx-panel);padding:6px 0;z-index:2}
body.arx .arx-tabs button{min-height:44px;padding:.3rem .25rem;border-radius:8px;border:1px solid #35536d;background:#13283c;color:#dbe7ef;font:inherit;font-size:.8rem;line-height:1.15;cursor:pointer}
body.arx .arx-tabs button[aria-selected="true"]{background:#1b4b55;border-color:#5fc5c1;color:#fff;font-weight:700}
body.arx .arx-group>h3{margin:.2rem 0 .6rem;font-size:1rem}
body.arx .arx-group .sidebar-category{margin:0 0 .6rem}
body.arx .arx-lead{margin:0 0 .75rem;color:var(--arx-muted);font-size:.9rem;line-height:1.45}
body.arx .arx-foot{margin-top:1rem;border-top:1px solid var(--arx-line);padding-top:.6rem;font-size:.8rem;color:var(--arx-muted)}
body.arx .arx-group .header-weather{display:grid!important;margin:0 0 .8rem}
body.arx .arx-group .header-weather .weather-metrics{grid-template-columns:repeat(3,minmax(0,1fr))!important}
body.arx #preparedness-menu{position:static}
body.arx #preparedness-menu>.control-menu-body{position:static!important;display:block;width:auto!important;max-width:none!important;max-height:none!important;box-shadow:none;border:0;padding:.5rem 0 0;background:transparent}

/* desktop drawer: overlays the map until pinned, then takes its own column */
@media (min-width:900px){
  body.arx aside.panel{position:absolute;top:0;right:0;bottom:0;width:var(--arx-drawer);box-shadow:-12px 0 30px #0008}
  body.arx.arx-pinned aside.panel{position:relative;box-shadow:none;width:auto}
  body.arx.arx-open:not(.arx-pinned){--arx-overlay:var(--arx-drawer)}
  body.arx.arx-open:not(.arx-pinned) .arx-right{right:calc(10px + var(--arx-drawer))}
  body.arx.arx-open:not(.arx-pinned) .arx-tools{right:calc(64px + var(--arx-drawer))}
  body.arx.arx-open:not(.arx-pinned) .leaflet-right{right:var(--arx-drawer)}
}

/* ---------------------------------------------------------------- Layers view */
body.arx .arx-lsec{border:1px solid #2c4760;border-radius:10px;padding:.6rem .7rem;margin:0 0 .7rem;background:#13283c}
body.arx .arx-lsec>h3{margin:0 0 .4rem;font-size:.95rem}
body.arx .arx-lsec p{margin:.3rem 0;font-size:.84rem;color:var(--arx-muted);line-height:1.4}
body.arx .arx-switch{display:flex;align-items:center;justify-content:space-between;gap:.6rem;width:100%;min-height:44px;padding:.35rem .1rem;border:0;background:transparent;color:var(--arx-ink);font:inherit;font-size:.93rem;text-align:left;cursor:pointer}
body.arx .arx-switch .sw{flex:none;width:44px;height:24px;border-radius:12px;background:#3a4f63;position:relative;transition:background .15s}
body.arx .arx-switch .sw::after{content:"";position:absolute;top:3px;left:3px;width:18px;height:18px;border-radius:50%;background:#fff;transition:left .15s}
body.arx .arx-switch[aria-checked="true"] .sw{background:#2aa39c}
body.arx .arx-switch[aria-checked="true"] .sw::after{left:23px}
body.arx .arx-switch .lbl small{display:block;color:var(--arx-muted);font-size:.78rem}
body.arx .arx-switch:focus-visible{outline:3px solid #ffc351;outline-offset:2px;border-radius:8px}
body.arx .arx-lsec .legend{position:static!important;display:flex;flex-wrap:wrap;gap:.3rem .5rem;align-items:center;font-size:.8rem;margin:.3rem 0;background:transparent;padding:0;box-shadow:none}
body.arx .arx-lsec .legend[hidden]{display:none!important}
body.arx .arx-lsec .radar-tools label{font-size:.86rem}
body.arx .arx-lsec input[type=range]{width:100%}
body.arx .arx-lsec select{width:100%;min-height:44px}
body.arx .arx-lsec details>summary{cursor:pointer;min-height:40px;display:flex;align-items:center;font-weight:700}
body.arx .arx-reset{width:100%;min-height:44px;margin-top:.3rem}

/* ---------------------------------------------------------------- Alerts (bell) and More views */
body.arx .arx-box{border:1px solid #2c4760;border-radius:10px;padding:.7rem .8rem;margin:0 0 .8rem;background:#13283c}
body.arx .arx-box>h3{margin:0 0 .4rem;font-size:1rem}
body.arx .arx-box .push-settings{border:0;padding:0;margin:0;background:transparent}
body.arx .arx-box select{width:100%;min-height:44px}
body.arx .arx-partners{display:flex;flex-wrap:wrap;gap:.8rem;align-items:center}
body.arx .arx-partners .wrn-mark,body.arx .arx-partners .skywarn-mark{display:block!important;position:relative;width:auto!important}
body.arx .arx-partners .wrn-mark img{width:122px;height:auto}
body.arx .arx-partners .skywarn-mark img{height:86px;width:auto}
body.arx .arx-more-links{display:flex;flex-wrap:wrap;gap:.5rem;margin:.5rem 0 0}
body.arx .arx-more-links a,body.arx .arx-more-links button{min-height:44px;display:inline-flex;align-items:center}

/* ---------------------------------------------------------------- phones: bottom sheet */
@media (max-width:899px){
  body.arx .arx-brand h1 .org-name{font-size:.8rem}
  body.arx .arx-brand h1 .tracker-name{font-size:.66rem}
  body.arx .arx-top{gap:.4rem;padding:5px 8px;flex-wrap:nowrap}
  body.arx .arx-chips{justify-content:flex-start}
  body.arx .arx-chips{display:none}
  body.arx .arx-chiprow{display:flex;gap:6px}
  body.arx .arx-chiprow[hidden]{display:none}
  body.arx .arx-chiprow .arx-chip{flex:1 1 0;min-width:0;min-height:44px;justify-content:center;box-shadow:0 4px 14px #0007}
  body.arx .arx-brand h1 .org-name{white-space:normal}
  body.arx .arx-btn .lbl{display:none}
  body.arx .arx-btn{padding:.4rem .55rem}
  body.arx .emergency-banner{font-size:.78rem;padding:3px 8px}
  body.arx .arx-tools{right:10px;max-width:none}
  body.arx .arx-right{top:auto;bottom:calc(var(--arx-sheet) + var(--arx-play,120px) + 22px + env(safe-area-inset-bottom));right:10px}
  /* just above the right-hand button stack, whatever its height (measured in ar-layout.js) */
  body.arx .leaflet-top.leaflet-right{top:auto;bottom:calc(var(--arx-sheet) + var(--arx-play,120px) + 22px + env(safe-area-inset-bottom) + var(--arx-right-h,94px) + 10px)}
  body.arx.arx-zoom-tight .leaflet-control-zoom{display:none!important}
  body.arx.arx-popup-open .leaflet-control-zoom,body.arx.arx-popup-open .arx-right{display:none!important}
  body.arx aside.panel{position:fixed;left:0;right:0;bottom:0;top:auto;width:auto;height:var(--arx-sheet);border-left:0;border-top:1px solid var(--arx-line);border-radius:16px 16px 0 0;box-shadow:0 -12px 30px #000a;transition:height .18s ease}
  body.arx .arx-handle{display:block;width:100%;height:26px;border:0;background:transparent;cursor:grab;touch-action:none;flex:none;position:relative}
  body.arx .arx-handle::before{content:"";position:absolute;left:50%;top:9px;width:44px;height:5px;margin-left:-22px;border-radius:3px;background:#5d7a93}
  body.arx .arx-phead{padding-top:0;touch-action:none}
  body.arx .arx-pin{display:none!important}
  body.arx .radar-loop-control{left:8px!important;right:8px!important;bottom:calc(24px + var(--arx-sheet) + env(safe-area-inset-bottom))!important;grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:"btns track latest" "frame frame frame";padding:4px 8px!important;gap:0 8px}
  body.arx .radar-loop-endpoints{display:none!important}
  body.arx .radar-loop-actions{gap:4px}
  body.arx .radar-loop-actions button{min-width:44px;padding:0 .35rem!important}
  body.arx #radar-loop-button{font-size:0!important;width:48px}
  body.arx #radar-loop-button::first-letter{font-size:1.15rem}
  body.arx .arx-frame{flex-wrap:nowrap;white-space:nowrap;overflow:hidden;font-size:.8rem}
  body.arx .arx-frame span:nth-child(2){overflow:hidden;text-overflow:ellipsis}
  body.arx .leaflet-control-attribution{max-width:calc(100vw - 16px);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:10px;cursor:pointer}
  body.arx .leaflet-control-attribution.arx-open-attr{white-space:normal;position:relative;z-index:1100;background:#fffffff2}
  body.arx #radar-loop-stop{justify-self:end}
}
@media (max-width:899px){
  /* while a sheet is open, pinch zoom replaces the side buttons; at full height the search row
     tucks away too, and the playback bar stays just above the sheet */
  body.arx.arx-open .arx-right,body.arx.arx-open .leaflet-control-zoom{display:none!important}
  body.arx.arx-sheet-full .arx-tools{display:none!important}
}
@media (max-width:899px) and (orientation:landscape) and (max-height:500px){
  body.arx .emergency-banner{font-size:.74rem;padding:2px 8px}
  body.arx .radar-loop-control{grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:"btns track latest" "frame frame frame";max-width:640px}
  body.arx .arx-tools{max-width:420px}
}
@media (min-width:900px){ body.arx .arx-expand{display:none!important} }
@media (prefers-reduced-motion:reduce){ body.arx aside.panel,body.arx .radar-loop-control{transition:none} }

/* ---------------------------------------------------------------- Power outages (ar-outages.js) */
body.arx .arx-out-status{font-size:.84rem;margin:.3rem 0;color:var(--arx-muted)}
body.arx .arx-out-status[data-kind="stale"],body.arx .arx-out-status[data-kind="error"]{color:#ffd0a8;background:#3a2410;border:1px solid #8a5a20;border-radius:8px;padding:.4rem .55rem}
body.arx .arx-out-status:empty{display:none}
body.arx .arx-out-op{display:block;font-size:.84rem;margin:.3rem 0}
body.arx .arx-out-legend{display:flex;flex-wrap:wrap;align-items:center;gap:.2rem .45rem;font-size:.78rem;margin:.35rem 0}
body.arx .arx-out-legend i{display:inline-block;width:14px;height:14px;border-radius:3px;vertical-align:-2px;border:1px solid #0006}
body.arx .arx-out-legend i.unknown{background:transparent;border:1.5px dashed #c9b8a6}
body.arx .arx-out-note{font-size:.78rem!important}
.arx-out-pop p{margin:.3rem 0}.arx-out-pop ul{margin:.3rem 0;padding-left:1.1rem}.arx-out-pop .stale{color:#9a3a00;font-weight:700}.arx-out-pop .src{font-size:.78rem;color:#555}
/* Tool search (ar-find.js): tool rows in the results list, and the message under the search box */
body.arx .arx-results li.arx-tool{flex-direction:row;align-items:center;justify-content:flex-start;gap:.6rem}
body.arx .arx-results li.arx-tool .arx-ico{flex:0 0 1.6rem;font-size:1.15rem;line-height:1;text-align:center}
body.arx .arx-results li.arx-tool .arx-lbl{display:flex;flex-direction:column;min-width:0}
body.arx .arx-find-note a{display:inline-flex;align-items:center;min-height:36px;padding:.25rem .6rem;border-radius:8px;border:1px solid #45637b;background:#172d42;color:#fff;font-size:.85rem;text-decoration:none}
body.arx .arx-find-note a.urgent{background:#b3261e;border-color:#ff8a80;font-weight:700}
@keyframes arx-find-pulse{0%,100%{box-shadow:0 0 0 0 #e7a93200}50%{box-shadow:0 0 0 6px #e7a93299}}
body.arx .arx-find-flash{outline:2px solid #e7a932;outline-offset:2px;animation:arx-find-pulse 1s ease-in-out 3}
@media (prefers-reduced-motion:reduce){body.arx .arx-find-flash{animation:none}}

/* Deployment Folders and Alert History (ar-folders.js) */
.alert .alert-save{margin-left:.4rem;min-height:36px;padding:.3rem .7rem;font-size:.85rem}
.leaflet-popup-content .ar-save-btn,.damage-popup .ar-save-btn{display:block;margin-top:10px;min-height:40px;font-size:14px}
.link-button{background:none!important;border:0!important;padding:0!important;min-height:0!important;color:#ffcc6a!important;text-decoration:underline;font:inherit;cursor:pointer}
.alert-history{margin-top:16px;padding-top:12px;border-top:1px solid #38516a}
.alert-history h3{margin:0 0 6px;font-size:1rem}
.alert-history-toggle{display:flex!important;gap:10px;align-items:center;min-height:44px;margin:4px 0;font-size:14px;line-height:1.35}
.alert-history-toggle input{width:22px;height:22px;flex:0 0 auto;accent-color:#e7a932}
.camera-viewer-actions{display:flex;flex-wrap:wrap;gap:8px}
.saved-viewer-body{padding:0 1rem 1rem;overflow:auto;max-height:calc(90dvh - 70px)}
.saved-viewer-body p{margin:.5rem 0;color:#dbe8f2;font-size:.95rem;line-height:1.5}
.saved-viewer-body .saved-lead{font-weight:600;color:#fff}
.saved-viewer-body .saved-meta{margin:.2rem 0;color:#b8cfdf;font-size:.88rem}
.saved-viewer-body .saved-heading{font-weight:700;margin-top:1rem;color:#fff}
.saved-viewer-body .saved-text{white-space:pre-wrap;background:#152b3d;border:1px solid #38516a;border-radius:8px;padding:.7rem;font-size:.9rem}
.saved-viewer-body .saved-photo{display:block;width:100%;max-height:60vh;object-fit:contain;background:#152b3d;border-radius:8px;margin:.3rem 0 .6rem}
.saved-viewer-body a{color:#ffcc6a}
.saved-viewer-actions{display:flex;flex-wrap:wrap;gap:8px;margin:1rem 0 .5rem}
.saved-viewer-actions button{min-height:44px;font-size:14px}
.saved-viewer-actions .saved-delete{border-color:#b5475a;color:#ffd6dc}
.saved-viewer-actions .saved-delete:hover{background:#4a1f2a}dialog.saved-viewer{width:min(760px,96vw)}

/* NOAA hazard maps (ar-wxmaps.js) */
.arx-wx-label{display:block;font-size:.85rem;margin:.4rem 0 .25rem;color:#d9e7f0}
.arx-wx-select{width:100%;min-height:44px;font-size:16px;padding:8px;border-radius:8px;background:#172d42;color:#fff;border:1px solid #45637b}
.arx-wx-legend{display:flex;flex-wrap:wrap;gap:6px 12px;margin:.4rem 0;font-size:.78rem;color:#d9e7f0}
.arx-wx-key{display:inline-flex;align-items:center;gap:5px}
.arx-wx-key img{width:16px;height:16px;flex:0 0 16px;border-radius:2px}body.arx .arx-out-sources{list-style:none;margin:.3rem 0 .5rem;padding:0;font-size:.8rem;line-height:1.45}
body.arx .arx-out-sources li.ok{color:#bfe8c9}
body.arx .arx-out-sources li.bad{color:#ffb4a8}
.arx-wx-pop{margin-top:.6rem;padding-top:.5rem;border-top:1px solid #0002}
/* Header: Preparedness and Donate (always visible) */
body.arx .arx-donate{background:#c1121f;border-color:#ff8a80;color:#fff;text-decoration:none;font-weight:700}
body.arx .arx-donate:hover,body.arx .arx-donate:focus-visible{background:#a30f1a;color:#fff}
body.arx .arx-donate svg{color:#fff}
@media (max-width:899px){
  body.arx .arx-donate .lbl{display:inline}
  body.arx .arx-donate svg{display:none}
  body.arx .arx-actions{gap:.3rem}
}
@media (max-width:400px){
  body.arx .arx-actions .arx-btn{min-width:40px;padding:.35rem .45rem}
  body.arx .arx-brand h1 .org-name{font-size:.72rem}
}body.arx .arx-brandtext{display:flex;flex-direction:column;min-width:0}
body.arx .arx-site{font-size:.72rem;line-height:1.2;color:#9fd3ff;text-decoration:underline;text-underline-offset:2px;white-space:nowrap;margin-top:1px}
body.arx .arx-brand:hover .arx-site,body.arx .arx-brand:focus-visible .arx-site{color:#fff}
@media (max-width:400px){body.arx .arx-site{font-size:.64rem}}/* Phones: two header rows. Row 1: brand and Donate. Row 2: the four panel buttons, with labels. */
body.arx .arx-donate{flex:none}
@media (max-width:599px){
  body.arx .arx-top{flex-wrap:wrap;row-gap:6px;padding:6px 8px}
  body.arx .arx-brand{order:1;flex:1 1 auto;min-width:0}
  body.arx .arx-brand h1 .org-name{white-space:nowrap;font-size:.8rem}
  body.arx .arx-donate{order:2;padding:.4rem .8rem}
  body.arx .arx-actions{order:3;flex:1 0 100%;gap:6px}
  body.arx .arx-actions>.arx-btn{flex:1 1 auto;min-width:0;padding:.35rem .4rem;gap:.25rem}
  body.arx .arx-actions>.arx-btn .lbl{display:inline;font-size:.78rem;overflow:hidden;text-overflow:ellipsis}
  body.arx .arx-actions>.arx-btn svg{width:18px;height:18px;flex:none}
}
@media (max-width:370px){
  body.arx .arx-actions>.arx-btn .lbl{font-size:.72rem}
  body.arx .arx-actions>.arx-btn{padding:.35rem .3rem;gap:.2rem}
}
/* Tablets: room for the Preparedness label. */
@media (min-width:600px) and (max-width:899px){
  body.arx .arx-actions>.arx-prep .lbl{display:inline}
}/* Very small phones (iPhone SE 1st gen, 320 px): keep two rows. */
@media (max-width:359px){
  body.arx .arx-brand{gap:.4rem}
  body.arx .arx-brand .arx-badge{width:32px;height:32px}
  body.arx .arx-brand .arx-badge img{width:50px}
  body.arx .arx-brand h1 .org-name{font-size:.64rem;letter-spacing:.02em}
  body.arx .arx-brand h1 .tracker-name{font-size:.56rem}
  body.arx .arx-site{font-size:.58rem}
  body.arx .arx-donate{padding:.35rem .6rem;font-size:.85rem}
  body.arx .arx-actions{gap:4px}
  body.arx .arx-actions>.arx-btn svg{display:none}
  body.arx .arx-actions>.arx-btn{padding:.3rem .25rem}
  body.arx .arx-actions>.arx-btn .lbl{font-size:.74rem}
}
/* Phones and tablets: while a header panel (Preparedness, Details, Alerts, More, Layers) is open,
   hide the radar play bar so the panel has the room. It comes back when the panel closes. */
@media (max-width:899px){
  body.arx.arx-open .radar-loop-control{display:none!important}
}
/* Hurricanes (ar-hazards.js): storm name on the map, and "what you tapped" in pop-ups. */
.leaflet-tooltip.arx-storm-label{background:#101f30;color:#fff;border:1px solid #f2b23e;border-radius:6px;font:700 12px/1.2 system-ui;padding:3px 6px;box-shadow:0 2px 6px #0007}
.leaflet-tooltip.arx-storm-label::before{border-right-color:#f2b23e}
.arx-storm-what{background:#fff6e0;border-left:3px solid #f2b23e;padding:6px 8px;border-radius:4px;margin:6px 0!important}
.arx-storm-key{font-size:12px;line-height:1.8;margin:0 0 6px -8px!important}
/* Search messages: the × stays in the top corner and long messages scroll inside a capped box,
   so the close button is never pushed behind a bottom sheet on a phone. */
body.arx .arx-find-note{position:relative;padding-right:2.8rem}
body.arx .arx-find-note>.x{position:absolute;top:4px;right:4px;margin:0;min-width:40px;min-height:40px;font-size:1.3rem;line-height:1;color:#fff}
body.arx .arx-find-note .arx-note-body{max-height:40vh;overflow-y:auto;-webkit-overflow-scrolling:touch}
@media (max-width:899px){body.arx .arx-find-note .arx-note-body{max-height:24vh}}
/* Wildfire flame icons (ar-fires.js): no default divIcon box, a shadow so they read on any map. */
.leaflet-marker-icon.arx-fire-icon{background:none;border:0;display:flex;align-items:center;justify-content:center}
.leaflet-marker-icon.arx-fire-icon svg{display:block;filter:drop-shadow(0 1px 1.5px rgba(0,0,0,.6));pointer-events:none}
.arx-fire-key{display:inline-flex;vertical-align:-3px;margin-right:3px}
.arx-fire-key svg{display:block}
/* State DOT camera pop-ups (ar-cams.js): still image or live video. */
.arx-cam-pop .arx-cam-box{margin:.4rem 0;background:#0b1622;border-radius:8px;overflow:hidden;height:220px;display:flex;align-items:center;justify-content:center}
.arx-cam-pop .arx-cam-media{display:block;width:100%;height:100%;object-fit:contain;background:#0b1622}
.arx-cam-pop .arx-cam-box p{margin:0;padding:.8rem;color:#e6ebf5}
.arx-cam-pop .arx-cam-actions{display:flex;flex-wrap:wrap;gap:.4rem .8rem;align-items:center;margin:.3rem 0}@media (max-width:899px){.arx-cam-pop .arx-cam-box{height:150px}}
.arx-cam-pop .arx-cam-note{min-height:1.4em;margin:.2rem 0}
.arx-cam-pop .arx-cam-actions .ar-save-btn{margin:0;min-height:36px;padding:.3rem .7rem;font-size:.88rem}
.arx-cam-pop .arx-cam-actions a{font-size:.9rem}

/* Zoomed-out camera bubbles, one per state (ar-cams.js). */
.leaflet-marker-icon.arx-cam-count{background:none;border:0}
.arx-cam-count span{display:flex;flex-direction:column;align-items:center;justify-content:center;transform:translate(-50%,-50%);min-width:38px;height:38px;padding:0 4px;box-sizing:border-box;border-radius:19px;background:#0f2a3fee;color:#fff;border:1.5px solid #4dbce4;box-shadow:0 2px 6px #0008;cursor:pointer;line-height:1.05;white-space:nowrap}
.arx-cam-count b{font:700 12px/1 system-ui,sans-serif;color:#8fdcff}
.arx-cam-count small{font:600 9.5px/1.1 system-ui,sans-serif;color:#fff}
@media (max-width:899px){.arx-cam-count span{min-width:32px;height:32px;border-radius:16px}.arx-cam-count b{font-size:11px}.arx-cam-count small{font-size:8.5px}}
/* Disaster response layers (ar-response.js). */
.leaflet-marker-icon.arx-dat-pin,.leaflet-marker-icon.arx-shelter-pin{background:none;border:0}
.arx-dat-pin span{display:flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:50%;border:1.5px solid #111;font-size:12px;box-shadow:0 1px 4px #0008}
.arx-shelter-pin span{display:flex;align-items:center;justify-content:center;width:30px;height:30px;border-radius:8px;background:#1f7a4d;border:2px solid #fff;font-size:16px;box-shadow:0 2px 6px #0008}
#arx-response select{margin:.2rem 0 .4rem}
/* Emergency management card (ar-ema.js). */
.arx-ema{border:1px solid #e7a932;border-left-width:4px;border-radius:8px;background:#1c3449;padding:.6rem .8rem;margin:.5rem 0 .8rem}
.arx-ema h4{margin:0 0 .3rem;font-size:1rem;color:#ffd27a}
.arx-ema .arx-ema-name{margin:.1rem 0;font-weight:700;font-size:1.02rem}
.arx-ema .arx-ema-actions{display:flex;flex-wrap:wrap;gap:.45rem .9rem;align-items:center;margin:.35rem 0}
.arx-ema .arx-ema-call{display:inline-flex;align-items:center;min-height:40px;padding:.3rem .8rem;border-radius:8px;background:#b3261e;color:#fff!important;font-weight:700;text-decoration:none}
.arx-ema a{color:#ffce6a}
.arx-ema .arx-ema-state{margin:.35rem 0}
.arx-ema-compact{margin:.5rem 0 0;padding:.45rem .6rem}
.arx-ema-compact .arx-ema-label{margin:0 0 .2rem;font-weight:700;color:#ffd27a}
.leaflet-popup-content .arx-ema{background:#fff6e0;border-color:#e7a932;color:#1b1b1b}
.leaflet-popup-content .arx-ema .arx-ema-label{color:#7a4b00}
.leaflet-popup-content .arx-ema a{color:#0b57d0}
@media (max-width:420px){.arx-ema-tag{display:none}}
/* Map button: traffic cameras on/off (ar-layout.js). Lit while cameras are on. */
body.arx #arx-b-cams[aria-pressed="true"]{background:#0f3b52;border-color:#4dbce4;color:#8fdcff;box-shadow:0 0 0 2px #4dbce455}
/* Hospitals and fire & EMS stations (ar-response.js). */
.leaflet-marker-icon.arx-fac{background:none;border:0}
.arx-fac span{display:flex;align-items:center;justify-content:center;width:26px;height:26px;border-radius:7px;font-size:15px;box-shadow:0 1px 4px #0008}
.arx-fac-hosp span{background:#fff;border:2px solid #d62828}
.arx-fac-fire span{background:#b3261e;border:2px solid #fff}
/* Saved Alerts panel: "My Folders" and "Past NWS Alerts" headings. */
.saved-heading{margin:.4rem 0 .1rem;font-size:1rem}
.saved-subtitle{margin:0 0 .5rem!important}.arx-fac-police span{background:#1f4fa8;border:2px solid #fff}
/* Radar rotation and hail tracks (ar-rotation.js). */
.leaflet-marker-icon.arx-tvs{background:none;border:0}
.arx-tvs span{display:block;font:700 20px/1 system-ui,sans-serif;color:#8e24aa;text-shadow:0 0 2px #fff,0 0 3px #fff,0 1px 3px #000}
.arx-tvs-key{color:#8e24aa;font-weight:700;text-shadow:0 0 2px #fff}
/* Menus inside Layers sections (damage-survey range, rotation hours): readable on the dark panel. */
body.arx .arx-lsec select.map-select{background:#172d42;color:#fff;border:1px solid #45637b;border-radius:8px;min-height:40px;padding:.3rem 2rem .3rem .6rem;font:inherit;font-size:.92rem;max-width:100%;-webkit-appearance:none;appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23fff' stroke-width='2'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right .7rem center}
body.arx .arx-lsec select.map-select option{color:#14202c;background:#fff}
/* Get help after a disaster (ar-help.js) */
.arx-help{border:1px solid #4f9d69;border-left-width:4px;border-radius:8px;background:#17332a;padding:.6rem .8rem;margin:.5rem 0 .8rem}
.arx-help h4{margin:0 0 .3rem;font-size:1.02rem;color:#9be3b0}
.arx-help .arx-help-911{margin:.1rem 0 .4rem;font-weight:700;color:#ffb4ab}
.arx-help .arx-help-status p{margin:.3rem 0}
.arx-help .arx-help-open{background:#1f4d33;border-radius:6px;padding:.4rem .55rem;font-weight:600}
.arx-help ul.arx-help-list{list-style:none;margin:.5rem 0 0;padding:0}
.arx-help ul.arx-help-list>li{border-top:1px solid rgba(255,255,255,.12);padding:.5rem 0}
.arx-help .arx-help-name{margin:0;font-size:.98rem}
.arx-help .arx-help-text{margin:.15rem 0;font-size:.9rem;opacity:.92}
.arx-help .arx-help-actions{display:flex;flex-wrap:wrap;gap:.4rem .8rem;align-items:center;margin:.3rem 0}
.arx-help a{color:#a6e8bb}
.arx-help .arx-help-call,.arx-help .arx-help-apply{display:inline-flex;align-items:center;min-height:40px;padding:.3rem .75rem;border-radius:8px;background:#2e7d4f;color:#fff!important;font-weight:700;text-decoration:none}
.arx-help .arx-help-tips{border-top:1px solid rgba(255,255,255,.12);padding-top:.4rem;font-size:.9rem}
.arx-help .arx-help-tips p{margin:.3rem 0}
.arx-help-open-btn{display:block;width:100%;margin:.7rem 0 .2rem;min-height:44px;padding:.45rem .7rem;border-radius:8px;border:1px solid #4f9d69;background:#17332a;color:#fff;font:inherit;font-weight:700;text-align:left;cursor:pointer}body.arx .arx-partners .cc-mark{display:block;background:#fff;border-radius:8px;padding:4px;line-height:0}
body.arx .arx-partners .cc-mark img{height:80px;width:auto}
.arx-help .arx-help-logo{display:inline-block;background:#fff;border-radius:8px;padding:3px;line-height:0;margin:.2rem 0}
.arx-help .arx-help-logo img{width:96px;height:auto}

/* Road closures (ar-roads.js) */
.arx-road-pin{display:flex;align-items:center;justify-content:center}
.arx-road-pin span{display:flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:50%;background:#fff;border:2px solid #d50000;font-size:13px;line-height:1;box-shadow:0 1px 3px rgba(0,0,0,.45)}
.arx-road-flood span{border-color:#1565c0}
.arx-road-detour span{border-color:#ef6c00}
/* Spanish (ar-es.js) */
.emergency-banner .arx-lang{margin-left:.5rem;padding:.12rem .6rem;min-height:28px;border-radius:999px;border:1px solid rgba(255,255,255,.55);background:transparent;color:#fff;font:inherit;font-size:.85em;font-weight:700;letter-spacing:0;cursor:pointer;vertical-align:middle}
.emergency-banner .arx-lang:hover,.emergency-banner .arx-lang:focus-visible{background:rgba(255,255,255,.15)}
.arx-es-tips{border:1px solid #3d6b8c;border-left-width:4px;border-radius:8px;background:#15304a;padding:.6rem .8rem;margin:.5rem 0 .8rem}
.arx-es-tips h4{margin:0 0 .3rem;font-size:1rem;color:#9fd3ff}
.arx-es-tips ul{margin:.2rem 0;padding-left:1.1rem;columns:2;column-gap:1rem}
.arx-es-tips li{margin:.2rem 0;break-inside:avoid}
.arx-es-tips a{color:#9fd3ff}
@media (max-width:420px){.arx-es-tips ul{columns:1}}
/* Offline notice (ar-offline.js) */
.arx-offline{background:#3b3a12;color:#fff6c2;border-top:1px solid #6b6620;padding:.45rem .9rem;font-size:.9rem;line-height:1.35;text-align:center}
/* NWS impact badges (ar-impact.js) */
.arx-impact{display:flex;flex-wrap:wrap;gap:4px 6px;margin:.3rem 0}
.arx-impact-b{display:inline-block;padding:.12rem .5rem;border-radius:6px;font-size:.82rem;font-weight:600;line-height:1.35;background:#24384b;color:#e6eef5;border:1px solid #3d5870}
.arx-impact-2{background:#6b1a14;border-color:#e0453a;color:#fff}
.arx-impact-3{background:#b3001b;border-color:#ff8a8a;color:#fff;font-weight:800;letter-spacing:.01em}
.leaflet-popup-content .arx-impact-b{background:#eef2f6;color:#14202c;border-color:#c5d0da}
.leaflet-popup-content .arx-impact-2{background:#fde3e0;color:#7a0d06;border-color:#e0453a}
.leaflet-popup-content .arx-impact-3{background:#b3001b;color:#fff;border-color:#7a0010}
body.arx .arx-chip[data-state="emergency"]{background:#b3001b;border-color:#ff8a8a;color:#fff;animation:arx-emerg 1.2s ease-in-out infinite alternate}
@keyframes arx-emerg{from{box-shadow:0 0 0 0 #ff4d4d99}to{box-shadow:0 0 0 6px #ff4d4d00}}
@media (prefers-reduced-motion:reduce){body.arx .arx-chip[data-state="emergency"]{animation:none}}
/* SPC outlook tap section (ar-spc.js) */
.arx-spc-pop{border-top:1px solid #d5dde5;margin-top:.5rem;padding-top:.4rem}
.arx-spc-pop .arx-spc-cat{display:flex;align-items:center;gap:.45rem}
.arx-spc-swatch{display:inline-block;width:18px;height:18px;border-radius:4px;border:1px solid #0004;flex:none}
/* Lightning (ar-lightning.js): a ⚡ button on the radar player, under Latest */
body.arx .radar-loop-control{grid-template-areas:"btns track track" "frame frame bolt"}
body.arx .arx-lightning-btn{grid-area:bolt;justify-self:end;min-width:44px;min-height:32px;padding:0 .6rem;border-radius:8px;border:1px solid #45637b;background:#172d42;color:#9fb6c9;font-size:1rem;line-height:1;cursor:pointer}
body.arx .arx-lightning-btn[aria-pressed="true"]{background:#f5c518;border-color:#f5c518;color:#14202c;box-shadow:0 0 0 2px #f5c51855}
body.arx .arx-lightning-btn:focus-visible{outline:2px solid #fff;outline-offset:2px}
.arx-lightning-legend{display:block;max-width:100%;height:auto;margin:.3rem 0;background:#fff;border-radius:6px;padding:2px}

/* Ownership line in More (ar-layout.js) */
body.arx .arx-legal{margin:.7rem 0 0;font-size:.8rem;line-height:1.45;color:var(--arx-muted,#9fb6c9)}
body.arx .arx-legal a{color:inherit;text-decoration:underline}

/* What's new in More (ar-whatsnew.js) */
body.arx .arx-whatsnew{margin:.8rem 0 0;border:1px solid var(--arx-line,#2c4a63);border-radius:10px;background:#12263a}
body.arx .arx-whatsnew summary{cursor:pointer;padding:.55rem .75rem;font-weight:700;list-style-position:inside;min-height:44px;display:flex;align-items:center;flex-wrap:wrap;gap:0 .2rem}
body.arx .arx-whatsnew .arx-wn-more{color:#9fd3ff;font-weight:600}
body.arx .arx-whatsnew ul{margin:0;padding:.1rem .8rem .2rem 2.4rem;list-style:none}
body.arx .arx-whatsnew li{margin:.35rem 0;position:relative;font-size:.92rem;line-height:1.4}
body.arx .arx-whatsnew .arx-wn-i{position:absolute;left:-1.7rem;top:0}
body.arx .arx-whatsnew .src{padding:0 .8rem .6rem;margin:.2rem 0 0}

/* Winds (ar-winds.js): 💨 and ⚡ side by side on the radar player */
body.arx .arx-player-toggles{grid-area:bolt;justify-self:end;display:flex;gap:6px}
body.arx .arx-winds-btn[aria-pressed="true"]{background:#4fc3f7;border-color:#4fc3f7;color:#0b1624;box-shadow:0 0 0 2px #4fc3f755}
.arx-wind{position:relative}
.arx-wind .arx-wind-arrow{position:absolute;left:50%;top:50%;width:30px;height:30px;margin:-15px 0 0 -15px;display:flex;align-items:center;justify-content:center;filter:drop-shadow(0 1px 1px #0008)}
.arx-wind .arx-wind-calm{position:absolute;left:50%;top:50%;width:8px;height:8px;margin:-4px 0 0 -4px;border-radius:50%;background:#90a4ae;border:1.5px solid #fff}
.arx-wind .arx-wind-lbl{position:absolute;left:24px;top:18px;white-space:nowrap;font:700 11px/1 system-ui,Arial,sans-serif;color:#10202e;background:#ffffffe6;border-radius:4px;padding:1px 3px;box-shadow:0 1px 2px #0005}
.arx-wind-strong .arx-wind-lbl{background:#ffe0b2}
.arx-wind-severe .arx-wind-lbl{background:#c2185b;color:#fff}
.arx-wind .arx-wind-puff{position:absolute;left:-6px;top:-12px;font-size:16px;line-height:1;pointer-events:none}
.arx-wind .arx-wind-puff.moving{animation:arx-drift 1.8s linear infinite}
@keyframes arx-drift{0%{transform:translate(0,0);opacity:0}25%{opacity:1}100%{transform:translate(calc(var(--dx) * 2.2),calc(var(--dy) * 2.2));opacity:0}}
.arx-wind .arx-wind-pulse{position:absolute;left:50%;top:50%;width:34px;height:34px;margin:-17px 0 0 -17px;border-radius:50%;border:3px solid #e91e63;animation:arx-wpulse 1.4s ease-out infinite}
@keyframes arx-wpulse{0%{transform:scale(.5);opacity:.9}100%{transform:scale(1.6);opacity:0}}
@media (prefers-reduced-motion:reduce){.arx-wind .arx-wind-puff.moving,.arx-wind .arx-wind-pulse{animation:none}}

/* Very small phones (iPhone SE and similar): buttons, then the slider, then the time with the map toggles */
@media (max-width:360px){
  body.arx .radar-loop-control{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"btns btns" "track track" "frame bolt"}
  body.arx .arx-player-toggles .arx-lightning-btn{min-width:40px}
}

/* Winds shading and flow canvases (ar-winds.js) */
.arx-wind-shade,.arx-wind-flow{position:absolute;left:0;top:0;pointer-events:none;transition:opacity .15s}
body.arx .arx-switch.arx-sub-switch{margin-left:1.2rem;width:calc(100% - 1.2rem)}
.arx-wind-rwis .arx-wind-arrow{opacity:.9}

/* Bold wind badges (ar-winds.js) */
.arx-wind .arx-wind-badge{position:absolute;left:50%;top:50%;width:26px;height:26px;margin:-13px 0 0 -13px;border-radius:50%;border:2px solid #0b1624;box-shadow:0 1px 4px #000a;display:flex;align-items:center;justify-content:center}
.arx-wind .arx-wind-badge.big{width:32px;height:32px;margin:-16px 0 0 -16px}
.arx-wind .arx-wind-badge .arx-wind-arrow{position:static;width:auto;height:auto;margin:0;filter:none;display:flex}
.arx-wind .arx-wind-lbl{left:21px;top:14px;font-size:12px;border:1px solid #0b162433}
.arx-wind-rwis .arx-wind-badge{opacity:.92}

/* Four map toggles on the radar player (🌀 ⛈️ 💨 ⚡) */
body.arx .arx-rot-btn[aria-pressed="true"]{background:#ab47bc;border-color:#ab47bc;color:#fff;box-shadow:0 0 0 2px #ab47bc55}
body.arx .arx-tracks-btn[aria-pressed="true"]{background:#90caf9;border-color:#90caf9;color:#0b1624;box-shadow:0 0 0 2px #90caf955}
body.arx .arx-player-toggles{gap:5px}
@media (max-width:899px){
  body.arx .arx-player-toggles .arx-lightning-btn{min-width:38px;padding:0 .35rem;font-size:.95rem}
  body.arx .arx-frame .state{display:none}
}

/* Phones: the four map toggles get their own row across the player, so the frame time is never cut */
@media (max-width:899px){
  body.arx .radar-loop-control{grid-template-areas:"btns track track" "frame frame frame" "bolt bolt bolt"}
  body.arx .arx-player-toggles{justify-self:stretch;display:grid;grid-template-columns:repeat(4,1fr);gap:6px;margin-top:4px}
  body.arx .arx-player-toggles .arx-lightning-btn{min-width:0;min-height:36px;width:100%;font-size:1.05rem}
  body.arx .arx-frame .state{display:inline}
}
@media (max-width:360px){
  body.arx .radar-loop-control{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"btns btns" "track track" "frame frame" "bolt bolt"}
}

/* The toggles share .arx-lightning-btn, whose grid-area is for the old single button: reset it inside the group */
body.arx .arx-player-toggles .arx-lightning-btn{grid-area:auto;justify-self:stretch}
body.arx .arx-rivers-btn[aria-pressed="true"]{background:#26a69a;border-color:#26a69a;color:#fff;box-shadow:0 0 0 2px #26a69a55}
@media (max-width:899px){ body.arx .arx-player-toggles{grid-template-columns:repeat(5,1fr)} }
/* 🔌 power outages on the radar player (ar-outages.js), a sixth toggle */
body.arx .arx-outages-btn[aria-pressed="true"]{background:#f47c3c;border-color:#f47c3c;color:#14202c;box-shadow:0 0 0 2px #f47c3c55}
@media (max-width:899px){ body.arx .arx-player-toggles{grid-template-columns:repeat(6,1fr)} }

/* First-visit and install cards: above the map buttons and player, with a close × (ar-layout.js) */
body.arx .arx-cards .ar-card{position:relative}
body.arx .arx-card-x{position:absolute;top:6px;right:6px;width:40px;height:40px;min-height:40px!important;padding:0;border-radius:50%;border:1px solid #45637b;background:#0b1624;color:#fff;font-size:24px;line-height:1;cursor:pointer;z-index:1}
body.arx .arx-cards .ar-card h2{padding-right:46px}
body.arx.arx-card-open .arx-tools{z-index:1150}
@media (max-width:899px){
  body.arx.arx-card-open .leaflet-control-zoom,body.arx.arx-card-open .arx-right{visibility:hidden}
  body.arx .arx-cards .ar-card{max-height:calc(100svh - 300px);overflow-y:auto}
}

/* The top stack (search, chips, notes, cards) stays above the side buttons: a note's × is never covered */
body.arx .arx-tools{z-index:1001}

/* Notes: solid background, and the × always in the top-right corner (it used to wrap onto its own line) */
body.arx .arx-note{position:relative;background:#0f2233;padding-right:46px}
body.arx .arx-note .x{position:absolute;top:4px;right:4px;margin:0;min-width:40px;min-height:40px;display:flex;align-items:center;justify-content:center}

/* Compact radar player on phones (owner: "the play button box is too big on mobile"):
   row 1: ▶ and the slider; row 2: a short time label (tap = latest) and the five map toggles.
   The ‹ › and Latest buttons are desktop only. */
body.arx .arx-frame .short{display:none}
@media (max-width:899px){
  body.arx .radar-loop-control{grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:"btns track track" "frame frame bolt";gap:4px 8px;padding:6px 8px!important}
  body.arx #radar-loop-prev,body.arx #radar-loop-next,body.arx #radar-loop-stop{display:none!important}
  body.arx #radar-loop-button{width:46px;min-height:40px!important}
  body.arx #radar-loop-range{height:40px}
  body.arx .arx-frame .kind,body.arx .arx-frame>span,body.arx .arx-frame .state{display:none!important}
  body.arx .arx-frame .short{display:inline-flex;align-items:center;min-height:34px;max-width:100%;padding:0 .55rem;border-radius:8px;border:1px solid var(--arx-obs,#2f7fd0);background:#123a5c;color:#dff0ff;font:inherit;font-size:.82rem;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;cursor:pointer}
  body.arx .arx-frame .short.fc{border:1px dashed var(--arx-fc,#9b6bd8);background:#35205a;color:#ecd9ff}
  body.arx .arx-frame .short.bad{border-color:#d86a74;background:#40262a;color:#ffd0d4}
  body.arx .arx-player-toggles{justify-self:end;display:flex;gap:5px;margin-top:0}
  body.arx .arx-player-toggles .arx-lightning-btn{width:36px;min-width:36px;min-height:34px;padding:0;font-size:.95rem}
}
@media (max-width:360px){
  body.arx .radar-loop-control{grid-template-columns:auto minmax(0,1fr) auto;grid-template-areas:"btns track track" "frame frame bolt"}
  body.arx .arx-player-toggles{gap:3px}
  body.arx .arx-player-toggles .arx-lightning-btn{width:32px;min-width:32px}
  body.arx .arx-frame .short{font-size:.75rem;padding:0 .4rem}
}
