/* foinfo — a calm sea-chart board.
   Layout: "Støðan nú" summary, category tiles, then notices beside the map; weather, notices from KVF and sources below. */
/* Fonts are served from this site (subsets of open fonts, see fonts/LICENSE.txt): no requests to Google. */
@font-face { font-family: "Schibsted Grotesk"; src: url("fonts/schibsted-grotesk.woff2") format("woff2"); font-weight: 500 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Public Sans"; src: url("fonts/public-sans.woff2") format("woff2"); font-weight: 400 600; font-style: normal; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("fonts/ibm-plex-mono-400.woff2") format("woff2"); font-weight: 400 500; font-style: normal; font-display: swap; }

:root {
  --bg: #edf2f4;
  --surface: #ffffff;
  --surface-2: #f5f8f9;
  --ink: #0e2330;
  --muted: #536772;
  --line: #d4dee2;
  --sea: #dbe7ec;
  --land: #b5c8a8;
  --land-edge: #7e9874;
  --accent: #1b4f93;
  --accent-soft: #e2ebf7;
  --accent-ink: #ffffff;
  --ok: #2b7a4b;
  --ok-soft: #e0f1e6;
  --warn: #8f5709;
  --warn-soft: #fbedd2;
  --crit: #b92e24;
  --crit-soft: #f8dfdb;
  --on-sev: #ffffff;
  --wind: #1b4f93;
  --head-bg: #0e2330;
  --head-bg-2: #143448;
  --head-fg: #e9f0f2;
  --shadow: 0 1px 2px rgb(14 35 48 / 0.06), 0 4px 16px rgb(14 35 48 / 0.06);

  --f-display: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Public Sans", "Segoe UI", Roboto, Arial, sans-serif;
  --f-data: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --r: 12px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b151a; --surface: #111e26; --surface-2: #15242d; --ink: #e3ecef; --muted: #95a9b2; --line: #22353f;
    --sea: #0e1d25; --land: #33493a; --land-edge: #557259;
    --accent: #8fb2ee; --accent-soft: #1b2b44; --accent-ink: #0b151a;
    --ok: #5cc48b; --ok-soft: #14301f; --warn: #e6ad50; --warn-soft: #3a2b11; --crit: #f07a6f; --crit-soft: #3f1a17; --on-sev: #0b151a;
    --wind: #a9c6f5; --head-bg: #070f14; --head-bg-2: #0d1d27; --head-fg: #e3ecef;
    --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 4px 16px rgb(0 0 0 / 0.25);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b151a; --surface: #111e26; --surface-2: #15242d; --ink: #e3ecef; --muted: #95a9b2; --line: #22353f;
  --sea: #0e1d25; --land: #33493a; --land-edge: #557259;
  --accent: #8fb2ee; --accent-soft: #1b2b44; --accent-ink: #0b151a;
  --ok: #5cc48b; --ok-soft: #14301f; --warn: #e6ad50; --warn-soft: #3a2b11; --crit: #f07a6f; --crit-soft: #3f1a17; --on-sev: #0b151a;
  --wind: #a9c6f5; --head-bg: #070f14; --head-bg-2: #0d1d27; --head-fg: #e3ecef;
  --shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 4px 16px rgb(0 0 0 / 0.25);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.5 var(--f-body); }
a { color: var(--accent); text-underline-offset: 2px; }
a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible, summary:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
h1, h2, h3 { font-family: var(--f-display); text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: 1.12rem; font-weight: 700; }
.ico { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
.num { font-family: var(--f-data); font-variant-numeric: tabular-nums; white-space: nowrap; }
.muted { color: var(--muted); }

.wrap {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}

/* ---------- Header ---------- */
.top { background: linear-gradient(180deg, var(--head-bg), var(--head-bg-2)); color: var(--head-fg); }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--head-bg); }
.top-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s3) var(--s4); padding-block: var(--s4) var(--s3); }
.brand { display: flex; align-items: center; gap: var(--s3); color: inherit; text-decoration: none; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 9px; flex: none; box-shadow: inset 0 0 0 1px rgb(255 255 255 / 0.25);
  background:
    linear-gradient(90deg, transparent 30%, #c8102e 30% 42%, transparent 42%),
    linear-gradient(0deg, transparent 42%, #c8102e 42% 56%, transparent 56%),
    linear-gradient(90deg, transparent 25%, #2a5db0 25% 47%, transparent 47%),
    linear-gradient(0deg, transparent 37%, #2a5db0 37% 61%, transparent 61%),
    #ffffff;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text b { font-family: var(--f-display); font-weight: 800; font-size: 1.45rem; letter-spacing: -0.02em; }
.brand-text small { font-size: 0.74rem; opacity: 0.72; letter-spacing: 0.08em; text-transform: uppercase; margin-top: 2px; }
.nav { display: flex; gap: 4px; margin-right: auto; }
.nav a { color: inherit; text-decoration: none; font-weight: 600; font-size: 0.9rem; padding: 6px 13px; border-radius: 999px; opacity: 0.72; }
.nav a:hover { opacity: 1; background: rgb(255 255 255 / 0.08); }
.nav a[aria-current="page"] { opacity: 1; background: rgb(255 255 255 / 0.15); }
.top-meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s3); font-size: 0.85rem; }
.updated { font-family: var(--f-data); opacity: 0.8; min-width: 17ch; text-align: right; }
.sos { background: #c8102e; color: #fff; padding: 5px 12px; border-radius: 999px; font-weight: 600; }
.sos b { font-family: var(--f-data); font-size: 1rem; }
.place-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); padding-block: 0 var(--s4); }
.place-label { font-weight: 600; display: inline-flex; gap: 6px; align-items: center; }
#place {
  font: inherit; font-size: 0.95rem; padding: 7px 10px; border-radius: 9px; min-width: 0; max-width: 100%;
  background: var(--surface); color: var(--ink); border: 1px solid var(--line);
}
.place-hint { font-size: 0.82rem; opacity: 0.72; }
@media (max-width: 640px) {
  .nav { order: 3; width: 100%; }
  .place-hint { display: none; }
}

main.wrap { display: flex; flex-direction: column; gap: var(--s5); padding-block: var(--s5) var(--s7); position: relative; }
/* Until the data has been drawn the page is hidden, so nothing jumps while it loads.
   If the script never runs, it shows anyway after 4 seconds. */
main[aria-busy="true"] > * { visibility: hidden; animation: reveal 0s 4s forwards; }
main[aria-busy="true"]::before { content: "Lesur inn…"; position: absolute; left: 0; right: 0; text-align: center; color: var(--muted); padding-top: var(--s6); animation: reveal-hide 0s 4s forwards; }
@keyframes reveal { to { visibility: visible; } }
@keyframes reveal-hide { to { visibility: hidden; } }

/* ---------- Støðan nú ---------- */
.now { display: grid; gap: var(--s3); }
.now-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--s1) var(--s4); }
.now-head h1 { font-size: clamp(1.7rem, 4.2vw, 2.4rem); font-weight: 800; letter-spacing: -0.025em; }
.now-date { margin: 0; color: var(--muted); font-size: 0.9rem; }
.now-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: var(--s2); }
.now-item { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: var(--s3); align-items: start; padding: var(--s3) var(--s4); background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); }
.now-item a { color: inherit; text-decoration: none; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.now-item a:hover b { text-decoration: underline; }
.now-item b { font-family: var(--f-display); font-weight: 700; font-size: 1rem; line-height: 1.3; overflow-wrap: anywhere; }
.now-meta { font-size: 0.8rem; color: var(--muted); display: block; }
.now-ico { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.now-ico .ico { width: 19px; height: 19px; }
.now-item[data-sev="warning"] .now-ico { background: var(--warn); color: var(--on-sev); }
.now-item[data-sev="critical"] .now-ico { background: var(--crit); color: var(--on-sev); }
.now-item.is-calm .now-ico { background: var(--ok-soft); color: var(--ok); }

/* ---------- Category tiles ---------- */
.status-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s2); }
@media (min-width: 640px) { .status-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.stat {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0 var(--s3); align-items: center;
  padding: var(--s3); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  text-align: left; font: inherit; color: inherit; cursor: pointer; transition: border-color 0.15s, background 0.15s;
}
.stat:hover { border-color: var(--muted); }
.stat-ico { grid-row: span 2; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); }
.stat b { font-family: var(--f-display); font-weight: 700; font-size: 0.93rem; line-height: 1.2; }
.stat-txt { font-size: 0.8rem; color: var(--muted); }
.stat[data-sev="ok"] .stat-ico { background: var(--ok-soft); color: var(--ok); }
.stat[data-sev="info"] .stat-ico { background: var(--accent-soft); color: var(--accent); }
.stat[data-sev="warning"] { background: var(--warn-soft); border-color: transparent; }
.stat[data-sev="warning"] .stat-ico { background: var(--warn); color: var(--on-sev); }
.stat[data-sev="warning"] .stat-txt { color: var(--warn); font-weight: 600; }
.stat[data-sev="critical"] { background: var(--crit-soft); border-color: transparent; }
.stat[data-sev="critical"] .stat-ico { background: var(--crit); color: var(--on-sev); }
.stat[data-sev="critical"] .stat-txt { color: var(--crit); font-weight: 600; }
.stat[aria-pressed="true"] { outline: 2px solid var(--ink); outline-offset: -1px; }

