/* The live map page: a panel with ships and events on the left, the map on the right. */

body.mappage { height: 100vh; overflow: hidden; }
body.mappage main { display: flex; min-height: 0; }
.mapapp { flex: 1; display: grid; grid-template-columns: 390px 1fr; min-height: 0; height: calc(100vh - var(--bar-h)); }

/* ---------- panel ---------- */
.panel { display: flex; flex-direction: column; min-height: 0; background: var(--surface); border-right: 1px solid var(--line); outline: none; }
.panel-top { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.tabs { display: flex; background: var(--surface-2); border-radius: 8px; padding: 3px; }
.tabs button { font: inherit; font-weight: 650; font-size: 14px; border: 0; background: none; color: var(--muted); padding: 6px 14px;
  border-radius: 6px; cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--text); box-shadow: 0 1px 2px rgba(0,0,0,.12); }
.status { margin-left: auto; font-size: 13px; color: var(--muted); white-space: nowrap; }
.status::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #22c55e; margin-right: 6px; vertical-align: 1px; }
.status.bad { color: var(--bad); } .status.bad::before { background: var(--bad); }
.panel-body { flex: 1; overflow-y: auto; padding: 4px 0 24px; }
.panel-sum { font-size: 14px; color: var(--muted); padding: 10px 16px 4px; margin: 0; }
.empty { color: var(--muted); padding: 24px 16px; text-align: center; }
.more { margin: 12px 16px; }

.shiplist { list-style: none; margin: 0; padding: 0; }
.shiprow, .eventrow { display: flex; gap: 12px; align-items: flex-start; width: 100%; text-align: left; font: inherit; color: inherit;
  background: none; border: 0; border-bottom: 1px solid var(--line); padding: 10px 16px; cursor: pointer; }
.shiprow:hover, .eventrow:hover { background: var(--surface-2); }
.shiprow .risk { min-width: 38px; justify-content: center; margin-top: 2px; }
.shiptext { display: flex; flex-direction: column; min-width: 0; }
.shiptext b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.shiptext .sub { font-size: 13.5px; color: var(--muted); }
.shiptext .tags { font-size: 13px; color: var(--muted); }
.shiptext b.unnamed { font-weight: 500; color: var(--muted); } .shiptext b.unnamed span { font-size: 13px; font-variant-numeric: tabular-nums; }
.shiptext .sub .risk { font-size: 11.5px; padding: 0 7px; vertical-align: 1px; }
.plainrow { gap: 10px; }
.kindmark { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--risk-none); margin-top: 7px; }
.kind-naval { background: var(--naval); border-radius: 2px; transform: rotate(45deg); }
.kind-gov { background: var(--gov); border-radius: 2px; transform: rotate(45deg); }
.sheetgrip { display: none; }
.flag { width: 20px; height: 15px; margin-right: 6px; vertical-align: -2px; border-radius: 2px; box-shadow: 0 0 0 1px var(--line); object-fit: cover; }
.kdot-tanker { background: #b0502a; } .kdot-cargo { background: #4f6d8f; } .kdot-passenger { background: #9a45c2; } .kdot-fishing { background: #1f9bc4; }
#trackmsg .linkbtn, .eventbar .linkbtn { font-size: 13px; }
/* the map's own controls and pop-ups in the site's colours (white boxes in dark mode otherwise) */
.leaflet-bar a, .leaflet-bar a:hover { background: var(--surface); color: var(--text); border-bottom-color: var(--line); }
.leaflet-bar a:hover { background: var(--surface-2); }
.leaflet-bar { border-color: var(--line) !important; }
.leaflet-control-scale-line { background: color-mix(in srgb, var(--surface) 80%, transparent); color: var(--text); border-color: var(--muted); text-shadow: none; }
.leaflet-container .leaflet-control-attribution { background: color-mix(in srgb, var(--surface) 82%, transparent); color: var(--muted); }
.leaflet-container .leaflet-control-attribution a { color: var(--link, var(--accent)); }
.leaflet-tooltip { background: var(--surface); color: var(--text); border-color: var(--line); box-shadow: var(--shadow); }
.leaflet-tooltip-top::before { border-top-color: var(--surface); } .leaflet-tooltip-bottom::before { border-bottom-color: var(--surface); }
.leaflet-tooltip-left::before { border-left-color: var(--surface); } .leaflet-tooltip-right::before { border-right-color: var(--surface); }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: var(--surface); color: var(--text); }
.leaflet-container a.leaflet-popup-close-button { color: var(--muted); }
.hint3d { background: color-mix(in srgb, var(--surface) 88%, transparent) !important; color: var(--text) !important; }
.sev { flex: none; display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-top: 7px; background: var(--risk-none); }
.sev-high { background: var(--risk-high); } .sev-medium { background: var(--risk-mid); }
.plain .sev { margin: 0 8px 0 0; vertical-align: 0; }

