/* Dashboard styles (extracted from dashboard.html 2026-09-06). Loaded after
   site-header.css. Cache-busted by content hash: /static/dashboard.css?v=<hash>. */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #0f1923;
    color: #e0e6ed;
    min-height: 100vh;
}
header {
    background: #1a2634;
    border-bottom: 2px solid #2d4a5e;
    padding: 8px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
header h1 {
    font-size: 18px;
    color: #4fc3f7;
    font-weight: 600;
}
header h1 span { color: #78909c; font-weight: 400; }
.last-update { color: #78909c; font-size: 12px; }
.period-select {
    background: #253545;
    color: #e0e6ed;
    border: 1px solid #2d4a5e;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 13px;
    cursor: pointer;
}
.container { max-width: 1400px; margin: 0 auto; padding: 20px; }


/* Cookie consent banner (EEA/UK/CH only; 12-month persistence) */
.consent-banner {
    position: fixed; left: 16px; right: 16px; bottom: 16px;
    z-index: 9600; display: none;
    max-width: 560px; margin: 0 auto;
    background: #1a2634; border: 1px solid #2d4a5e; border-radius: 10px;
    padding: 14px 16px; box-shadow: 0 8px 28px rgba(0,0,0,0.5);
    font-size: 0.84rem; color: #c7d2dc; line-height: 1.5;
}
.consent-banner.visible { display: block; }
.consent-banner a { color: #4fc3f7; }
.consent-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; margin-top: 10px; }
.consent-btn {
    border-radius: 6px; padding: 7px 16px; font-size: 0.84rem; font-weight: 600;
    cursor: pointer; border: 1px solid #2d4a5e;
}
.consent-accept { background: #4fc3f7; color: #06222a; border-color: #4fc3f7; }
.consent-accept:hover { background: #81d4fa; }
/* Lift our floating UI above the Mediavine adhesion banner when present */
body.mv-ad-open .consent-banner { bottom: 120px; }
@media (max-width: 767px) {
    body.mv-ad-open .consent-banner { bottom: 96px; }
}

/* Ad-block support note dock (not closable; shows while ads are blocked) */
.notice-dock {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 9400;
    display: none;
    align-items: center;
    justify-content: center;
    min-height: 62px;
    background: #101a24;
    border-top: 1px solid #2d4a5e;
    padding: 6px 44px;
    box-shadow: 0 -4px 14px rgba(0,0,0,0.35);
}
.notice-dock.visible { display: flex; }
body.notice-dock-open { padding-bottom: 66px; }
body.notice-dock-open .consent-banner { bottom: 78px; }
@media (min-width: 768px) {
    .notice-dock { min-height: 102px; }
    body.notice-dock-open { padding-bottom: 106px; }
    body.notice-dock-open .consent-banner { bottom: 116px; }
}
.support-note { font-size: 0.8rem; line-height: 1.45; color: #b9c8d4; max-width: 700px; }
.support-note strong { color: #ffa726; }
/* Soften (rare) grayscale toggles into a fade instead of a flash */
.sticky-top, main, footer { transition: filter 0.35s ease; }
/* Ad-block pressure: desaturate the content while ads are blocked.
   Filter goes on the content containers, not body — a filter on body
   would break position:fixed for the overlays (note, feedback,
   consent), which deliberately stay in color. */
body.muted-mode > .sticky-top,
body.muted-mode > main,
body.muted-mode > footer { filter: grayscale(1) brightness(0.92); }
.consent-continue {
    background: none; border: none; padding: 7px 2px;
    color: #78909c; font-size: 0.8rem; cursor: pointer;
    text-decoration: underline; text-underline-offset: 3px;
}
.consent-continue:hover { color: #b9c8d4; }

/* Summary cards — 7 tiles on /test (added Sanctions matches). */
.cards {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}
.card {
    background: #1a2634;
    border: 1px solid #2d4a5e;
    border-radius: 8px;
    padding: 16px 8px;
    text-align: center;
}
.card .value {
    font-size: 30px;
    font-weight: 700;
    color: #4fc3f7;
    line-height: 1.2;
}
.card .label {
    font-size: 11px;
    color: #78909c;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}
.card .card-sub {
    font-size: 10px;
    color: #607d8b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-top: 3px;
}
.card .card-sub span { color: #b0bec5; font-weight: 700; }
.card.inbound .value { color: #66bb6a; }
.card.outbound .value { color: #ef5350; }
.card.total .value { color: #ffa726; }
.card.in-strait .value { color: #ffee58; }
.card.oil-export .value { color: #ff7043; }
.card.gas-export .value { color: #26c6da; }
.card.sanctions  .value { color: #b388ff; }
/* Sanctions match table (rendered inside the chart modal instead of a chart) */
.sanc-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sanc-table th, .sanc-table td { text-align: left; padding: 6px 10px; border-bottom: 1px solid #1e3040; }
.sanc-table th { color: #78909c; font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.5px; }
.sanc-table tr:hover td { background: #152230; }
.sanc-tier { color: #78909c; font-size: 11px; text-transform: uppercase; padding: 10px 10px 4px; letter-spacing: 0.5px; }
.sanc-badge { display: inline-block; padding: 1px 6px; border-radius: 3px; font-size: 10px; font-weight: 600; }
.sanc-badge.confirmed { background: #4a1d4a; color: #e1bee7; }
.sanc-badge.possible  { background: #2d3a4a; color: #90a4ae; }
.sanc-source { color: #4fc3f7; text-decoration: none; }
.sanc-source:hover { text-decoration: underline; }
.card { cursor: pointer; transition: border-color 0.15s, background 0.15s; }
.card:hover { border-color: #4a7a9b; background: #1e2f40; }
.card-hint {
    margin-top: 6px;
    color: #3a5a70;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    font-size: 10px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}
.card:hover .card-hint { color: #78909c; }
.card { position: relative; }
/* Chart modal */
.chart-modal {
    background: #1a2634;
    border: 1px solid #2d4a5e;
    border-radius: 10px;
    width: 90vw;
    max-width: 760px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}
.chart-wrap { padding: 16px 20px 20px; }

/* Tables */
.section {
    background: #1a2634;
    border: 1px solid #2d4a5e;
    border-radius: 8px;
    margin-bottom: 24px;
    overflow: hidden;
}
.section-header {
    padding: 16px 20px;
    border-bottom: 1px solid #2d4a5e;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.section-header h2 {
    font-size: 15px;
    font-weight: 600;
    color: #b0bec5;
}
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
th {
    background: #152230;
    color: #78909c;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
    padding: 10px 16px;
    text-align: left;
    border-bottom: 1px solid #2d4a5e;
    position: sticky;
    top: 0;
}
th.right, td.right { text-align: right; }
td {
    padding: 8px 16px;
    border-bottom: 1px solid #1e3040;
}
tr:hover td { background: #1e3040; }
.scrollable { max-height: 450px; overflow-y: auto; }
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 600;
}
.badge.inbound { background: #1b3a1b; color: #66bb6a; }
.badge.outbound { background: #3a1b1b; color: #ef5350; }
.badge.in_strait { background: #2a2a1b; color: #ffee58; }
.badge.zone-pg { background: #1b2a3a; color: #4fc3f7; }
.badge.zone-oman { background: #3a2a1b; color: #ffa726; }
/* Strait lane (Oman-coast vs Iran-coast path) */
.badge.path-oman { background: #0f3438; color: #4dd0e1; }
.badge.path-iran { background: #3a2410; color: #ffb74d; }
.badge.path-unid { background: #262b31; color: #8a9aa8; }
.flag { margin-right: 4px; }
.dwt { color: #78909c; }
.speed { color: #4fc3f7; }
.no-data {
    padding: 40px;
    text-align: center;
    color: #78909c;
    font-style: italic;
}
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}
@media (max-width: 900px) {
    .grid-2 { grid-template-columns: 1fr; }
    .cards { grid-template-columns: repeat(4, 1fr); }
}
.tab-bar {
    display: flex;
    gap: 0;
    border-bottom: 1px solid #2d4a5e;
}
.tab {
    padding: 10px 20px;
    cursor: pointer;
    color: #78909c;
    font-size: 13px;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}
.tab:hover { color: #b0bec5; }
.tab.active {
    color: #4fc3f7;
    border-bottom-color: #4fc3f7;
}
.tab-content { display: none; }
.tab-content.active { display: block; }
.btab-content { display: none; }
.btab-content.active { display: block; }
.loading {
    text-align: center;
    padding: 40px;
    color: #78909c;
}
a.ship-link {
    color: #4fc3f7;
    text-decoration: none;
    font-weight: 600;
}
a.ship-link:hover { text-decoration: underline; color: #81d4fa; }
.map-container {
    width: 100%;
    height: 75vh;
    min-height: 500px;
}
.map-container iframe {
    width: 100%;
    height: 100%;
    border: none;
}
/* Responsive tables */
.table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
/* Track modal */
/* Sticky header + section quick-nav (pinned together) */
html { scroll-behavior: smooth; }
.sticky-top { position: sticky; top: 0; z-index: 9000; }
.quicknav {
    display: flex; gap: 2px; overflow-x: auto;
    background: rgba(13,21,29,0.94);
    backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
    border-bottom: 1px solid #1a2d3d;
    padding: 5px 16px;
    -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.quicknav::-webkit-scrollbar { display: none; }
.quicknav a {
    color: #78909c; text-decoration: none; font-size: 12.5px; font-weight: 600;
    padding: 5px 12px; border-radius: 14px; white-space: nowrap;
}
.quicknav a:hover { color: #4fc3f7; background: #1a2634; }
#tabsSection, #bottomSection, #siteFooter, #summaryCards, #apiDocs {
    scroll-margin-top: calc(var(--stickyH, 130px) + 8px);
}
/* Tanker/Chem table filter — red to match the Map Replay tanker chip */
#oilOnlyBtn {
    background: #1a2634; color: #78909c; border: 1px solid #2d4a5e;
    padding: 4px 14px; border-radius: 12px; font-size: 12px;
    font-weight: 600; cursor: pointer; transition: all 0.15s;
}
#oilOnlyBtn:hover { color: #ef5350; border-color: #ef5350; }
#oilOnlyBtn.active {
    background: rgba(239,83,80,0.2); color: #ef5350; border-color: #ef5350;
}
/* Timeframe chips */
.period-chips { display: flex; gap: 4px; flex-wrap: wrap; }
.period-chips button {
    background: #1a2634; color: #78909c; border: 1px solid #2d4a5e;
    padding: 4px 11px; border-radius: 12px; font-size: 12px; font-weight: 600;
    cursor: pointer; transition: all 0.15s;
}
.period-chips button:hover { color: #b0bec5; border-color: #4fc3f7; }
/* Footer card title links */
.ftitle a { color: inherit; text-decoration: none; }
.ftitle a:hover { color: #81d4fa; text-decoration: underline; }
/* Footer nav buttons */
.footer-btn {
    display: inline-block; background: #1e3a52; color: #4fc3f7;
    border: 1px solid #2d4a5e; border-radius: 8px;
    padding: 8px 16px; font-size: 13px; font-weight: 600;
    text-decoration: none; transition: all 0.15s;
}
.footer-btn:hover { border-color: #4fc3f7; background: #234763; color: #fff; }
.period-chips button.active { background: #1e3a52; color: #4fc3f7; border-color: #4fc3f7; }
/* Replay scrubbers: bigger track + thumb for easier grabbing */
input[type=range].scrubber {
    -webkit-appearance: none; appearance: none;
    background: transparent; height: 26px; cursor: pointer; width: 100%;
}
input[type=range].scrubber::-webkit-slider-runnable-track { height: 6px; background: #253545; border-radius: 3px; }
input[type=range].scrubber::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 18px; height: 18px; border-radius: 50%;
    background: #4fc3f7; border: 2px solid #0d151d; margin-top: -6px;
}
input[type=range].scrubber::-moz-range-track { height: 6px; background: #253545; border-radius: 3px; }
input[type=range].scrubber::-moz-range-thumb {
    width: 16px; height: 16px; border-radius: 50%;
    background: #4fc3f7; border: 2px solid #0d151d;
}
.modal-overlay {
    display: none;
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    background: rgba(0,0,0,0.7);
    z-index: 10000;
    justify-content: center;
    align-items: center;
}
.modal-overlay.open { display: flex; }
.modal {
    background: #1a2634;
    border: 1px solid #2d4a5e;
    border-radius: 10px;
    width: 90vw;
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5);
}
.modal-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    border-bottom: 1px solid #2d4a5e;
}
.modal-head h2 {
    font-size: 15px;
    color: #4fc3f7;
}
.modal-close {
    background: none;
    border: none;
    color: #78909c;
    font-size: 22px;
    cursor: pointer;
    padding: 0 4px;
}
.modal-close:hover { color: #e0e6ed; }
.modal-body { padding: 16px 20px; }
.track-map {
    width: 100%;
    height: 350px;
    border-radius: 6px;
    margin-top: 16px;
    border: 1px solid #2d4a5e;
}
.track-table { max-height: 250px; overflow-y: auto; margin-top: 12px; }
.btn-track {
    background: #253545;
    color: #4fc3f7;
    border: 1px solid #2d4a5e;
    padding: 3px 10px;
    border-radius: 3px;
    font-size: 11px;
    cursor: pointer;
    font-weight: 600;
}
.btn-track:hover { background: #2d4a5e; }

/* History modal tabs */
.hist-tab-bar {
    display: flex;
    border-bottom: 1px solid #2d4a5e;
    margin-bottom: 12px;
}
.hist-tab {
    padding: 8px 18px;
    cursor: pointer;
    color: #78909c;
    font-size: 13px;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: all 0.15s;
}
.hist-tab:hover { color: #b0bec5; }
.hist-tab.active { color: #4fc3f7; border-bottom-color: #4fc3f7; }

/* Sortable column headers */
th.sortable { cursor: pointer; user-select: none; white-space: nowrap; }
th.sortable:hover { color: #4fc3f7; }
th.sortable .sort-arrow { font-size: 9px; margin-left: 3px; opacity: 0.4; }
th.sortable.sort-active .sort-arrow { opacity: 1; color: #4fc3f7; }

/* Directory filters row */
.dir-filters {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    padding: 0;
}
.dir-filters select, .dir-filters input {
    background: #253545;
    color: #e0e6ed;
    border: 1px solid #2d4a5e;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
}

/* Mobile responsive */
@media (max-width: 768px) {
    header {
        flex-direction: column;
        gap: 8px;
        padding: 8px 16px;
        align-items: flex-start;
    }
    header h1 { font-size: 16px; }
    .container { padding: 12px; }
    .cards { grid-template-columns: repeat(3, 1fr); gap: 8px; }
    .card { padding: 10px 6px; }
    .card .value { font-size: 22px; }
    .card .label { font-size: 10px; }
    .section-header { padding: 10px 12px; }
    .tab { padding: 8px 12px; font-size: 12px; }
    td, th { padding: 6px 8px; font-size: 12px; }
    .grid-2 { grid-template-columns: 1fr; }
    .modal {
        width: 98vw;
        max-width: 98vw;
        max-height: 95vh;
        border-radius: 6px;
    }
    .track-map { height: 280px; }
    .track-table { max-height: 200px; }
    .btn-track {
        padding: 6px 14px;
        font-size: 12px;
        min-height: 32px;
        min-width: 50px;
    }
    .map-container { height: 60vh; min-height: 300px; }
    .dir-filters { gap: 6px; }
    .dir-filters select, .dir-filters input { font-size: 11px; padding: 5px 6px; }
    #dirSearch { min-width: 150px !important; }
    .scrollable { max-height: 400px; }
}
@media (max-width: 480px) {
    .cards { grid-template-columns: repeat(2, 1fr); }
    .card .value { font-size: 20px; }
    .tab { padding: 6px 8px; font-size: 11px; }
    .tab-bar { flex-wrap: wrap; }
}
/* Pulsing last-position marker */
.pulse-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    position: relative;
}
.pulse-ring {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    border-radius: 50%;
    border: 2px solid;
    animation: pulse-ring 1.5s ease-out infinite;
    pointer-events: none;
}
@keyframes pulse-ring {
    0%   { transform: scale(1);   opacity: 0.9; }
    100% { transform: scale(2.8); opacity: 0; }
}
/* Feedback modal */
.feedback-form label { display: block; color: #b0bec5; font-size: 12px; margin: 10px 0 4px; }
.feedback-form select,
.feedback-form input[type=email],
.feedback-form textarea {
    width: 100%; box-sizing: border-box;
    background: #0f1a24; color: #e0e6ed;
    border: 1px solid #2d4a5e; border-radius: 4px;
    padding: 8px 10px; font: inherit; font-size: 13px;
}
.feedback-form textarea { min-height: 110px; resize: vertical; }
.feedback-form .hint { color: #78909c; font-size: 11px; margin-top: 4px; }
.feedback-form .row-bottom { display: flex; align-items: center; gap: 10px; margin-top: 14px; }
.feedback-form .status { flex: 1; font-size: 12px; }
.feedback-form .status.ok { color: #66bb6a; }
.feedback-form .status.err { color: #ef5350; }
.feedback-form .submit {
    background: #ffee58; color: #1a1500; border: 1px solid #d4c800;
    border-radius: 4px; padding: 7px 16px; font-weight: 600; cursor: pointer;
}
.feedback-form .submit:disabled { opacity: 0.5; cursor: wait; }
.feedback-form .honey {
    position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0;
}
/* ---- Theme switch (Dark | Light slider) ---- */
.theme-switch { display: flex; align-items: center; gap: 7px; background: none;
    border: none; cursor: pointer; color: #78909c; font-size: 11px; font-weight: 600;
    margin-left: 12px; flex-shrink: 0; padding: 4px 2px; font-family: inherit;
    letter-spacing: 0.3px; }
.theme-switch .ts-track { width: 34px; height: 18px; border-radius: 9px;
    background: #2d4a5e; position: relative; transition: background 0.2s; }
.theme-switch .ts-knob { position: absolute; top: 2px; left: 2px; width: 14px;
    height: 14px; border-radius: 50%; background: #4fc3f7; transition: left 0.2s; }
.theme-switch .ts-dark { color: #e0e6ed; }
html.light .theme-switch .ts-dark { color: #7d92a2; }
html.light .theme-switch .ts-light { color: #22323f; }
html.light .theme-switch .ts-track { background: #b6cfdd; }
html.light .theme-switch .ts-knob { left: 18px; background: #075985; }
/* ---- Light theme ---- */
html.light body { background: #eef2f5; color: #22323f; }
html.light header { background: #ffffff; border-bottom-color: #cfd8e0; }
html.light header h1 { color: #075985; }
html.light header h1 span { color: #5b7284; }
html.light .last-update { color: #5b7284; }
html.light .quicknav { background: rgba(238,242,245,0.94); border-bottom-color: #dbe3e9; }
html.light .quicknav a { color: #5b7284; }
html.light .quicknav a:hover { color: #075985; background: #e3eef5; }
html.light .card, html.light .section, html.light .modal, html.light .chart-modal {
    background: #ffffff; border-color: #d3dde4; }
html.light .card:hover { border-color: #7fb3d4; background: #f4f9fc; }
html.light .card .value { color: #075985; }
html.light .card .label, html.light .card-sub, html.light .card-hint { color: #5b7284; }
html.light .section-header { border-bottom-color: #e0e7ec; }
html.light .section-header h2 { color: #33454f; }
html.light th { background: #f2f6f9; color: #5b7284; }
html.light td { color: #33454f; border-color: #e6ecf0; }
html.light tr:hover td { background: #f2f7fa; }
html.light .tab { color: #5b7284; }
html.light .tab:hover { color: #33454f; }
html.light .tab.active { color: #075985; border-bottom-color: #075985; }
html.light .tab-bar { border-bottom-color: #dbe3e9; }
html.light .loading, html.light .no-data { color: #5b7284; }
html.light .modal-head { border-bottom-color: #e0e7ec; }
html.light .modal-head h2 { color: #075985; }
html.light .modal-close { color: #5b7284; }
html.light .period-chips button { background: #ffffff; color: #5b7284; border-color: #c9d5dd; }
html.light .period-chips button:hover { color: #33454f; border-color: #075985; }
html.light .period-chips button.active { background: #e3f2fd; color: #075985; border-color: #075985; }
html.light .footer-btn { background: #e3f2fd; color: #075985; border-color: #b6d8ee; }
html.light .footer-btn:hover { background: #d2e9f9; color: #01579b; }
html.light .btn-track { background: #ffffff; color: #075985; border-color: #9fc3da; }
html.light .notice-dock { background: #ffffff; border-top-color: #cfd8e0; }
html.light .support-note { color: #44586a; }
html.light .consent-banner { background: #ffffff; border-color: #cfd8e0; color: #33454f; }
html.light .feedback-form select, html.light .feedback-form input[type=email],
html.light .feedback-form textarea { background: #f7fafb; color: #22323f; border-color: #c9d5dd; }
html.light .feedback-form label { color: #44586a; }
html.light #siteFooter { color: #5b7284 !important; }
html.light #siteFooter > section > div { background: #ffffff !important; border-color: #d3dde4 !important; }
html.light [style*="color:#4fc3f7"] { color: #075985 !important; }
/* Inline light-gray text (notes, hints, labels) darkened for light bg */
html.light [style*="color:#78909c"], html.light [style*="color: #78909c"],
html.light [style*="color:#546e7a"], html.light [style*="color: #546e7a"],
html.light [style*="color:#8fa8b8"], html.light [style*="color: #8fa8b8"] { color: #4a6172 !important; }
html.light [style*="color:#8a9aa8"], html.light [style*="color: #8a9aa8"] { color: #5b7284 !important; }
html.light [style*="color:#b0bec5"], html.light [style*="color: #b0bec5"] { color: #44586a !important; }
html.light #chartMethod { color: #4a6172 !important; border-top-color: #e0e7ec !important; }
html.light a.ship-link { color: #075985; }
html.light a.ship-link:hover { color: #0369a1; }
html.light .badge.inbound { background: #e3f2e6; color: #1b7a2f; border: 1px solid #bfe3c7; }
html.light .badge.outbound { background: #fdeaea; color: #c62828; border: 1px solid #f3c1c1; }
html.light .badge.in_strait { background: #fbf3d9; color: #8d6e00; border: 1px solid #ead9a0; }
html.light .badge.zone-pg { background: #e3f1fa; color: #075985; border: 1px solid #bcd7ea; }
html.light .badge.zone-oman { background: #fdf0e0; color: #b26a00; border: 1px solid #ecd3ac; }
html.light .badge.path-oman { background: #e0f4f7; color: #006978; border: 1px solid #b8e0e7; }
html.light .badge.path-iran { background: #fdf0e0; color: #b26a00; border: 1px solid #ecd3ac; }
html.light .badge.path-unid { background: #edf1f4; color: #5b7284; border: 1px solid #d5dee5; }
html.light .dir-filters select, html.light .dir-filters input {
    background: #f7fafb !important; color: #22323f !important; border-color: #c9d5dd !important; }
.site-intro { position: relative; margin: 0 0 14px; padding: 12px 44px 12px 16px; background: #10202c;
              border: 1px solid #1e2f40; border-radius: 8px; color: #8fa8b8; font-size: 13px; line-height: 1.55; }
.site-intro strong { color: #b9c8d4; font-weight: 600; }
.site-intro a { color: #4fc3f7; }
.site-intro-close { position: absolute; top: 6px; right: 6px; width: 32px; height: 32px; border: none; border-radius: 6px;
                    background: none; color: #78909c; font-size: 22px; line-height: 1; cursor: pointer; }
.site-intro-close:hover { color: #4fc3f7; background: #1a2634; }
html.light .site-intro { background: #fff; border-color: #d3dde4; color: #4a6172; }
html.light .site-intro strong { color: #22323f; }
html.light .site-intro a { color: #075985; }
html.light .site-intro-close { color: #5b7284; }
html.light .site-intro-close:hover { color: #075985; background: #e3eef5; }
body.mv-ad-open .container, body.mv-ad-open footer { padding-bottom: 120px; }
.feed-notice { margin: 0 0 14px; padding: 10px 16px; border-radius: 8px; font-size: 13px; line-height: 1.5;
               background: #2a1616; border: 1px solid #7f2a2a; color: #ffb4b4; }
.feed-notice strong { color: #ff8a80; }
html.light .feed-notice { background: #fdecea; border-color: #f5b5b0; color: #8b1e1e; }
html.light .feed-notice strong { color: #b71c1c; }
/* Shared live ship map (Hormuz Map tab and /test/bab; markers in ship_ui.js) */
.ship-popup .leaflet-popup-content-wrapper, .ship-popup .leaflet-popup-tip {
    background: #1a2634; color: #e0e6ed; border: 1px solid #2d4a5e; box-shadow: 0 4px 16px rgba(0,0,0,0.45); }
.ship-popup .leaflet-popup-content { margin: 10px 14px; font-size: 13px; line-height: 1.5; }
.ship-popup .btn-track { margin-top: 6px; }
.ship-popup a.leaflet-popup-close-button { color: #78909c; }
/* Incident reports on the live map (beta) */
.incident-pin { display: flex; align-items: center; justify-content: center; filter: drop-shadow(0 0 3px rgba(239, 83, 80, .9)); }
.incident-pin.big { animation: incident-pulse 2.4s ease-in-out infinite; }
@keyframes incident-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.18); } }
.incident-popup .leaflet-popup-content { max-width: 300px; }
.incident-text { margin-top: 6px; max-height: 128px; overflow-y: auto; color: #b0bec5; font-size: 11.5px; line-height: 1.45; }
.incident-marks { color: #ffab91; font-size: 11.5px; }
.incident-src { margin-top: 6px; color: #78909c; font-size: 10.5px; line-height: 1.4; }
.incident-chip { display: inline-flex; align-items: center; gap: 6px; background: #ef5350; color: #ffffff;
    border: 1px solid #ef5350; padding: 4px 12px; border-radius: 12px; font-size: 12px; font-weight: 600;
    cursor: pointer; transition: all 0.15s; }
.incident-chip.off { background: transparent; color: #ef5350; }
.incident-chip .n { opacity: .75; font-weight: 400; }
.ship-hit { position: relative; width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; }
.ship-hit-badge { position: absolute; right: -1px; top: -3px; line-height: 0;
    filter: drop-shadow(0 0 2px rgba(239, 83, 80, .95)); }
.ship-attacked { background: #3a1414; border-left: 3px solid #ef5350; color: #ffcdd2; padding: 4px 6px;
    margin: -2px 0 6px; font-size: 11.5px; display: flex; align-items: center; gap: 5px; }
.ship-attacked a { color: #ff8a80; }
html.light .incident-text { color: #4a6172; }
html.light .incident-src { color: #5b7284; }
html.light .ship-attacked { background: #fdecea; color: #8c2f26; }
/* Live-map ship type filter (same groups as the 24h replay) */
.ship-type-filter { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding: 8px 16px 4px; }
.ship-type-filter .lbl { color: #78909c; font-size: 12px; margin-right: 4px; }
.ship-type-filter button { background: #1a2634; color: #78909c; border: 1px solid #2d4a5e;
    padding: 4px 14px; border-radius: 12px; font-size: 12px; font-weight: 600; cursor: pointer;
    transition: all 0.15s; }
.ship-type-filter button.off:hover { color: #b0bec5; border-color: #4fc3f7; }
.ship-type-filter .count { margin-left: auto; color: #607d8b; font-size: 11.5px; }
html.light .ship-type-filter .lbl { color: #4a6172; }
html.light .ship-type-filter button.off { background: #ffffff; color: #5b7284; border-color: #c9d5dd; }
html.light .ship-type-filter .count { color: #5b7284; }
.ship-legend { display: flex; gap: 6px 18px; flex-wrap: wrap; align-items: center; padding: 8px 16px;
               font-size: 11.5px; color: #8fa8b8; border-top: 1px solid #1a2d3d; }
.ship-legend .sw { display: inline-flex; align-items: center; gap: 6px; }
.ship-legend .dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.ship-legend .hint { margin-left: auto; color: #607d8b; }
html.light .ship-popup .leaflet-popup-content-wrapper, html.light .ship-popup .leaflet-popup-tip {
    background: #ffffff; color: #22323f; border-color: #d3dde4; }
html.light .ship-legend { color: #4a6172; border-top-color: #e0e7ec; }
html.light .ship-legend .hint { color: #5b7284; }
/* History in Map focus bar (live maps; same look as the 24h replay's Tracking bar) */
.ship-focus-bar { display: none; align-items: center; gap: 10px; padding: 6px 16px; background: #1a2d3d;
                  border-bottom: 1px solid #2d4a5e; flex-wrap: wrap; }
.ship-focus-bar .name { color: #4fc3f7; font-size: 13px; font-weight: 600; }
.ship-focus-bar .hint { color: #78909c; font-size: 12px; }
.ship-focus-restore { margin-left: auto; background: #ef5350; color: #ffffff; border: 1px solid #ef5350;
                      padding: 5px 14px; border-radius: 4px; font-size: 12px; cursor: pointer; font-weight: 700;
                      box-shadow: 0 1px 4px rgba(239, 83, 80, .45); }
.ship-focus-restore:hover { background: #e53935; border-color: #e53935; }
.ship-focus-restore:focus-visible { outline: 2px solid #ffffff; outline-offset: 2px; }
html.light .ship-focus-bar { background: #e3eef5; border-bottom-color: #cfd8e0; }
html.light .ship-focus-bar .name { color: #075985; }
html.light .ship-focus-bar .hint { color: #4a6172; }
html.light .ship-focus-restore { background: #d32f2f; color: #ffffff; border-color: #d32f2f;
                                box-shadow: 0 1px 4px rgba(211, 47, 47, .35); }
html.light .ship-focus-restore:hover { background: #b71c1c; border-color: #b71c1c; }
html.light .ship-focus-restore:focus-visible { outline-color: #7f1d1d; }