/* ---------- Notices and map ---------- */
.main-grid { display: grid; grid-template-columns: 1fr; gap: var(--s5); align-items: start; }
@media (min-width: 960px) {
  .main-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
  .map-card { position: sticky; top: var(--s4); }
}
.map-card, .feed-card { background: var(--surface); border-radius: var(--r); min-width: 0; box-shadow: var(--shadow); overflow: hidden; }
.card-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s2); padding: var(--s3) var(--s4); border-bottom: 1px solid var(--line); }
.map-tools { display: flex; flex-wrap: wrap; gap: var(--s2); align-items: center; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 9px; overflow: hidden; }
.seg button { font: inherit; font-size: 0.82rem; padding: 5px 11px; background: transparent; color: var(--muted); border: 0; cursor: pointer; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button.on { background: var(--ink); color: var(--bg); }
.zoom-out { font: inherit; font-size: 0.82rem; padding: 5px 11px; border-radius: 9px; border: 1px solid var(--accent); background: var(--accent-soft); color: var(--accent); cursor: pointer; font-weight: 600; }

.map-wrap { position: relative; background: radial-gradient(120% 90% at 30% 20%, var(--surface-2), var(--sea)); }
.fo-map { display: block; width: 100%; height: auto; max-height: 74vh; aspect-ratio: 1000 / 1493; max-width: 100%; margin-inline: auto; }
.fo-map .land { fill: var(--land); stroke: var(--land-edge); stroke-width: 1px; }
.fo-map .village { fill: var(--ink); opacity: 0.35; }
.fo-map .village.mine { fill: var(--accent); opacity: 1; }
.fo-map .mine-ring { fill: none; stroke: var(--accent); }
.fo-map .lbl { font-family: var(--f-display); font-weight: 600; fill: var(--ink); paint-order: stroke; stroke: var(--sea); stroke-linejoin: round; pointer-events: none; }
.fo-map .lbl-mine { fill: var(--accent); font-weight: 800; }
.fo-map .wind-arrow { stroke: var(--wind); fill: var(--wind); }
.fo-map .wind-txt { font-family: var(--f-data); font-weight: 500; fill: var(--wind); paint-order: stroke; stroke: var(--sea); stroke-linejoin: round; cursor: default; }
.fo-map .road-st { stroke: var(--surface); cursor: pointer; }
.fo-map .road-st[data-g="lo"] { fill: var(--wind); opacity: 0.55; }
.fo-map .road-st[data-g="hi"] { fill: var(--warn); }
.fo-map .road-st[data-g="xhi"] { fill: var(--crit); }
.fo-map .marker { cursor: pointer; }
.fo-map .marker circle { stroke: var(--surface); }
.fo-map .marker[data-sev="info"] > circle:first-child { fill: var(--accent); }
.fo-map .marker[data-sev="warning"] > circle:first-child { fill: var(--warn); }
.fo-map .marker[data-sev="critical"] > circle:first-child,
.fo-map .marker.is-closure > circle:first-child { fill: var(--crit); }
.fo-map .marker .mk-ico { color: var(--on-sev); pointer-events: none; }
.fo-map .marker:hover > circle:first-child, .fo-map .marker:focus > circle:first-child { stroke: var(--ink); }
.fo-map .mk-n { fill: var(--ink); stroke: var(--surface); }
.fo-map .mk-n-t { font-family: var(--f-data); font-weight: 700; fill: var(--bg); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.fo-map .closure-line { fill: none; stroke: var(--crit); stroke-width: 4px; stroke-linecap: round; stroke-dasharray: 7 5; }
.fo-map .works-line { fill: none; stroke: var(--warn); stroke-width: 3px; stroke-linecap: round; stroke-linejoin: round; }
.fo-map .ship { cursor: pointer; }
.fo-map .ship path { fill: var(--accent); stroke: var(--surface); }
.fo-map .ship.is-old path { fill: var(--muted); }
.fo-map .ship:hover path, .fo-map .ship:focus path { fill: var(--ink); }
.fo-map .ship-txt { font-family: var(--f-display); font-weight: 700; fill: var(--accent); paint-order: stroke; stroke: var(--sea); stroke-linejoin: round; font-style: italic; }
.fo-map .cam-mk { cursor: pointer; }
.fo-map .cam-mk circle { fill: var(--ink); stroke: var(--surface); }
.fo-map .cam-mk use { color: var(--surface); pointer-events: none; }
.fo-map .cam-mk:hover circle, .fo-map .cam-mk:focus circle { fill: var(--accent); }
.fo-map .cam-mk.is-stale circle { fill: var(--muted); }
.fo-map .cam-n { fill: var(--accent); stroke: var(--surface); stroke-width: 2; }
.fo-map .cam-n-t { font: 700 12px var(--f-data); fill: var(--accent-ink); text-anchor: middle; dominant-baseline: central; pointer-events: none; }
.map-tip {
  position: absolute; z-index: 2; max-width: min(280px, 82%); padding: var(--s2) var(--s3);
  background: var(--ink); color: var(--bg); border-radius: 9px; font-size: 0.82rem; pointer-events: none;
  box-shadow: 0 6px 20px rgb(0 0 0 / 0.28);
}
.map-tip b { display: block; font-family: var(--f-display); }
.map-tip a { color: inherit; font-weight: 600; }
.map-tip img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 6px; margin: 2px 0 6px; background: rgb(127 127 127 / 0.25); }
.map-legend { display: flex; flex-wrap: wrap; gap: 4px var(--s3); padding: var(--s2) var(--s4) 0; font-size: 0.74rem; color: var(--muted); }
.map-legend span { display: inline-flex; align-items: center; gap: 5px; }
.map-legend .dot { width: 11px; height: 11px; display: inline-block; border-radius: 50%; }
.map-legend .ship-key { width: 10px; height: 13px; display: inline-block; background: var(--accent); clip-path: polygon(50% 0, 100% 60%, 85% 100%, 15% 100%, 0 60%); }
.map-legend .sq { width: 11px; height: 11px; display: inline-block; border-radius: 3px; background: var(--wind); opacity: 0.55; }
.map-legend .ico { width: 14px; height: 14px; color: var(--crit); }
.map-legend .num { color: var(--wind); }
.map-foot { margin: 0; padding: var(--s2) var(--s4) var(--s3); font-size: 0.72rem; color: var(--muted); }

.mine-toggle { font-size: 0.85rem; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.mine-toggle:has(input:disabled) { opacity: 0.5; cursor: default; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: var(--s3) var(--s4) 0; }
.chip {
  font: inherit; font-size: 0.8rem; padding: 4px 11px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); display: inline-flex; align-items: center;
}
.chip:hover { border-color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip .n { font-family: var(--f-data); opacity: 0.7; margin-left: 5px; }
.chip-ico { width: 14px; height: 14px; margin-right: 5px; }

.feed { list-style: none; margin: 0; padding: var(--s2) 0; }
.item {
  display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: 3px var(--s3);
  padding: var(--s3) var(--s4); border-left: 4px solid transparent; scroll-margin: 90px;
}
.item > :not(.cat) { grid-column: 2; min-width: 0; }
.item + .item { border-top: 1px solid var(--line); }
.item[data-sev="warning"] { border-left-color: var(--warn); }
.item[data-sev="critical"] { border-left-color: var(--crit); background: var(--crit-soft); }
.item.is-mine { background: linear-gradient(90deg, var(--accent-soft), transparent 60%); }
.item[data-sev="critical"].is-mine { background: var(--crit-soft); }
.item.flash { animation: flash 1.6s ease; }
@keyframes flash { 0%, 30% { box-shadow: inset 0 0 0 3px var(--accent); } 100% { box-shadow: inset 0 0 0 3px transparent; } }
.item .cat { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); grid-row: span 3; }
.item[data-sev="warning"] .cat { background: var(--warn-soft); color: var(--warn); }
.item[data-sev="critical"] .cat, .item.is-closure .cat { background: var(--crit); color: var(--on-sev); }
.item .cat .ico { width: 19px; height: 19px; }
.item .meta { display: flex; flex-wrap: wrap; gap: 2px var(--s2); font-size: 0.78rem; color: var(--muted); align-items: baseline; }
.item .meta .src { font-weight: 600; color: var(--ink); }
.item .meta time { font-family: var(--f-data); }
.item .sev-tag, .item .ok-tag { font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 6px; border-radius: 4px; }
.item[data-sev="warning"] .sev-tag { background: var(--warn-soft); color: var(--warn); }
.item[data-sev="critical"] .sev-tag, .item.is-closure .sev-tag { background: var(--crit); color: var(--on-sev); }
.item .ok-tag { background: var(--ok-soft); color: var(--ok); }
.item .aged-tag { font-style: italic; }
.item .new-tag { font-size: 0.68rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 6px; border-radius: 4px; background: var(--accent); color: var(--accent-ink); }
.item .media-tag { border: 1px solid var(--line); padding: 0 5px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.banner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s3); padding: var(--s3) var(--s4); border-radius: var(--r); background: var(--warn-soft); color: var(--ink); border-left: 4px solid var(--warn); }
.banner[hidden] { display: none; }
.banner button { font: inherit; font-weight: 600; padding: 4px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.update-bar { position: fixed; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 50; background: var(--head-bg); color: var(--head-fg); border-radius: 999px; padding: 8px 8px 8px 16px; display: flex; gap: var(--s3); align-items: center; box-shadow: var(--shadow); max-width: calc(100% - 32px); }
.update-bar button { font: inherit; font-weight: 600; border: 0; border-radius: 999px; padding: 6px 14px; background: var(--accent); color: var(--accent-ink); cursor: pointer; }
.item h3 { font-size: 1rem; font-weight: 700; line-height: 1.3; }
.item h3 a { color: var(--ink); text-decoration: none; }
.item h3 a:hover { text-decoration: underline; }
.item.is-resolved h3 a { color: var(--muted); }
.item.is-resolved .cat { background: var(--ok-soft); color: var(--ok); }
.item .update { margin: 2px 0 0; display: flex; gap: 6px; align-items: flex-start; font-size: 0.9rem; }
.item .update .ico { color: var(--ok); margin-top: 1px; width: 17px; height: 17px; }
.item .update b { color: var(--ok); font-weight: 600; }
.item .update a { color: var(--ink); }
.item p { margin: 0; font-size: 0.88rem; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item .places { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
.item .places span { font-size: 0.72rem; padding: 1px 8px; border-radius: 999px; background: var(--surface-2); color: var(--muted); white-space: nowrap; }
.item .places .where { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.item .places a { color: var(--accent); text-decoration: none; font-weight: 600; }
.empty { padding: var(--s5) var(--s4); color: var(--muted); margin: 0; }

/* ---------- Sections ---------- */
.sec-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--s2) var(--s4); margin-bottom: var(--s3); }
.links { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s4); font-size: 0.88rem; }
.links a::after { content: " ↗"; font-size: 0.8em; }
.wx-head { margin: 0 0 var(--s3); font-size: 1rem; max-width: 75ch; }
.wx-head b { font-family: var(--f-data); font-weight: 500; }
.wx-head .muted { font-size: 0.88rem; }
.wx-table-wrap, .src-table-wrap { overflow-x: auto; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); }
table { border-collapse: collapse; width: 100%; font-size: 0.9rem; }
th { text-align: left; font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 700; padding: var(--s2) var(--s3); border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: var(--s2) var(--s3); border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
.wx-table td:first-child { font-weight: 600; white-space: nowrap; }
.wx-table tr.mine td { background: var(--accent-soft); }
.wx-table tr.mine td:first-child { color: var(--accent); }
.obs { font-weight: 400; font-size: 0.74rem; color: var(--muted); font-family: var(--f-data); }
.dir { display: inline-block; width: 14px; height: 14px; vertical-align: -2px; margin-right: 4px; color: var(--wind); }
.dirname { color: var(--muted); font-size: 0.8em; }
.gust-hi { color: var(--warn); font-weight: 600; }
.gust-xhi { color: var(--crit); font-weight: 600; }
.spark-col { min-width: 190px; }
.spark { display: block; width: 190px; height: 34px; }
.spark rect { fill: var(--wind); opacity: 0.5; }
.spark rect.hi { fill: var(--warn); opacity: 1; }
.spark rect.xhi { fill: var(--crit); opacity: 1; }
.spark line { stroke: var(--line); stroke-dasharray: 2 3; }
.windy-box:empty { display: none; }
.windy-box { margin-top: var(--s4); }
.windy-box iframe { display: block; width: 100%; aspect-ratio: 16 / 10; max-width: 100%; border: 0; border-radius: var(--r); box-shadow: var(--shadow); }

/* ---------- Travel links board ---------- */
.links-sec { display: grid; gap: var(--s2); }
.links-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: var(--s1) var(--s4); }
.links-legend { margin: 0; display: flex; flex-wrap: wrap; gap: var(--s1) var(--s3); font-size: 0.78rem; color: var(--muted); }
.lk-key { display: inline-flex; align-items: center; gap: 4px; }
.lk-key .ico { width: 14px; height: 14px; }
.links-board { display: grid; gap: var(--s2); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) { .links-board { grid-template-columns: 4fr 6fr 3fr; } }
.lk-group { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s2) var(--s3) var(--s3); min-width: 0; }
.lk-group h3 { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin: 2px 0 var(--s2); }
.lk-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lk { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 4px 10px 4px 6px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: inherit; font-size: 0.86rem; cursor: default; text-align: left; max-width: 100%; }
button.lk { cursor: pointer; }
button.lk:hover { border-color: var(--muted); }
.lk .ico { width: 18px; height: 18px; flex: none; }
.lk b { font-weight: 600; white-space: nowrap; }
.links-head h2 { flex: none; }
.links-legend { min-width: 0; }
@media (max-width: 600px) { .lk:has(.lk-state) { flex: 1 1 100%; } }
.lk .lk-state { color: var(--muted); font-size: 0.8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
[data-lvl="green"] .ico { color: var(--ok); }
[data-lvl="blue"] .ico { color: var(--accent); }
[data-lvl="amber"] .ico { color: var(--warn); }
[data-lvl="red"] .ico { color: var(--crit); }
.lk[data-lvl="amber"] { background: var(--warn-soft); border-color: transparent; }
.lk[data-lvl="red"] { background: var(--crit-soft); border-color: var(--crit); }
.lk[data-lvl="red"] .lk-state, .lk[data-lvl="amber"] .lk-state { color: var(--ink); }

/* ---------- Traffic and ships ---------- */
.traffic-grid { display: grid; gap: var(--s4); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 960px) { .traffic-grid { grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); } }
.traffic-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s4); min-width: 0; }
.traffic-card h3 { font-size: 1rem; display: flex; align-items: center; gap: var(--s2); margin-bottom: var(--s2); }
.traffic-card h3 .ico { color: var(--accent); }
.rush { margin: 0 0 var(--s3); max-width: 70ch; }
.rush b { font-family: var(--f-data); font-weight: 500; }
.tc-table-wrap { overflow-x: auto; margin: 0 calc(-1 * var(--s4)); }
.tc-table th.num, .tc-table td.num { text-align: right; }
.tc-table td .muted { font-size: 0.8em; }
.tc-table tr.mine td { background: var(--accent-soft); }
.tc-table tr.mine td:first-child { color: var(--accent); font-weight: 600; }
.tc-foot { margin: var(--s3) 0 0; font-size: 0.8rem; color: var(--muted); }
/* On a phone each counter becomes two lines: name and cars per day, then the rush hours. */
@media (max-width: 600px) {
  .tc-table thead { display: none; }
  .tc-table tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px var(--s3); padding: var(--s2) var(--s4); border-bottom: 1px solid var(--line); }
  .tc-table tr:last-child { border-bottom: 0; }
  .tc-table td { border: 0; padding: 0; }
  .tc-table td:first-child { font-weight: 600; }
  .tc-table td:nth-child(2)::after { content: " bilar"; font-family: var(--f-body); color: var(--muted); font-size: 0.85em; }
  .tc-table td:nth-child(3), .tc-table td:nth-child(4) { font-size: 0.78rem; color: var(--muted); }
  .tc-table td:nth-child(3) { text-align: left; }
  .tc-table td[data-l]::before { content: attr(data-l) " "; font-family: var(--f-body); }
  .tc-table td .muted { display: none; }
  .tc-table tr.mine, .tc-table tr.mine td { background: var(--accent-soft); }
}
.ships { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s2); }
.ships li { display: flex; gap: var(--s3); align-items: flex-start; padding: var(--s2) 0; border-bottom: 1px solid var(--line); }
.ships li:last-child { border-bottom: 0; }
.ships li.is-old { opacity: 0.7; }
.ships li.none { color: var(--muted); font-size: 0.85rem; }
.ship-ico { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); flex: none; }
.ship-meta { font-size: 0.78rem; color: var(--muted); font-family: var(--f-data); }

