/* Quakemap dashboard shell, implemented without an additional UI dependency. */
:root{color-scheme:light;--bg:#f2f5f8;--panel:#fff;--line:#dce4ec;--text:#1b2b40;--muted:#566b80;--mint:#216a83;--gold:#946015;--red:#ad4936}
body{min-width:320px}html{scroll-padding-top:90px}.skip-link{position:absolute;left:12px;top:-80px;z-index:100;background:white;padding:10px}.skip-link:focus{top:10px}.topbar{max-width:none;position:sticky;top:0;z-index:20;height:72px;padding:0 28px;background:#142438;border:0;color:#fff}.brand{font-size:20px;letter-spacing:-.5px;text-transform:none;color:#eef4fa;gap:10px}.brand-icon{display:grid;place-items:center;width:32px;height:32px;border-radius:9px;background:#9de8c7;color:#142438;font-size:26px}.badge{color:#bcd8ce;border-color:#648078}.top-note{color:#b8c9da}.dashboard-sidebar{position:fixed;top:72px;bottom:0;left:0;width:210px;background:#fff;border-right:1px solid var(--line);padding:24px 16px;display:flex;flex-direction:column;z-index:19}.view-tabs{display:flex;flex-direction:column;border:0;gap:4px;padding:0}.view-tabs button{flex:none;width:100%;max-width:none;text-align:left;border:0;border-radius:7px;padding:11px 14px;color:#52667c;font-size:14px}.view-tabs [aria-selected=true]{background:#eaf1f8;color:#1d5d91}.sidebar-note{margin-top:auto;font-size:12px;color:var(--muted);line-height:1.8}.page-content{margin-left:210px}main,footer{max-width:1600px;padding-left:28px;padding-right:28px}.intro{padding:26px 0 8px;background:none}.intro h1{font-size:28px;letter-spacing:-.6px;font-weight:650}.intro-description{color:var(--muted);font-size:14px;margin:10px 0}.toolbar{padding:10px 0 22px;align-items:center}#connection{border-radius:24px;background:#e5edf4;color:#47617a;padding:8px 13px}.overview-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:24px}.card,.archive-section{box-shadow:0 3px 14px #1b2b4005;padding:22px;border-radius:12px}.card-head{padding-bottom:12px;border-bottom:1px solid var(--line)}.card h2{font-size:18px}.content p{color:#52667c}.value.mint{color:#216a83}.chart-frame{background:#f8fafc;border-color:#dce4ec}.history-bar.quiet,.meter i.on{background:#4c9f91}.history-bar.storm,.meter i.storm.on{background:#d89c45}.history-bar.severe{background:#ce705b}.meter i{background:#dfe7ed}.history-bar.is-reading{outline-color:#1b2b40}.periods [aria-pressed=true]{background:#e3eef6;border-color:#8cacbf;color:#1d5d91}button:hover{background:#eaf1f8}.aurora-summary .aurora-marker{background:#f8fafc;color:#267e70}.aurora-track{border-color:#7da69f;background:#e9f2ef}.situation{background:#eaf3f2;border-color:#c5dcda;min-height:0}.situation p:not(.eyebrow){color:#3a5866}.situation .eyebrow{color:#216a83}.scale-pill{background:#fff;border-color:#c5d8df}.status{color:#286e62}.status.warning,.error{color:#986014!important}.overview-note{font-size:12px}.aurora-summary h3{font-size:22px}.aurora-summary button{font-size:13px}footer{background:#fff;padding-top:20px;padding-bottom:20px;font-size:11px;margin-top:28px}.history-navigation input{background:#fff}.lightbox-head{background:#fff}.aurora-inline .aurora-image-frame{max-width:390px}#navigation-toggle{display:none;color:#fff;border-color:#7890a5}#navigation-toggle:hover{background:#294057}
@media(max-width:1100px) and (min-width:992px){main,footer{padding-inline:20px}.overview-grid{gap:16px}.card{padding:18px}}
@media(max-width:991px){.page-content{margin-left:0}.topbar{padding-inline:20px}.top-note{display:none}#navigation-toggle{display:block}.dashboard-sidebar{display:none;top:72px;bottom:auto;width:100%;padding:16px 20px;box-shadow:0 10px 20px #14243820}.dashboard-sidebar.is-open{display:flex}.sidebar-note{display:none}.dashboard-sidebar .eyebrow{margin-bottom:8px}.overview-grid{gap:18px}}
@media(max-width:600px){main,footer{padding-inline:14px}.topbar{height:64px;padding-inline:14px}.brand{font-size:17px}.dashboard-sidebar{top:64px}.intro{padding-top:20px}.intro h1{font-size:23px}.intro-description{font-size:13px}.overview-grid{grid-template-columns:1fr;gap:16px}.toolbar{gap:10px;font-size:10px}.toolbar span{max-width:55%}.card,.archive-section{padding:16px}.overview-grid .card{padding:16px}.aurora-summary h3{font-size:21px}.view-tabs button{font-size:14px}}
.info-dialog{width:min(860px,94vw);max-width:94vw;max-height:90dvh;padding:0 22px 22px;border:1px solid var(--line);border-radius:12px;background:var(--panel);color:var(--text);overflow:auto}.info-dialog::backdrop{background:#142438aa}.info-dialog-head{position:sticky;top:0;z-index:1;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:18px 0;background:var(--panel);border-bottom:1px solid var(--line)}.info-dialog-head h2{font-size:18px;margin:0}.info-dialog-head button{font-size:12px}.info-dialog .archive-section{margin-top:14px!important;padding:0;border:0;box-shadow:none}.info-dialog .situation{margin-top:18px}.context-action{font-size:12px;text-align:left;color:var(--mint);margin-top:12px;white-space:normal}body:has(.info-dialog[open]){overflow:hidden}@media(max-width:600px){.info-dialog{padding:0 14px 14px}.info-dialog-head h2{font-size:16px}.info-dialog .timeline-item{grid-template-columns:1fr}}
.aurora-summary>.aurora-inline{margin-top:0;padding-top:0;border-top:0}.observations-group{margin-top:22px;padding-top:20px;border-top:1px solid var(--line)}.observations-group .eyebrow{margin-bottom:8px}.observations-group #aurora-track{margin-top:12px}.observations-group #sightings-summary h3{font-size:20px;margin:4px 0 8px}
.sighting-row{display:grid;grid-template-columns:110px minmax(0,1fr);gap:12px;align-items:start;padding:12px 14px;background:#f2f6fa;border-block:1px solid var(--line);font-size:13px}.sighting-row time{font-weight:650;color:var(--text);font-size:13px;white-space:nowrap;font-variant-numeric:tabular-nums}.sighting-places{overflow-wrap:anywhere;line-height:1.5}.observations-group #sightings-summary>.meta{margin:6px 0;font-size:11px}.observations-group>#sightings-summary+.meta{font-size:11px;line-height:1.5;margin:6px 0 10px}#sightings-list{border:1px solid var(--line);border-radius:8px;overflow:hidden;margin-top:16px}#sightings-list .sighting-row{border:0;border-bottom:1px solid var(--line);padding:14px;gap:14px}#sightings-list .sighting-row:nth-child(even){background:#fff}#sightings-list .sighting-row:last-child{border-bottom:0}#sightings-list h3.sighting-places{font-size:13px;margin:0 0 8px;font-weight:650}#sightings-list .sighting-row p{line-height:1.5;margin:6px 0}#sightings-list .sighting-row a{display:inline-block;overflow-wrap:anywhere}#sightings-list .sighting-row:focus{outline-offset:-2px}@media(max-width:480px){.sighting-row,#sightings-list .sighting-row{grid-template-columns:1fr;gap:4px;padding:10px 12px}}
footer{flex-wrap:wrap}.legal-links{display:flex;gap:18px;flex-wrap:wrap}

body:not(.show-explanations) [data-explanation]{display:none!important}
.explanations-toggle{margin-top:auto;padding:10px;border:1px solid transparent;border-radius:8px;display:flex;align-items:center;gap:9px;color:var(--muted);font-size:12px;line-height:1.5;cursor:pointer;min-height:44px}
.explanations-toggle input{margin:0;width:16px;height:16px;flex-shrink:0;accent-color:var(--mint)}
@media(max-width:991px){.explanations-toggle{margin-top:12px}}

/* The same amber accent connects the explanation switch and its content. */
.show-explanations .explanations-toggle,
.show-explanations [data-explanation]{background:#fbc219;border:0;border-radius:8px;color:#332800}
.show-explanations .explanations-toggle input{accent-color:#98600c}
.show-explanations [data-explanation]{padding:10px 12px}
.show-explanations [data-explanation] :is(p,summary,a){color:inherit}
.show-explanations button[data-explanation]:hover{background:#fbc219}
.show-explanations details[data-explanation]>summary{font-weight:600}

#history-chart{position:relative}
.history-tooltip{position:absolute;z-index:3;width:max-content;max-width:calc(100% - 16px);padding:9px 12px;border-radius:6px;background:#142438;color:#fff;font-size:12px;line-height:1.5;box-shadow:0 3px 12px #14243825;pointer-events:none}
.history-tooltip[hidden]{display:none}

/* Fixed photo backdrop, separate from the opaque navigation shell. */
body.dashboard-layout{background:#292735}
.dashboard-layout::before{content:"";position:fixed;inset:72px 0 0;z-index:-1;background:url('images/starry-background.jpg') center bottom / cover no-repeat;pointer-events:none}
.dashboard-layout .page-content{background:transparent}
.dashboard-layout main>.intro h1,.dashboard-layout main>.intro>.eyebrow,.dashboard-layout .refresh-countdown{color:#fff;text-shadow:0 1px 4px #0009}
.dashboard-layout main .card,.dashboard-layout main .archive-section{background:rgba(255,255,255,.92)}
.dashboard-layout #measurements>p{background:rgba(255,255,255,.92);padding:10px 12px;border-radius:8px}
@media(max-width:600px){.dashboard-layout::before{top:64px}}

/* Night palette for the public dashboard; the editorial tool stays light. */
body.dashboard-layout{color-scheme:dark;--bg:#101e2b;--panel:#192c3c;--line:#385062;--text:#e3ebf1;--muted:#b3c4d1;--mint:#8bd6c3;--gold:#edbc72;--red:#f29a83;background:#101e2b}
.dashboard-layout::before{background-image:linear-gradient(#07152235,#07152235),url('images/night-sky-background.jpg')}
.dashboard-layout .topbar,.dashboard-layout .dashboard-sidebar,.dashboard-layout footer{background:#142438;color:var(--muted)}
.dashboard-layout main .card,.dashboard-layout main .archive-section,.dashboard-layout #measurements>p{background:rgba(22,41,57,.85)}
.dashboard-layout .view-tabs button{color:var(--muted)}
.dashboard-layout .view-tabs [aria-selected=true],.dashboard-layout .periods [aria-pressed=true]{background:#304d61;color:#e3f6ff;border-color:#7194ab}
.dashboard-layout button:hover{background:#304d61}
.dashboard-layout .content p,.dashboard-layout .intro-description{color:var(--muted)}
.dashboard-layout .value.mint,.dashboard-layout .status{color:var(--mint)}
.dashboard-layout .status.warning,.dashboard-layout .error{color:var(--gold)!important}
.dashboard-layout #connection{background:#294355;color:#dce9f1}
.dashboard-layout .chart-frame{background:rgba(13,29,42,.75);border-color:var(--line)}
.dashboard-layout .history-bar.is-reading{outline-color:#e3ebf1}
.dashboard-layout .meter i{background:#354c5b}
.dashboard-layout .meter i.on{background:#4c9f91}
.dashboard-layout .meter i.storm.on{background:#d89c45}
.dashboard-layout .sighting-row,.dashboard-layout #sightings-list .sighting-row:nth-child(even){background:#21394b}
.dashboard-layout #sightings-list .sighting-row:nth-child(odd){background:#192e3f}
.dashboard-layout .aurora-track{background:#24443f;border-color:#52877b}
.dashboard-layout .aurora-summary .aurora-marker{background:#182f3e;color:#a4ebd5}
.dashboard-layout .history-navigation input,.dashboard-layout .lightbox-head,.dashboard-layout .info-dialog-head{background:var(--panel);color:var(--text)}
.dashboard-layout .situation{background:#213e43;border-color:#45676c}
.dashboard-layout .situation p:not(.eyebrow){color:#c7dfdf}
.dashboard-layout .situation .eyebrow{color:var(--mint)}
.dashboard-layout .scale-pill{background:#192e3f;border-color:var(--line)}
.dashboard-layout.show-explanations [data-explanation],.dashboard-layout.show-explanations .explanations-toggle{background:#fbc219;color:#332800}
.dashboard-layout.show-explanations [data-explanation] :is(p,summary,a){color:inherit}

@media(min-width:992px){
  .dashboard-layout .dashboard-sidebar{background:rgba(20,36,56,.55)}
  .dashboard-layout .dashboard-sidebar .eyebrow,
  .dashboard-layout .dashboard-sidebar .explanations-toggle{color:#e3ebf1}
  .dashboard-layout .dashboard-sidebar .view-tabs button{color:#e3ebf1}
  .dashboard-layout.show-explanations .dashboard-sidebar .explanations-toggle{color:#332800}
}

.overview-grid{align-items:start}
.detail-tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);padding-bottom:12px;margin-bottom:18px}
.aurora-summary .detail-tabs button{flex:1;min-width:0;padding:9px 5px;margin:0;font-size:12px;white-space:normal;border-color:transparent}
.dashboard-layout .detail-tabs [aria-selected=true]{background:#304d61;color:#e3f6ff;border-color:#7194ab}
.aurora-summary>[role=tabpanel]{margin-top:0;padding-top:0;border-top:0}
.aurora-summary>[role=tabpanel][hidden]{display:none}
@media(max-width:400px){.aurora-summary .detail-tabs button{font-size:11px;padding-inline:3px}}

/* Standalone tabs above the panel, with open background beside them. */
.dashboard-layout main .card.aurora-summary{background:transparent;border:0;padding:0;box-shadow:none}
.aurora-summary .detail-tabs{display:inline-flex;width:auto;max-width:100%;gap:3px;margin:0;padding:0;border:0;vertical-align:bottom}
.aurora-summary .detail-tabs button{flex:0 1 auto;margin:0;padding:12px 14px;border:1px solid var(--line);border-bottom:0;border-radius:10px 10px 0 0;background:rgba(13,29,42,.72);color:var(--muted)}
.dashboard-layout .aurora-summary .detail-tabs [aria-selected=true]{background:rgba(22,41,57,.95);color:#e3f6ff;border-color:#7194ab;box-shadow:inset 0 3px #8bd6c3}
.aurora-summary>[role=tabpanel]{padding:22px;border:1px solid var(--line);border-radius:0 12px 12px 12px;background:rgba(22,41,57,.85);box-shadow:0 3px 14px #1b2b4005}
@media(max-width:600px){.aurora-summary>[role=tabpanel]{padding:16px}.aurora-summary .detail-tabs button{padding:11px 10px;font-size:12px}}
@media(max-width:380px){.aurora-summary .detail-tabs button{padding-inline:7px;font-size:11px}}

/* Bright stellar blue for navigation and interactive accents. */
body.dashboard-layout{--mint:#82caff}
.dashboard-layout .brand-icon{background:#82caff;color:#fff}
.dashboard-layout .badge{color:#c0e4ff;border-color:#557f9f}
.dashboard-layout .view-tabs [aria-selected=true],
.dashboard-layout .periods [aria-pressed=true]{background:#254a64;color:#e0f3ff;border-color:#6aafd9}
.dashboard-layout .aurora-summary .detail-tabs [aria-selected=true]{color:#e0f3ff;border-color:#6aafd9;box-shadow:inset 0 3px #82caff}
.dashboard-layout .aurora-summary .aurora-marker{color:#82caff}
.dashboard-layout .legend span:first-child{color:#72b8aa}

/* Calm Kp intervals use a darker blue than the primary accent. */
.dashboard-layout .history-bar.quiet,
.dashboard-layout .meter i.on{background:#478fbe}
.dashboard-layout .meter i.storm.on{background:#d89c45}
.dashboard-layout .legend span:first-child{color:#478fbe}

.aurora-summary .detail-tabs button{border-radius:5px 5px 0 0}
.dashboard-layout .aurora-summary .detail-tabs [aria-selected=true]{box-shadow:inset 0 2px #82caff}
.aurora-summary .detail-tabs button:focus-visible{outline:2px solid #82caff;outline-offset:-4px}

/* Selection uses a flat fill; keyboard focus uses a text underline. */
.dashboard-layout .aurora-summary .detail-tabs button{border:0;box-shadow:none}
.dashboard-layout .aurora-summary .detail-tabs [aria-selected=true]{background:#365f7b;color:#fff;box-shadow:none}
.dashboard-layout .aurora-summary .detail-tabs button:focus-visible{outline:none;text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:5px}

.aurora-summary .aurora-inline .aurora-image-frame{width:100%;max-width:none}

.brand-badges{display:inline-flex;gap:5px;align-items:center}
.brand-badges .badge{box-sizing:border-box;width:34px;height:20px;display:inline-flex;align-items:center;justify-content:center;padding:0;flex-shrink:0}
.dashboard-layout .badge-austria{background:linear-gradient(to bottom,#d83240 0 33.333%,#fff 33.333% 66.667%,#d83240 66.667% 100%);border-color:#ffffff40}
@media(max-width:380px){.brand{gap:6px;font-size:15px}.brand-badges{gap:4px}}

.kp-history .history-options{position:relative;margin:0}
.history-options>summary{display:flex;align-items:center;justify-content:center;list-style:none;width:30px;height:32px;border:1px solid var(--line);border-radius:6px;font-size:22px;line-height:1;cursor:pointer;color:var(--text)}
.history-options>summary::-webkit-details-marker{display:none}
.history-options[open]>summary,.history-options>summary:hover{background:#304d61}
.history-dropdown{position:absolute;right:0;bottom:calc(100% + 8px);z-index:6;width:300px;max-width:calc(100vw - 64px);padding:16px;background:var(--panel);border:1px solid var(--line);border-radius:8px;box-shadow:0 8px 24px #0006}
.history-dropdown .eyebrow{font-size:10px;margin:0 0 12px}
.history-dropdown .history-navigation{margin:0;gap:10px;flex-wrap:wrap}
.history-dropdown .meta{margin-bottom:0}

.dashboard-layout .info-dialog::backdrop,.dashboard-layout :is(#aurora-lightbox,#magnetosphere-lightbox)::backdrop{background:rgba(3,9,16,.9)}

/* One quiet status block for source health and the refresh countdown. */
.dashboard-layout .toolbar{justify-content:flex-end}
.refresh-status{display:flex;flex-direction:column;align-items:flex-end;gap:5px;max-width:100%;padding:10px 14px;border-radius:8px;background:rgba(35,43,51,.88);font-size:11px;line-height:1.5;text-align:right}
.dashboard-layout .refresh-status #connection{background:none;padding:0;border-radius:0;color:#d2dce4}
.dashboard-layout .refresh-status .refresh-countdown{color:#acbbc7;text-shadow:none}
.dashboard-layout .toolbar .refresh-status span{max-width:100%}

.refresh-status{box-sizing:border-box;width:230px;min-height:58px;font-variant-numeric:tabular-nums}
.refresh-status>span{display:block;min-height:16.5px;white-space:nowrap}

/* Full-width footer flush with the bottom of short pages. */
.dashboard-layout .page-content{min-height:calc(100dvh - 72px);display:flex;flex-direction:column}
.dashboard-layout main{width:100%;margin:0 auto;flex:1}
.dashboard-layout footer{width:100%;max-width:none;margin:28px 0 0}
@media(max-width:600px){.dashboard-layout .page-content{min-height:calc(100dvh - 64px)}}