/* ---------- ship details ---------- */
.back { margin: 8px 8px 0; }
.shiphead { padding: 4px 16px 0; }
.shiphead h2 { font-size: 22px; margin: 6px 0 8px; outline: none; }
.shiphead .chips { display: flex; flex-wrap: wrap; gap: 6px; }
.shiphead .sub { color: var(--muted); margin: 8px 0 0; }
.panel-body .actions { padding: 0 16px; margin-top: 12px; gap: 8px; }
.panel-body .actions [aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
#trackmsg { padding: 6px 16px 0; min-height: 1em; }
.panel-body section { padding: 14px 16px 0; }
.panel-body section h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 8px; }
.reasons { margin: 0; padding-left: 18px; font-size: 15px; } .reasons li { margin-bottom: 4px; }
.match { border: 1px solid var(--line); border-radius: var(--radius-s); padding: 10px 12px; margin-bottom: 8px; font-size: 14.5px; }
.match > div { margin-top: 6px; } .match .badge { margin: 2px 2px 0 0; }
.plain { list-style: none; margin: 0; padding: 0; } .plain li { margin-bottom: 6px; }
.facts { font-size: 14.5px; } .facts th { width: 40%; text-transform: none; letter-spacing: 0; font-size: 14px; padding: 6px 8px 6px 0; }
.facts td { padding: 6px 0; } .facts tr:last-child th, .facts tr:last-child td { border-bottom: 0; }
.teaser { background: var(--accent-soft); border-radius: var(--radius-s); padding: 10px 12px; font-size: 14.5px; margin: 0; }
.panel-body > .note { margin: 18px 16px 0; }
.teaser.pad-x { margin: 10px 16px 0; }
.panel-body > .alert { margin: 12px 16px 0; }
.panel-body > p.muted { padding: 12px 16px 0; margin: 0; }

/* ---------- map ---------- */
.mapwrap { position: relative; min-width: 0; }
#map { position: absolute; inset: 0; background: #aad3df; }
.ship-canvas { position: absolute; left: 0; top: 0; pointer-events: none; z-index: 450; }
.leaflet-container.over-ship { cursor: pointer; }
.mapbar { position: absolute; top: 12px; left: 12px; right: 12px; z-index: 900; display: flex; gap: 8px; flex-wrap: wrap; pointer-events: none; }
.mapbar > * { pointer-events: auto; box-shadow: var(--shadow); }
.mapbar input[type=search] { width: min(360px, 100%); min-height: 38px; }
.mapbar select { width: auto; min-height: 38px; }
.mapbar #goto { width: 118px; }
.mapbar .btn { min-height: 38px; }
.mapbar-tools { display: contents; }
.mapbar [hidden], .panel-body .actions [hidden], .mappop [hidden] { display: none !important; }   /* .btn sets display: hidden must win */
.mapbar-tools > * { box-shadow: var(--shadow); }
.popclose { display: none; }
.mappop-backdrop { display: none; }
.mappop .check > span { min-width: 0; }
.mappop { position: absolute; top: 60px; right: 12px; z-index: 950; width: 320px; max-height: calc(100% - 80px); overflow-y: auto;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px; font-size: 15px; }
.mappop h3 { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin: 10px 0 6px; }
.mappop h3:first-child { margin-top: 0; }
.mappop .check { margin-top: 6px; }
.tip { position: absolute; z-index: 960; pointer-events: none; background: var(--surface); color: var(--text); border: 1px solid var(--line);
  border-radius: var(--radius-s); box-shadow: var(--shadow); padding: 7px 10px; font-size: 14px; max-width: 260px; }