.kunn { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); gap: var(--s2); }
.kunn li { background: var(--surface); border-radius: var(--r); padding: var(--s3) var(--s4); display: flex; flex-direction: column; gap: 2px; min-width: 0; box-shadow: var(--shadow); }
.kunn time { font-family: var(--f-data); font-size: 0.75rem; color: var(--muted); }
.kunn a { color: var(--ink); font-weight: 600; text-decoration: none; overflow-wrap: anywhere; }
.kunn a:hover { text-decoration: underline; }
.kunn .none { color: var(--muted); }
.kunn-text { font-size: 0.85rem; color: var(--muted); }

.src-intro { margin: 0 0 var(--s2); max-width: 70ch; color: var(--muted); }
.src-details summary { cursor: pointer; font-weight: 600; color: var(--accent); padding: var(--s2) 0; }
.src-details[open] summary { margin-bottom: var(--s2); }
.src-table td:first-child a { font-weight: 600; }
.pill { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8rem; white-space: nowrap; }
.pill::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.pill.ok::before { background: var(--ok); }
.pill.err::before { background: var(--crit); }
.pill.plan::before { background: transparent; border: 1.5px solid var(--muted); }
.method { font-family: var(--f-data); font-size: 0.78rem; color: var(--muted); }

.foot { border-top: 1px solid var(--line); background: var(--surface); }
.foot-in { padding-block: var(--s5); font-size: 0.85rem; color: var(--muted); display: flex; flex-direction: column; gap: var(--s2); }
.foot p { margin: 0; max-width: 75ch; }
.preview-note { margin: 0; padding: var(--s2) var(--s3); border: 1px dashed var(--line); border-radius: var(--r); font-size: 0.85rem; color: var(--muted); max-width: 80ch; }

