:root {
    color-scheme: light;
    --map-text:#182230;
    --map-muted:#667085;
    --map-bg:#ffffff;
    --map-border:#d9dee5;
    --map-soft:#f6f8fa;
    --map-brand:#2a8e9d;
}
* { box-sizing:border-box; }
html, body { margin:0; width:100%; height:100%; overflow:hidden; }
body.s59dx-map-page { font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; background:var(--map-bg); color:var(--map-text); }
.s59dx-map-app { display:flex; flex-direction:column; width:100%; height:100vh; height:100dvh; min-height:0; }
.s59dx-map-head { position:relative; z-index:20; flex:0 0 auto; min-height:58px; display:grid; grid-template-columns:auto minmax(0,1fr) auto; align-items:center; gap:12px; padding:8px 12px; border-bottom:1px solid var(--map-border); background:rgba(255,255,255,.96); backdrop-filter:blur(8px); box-shadow:0 1px 5px rgba(16,24,40,.08); }
.s59dx-map-install-panel[hidden] { display:none !important; }
.s59dx-map-install-panel { position:relative; z-index:19; flex:0 0 auto; display:flex; align-items:center; justify-content:space-between; gap:12px; padding:9px 12px; border-bottom:1px solid #b9dce1; background:#f0fbfc; box-shadow:0 2px 7px rgba(16,24,40,.06); }
.s59dx-map-install-copy strong { display:block; color:#155d68; font-size:12px; }
.s59dx-map-install-copy span { display:block; margin-top:2px; color:#526772; font-size:10px; }
.s59dx-map-install-actions { display:flex; align-items:center; gap:6px; flex:0 0 auto; }
.s59dx-map-install-action { min-height:34px; border:1px solid #72b9c4; border-radius:8px; background:#fff; color:#176b78; padding:6px 10px; font:inherit; font-size:10.5px; font-weight:800; cursor:pointer; white-space:nowrap; }
.s59dx-map-install-action:hover { background:#e2f6f8; }
.s59dx-map-install-close { width:30px; height:30px; display:inline-flex; align-items:center; justify-content:center; border:0; border-radius:50%; background:transparent; color:#526772; font:19px/1 Arial,sans-serif; cursor:pointer; }
.s59dx-map-install-close:hover { background:rgba(23,107,120,.10); color:#213a41; }
.s59dx-map-back, .s59dx-map-qth-btn, .s59dx-map-install-btn { min-height:38px; display:inline-flex; align-items:center; justify-content:center; gap:5px; border:1px solid var(--map-border); border-radius:8px; background:#fff; color:var(--map-text); padding:7px 11px; font:inherit; font-size:12px; font-weight:700; text-decoration:none; cursor:pointer; white-space:nowrap; }
.s59dx-map-back:hover, .s59dx-map-qth-btn:hover { background:var(--map-soft); border-color:#b7c1ce; }
.s59dx-map-head-actions { display:flex; align-items:center; gap:7px; }
.s59dx-map-install-btn { display:inline-flex; align-items:center; justify-content:center; gap:5px; border:1px solid #9fcfd6; border-radius:8px; background:#f0fbfc; color:#176b78; padding:7px 10px; font:inherit; font-size:11px; font-weight:800; cursor:pointer; white-space:nowrap; }
.s59dx-map-install-btn:hover { background:#e2f6f8; border-color:#72b9c4; }
.s59dx-map-install-btn[hidden] { display:none !important; }
.s59dx-map-install-btn svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; }
.s59dx-map-heading { min-width:0; text-align:center; }
.s59dx-map-heading strong { display:block; font-size:16px; line-height:1.15; }
.s59dx-map-summary { display:block; margin-top:3px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--map-muted); font-size:10.5px; line-height:1.2; }
.s59dx-map-stage { position:relative; flex:1 1 auto; min-height:0; }
.s59dx-map { position:absolute; inset:0; }
.s59dx-map-status { position:absolute; z-index:5; left:12px; bottom:12px; max-width:min(620px,calc(100vw - 24px)); padding:7px 10px; border:1px solid rgba(217,222,229,.96); border-radius:8px; background:rgba(255,255,255,.94); color:#475467; box-shadow:0 3px 15px rgba(16,24,40,.12); font-size:10.5px; line-height:1.3; pointer-events:none; }
.s59dx-map-status.warn { color:#8a5b00; background:rgba(255,248,230,.96); border-color:#e8c66a; }
.s59dx-map-legend { position:absolute; z-index:5; right:12px; bottom:12px; display:flex; flex-wrap:wrap; justify-content:flex-end; gap:7px 11px; max-width:min(560px,calc(100vw - 24px)); padding:7px 9px; border:1px solid rgba(217,222,229,.96); border-radius:8px; background:rgba(255,255,255,.94); color:#475467; box-shadow:0 3px 15px rgba(16,24,40,.12); font-size:9.5px; line-height:1.2; }
.s59dx-map-legend span { display:inline-flex; align-items:center; gap:5px; white-space:nowrap; }
.s59dx-map-legend > b { color:#182230; font-size:9.5px; white-space:nowrap; }
.s59dx-map-legend i { width:9px; height:9px; border-radius:50%; display:inline-block; border:1px solid rgba(0,0,0,.12); }
.s59dx-map-legend i.very-strong { width:12px; height:12px; background:#1f8f80; }
.s59dx-map-legend i.good { width:11px; height:11px; background:#76a83f; }
.s59dx-map-legend i.moderate { width:10px; height:10px; background:#c3ad2f; }
.s59dx-map-legend i.possible { width:10px; height:10px; background:#e0a137; }
.s59dx-map-legend i.low { background:#7e8a97; opacity:.72; }
.s59dx-map-qth-marker { width:18px; height:18px; border:3px solid #fff; border-radius:50%; background:#0d6efd; box-shadow:0 0 0 3px rgba(13,110,253,.28),0 2px 8px rgba(16,24,40,.28); }
.s59dx-map-qth-marker::after { content:""; position:absolute; left:50%; top:50%; width:34px; height:34px; border:1px solid rgba(13,110,253,.35); border-radius:50%; transform:translate(-50%,-50%); }
.maplibregl-popup { max-width:min(320px,calc(100vw - 28px)) !important; }
.maplibregl-popup-content { border-radius:10px; padding:11px 12px 10px; box-shadow:0 8px 28px rgba(16,24,40,.22); color:#182230; font:12px/1.35 system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif; }
.s59dx-map-popup-head { display:flex; align-items:baseline; justify-content:space-between; gap:10px; margin-right:13px; }
.s59dx-map-popup-call { font-size:16px; font-weight:800; color:#0b57b7; text-decoration:none; }
.s59dx-map-popup-country { color:#667085; font-size:10.5px; text-align:right; }
.s59dx-map-popup-main { margin-top:5px; font-weight:700; }
.s59dx-map-popup-meta { margin-top:4px; color:#667085; font-size:10.5px; }
.s59dx-map-popup-evidence { margin-top:7px; padding:6px 7px; border-radius:7px; background:#f6f8fa; color:#344054; font-size:10.5px; }
.s59dx-map-popup-evidence strong { display:block; color:#182230; font-size:11px; }
.s59dx-map-popup-actions { display:flex; gap:6px; margin-top:8px; align-items:stretch; }
.s59dx-map-popup-actions button { min-height:31px; border:1px solid #9fcfd6; border-radius:7px; background:#f0fbfc; color:#176b78; padding:6px 9px; font:inherit; font-size:10.5px; font-weight:800; cursor:pointer; }
.s59dx-map-sdr-nav { display:inline-flex; align-items:stretch; }
.s59dx-map-sdr-nav button { border-radius:0; margin:0; }
.s59dx-map-sdr-nav .s59dx-map-sdr-prev { width:28px; padding:4px 5px; border-radius:7px 0 0 7px; border-right:0; font-size:16px; line-height:1; }
.s59dx-map-sdr-nav .s59dx-map-sdr { border-radius:0; }
.s59dx-map-sdr-nav .s59dx-map-sdr-next { width:28px; padding:4px 5px; border-radius:0 7px 7px 0; border-left:0; font-size:16px; line-height:1; }
.s59dx-map-sdr-nav.is-busy .s59dx-map-sdr { cursor:wait; }
.s59dx-map-popup-actions button:hover { background:#e2f6f8; border-color:#72b9c4; }
.s59dx-map-popup-actions button:disabled { opacity:.55; cursor:wait; }
.maplibregl-ctrl-attrib { font-size:9px; }
.maplibregl-ctrl-group { border-radius:8px; overflow:hidden; }
body.s59dx-map-dark { --map-text:#edf2f7; --map-muted:#aeb9c7; --map-bg:#11161c; --map-border:#334155; --map-soft:#1d2530; background:#11161c; color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-head { background:rgba(17,22,28,.96); border-color:#334155; }
body.s59dx-map-dark .s59dx-map-install-panel { background:#17272d; border-color:#31545c; }
body.s59dx-map-dark .s59dx-map-install-copy strong { color:#9be0e8; }
body.s59dx-map-dark .s59dx-map-install-copy span { color:#b8c6cc; }
body.s59dx-map-dark .s59dx-map-install-action { background:#1f353c; color:#b7e9ef; border-color:#4a7a84; }
body.s59dx-map-dark .s59dx-map-install-close { color:#c4d0d5; }
body.s59dx-map-dark .s59dx-map-back, body.s59dx-map-dark .s59dx-map-qth-btn { background:#171d24; color:#edf2f7; border-color:#3f4b5b; }
body.s59dx-map-dark .s59dx-map-install-btn { background:#19333a; color:#a8e1e9; border-color:#35616b; }
body.s59dx-map-dark .s59dx-map-install-btn:hover { background:#21434b; border-color:#4a7a84; }
body.s59dx-map-dark .s59dx-map-back:hover, body.s59dx-map-dark .s59dx-map-qth-btn:hover { background:#202833; }
body.s59dx-map-dark .s59dx-map-status, body.s59dx-map-dark .s59dx-map-legend { background:rgba(20,26,33,.94); color:#c2cad4; border-color:#3b4655; }
body.s59dx-map-dark .s59dx-map-legend > b { color:#edf2f7; }
@media (max-width:720px) {
    .s59dx-map-head { min-height:52px; gap:7px; padding:6px 7px; }
    .s59dx-map-install-panel { align-items:flex-start; padding:8px 9px; gap:8px; }
    .s59dx-map-install-copy span { max-width:220px; line-height:1.3; }
    .s59dx-map-install-action { min-height:32px; padding:5px 8px; font-size:10px; }
    .s59dx-map-back, .s59dx-map-qth-btn, .s59dx-map-install-btn { min-height:34px; padding:5px 8px; font-size:10.5px; }
    .s59dx-map-head-actions { gap:5px; }
    .s59dx-map-install-btn { width:34px; padding:0; }
    .s59dx-map-install-btn span { display:none; }
    .s59dx-map-install-btn svg { width:16px; height:16px; }
    .s59dx-map-heading strong { font-size:14px; }
    .s59dx-map-summary { font-size:9px; }
    .s59dx-map-legend { left:8px; right:8px; bottom:42px; justify-content:center; gap:5px 9px; padding:6px 7px; font-size:8.5px; }
    .s59dx-map-status { left:8px; right:8px; bottom:7px; max-width:none; text-align:center; font-size:9.5px; padding:6px 8px; }
    .maplibregl-ctrl-top-right { top:4px; right:4px; }
}

/* v0.1.133 map interaction polish */
.s59dx-map-fit-control button {
    width:30px;
    height:30px;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:0;
    color:#176b78;
    background:#f2fbfc;
}
.s59dx-map-fit-control button:hover { background:#e2f6f8; }
.s59dx-map-fit-control svg { width:17px; height:17px; fill:none; stroke:currentColor; stroke-width:1.9; stroke-linecap:round; stroke-linejoin:round; }
.s59dx-map-fit-control { margin-top:6px !important; }
.s59dx-map-stage .maplibregl-ctrl-top-right { top:5px; right:5px; }

body.s59dx-map-dark .s59dx-map-fit-control button { background:#171d24; color:#7ed4df; }
body.s59dx-map-dark .s59dx-map-fit-control button:hover { background:#202833; }

@media (max-width:720px) {
    .s59dx-map-head { min-height:50px; }
    .s59dx-map-back, .s59dx-map-qth-btn, .s59dx-map-install-btn { min-height:32px; border-radius:9px; }
    .s59dx-map-stage .maplibregl-ctrl-top-right { top:6px; right:6px; }
    .s59dx-map-fit-control { margin-top:5px !important; }
    .s59dx-map-fit-control button { width:32px; height:32px; }
    .s59dx-map-fit-control svg { width:18px; height:18px; }
    .s59dx-map-legend { bottom:calc(43px + env(safe-area-inset-bottom)); }
    .s59dx-map-status { bottom:calc(7px + env(safe-area-inset-bottom)); }
    .maplibregl-popup-content { padding:10px 11px 9px; }
}

/* v0.1.134 shared map filters */
.s59dx-map-head-actions { display:flex; align-items:center; justify-content:flex-end; gap:7px; }
.s59dx-map-lang-toggle { display:inline-flex; align-items:center; height:38px; padding:2px; border:1px solid #cfd7e1; border-radius:9px; background:#f7f9fb; }
.s59dx-map-lang-option { min-width:32px; height:32px; padding:0 8px; border:0; border-radius:7px; background:transparent; color:#667085; font:800 10.5px/1 system-ui,-apple-system,"Segoe UI",sans-serif; cursor:pointer; }
.s59dx-map-lang-option:hover { color:#176b78; background:#eefafb; }
.s59dx-map-lang-option.active { background:#176b78; color:#fff; box-shadow:0 1px 3px rgba(16,24,40,.16); }
.s59dx-map-qth-btn svg, .s59dx-map-filter-btn svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; flex:0 0 auto; }
.s59dx-map-filter-btn { position:relative; width:38px; min-width:38px; height:38px; display:inline-flex; align-items:center; justify-content:center; border:1px solid #9fcfd6; border-radius:8px; background:#eefafb; color:#176b78; padding:0; font:inherit; cursor:pointer; }
.s59dx-map-filter-btn:hover, .s59dx-map-filter-btn[aria-expanded="true"] { background:#dff4f7; border-color:#72b9c4; }
.s59dx-map-filter-count { position:absolute; right:-5px; top:-5px; min-width:17px; height:17px; padding:0 4px; display:flex; align-items:center; justify-content:center; border-radius:999px; background:#0d6efd; color:#fff; border:2px solid #fff; font-size:9px; line-height:1; font-weight:800; }
.s59dx-map-filter-panel { position:absolute; z-index:14; top:9px; right:54px; width:min(410px,calc(100% - 72px)); max-height:calc(100% - 18px); overflow:auto; overscroll-behavior:contain; border:1px solid rgba(190,199,210,.96); border-radius:12px; background:rgba(255,255,255,.97); box-shadow:0 10px 34px rgba(16,24,40,.2); backdrop-filter:blur(10px); }
.s59dx-map-filter-panel[hidden] { display:none !important; }
.s59dx-map-filter-head { min-height:43px; display:flex; align-items:center; justify-content:space-between; gap:12px; padding:8px 10px 7px 12px; border-bottom:1px solid var(--map-border); }
.s59dx-map-filter-head strong { font-size:13px; }
.s59dx-map-filter-close { width:31px; height:31px; display:flex; align-items:center; justify-content:center; border:0; border-radius:7px; background:transparent; color:var(--map-muted); padding:0; font:700 21px/1 system-ui,sans-serif; cursor:pointer; }
.s59dx-map-filter-close:hover { background:var(--map-soft); color:var(--map-text); }
.s59dx-map-filter-body { display:grid; gap:10px; padding:10px 11px 12px; }
.s59dx-map-search-wrap { position:relative; }
.s59dx-map-search, .s59dx-map-field input, .s59dx-map-field select { width:100%; min-height:38px; border:1px solid #cfd7e1; border-radius:8px; background:#fff; color:#182230; padding:7px 10px; font:inherit; font-size:12px; outline:none; }
.s59dx-map-search { padding-right:72px; }
.s59dx-map-search::-webkit-search-cancel-button { -webkit-appearance:none; appearance:none; }
.s59dx-map-search:focus, .s59dx-map-field input:focus, .s59dx-map-field select:focus { border-color:#56b3c0; box-shadow:0 0 0 2px rgba(42,142,157,.12); }
.s59dx-map-field input.invalid { border-color:#d87a7a; box-shadow:0 0 0 2px rgba(204,53,53,.08); }
.s59dx-map-search-help-btn { position:absolute; right:36px; top:50%; transform:translateY(-50%); width:26px; height:26px; padding:0; border:1px solid #cfd7e1; border-radius:999px; background:#f8fafb; color:#667085; font:700 13px/24px system-ui,sans-serif; text-align:center; cursor:pointer; }
.s59dx-map-search-help-btn:hover, .s59dx-map-search-help-btn:focus-visible, .s59dx-map-search-help-btn[aria-expanded="true"] { border-color:#56b3c0; background:#e9f8fa; color:#176b78; outline:none; }
.s59dx-map-search-help-btn::after { content:attr(data-tooltip); position:absolute; right:-4px; bottom:calc(100% + 8px); width:max-content; max-width:min(360px,calc(100vw - 42px)); padding:6px 8px; border-radius:7px; background:#172033; color:#fff; font:600 10.5px/1.35 system-ui,-apple-system,"Segoe UI",sans-serif; text-align:left; white-space:normal; box-shadow:0 5px 18px rgba(16,24,40,.24); opacity:0; visibility:hidden; pointer-events:none; transform:translateY(3px); transition:opacity .12s ease,transform .12s ease,visibility .12s ease; }
.s59dx-map-search-help-btn::before { content:""; position:absolute; right:7px; bottom:calc(100% + 3px); border:5px solid transparent; border-top-color:#172033; opacity:0; visibility:hidden; transition:opacity .12s ease,visibility .12s ease; }
.s59dx-map-search-help-btn:hover::after, .s59dx-map-search-help-btn:hover::before, .s59dx-map-search-help-btn:focus-visible::after, .s59dx-map-search-help-btn:focus-visible::before { opacity:1; visibility:visible; transform:translateY(0); }
.s59dx-map-search-help-btn[aria-expanded="true"]::after, .s59dx-map-search-help-btn[aria-expanded="true"]::before { display:none; }
.s59dx-map-search-clear { position:absolute; right:4px; top:50%; transform:translateY(-50%); width:30px; height:30px; border:0; border-radius:7px; background:transparent; color:#667085; font:700 18px/1 system-ui,sans-serif; cursor:pointer; }
.s59dx-map-search-clear:hover { background:#f1f4f7; color:#182230; }
.s59dx-map-search-help { position:absolute; z-index:22; left:0; top:calc(100% + 7px); width:min(760px,calc(100vw - 44px)); padding:12px; border:1px solid #d8dee6; border-radius:10px; background:#fff; color:#182230; box-shadow:0 12px 30px rgba(16,24,40,.2); font-size:11px; line-height:1.42; }
.s59dx-map-search-help[hidden] { display:none !important; }
.s59dx-map-search-help-head { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:4px; }
.s59dx-map-search-help-head strong { font-size:12px; }
.s59dx-map-search-help-close { width:25px; height:25px; margin:-5px -4px -3px 0; padding:0; border:0; border-radius:50%; background:transparent; color:#667085; font:400 19px/23px system-ui,sans-serif; cursor:pointer; }
.s59dx-map-search-help-close:hover { color:#176b78; background:#f1f4f7; }
.s59dx-map-search-help-intro, .s59dx-map-search-help-note { margin:0; color:#667085; }
.s59dx-map-search-help-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; margin:10px 0; }
.s59dx-map-search-help-group { min-width:0; padding:8px; border:1px solid #d8dee6; border-radius:8px; background:#f8fafb; }
.s59dx-map-search-help-group > b { display:block; margin-bottom:5px; color:#182230; font-size:10.5px; }
.s59dx-map-search-help-examples { display:flex; flex-wrap:wrap; gap:5px; }
.s59dx-map-search-help-examples button { max-width:100%; padding:4px 6px; border:1px solid #d8dee6; border-radius:6px; background:#fff; color:#182230; font:600 10px/1.25 system-ui,sans-serif; text-align:left; cursor:pointer; }
.s59dx-map-search-help-examples button:hover, .s59dx-map-search-help-examples button:focus-visible { color:#176b78; border-color:#56b3c0; background:#eefafb; outline:none; }
.s59dx-map-search-help-note { padding-top:8px; border-top:1px solid #d8dee6; }
.s59dx-map-field { display:grid; gap:4px; min-width:0; }
.s59dx-map-field > span { color:#475467; font-size:10px; font-weight:700; }
.s59dx-map-filter-grid, .s59dx-map-distance-grid { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:8px; }
.s59dx-map-multi { position:relative; min-width:0; }
.s59dx-map-multi summary { list-style:none; min-height:38px; display:flex; align-items:center; justify-content:space-between; gap:8px; border:1px solid #cfd7e1; border-radius:8px; background:#fff; color:#344054; padding:7px 9px; cursor:pointer; font-size:11px; }
.s59dx-map-multi summary::-webkit-details-marker { display:none; }
.s59dx-map-multi summary::after { content:"⌄"; color:#667085; font-weight:800; }
.s59dx-map-multi[open] summary { border-color:#56b3c0; box-shadow:0 0 0 2px rgba(42,142,157,.1); }
.s59dx-map-multi summary b { margin-left:auto; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#176b78; font-size:10px; font-weight:800; }
.s59dx-map-multi-menu { margin-top:5px; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:4px; padding:6px; border:1px solid #d8dee6; border-radius:8px; background:#f8fafb; }
.s59dx-map-multi-all { grid-column:1/-1; min-height:29px; border:1px solid #d5dde5; border-radius:6px; background:#fff; color:#344054; font:inherit; font-size:10px; font-weight:800; cursor:pointer; }
.s59dx-map-option { min-width:0; }
.s59dx-map-option input { position:absolute; opacity:0; pointer-events:none; }
.s59dx-map-option span { min-height:29px; display:flex; align-items:center; justify-content:center; border:1px solid #d7dee6; border-radius:6px; background:#fff; color:#475467; padding:4px 5px; font-size:10px; font-weight:700; cursor:pointer; white-space:nowrap; }
.s59dx-map-option input:checked + span { border-color:#74bdc7; background:#e9f8fa; color:#176b78; }

.s59dx-map-qth-setting { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:7px; align-items:end; }
.s59dx-map-qth-pick { min-height:38px; display:inline-flex; align-items:center; justify-content:center; gap:5px; border:1px solid #cfd7e1; border-radius:8px; background:#fff; color:#176b78; padding:7px 9px; font:inherit; font-size:10px; font-weight:800; cursor:pointer; white-space:nowrap; }
.s59dx-map-qth-pick:hover, .s59dx-map-qth-pick.active { border-color:#56b3c0; background:#e9f8fa; }
.s59dx-map-qth-pick svg { width:14px; height:14px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.s59dx-map-qth-reminder { position:absolute; z-index:19; top:12px; left:50%; transform:translateX(-50%); width:min(720px,calc(100% - 32px)); display:grid; grid-template-columns:minmax(0,1fr) auto 30px; align-items:center; gap:10px; padding:9px 10px 9px 12px; border:1px solid #e3aa5a; border-radius:11px; background:rgba(255,249,235,.97); color:#6b4712; box-shadow:0 8px 28px rgba(16,24,40,.18); backdrop-filter:blur(8px); }
.s59dx-map-qth-reminder[hidden] { display:none !important; }
.s59dx-map-qth-reminder-copy { min-width:0; display:grid; gap:2px; }
.s59dx-map-qth-reminder-copy strong { font-size:11px; color:#52370e; }
.s59dx-map-qth-reminder-copy span { font-size:10px; line-height:1.35; }
.s59dx-map-qth-reminder-actions { display:flex; align-items:center; gap:5px; flex-wrap:wrap; justify-content:flex-end; }
.s59dx-map-qth-reminder-actions button { min-height:31px; border:1px solid #d8a24f; border-radius:7px; background:#fff; color:#6b4712; padding:5px 8px; font:inherit; font-size:9.5px; font-weight:800; cursor:pointer; white-space:nowrap; }
.s59dx-map-qth-reminder-actions button:hover { background:#fff5dc; border-color:#c88c32; }
.s59dx-map-qth-reminder-actions button:disabled { opacity:.6; cursor:wait; }
.s59dx-map-qth-reminder-close { width:28px; height:28px; display:flex; align-items:center; justify-content:center; border:0; border-radius:7px; background:transparent; color:#8b672f; padding:0; font:700 19px/1 system-ui,sans-serif; cursor:pointer; }
.s59dx-map-qth-reminder-close:hover { background:rgba(164,110,28,.1); }
body.s59dx-map-dark .s59dx-map-qth-reminder { background:rgba(61,45,20,.97); color:#f0cf98; border-color:#806331; }
body.s59dx-map-dark .s59dx-map-qth-reminder-copy strong { color:#ffe0a9; }
body.s59dx-map-dark .s59dx-map-qth-reminder-actions button { background:#171d24; color:#f0cf98; border-color:#806331; }
body.s59dx-map-dark .s59dx-map-qth-reminder-actions button:hover { background:#2c281f; }
body.s59dx-map-dark .s59dx-map-qth-reminder-close { color:#d9b87e; }
.s59dx-map-pick-hint { position:absolute; z-index:18; top:12px; left:50%; transform:translateX(-50%); max-width:calc(100% - 32px); border:1px solid #6bc1cc; border-radius:999px; background:rgba(238,250,251,.96); color:#155e69; box-shadow:0 5px 18px rgba(16,24,40,.16); padding:7px 12px; font-size:11px; font-weight:800; pointer-events:none; white-space:nowrap; }
.s59dx-map-stage.qth-pick-mode .s59dx-map { cursor:crosshair; }
.s59dx-map-popup-elevation { color:#667085; font-size:10px; font-weight:700; white-space:nowrap; }
body.s59dx-map-dark .s59dx-map-qth-pick { background:#171d24; color:#8ad9e3; border-color:#3f4b5b; }
body.s59dx-map-dark .s59dx-map-qth-pick:hover, body.s59dx-map-dark .s59dx-map-qth-pick.active { background:#173038; border-color:#386772; }
body.s59dx-map-dark .s59dx-map-pick-hint { background:rgba(23,48,56,.96); color:#a8e7ef; border-color:#386772; }
body.s59dx-map-dark .s59dx-map-popup-elevation { color:#9ba9b8; }
.s59dx-map-station { display:grid; gap:7px; padding-top:2px; border-top:1px solid #e5e9ef; }
.s59dx-map-station-head { display:flex; align-items:center; gap:5px; color:#344054; font-size:10px; font-weight:800; }
.s59dx-map-station-help { color:#667085; cursor:help; line-height:1; }
.s59dx-map-station-grid { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1fr); gap:8px; }
.s59dx-map-field select { width:100%; min-height:38px; border:1px solid #cfd7e1; border-radius:8px; background:#fff; color:#182230; padding:7px 28px 7px 10px; font:inherit; font-size:12px; outline:none; }
.s59dx-map-station > small { color:#667085; font-size:9px; line-height:1.35; }
body.s59dx-map-dark .s59dx-map-station { border-top-color:#334155; }
body.s59dx-map-dark .s59dx-map-station-head { color:#dbe4ee; }
body.s59dx-map-dark .s59dx-map-station-help, body.s59dx-map-dark .s59dx-map-station > small { color:#9ba9b8; }
.s59dx-map-reset-filters { justify-self:start; min-height:31px; border:0; border-radius:7px; background:transparent; color:#667085; padding:4px 2px; font:inherit; font-size:10px; font-weight:700; text-decoration:underline; text-underline-offset:2px; cursor:pointer; }
.s59dx-map-reset-filters:hover { color:#176b78; }
.s59dx-map-stage.filters-open .maplibregl-ctrl-top-right { opacity:.15; pointer-events:none; }

body.s59dx-map-dark .s59dx-map-lang-toggle { background:#171d24; border-color:#3f4b5b; }
body.s59dx-map-dark .s59dx-map-lang-option { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-lang-option:hover { background:#173038; color:#8ad9e3; }
body.s59dx-map-dark .s59dx-map-lang-option.active { background:#237f8c; color:#fff; }
body.s59dx-map-dark .s59dx-map-filter-btn { background:#173038; color:#8ad9e3; border-color:#386772; }
body.s59dx-map-dark .s59dx-map-filter-btn:hover, body.s59dx-map-dark .s59dx-map-filter-btn[aria-expanded="true"] { background:#20424b; }
body.s59dx-map-dark .s59dx-map-filter-count { border-color:#11161c; }
body.s59dx-map-dark .s59dx-map-filter-panel { background:rgba(19,25,32,.97); border-color:#3b4655; }
body.s59dx-map-dark .s59dx-map-search, body.s59dx-map-dark .s59dx-map-field input, body.s59dx-map-dark .s59dx-map-field select, body.s59dx-map-dark .s59dx-map-multi summary, body.s59dx-map-dark .s59dx-map-multi-all, body.s59dx-map-dark .s59dx-map-option span { background:#171d24; color:#edf2f7; border-color:#3f4b5b; }
body.s59dx-map-dark .s59dx-map-field > span { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-multi-menu { background:#121820; border-color:#3b4655; }
body.s59dx-map-dark .s59dx-map-option input:checked + span { background:#173038; color:#8ad9e3; border-color:#386772; }
body.s59dx-map-dark .s59dx-map-search-help-btn { background:#171d24; color:#aeb9c7; border-color:#3f4b5b; }
body.s59dx-map-dark .s59dx-map-search-help-btn:hover, body.s59dx-map-dark .s59dx-map-search-help-btn:focus-visible, body.s59dx-map-dark .s59dx-map-search-help-btn[aria-expanded="true"] { background:#173038; color:#8ad9e3; border-color:#386772; }
body.s59dx-map-dark .s59dx-map-search-help { background:#1d2127; border-color:#3b4655; color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-search-help-group { background:#171d24; border-color:#3b4655; }
body.s59dx-map-dark .s59dx-map-search-help-group > b { color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-search-help-intro, body.s59dx-map-dark .s59dx-map-search-help-note, body.s59dx-map-dark .s59dx-map-search-help-close, body.s59dx-map-dark .s59dx-map-search-clear, body.s59dx-map-dark .s59dx-map-filter-close, body.s59dx-map-dark .s59dx-map-reset-filters { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-search-help-examples button { background:#1d2127; border-color:#3b4655; color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-search-help-examples button:hover, body.s59dx-map-dark .s59dx-map-search-help-close:hover { background:#173038; border-color:#386772; color:#8ad9e3; }

@media (max-width:720px) {
    .s59dx-map-head-actions { gap:5px; }
    .s59dx-map-lang-toggle { height:34px; border-radius:9px; }
    .s59dx-map-lang-option { min-width:29px; height:28px; padding:0 6px; font-size:10px; border-radius:7px; }
    .s59dx-map-qth-btn span { display:none; }
    .s59dx-map-qth-btn { width:34px; min-width:34px; padding:0; }
    .s59dx-map-filter-btn { width:34px; min-width:34px; height:34px; border-radius:9px; }
    .s59dx-map-filter-btn svg, .s59dx-map-qth-btn svg { width:17px; height:17px; }
    .s59dx-map-filter-panel { top:8px; left:8px; right:8px; width:auto; max-height:calc(100% - 16px); border-radius:11px; }
    .s59dx-map-filter-body { gap:9px; padding:9px 10px 11px; }
    .s59dx-map-search, .s59dx-map-field input, .s59dx-map-field select, .s59dx-map-multi summary { min-height:40px; font-size:16px; }
    .s59dx-map-search-help-btn { width:28px; height:28px; line-height:26px; }
    .s59dx-map-search-help-btn::after, .s59dx-map-search-help-btn::before { display:none !important; }
    .s59dx-map-search-help { position:fixed; z-index:10020; left:12px; right:12px; top:auto; bottom:12px; width:auto; max-height:min(70vh,520px); overflow:auto; padding:13px; border-radius:13px; }
    .s59dx-map-search-help-grid { grid-template-columns:1fr; gap:7px; }
    .s59dx-map-search-help-group { padding:8px 9px; }
    .s59dx-map-search-help-examples button { font-size:11px; padding:5px 7px; }
    .s59dx-map-field > span, .s59dx-map-multi summary b { font-size:10px; }
    .s59dx-map-multi summary { font-size:11px; }
    .s59dx-map-multi-menu { grid-template-columns:repeat(4,minmax(0,1fr)); }
    .s59dx-map-option span { min-height:32px; font-size:10px; }
    .s59dx-map-qth-reminder { top:8px; left:8px; right:8px; transform:none; width:auto; grid-template-columns:1fr 28px; gap:7px; padding:9px 8px 8px 10px; }
    .s59dx-map-qth-reminder-actions { grid-column:1/-1; justify-content:flex-start; }
    .s59dx-map-qth-reminder-actions button { min-height:33px; font-size:10px; }
    .s59dx-map-qth-reminder-close { grid-column:2; grid-row:1; align-self:start; }
}

@media (max-width:390px) {
    .s59dx-map-filter-grid, .s59dx-map-station-grid { grid-template-columns:1fr; }
    .s59dx-map-qth-setting { grid-template-columns:1fr; }
    .s59dx-map-qth-pick { justify-self:start; min-height:34px; }
    .s59dx-map-pick-hint { top:9px; font-size:10px; white-space:normal; text-align:center; }
    .s59dx-map-multi-menu { grid-template-columns:repeat(3,minmax(0,1fr)); }
}

/* Callsign history popup and close-zoom label presentation */
.s59dx-map-popup-call { border:0; background:transparent; padding:0; font:inherit; font-size:16px; font-weight:800; color:#0b57b7; cursor:pointer; text-decoration:none; }
.s59dx-map-popup-call:hover { text-decoration:underline; }
.s59dx-map-popup-qrz { margin-left:5px; color:#667085; text-decoration:none; font-size:12px; vertical-align:2px; }
.s59dx-map-popup-qrz:hover { color:#0b57b7; }
.s59dx-map-history[hidden] { display:none !important; }
.s59dx-map-history { position:absolute; inset:0; z-index:30; display:flex; align-items:center; justify-content:center; padding:18px; background:rgba(16,24,40,.38); backdrop-filter:blur(2px); }
.s59dx-map-history-card { width:min(620px,calc(100vw - 28px)); max-height:min(720px,calc(100dvh - 88px)); display:flex; flex-direction:column; overflow:hidden; border:1px solid #d7dee6; border-radius:13px; background:#fff; box-shadow:0 18px 54px rgba(16,24,40,.3); }
.s59dx-map-history-head { flex:0 0 auto; display:flex; align-items:center; justify-content:space-between; gap:12px; min-height:48px; padding:9px 10px 9px 14px; border-bottom:1px solid #e3e7ec; }
.s59dx-map-history-head strong { font-size:15px; }
.s59dx-map-history-close { width:32px; height:32px; border:0; border-radius:7px; background:transparent; color:#667085; font:700 22px/1 system-ui,sans-serif; cursor:pointer; }
.s59dx-map-history-close:hover { background:#f2f4f7; color:#182230; }
.s59dx-map-history-body { min-height:120px; overflow:auto; padding:13px 14px 15px; }
.s59dx-map-history-loading,.s59dx-map-history-empty { padding:26px 8px; text-align:center; color:#667085; }
.s59dx-map-history-summary { margin-bottom:12px; color:#475467; font-size:11px; }
.s59dx-map-history-summary strong { color:#182230; font-size:16px; }
.s59dx-map-history-section + .s59dx-map-history-section { margin-top:16px; }
.s59dx-map-history-section h3 { margin:0 0 7px; font-size:12px; color:#344054; }
.s59dx-map-history-refs { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; }
.s59dx-map-history-ref { min-width:0; display:grid; gap:2px; padding:8px 9px; border:1px solid #e1e6ec; border-radius:8px; background:#f8fafb; }
.s59dx-map-history-ref strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#0b57b7; font-size:12px; }
.s59dx-map-history-ref span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:#667085; font-size:9.5px; }
.s59dx-map-history-recent { display:grid; border:1px solid #e1e6ec; border-radius:8px; overflow:hidden; }
.s59dx-map-history-recent > div { display:grid; grid-template-columns:96px minmax(120px,.9fr) minmax(0,1fr); gap:8px; align-items:center; padding:7px 9px; font-size:10px; }
.s59dx-map-history-recent > div + div { border-top:1px solid #edf0f3; }
.s59dx-map-history-recent time,.s59dx-map-history-recent span { color:#667085; }
.s59dx-map-history-recent b,.s59dx-map-history-recent span { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
body.s59dx-map-dark .s59dx-map-history-card { background:#171d24; border-color:#3b4655; color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-history-head { border-color:#334155; }
body.s59dx-map-dark .s59dx-map-history-close { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-history-close:hover { background:#202833; color:#fff; }
body.s59dx-map-dark .s59dx-map-history-summary,body.s59dx-map-dark .s59dx-map-history-loading,body.s59dx-map-dark .s59dx-map-history-empty,body.s59dx-map-dark .s59dx-map-history-ref span,body.s59dx-map-dark .s59dx-map-history-recent time,body.s59dx-map-dark .s59dx-map-history-recent span { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-history-summary strong,body.s59dx-map-dark .s59dx-map-history-section h3 { color:#edf2f7; }
body.s59dx-map-dark .s59dx-map-history-ref,body.s59dx-map-dark .s59dx-map-history-recent { background:#121820; border-color:#334155; }
body.s59dx-map-dark .s59dx-map-history-recent > div + div { border-color:#2d3745; }
@media (max-width:720px) {
    .s59dx-map-history { padding:8px; align-items:flex-end; }
    .s59dx-map-history-card { width:100%; max-height:82dvh; border-radius:13px 13px 8px 8px; }
    .s59dx-map-history-body { padding:11px 11px 14px; }
    .s59dx-map-history-refs { grid-template-columns:1fr; }
    .s59dx-map-history-recent > div { grid-template-columns:82px minmax(0,1fr); }
    .s59dx-map-history-recent span { grid-column:1/-1; }
}

/* v0.1.160: keep QTH summary clean; show active filters in their own row */
.s59dx-map-active-filters {
    position:relative; z-index:19; flex:0 0 auto; display:flex; align-items:center; justify-content:space-between; gap:10px;
    min-height:34px; padding:5px 12px; border-bottom:1px solid #b9d7df; background:#eef8fb; color:#344054; font-size:10.5px; line-height:1.3;
}
.s59dx-map-active-filters[hidden] { display:none !important; }
.s59dx-map-active-filters-copy { min-width:0; display:flex; align-items:center; gap:6px; overflow:hidden; }
.s59dx-map-active-filters-copy strong { flex:0 0 auto; color:#176b78; font-size:10.5px; }
.s59dx-map-active-filters-text { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.s59dx-map-active-filters-reset { flex:0 0 auto; border:0; border-radius:6px; background:transparent; color:#176b78; padding:4px 6px; font:inherit; font-weight:800; text-decoration:underline; cursor:pointer; }
.s59dx-map-active-filters-reset:hover { background:rgba(42,142,157,.09); }
body.s59dx-map-dark .s59dx-map-active-filters { background:#152830; border-color:#315b65; color:#cbd5df; }
body.s59dx-map-dark .s59dx-map-active-filters-copy strong, body.s59dx-map-dark .s59dx-map-active-filters-reset { color:#8ad9e3; }
@media (max-width:720px) {
    .s59dx-map-active-filters { align-items:flex-start; padding:5px 8px; gap:6px; font-size:9.5px; }
    .s59dx-map-active-filters-copy { align-items:flex-start; flex-wrap:wrap; gap:2px 5px; overflow:visible; }
    .s59dx-map-active-filters-copy strong { font-size:9.5px; }
    .s59dx-map-active-filters-text { white-space:normal; overflow:visible; }
    .s59dx-map-active-filters-reset { padding:2px 4px; white-space:nowrap; }
}


/* v0.1.164: compact hover context for clusters and My QTH */
.s59dx-map-cluster-tip { display:grid; gap:2px; min-width:130px; color:#344054; font-size:10px; line-height:1.3; }
.s59dx-map-cluster-tip strong { color:#182230; font-size:12px; }
.s59dx-map-cluster-tip span { white-space:nowrap; }
.maplibregl-popup:has(.s59dx-map-cluster-tip) { pointer-events:none; }
.maplibregl-popup:has(.s59dx-map-cluster-tip) .maplibregl-popup-content { padding:7px 9px; border-radius:8px; box-shadow:0 5px 16px rgba(16,24,40,.16); }
body.s59dx-map-dark .s59dx-map-cluster-tip { color:#aeb9c7; }
body.s59dx-map-dark .s59dx-map-cluster-tip strong { color:#edf2f7; }
body.s59dx-map-dark .maplibregl-popup:has(.s59dx-map-cluster-tip) .maplibregl-popup-content { background:#171d24; }

/* v1.1.3: compact callsign hover so a hidden collision label is always recoverable */
.s59dx-map-call-hover { pointer-events:none; }
.s59dx-map-call-hover .maplibregl-popup-content { padding:5px 8px; border-radius:7px; font-size:11px; line-height:1; color:#182230; box-shadow:0 4px 14px rgba(16,24,40,.16); }
body.s59dx-map-dark .s59dx-map-call-hover .maplibregl-popup-content { background:#171d24; color:#edf2f7; }

/* v1.1.4: show detected activity/reference directly in the DX popup. */
.s59dx-map-popup-activity { margin-top:6px; display:flex; flex-wrap:wrap; gap:4px; align-items:center; }
.s59dx-map-act { display:inline-flex; align-items:center; gap:5px; min-height:21px; padding:3px 6px; border:1px solid #d0d5dd; border-radius:6px; background:#f8fafc; color:#344054; font-size:10px; line-height:1.15; white-space:nowrap; }
.s59dx-map-act b { font-size:10px; }
.s59dx-map-act span { color:#667085; font-weight:600; }
.s59dx-map-act-sota { background:#fff3e6; border-color:#e7c6a5; color:#8a4b12; }
.s59dx-map-act-pota { background:#eef8ef; border-color:#b7d8ba; color:#256b2d; }
.s59dx-map-act-wwff { background:#eef8f3; border-color:#b7dcca; color:#176b49; }
.s59dx-map-act-wca { background:#f4f1ff; border-color:#cbc2ee; color:#5941a9; }
.s59dx-map-act-iota { background:#edf7ff; border-color:#b8d7ee; color:#17628c; }
.s59dx-map-act-contest { background:#fff7df; border-color:#ead28b; color:#7a5b00; }

/* v1.1.6 country-local DX filter */
.s59dx-map-local-filter{display:flex;align-items:flex-start;gap:9px;padding:9px 10px;border:1px solid #d8e0e8;border-radius:9px;background:#f8fafc;color:#344054;cursor:pointer}
.s59dx-map-local-filter input{margin:2px 0 0;accent-color:#2a8e9d}
.s59dx-map-local-filter span{display:grid;gap:2px;min-width:0}
.s59dx-map-local-filter strong{font-size:11px;line-height:1.2}
.s59dx-map-local-filter small{font-size:9px;line-height:1.3;color:#667085}
body.s59dx-map-dark .s59dx-map-local-filter{background:#171d24;border-color:#3f4b5b;color:#edf2f7}
body.s59dx-map-dark .s59dx-map-local-filter small{color:#9ba9b8}