.dot-high { background: var(--risk-high); } .dot-mid { background: var(--risk-mid); } .dot-low { background: var(--risk-low); }
.dot-none { background: var(--risk-none); } .dot-naval { background: var(--naval); border-radius: 2px; transform: rotate(45deg); }
.dot-gov { background: var(--gov); border-radius: 2px; transform: rotate(45deg); }
.line { display: inline-block; width: 22px; height: 3px; border-radius: 2px; margin-right: 8px; vertical-align: middle; }
.line-telecom { background: #7b4fd0; } .line-power { background: #d6336c; } .line-pipeline { background: #a0662a; }
.line-dash { background: repeating-linear-gradient(90deg, var(--muted) 0 5px, transparent 5px 9px); }
.sym { display: inline-block; width: 22px; margin-right: 8px; text-align: center; color: var(--muted); }
.sym-arrow { transform: rotate(-35deg); }
.ring, .place { display: inline-block; width: 16px; height: 16px; border-radius: 50%; margin: 0 11px 0 3px; vertical-align: -3px; }
.ring { border: 2.5px solid var(--risk-high); }
.place { width: 12px; height: 12px; border: 3px solid var(--risk-high); background: #fff; margin: 0 13px 0 5px; }
.mappop .check .help { display: block; margin: 0; }
/* accessibility mode: bigger map controls and lists */
@media (min-width: 861px) { html.a11y .mapapp { grid-template-columns: 430px 1fr; } }   /* not on phones: the panel goes below there */
html.a11y .shiprow, html.a11y .eventrow { padding-top: 13px; padding-bottom: 13px; }
html.a11y .tip, html.a11y .leaflet-tooltip { font-size: 16px; }
html.a11y .leaflet-control-zoom a { width: 44px; height: 44px; line-height: 44px; font-size: 24px; }
html.a11y .mapbar input[type=search], html.a11y .mapbar select, html.a11y .mapbar .btn { min-height: 46px; }
.leaflet-control-attribution { font-size: 11px; }
.leaflet-tooltip { font: 13.5px/1.4 var(--font); }

/* ---------- small screens: the map on top, the panel as a sheet below ---------- */
@media (max-width: 860px) {
  /* the map gets most of the screen; the list is a sheet in three heights (the grip on its top edge) */
  .mapapp { grid-template-columns: 1fr; grid-template-rows: minmax(0, 1fr) 40%; }
  .mapapp[data-sheet="max"] { grid-template-rows: minmax(0, 1fr) 76%; }
  .mapapp[data-sheet="min"] { grid-template-rows: minmax(0, 1fr) 76px; }
  .mapapp[data-sheet="min"] .panel-body { display: none; }
  .panel { order: 2; border-right: 0; border-top: 1px solid var(--line); border-radius: 14px 14px 0 0; margin-top: -12px; z-index: 910;
    box-shadow: 0 -6px 20px rgba(0,0,0,.14); }
  .sheetgrip { display: block; flex: none; width: 100%; height: 22px; border: 0; background: none; cursor: pointer; position: relative; }
  .sheetgrip::before { content: ""; position: absolute; left: 50%; top: 8px; width: 44px; height: 5px; margin-left: -22px; border-radius: 3px;
    background: var(--line); }
  .panel-top { padding-top: 2px; }
  .mapbar-tools > [data-pop] { order: -1; }                /* Layers and Legend before the rest: always on the screen */
  .mapbar-tools > #filter { order: -2; }
  .mapbar #goto { width: 108px; }
  .leaflet-bottom { margin-bottom: 12px; }                  /* clear of the sheet's rounded top */
  .mapwrap { order: 1; }
  .mapbar { top: 8px; left: 8px; right: 8px; gap: 6px; }
  .mapbar input[type=search] { width: 100%; }
  /* the rest on one row that scrolls sideways, so the bar stays two rows high over the small map */
  .mapbar > .mapbar-tools { display: flex; gap: 6px; width: 100%; overflow-x: auto; scrollbar-width: none; box-shadow: none;
    padding: 2px 4px 8px; margin: -2px -4px -8px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent);
    mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .mapbar-tools::-webkit-scrollbar { display: none; }
  .mapbar-tools > * { flex: none; }
  .mapbar-tools > :last-child { margin-right: 24px; }
  .mapbar select { width: 132px; }
  /* Layers and Legend: a sheet from the bottom of the screen, big enough to read */
  .mappop { position: fixed; top: auto !important; left: 0; right: 0; bottom: 0; width: auto; max-height: min(78vh, 78dvh);
    z-index: 1200; border-radius: 16px 16px 0 0; border-bottom: 0; padding: 0 18px calc(18px + env(safe-area-inset-bottom));
    font-size: 16px; box-shadow: 0 -8px 30px rgba(0,0,0,.25); }
  .popclose { display: block; box-sizing: border-box; position: sticky; top: 0; z-index: 1; margin: 0 -18px 4px; width: calc(100% + 36px);
    padding: 14px 18px 10px; background: var(--surface); border: 0; border-bottom: 1px solid var(--line); color: var(--accent);
    font: inherit; font-weight: 700; cursor: pointer; text-align: right; }
  .mappop h3 { font-size: 13px; margin-top: 18px; }
  .mappop .check { margin-top: 0; padding: 9px 0; border-bottom: 1px solid var(--line); gap: 12px; }
  .mappop .check input { width: 22px; height: 22px; margin-top: 1px; flex: none; }
  .mappop .check .help { margin-top: 2px; }
  .mappop ul.plain li { padding: 5px 0; display: flex; align-items: center; }   /* a long text stays beside its symbol */
  .mappop ul.plain li > :first-child { flex: none; }
  .mappop-backdrop:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 1150; background: rgba(0,0,0,.35); }
  .leaflet-control-attribution { font-size: 10px; max-width: 100%; }
}

/* ---------- Global Fishing Watch events and satellite images ---------- */
.gfw-encounter { --gfw: #f57c00; } .gfw-loitering { --gfw: #e0b000; } .gfw-port_visit { --gfw: #1f6fd1; }
.gfw-gap { --gfw: #d32f2f; } .gfw-fishing { --gfw: #2e7d32; }
.gfwicon > span { display: block; width: 100%; height: 100%; background: var(--gfw, #888); border: 2px solid #fff; border-radius: 3px;
  transform: rotate(45deg); box-shadow: 0 0 0 1px rgba(0,0,0,.45); box-sizing: border-box; }
.gfwdot { display: inline-block; flex: none; width: 11px; height: 11px; border-radius: 2px; transform: rotate(45deg);
  background: var(--gfw, #888); margin: 0 9px 0 3px; vertical-align: 0; }
.panel-body section h4 { font-size: 14px; margin: 14px 0 6px; }
.gfwlist { list-style: none; margin: 0; padding: 0; }
.gfwlist li { display: flex; gap: 4px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.gfwlist li:last-child { border-bottom: 0; }
.gfwlist .gfwdot { margin-top: 6px; }
.gfwbtns { display: flex; gap: 2px; margin-top: 2px; } .gfwbtns .btn { margin-left: -8px; }
.facts td.warn { color: var(--bad); font-weight: 600; }
.line-gap { background: repeating-linear-gradient(90deg, #d32f2f 0 6px, transparent 6px 10px); }
.nwpop .leaflet-popup-content-wrapper { background: var(--surface); color: var(--text); border-radius: var(--radius); }
.nwpop .leaflet-popup-tip { background: var(--surface); }
.nwpop .leaflet-popup-content { margin: 12px 14px; font: 14.5px/1.45 var(--font); }
.satpop > div { margin-top: 3px; }
.satpop > .wx:empty { display: none; }
.newslist li { margin-bottom: 8px; } .newslist li span { display: block; font-size: 12.5px; }
.pophead { display: flex; align-items: center; gap: 4px; margin-bottom: 4px; }
.sathead { font-weight: 700; margin-top: 10px; font-size: 13.5px; }
.satlist { margin: 4px 0 0; padding-left: 18px; } .satlist li { margin-bottom: 2px; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); text-decoration: underline; cursor: pointer; }
html.a11y .nwpop .leaflet-popup-content { font-size: 16px; }

/* ---------- replay, area search, coverage ---------- */
.tabs button { padding: 6px 11px; }
.toolform { padding: 10px 16px 4px; }
.toolform .row2 { margin-top: 10px; }
.toolform select, .toolform input[type=time] { min-height: 38px; }
.toolform .btn { margin-top: 12px; }
.player { margin: 14px 16px 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); }
.rpwhen { font-weight: 800; font-size: 17px; font-variant-numeric: tabular-nums; }
.player input[type=range] { width: 100%; margin: 10px 0 2px; accent-color: var(--accent); }
.trackkey { margin: 4px 0 0 28px; font-size: 14px; }
.tracks-on .leaflet-overlay-pane { opacity: .3; }   /* Replay with all tracks: cables and pipelines fade, the tracks stand out */
.trackkey .check { margin-top: 4px; }
.trk-shadow { background: #d62a2f; height: 4px; } .trk-russia { background: #ee7a12; } .trk-china { background: #b8860b; }
.trk-naval { background: var(--naval); } .trk-gov { background: var(--gov); } .trk-other { background: #8a94a6; height: 2px; }
.player .actions { margin-top: 6px; } .player select { width: auto; min-height: 32px; padding: 2px 8px; font-size: 14px; }
.replaybar { position: absolute; left: 50%; transform: translateX(-50%); bottom: 26px; z-index: 950; display: flex; gap: 12px; align-items: center;
  background: var(--accent); color: var(--accent-ink); padding: 8px 10px 8px 16px; border-radius: 999px; box-shadow: var(--shadow); font-weight: 700; }
.replaybar .btn { background: #fff; color: var(--accent); }
.replaybar[hidden], .mappop[hidden], .tip[hidden] { display: none; }   /* [hidden] beats display: flex */
.help.pad { padding: 0 16px; margin: 0; }
.cov { display: inline-block; width: 18px; height: 12px; background: rgba(22,163,74,.35); margin-right: 10px; vertical-align: -1px; border-radius: 2px; }
.ring-search { border: 2.5px dashed var(--risk-mid); }
@media (max-width: 860px) { .tabs button { padding: 6px 8px; font-size: 13px; } .replaybar { bottom: 12px; } }

/* ---------- the case file: the side panel's look, on a page of its own ---------- */
.casewrap { max-width: 860px; margin: 0 auto; padding: 24px 16px 56px; }
.casefile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 6px 0 24px; overflow: visible; }
.casefile .kicker { text-transform: uppercase; letter-spacing: .08em; font-size: 12px; color: var(--muted); font-weight: 700; margin: 14px 0 0; }
.casefile .shiphead h2 { font-size: 28px; }
.casefile > .actions { margin-top: 14px; }
.casefile > .note { margin: 16px 16px 0; }
.casemap { height: 340px; border-radius: var(--radius-s); border: 1px solid var(--line); margin-bottom: 6px; }
@media print {
  :root { --surface: #fff; --bg: #fff; --text: #000; --muted: #444; --line: #ccc; --surface-2: #f2f2f2; }
  .topbar, .footer, .skip, .noprint, .leaflet-control-zoom { display: none !important; }
  body { background: #fff; color: #000; }
  .casewrap { padding: 0; max-width: none; }
  .casefile { border: 0; }
  .panel-body section { break-inside: avoid-page; }
  a { color: inherit; }
}

/* false positives: the dialog where a member suggests, or an admin marks, that a ship's findings are wrong */
.fpdialog { max-width: 30rem; width: calc(100% - 2rem); border: 1px solid var(--line, #d0d7de); border-radius: 12px; padding: 1.25rem;
  background: var(--surface); color: var(--text, inherit); }
.fpdialog::backdrop { background: rgb(0 0 0 / .45); }
.fpdialog h2 { margin: 0 0 .25rem; font-size: 1.15rem; }
.fpdialog fieldset { border: 0; padding: 0; margin: .75rem 0; }
.fpdialog textarea { width: 100%; box-sizing: border-box; margin-top: .25rem; font: inherit; }
.fprow { display: flex; gap: .5rem; align-items: center; margin: .25rem 0; }
.fptags { margin-left: 1.5rem; }

/* places layer: Russian oil terminals and ship-to-ship transfer areas, labelled above the ships */
.place { display: flex; align-items: center; gap: 4px; white-space: nowrap; transform: translate(-11px, -11px); }
.place-mark { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-size: 13px;
  border: 2px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,.4); }
.place-terminal .place-mark { background: #b91c1c; color: #fff; }
.place-sts .place-mark { background: #7c3aed; color: #fff; }
.place-name { font: 600 12px/1 system-ui, sans-serif; color: #111; background: rgba(255,255,255,.85); padding: 2px 5px;
  border-radius: 4px; }
.platform { background: #57534e; border: 1.5px solid #fbbf24; box-sizing: border-box; }

/* navigational warnings */
.navwarn { display: grid; place-items: center; font-size: 16px; line-height: 1; color: #b45309;
  text-shadow: 0 0 2px #fff, 0 0 2px #fff; }
.navtext { white-space: pre-wrap; font: 12px/1.35 ui-monospace, monospace; max-height: 240px; overflow: auto; margin: 6px 0 0; }

/* the member's own note in a ship's panel */
.note-box { margin: 6px 16px 10px; }
.note-box summary { cursor: pointer; font-weight: 600; font-size: 14px; }
.note-box textarea { width: 100%; box-sizing: border-box; margin: 6px 0; font: inherit; }

/* a photo of the open ship */
.shipphoto { margin: 4px 16px 10px; }
.shipphoto img { width: 100%; max-height: 220px; object-fit: cover; border-radius: 8px; display: block; background: var(--surface-2); }
.shipphoto figcaption { font-size: 11px; color: var(--muted); margin-top: 3px; }

/* the 3D view */
.app3d { position: relative; flex: 1; min-width: 0; height: calc(100vh - var(--bar-h)); display: flex; flex-direction: column; }
.bar3d { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 8px 12px; border-bottom: 1px solid var(--line);
  background: var(--surface); }
.segmented3d { display: inline-flex; gap: 4px; }
.segmented3d [aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.depth3d { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; }
.depth3d[hidden] { display: none; }
.bar3d .status { margin-left: auto; }
#map3d { flex: 1; min-height: 0; }
.hint3d { position: absolute; left: 12px; bottom: 28px; margin: 0; padding: 6px 10px; max-width: 420px; border-radius: 8px;
  background: rgba(255,255,255,.88); color: #111; pointer-events: none; }
@media (max-width: 760px) { .hint3d { display: none; } }
.bar3d select { width: auto; min-width: 0; }

/* the 3D view's ship card and credits in the site's colours (MapLibre's own are white, unreadable in dark mode) */
.app3d .maplibregl-popup-content { background: var(--surface); color: var(--text); border-radius: 8px; box-shadow: var(--shadow);
  font-size: 14px; line-height: 1.45; padding: 10px 28px 10px 12px; }
.app3d .maplibregl-popup-content b { font-size: 15px; }
.app3d .maplibregl-popup-close-button { color: var(--muted); font-size: 18px; }
.app3d .maplibregl-popup-anchor-top .maplibregl-popup-tip,
.app3d .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
.app3d .maplibregl-popup-anchor-top-right .maplibregl-popup-tip { border-bottom-color: var(--surface); }
.app3d .maplibregl-popup-anchor-bottom .maplibregl-popup-tip,
.app3d .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
.app3d .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip { border-top-color: var(--surface); }
.app3d .maplibregl-popup-anchor-left .maplibregl-popup-tip { border-right-color: var(--surface); }
.app3d .maplibregl-popup-anchor-right .maplibregl-popup-tip { border-left-color: var(--surface); }
.app3d .maplibregl-ctrl-attrib { background: color-mix(in srgb, var(--surface) 85%, transparent); color: var(--text); }
.app3d .maplibregl-ctrl-attrib a { color: var(--text); }

/* events: who is behind the ship, and the panel's own controls */
.eventbar { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; padding: 8px 16px 0; font-size: 13px; }
.eventbar select { width: auto; font-size: 13px; padding: 2px 6px; }
.linkchip { display: inline-block; width: fit-content; align-self: flex-start; font-size: 11px; font-weight: 600; padding: 0 6px; border-radius: 9px; vertical-align: 1px;
  color: #fff; background: var(--risk-high); }
.linkchip.link-russia { background: #7a2e9e; }
.linkchip.link-china { background: #9a6a00; }
.eventrow.linked { box-shadow: inset 3px 0 0 var(--risk-high); }
#hide-norway[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