/* ---------- Webcam page ---------- */
.wc-intro { display: flex; flex-direction: column; gap: var(--s3); }
.wc-intro h1 { font-size: clamp(1.7rem, 4.2vw, 2.4rem); font-weight: 800; letter-spacing: -0.025em; }
.wc-intro p { margin: 0; max-width: 70ch; color: var(--muted); }
.wc-intro .chips { padding: 0; }
.wc-layout { display: grid; grid-template-columns: 1fr; gap: var(--s5); align-items: start; }
@media (min-width: 960px) {
  .wc-layout { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); }
  .wc-map { position: sticky; top: var(--s4); }
}
@media (max-width: 959px) { .wc-map .fo-map { max-height: 46vh; } }
.wc-gallery { min-width: 0; }
.wc-group { font-size: 1.05rem; margin: var(--s5) 0 var(--s3); }
.wc-group:first-child { margin-top: 0; }
.wc-group .n { font-family: var(--f-data); font-weight: 400; color: var(--muted); font-size: 0.85rem; }
.wc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr)); gap: var(--s3); }
.wc-card { margin: 0; background: var(--surface); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; min-width: 0; box-shadow: var(--shadow); }
.wc-shot { display: block; width: 100%; aspect-ratio: 4 / 3; max-width: 100%; padding: 0; border: 0; background: var(--sea); cursor: zoom-in; position: relative; color: var(--muted); font: inherit; }
.wc-shot img { display: block; width: 100%; height: 100%; object-fit: cover; }
.wc-shot:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }
.wc-card.is-stale .wc-shot img { filter: grayscale(0.85); opacity: 0.55; }
.wc-broken { display: grid; place-items: center; height: 100%; font-size: 0.85rem; padding: var(--s3); text-align: center; }
.wc-card figcaption { padding: var(--s2) var(--s3) var(--s3); display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.wc-card figcaption b { font-family: var(--f-display); font-size: 0.98rem; overflow-wrap: anywhere; }
.wc-meta { font-size: 0.8rem; color: var(--muted); display: flex; align-items: center; gap: 5px; }
.wc-meta .ico { width: 14px; height: 14px; }
.wc-age { font-family: var(--f-data); font-size: 0.74rem; color: var(--muted); }
.wc-age.is-old { color: var(--warn); }
.wc-age.is-ok { color: var(--ok); }
.wc-age.is-ok::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--ok); margin-right: 6px; vertical-align: 1px; }
.wc-links { margin-top: var(--s6); padding-top: var(--s4); border-top: 1px solid var(--line); }
.wc-links > p { margin: 0 0 var(--s3); max-width: 70ch; }
.wc-sub { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin: var(--s4) 0 var(--s2); }
.wc-linklist { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr)); gap: 6px var(--s4); }
.wc-linklist a { font-weight: 600; text-decoration: none; }
.wc-linklist a:hover { text-decoration: underline; }

.viewer { width: min(1100px, 96vw); max-width: 96vw; max-height: 94vh; padding: 0; border: 0; border-radius: 14px; background: var(--surface); color: var(--ink); overflow: auto; }
.viewer::backdrop { background: rgb(5 12 16 / 0.78); }
.v-bar { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--s3); padding: var(--s3) var(--s4); }
.v-text { min-width: 0; }
.v-text h2 { font-size: 1.15rem; }
.v-text p { margin: 2px 0 0; }
.v-stage { position: relative; background: #05090c; }
.v-stage img { display: block; width: 100%; max-height: 72vh; object-fit: contain; }
.v-btn { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer; background: rgb(0 0 0 / 0.55); color: #fff; }
.v-bar .v-btn { background: var(--bg); color: var(--ink); }
.v-btn .ico { width: 20px; height: 20px; }
.v-prev, .v-next { position: absolute; top: 50%; transform: translateY(-50%); }
.v-prev { left: 10px; }
.v-next { right: 10px; }
.v-links { display: flex; flex-wrap: wrap; gap: var(--s2) var(--s4); padding: var(--s3) var(--s4); font-size: 0.9rem; }

@media (max-width: 520px) {
  body { font-size: 14.5px; }
  .item { padding-inline: var(--s3); }
  .now-item { padding: var(--s3); }
}
@media (prefers-reduced-motion: no-preference) {
  .item { animation: rise 0.3s ease both; }
  @keyframes rise { from { transform: translateY(3px); } to { transform: none; } }
}
@media (prefers-reduced-motion: reduce) {
  .item.flash { animation: none; box-shadow: inset 0 0 0 3px var(--accent); }
}
.foot .install { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); }
.foot .install[hidden] { display: none; }

/* ---------- "Nær mær" ---------- */
.near-btn { font: inherit; font-size: 0.85rem; display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border-radius: 9px; border: 1px solid rgb(255 255 255 / 0.3); background: transparent; color: var(--head-fg); cursor: pointer; }
.near-btn:disabled { opacity: 0.6; cursor: progress; }
.near-btn[hidden] { display: none; }

/* ---------- Wall-screen mode (?skjar=1) ---------- */
.kiosk { font-size: 18px; }
.kiosk .nav, .kiosk .near-btn, .kiosk .place-hint, .kiosk #place, .kiosk .chips, .kiosk .mine-toggle, .kiosk .map-tools,
.kiosk .wx-sec, .kiosk .traffic-sec, .kiosk .kunn-sec, .kiosk .src-sec, .kiosk .foot, .kiosk .map-foot, .kiosk .update-bar { display: none !important; }
.kiosk .feed > li:nth-child(n+7) { display: none; }
.kiosk .item p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.kiosk .now-head h1 { font-size: 2.6rem; }
.kiosk .place-label::after { content: "· " attr(data-place); }
.kiosk .wrap { max-width: 1800px; }

/* ---------- Push notifications ---------- */
.push-btn.on { background: rgb(255 255 255 / 0.14); border-color: rgb(255 255 255 / 0.5); }
.push-btn.on::after { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #5cc48b; margin-left: 2px; }
.dialog { border: 0; border-radius: var(--r); padding: 0; max-width: min(560px, calc(100vw - 32px)); width: 100%; background: var(--surface); color: var(--ink); box-shadow: 0 10px 40px rgb(0 0 0 / 0.35); }
.dialog::backdrop { background: rgb(5 15 20 / 0.55); }
.dialog-in { padding: var(--s5); display: grid; gap: var(--s3); max-height: calc(100vh - 64px); overflow: auto; }
.dialog-in h2 { font-size: 1.3rem; }
.dialog-in p { margin: 0; }
.dialog fieldset { border: 1px solid var(--line); border-radius: 10px; padding: var(--s2) var(--s3) var(--s3); margin: 0; display: grid; gap: 6px; }
.dialog legend { font-weight: 700; padding: 0 4px; }
.dialog .opts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr)); gap: 4px var(--s3); }
.dialog .opt { display: flex; gap: 8px; align-items: center; min-height: 28px; }
.dialog .opt input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.dialog .opt input:disabled + * , .dialog .opt:has(input:disabled) { color: var(--muted); }
.dialog .admin { padding: var(--s2) var(--s3); border-radius: 10px; background: var(--surface-2); }
.dialog .hint, .dialog-note { font-size: 0.82rem; color: var(--muted); }
.dialog-status { font-weight: 600; color: var(--ok); min-height: 1.2em; }
.dialog-status:empty { display: none; }
.dialog-actions { display: flex; flex-wrap: wrap; gap: var(--s2); }
.btn { font: inherit; font-weight: 600; padding: 8px 14px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); cursor: pointer; }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: transparent; }
.btn:disabled { opacity: 0.6; cursor: progress; }

/* ---------- Komandi ---------- */
.coming-intro { margin: 0 0 var(--s3); color: var(--muted); font-size: 0.9rem; max-width: 75ch; }
.coming { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
.coming .day { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.coming .day h3 { font-size: 0.95rem; padding: var(--s2) var(--s4); background: var(--surface-2); border-bottom: 1px solid var(--line); }
.coming .day ul { list-style: none; margin: 0; padding: 0; }
.coming .day li { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 2px var(--s3); padding: var(--s2) var(--s4); align-items: start; scroll-margin: 90px; }
.coming .day li + li { border-top: 1px solid var(--line); }
.coming .day li .ico { color: var(--muted); margin-top: 2px; }
.coming .day li[data-sev="warning"] .ico, .coming .day li[data-sev="critical"] .ico { color: var(--warn); }
.coming .day li a { color: var(--ink); font-weight: 600; text-decoration: none; }
.coming .day li a:hover { text-decoration: underline; }
.coming .day li .meta { grid-column: 2; font-size: 0.8rem; color: var(--muted); }
.coming .none { color: var(--muted); }
.kiosk .coming-sec { display: none; }

/* ---------- The owner's page (umsiting.html) ---------- */
.admin-main { gap: var(--s5); }
#adminBody { display: flex; flex-direction: column; gap: var(--s5); }
.admin-login[hidden], #adminBody[hidden] { display: none; }
.admin-login { max-width: 520px; display: grid; gap: var(--s3); }
.admin-login code, .admin-main code { font-family: var(--f-data); font-size: 0.85em; background: var(--surface-2); padding: 1px 4px; border-radius: 4px; }
.login-form { display: grid; gap: var(--s2); background: var(--surface); padding: var(--s4); border-radius: var(--r); box-shadow: var(--shadow); }
.acc-form { display: grid; gap: var(--s2); align-content: start; }
.acc-form h3 { margin-bottom: 0; }
.acc-current { display: grid; gap: var(--s2); }
.acc-current[hidden] { display: none; }
.login-form input, .acc-form input { font: inherit; padding: 9px 12px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); }
.login-form .dialog-status, .dialog-status.err { color: var(--crit); }
.admin-login .admin-details { margin-top: 0; }
.admin-login .admin-details .login-form { margin-top: var(--s2); }
.admin-notice { margin: 0; background: var(--warn-soft); border-left: 4px solid var(--warn); padding: var(--s3) var(--s4); border-radius: var(--r); }
.admin-notice a { font-weight: 600; margin-left: var(--s2); }
.sessions { list-style: none; margin: 0 0 var(--s3); padding: 0; display: grid; gap: var(--s2); }
.sessions li { display: flex; justify-content: space-between; align-items: center; gap: var(--s3); padding-bottom: var(--s2); border-bottom: 1px solid var(--line); }
.sessions li:last-child { border-bottom: 0; }
.sys-grid { display: grid; gap: var(--s3); grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); }
.sys-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s3) var(--s4); border-top: 4px solid var(--ok); }
.sys-card[data-state="warn"] { border-top-color: var(--warn); }
.sys-card[data-state="bad"] { border-top-color: var(--crit); }
.sys-card h3 { font-size: 1rem; display: flex; align-items: center; gap: var(--s2); margin-bottom: var(--s2); }
.sys-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--ok); flex: none; }
.sys-card[data-state="warn"] .sys-dot { background: var(--warn); }
.sys-card[data-state="bad"] .sys-dot { background: var(--crit); }
.sys-card dl { margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 3px var(--s3); font-size: 0.86rem; }
.sys-card dt { color: var(--muted); }
.sys-card dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
.admin-card { background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s4); min-width: 0; }
.admin-card h3 { font-size: 1rem; margin-bottom: var(--s2); }
.admin-card h4 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin: var(--s3) 0 var(--s1); }
.small { font-size: 0.8rem; margin: var(--s2) 0 0; }
.runs-svg, .use-svg { display: block; width: 100%; height: auto; }
.runs-svg rect { fill: var(--wind); opacity: 0.6; }
.runs-svg rect.bad { fill: var(--crit); opacity: 0.9; }
.runs-base { stroke: var(--line); stroke-width: 1; }
.admin-details { margin-top: var(--s3); }
.admin-details summary { cursor: pointer; font-weight: 600; padding: var(--s2) 0; color: var(--accent); }
.admin-details .src-table-wrap { margin-top: var(--s2); }
.ok-note { margin: 0; }
.ok-note::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--ok); margin-right: var(--s2); }
.events li.muted { display: block; }
.runs-lbl { font-family: var(--f-data); font-size: 10px; fill: var(--muted); }
.use-grid { display: grid; gap: var(--s3); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .use-grid { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); } }
.use-svg rect.views { fill: var(--wind); opacity: 0.35; }
.use-svg rect.app { fill: var(--accent); }
.use-nums { display: flex; flex-wrap: wrap; gap: var(--s4); margin-bottom: var(--s3); }
.use-nums div { display: grid; }
.use-nums b { font-family: var(--f-display); font-size: 1.7rem; line-height: 1.1; }
.use-nums span { font-size: 0.8rem; color: var(--muted); }
.hbars { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.hbars li { display: grid; grid-template-columns: minmax(0, 9rem) minmax(0, 1fr) 2.5rem; gap: var(--s2); align-items: center; font-size: 0.85rem; }
.hb-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hb-bar { height: 10px; border-radius: 5px; background: linear-gradient(90deg, var(--accent) var(--w), var(--surface-2) var(--w)); }
.hb-n { text-align: right; }
.admin-src tr.bad td { background: var(--crit-soft); }
.admin-src .method { font-size: 0.72rem; color: var(--muted); }
.err-text { font-size: 0.75rem; color: var(--muted); font-family: var(--f-data); overflow-wrap: anywhere; margin-top: 2px; }
.events { list-style: none; margin: 0; padding: 0; background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); max-height: 480px; overflow: auto; }
.events li { display: grid; grid-template-columns: 7.5rem 6.5rem minmax(0, 1fr); gap: var(--s2); padding: var(--s2) var(--s4); border-bottom: 1px solid var(--line); font-size: 0.86rem; }
.events li:last-child { border-bottom: 0; }
.events time { font-family: var(--f-data); color: var(--muted); font-size: 0.8rem; }
.ev-kind { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); }
.events li[data-kind="feilur"] .ev-kind, .events li[data-kind="kelda"] .ev-kind { color: var(--crit); }
@media (max-width: 600px) { .events li { grid-template-columns: 1fr; gap: 0; } }

/* Public list of sources: grouped by kind, names and links only. */
.src-groups { display: grid; gap: var(--s3) var(--s5); grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); margin-top: var(--s3); background: var(--surface); border-radius: var(--r); box-shadow: var(--shadow); padding: var(--s4); }
.src-group h3 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin-bottom: var(--s1); }
.src-group ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; font-size: 0.9rem; }

