:root {
    --bg: #05070d;
    --bg-2: #0b1020;
    --panel: rgba(13, 20, 34, .78);
    --panel-strong: rgba(15, 26, 43, .94);
    --line: rgba(124, 240, 255, .18);
    --line-strong: rgba(124, 240, 255, .42);
    --text: #eef7ff;
    --muted: #93a8bb;
    --cyan: #24e8ff;
    --green: #39f5a4;
    --magenta: #ff4fd8;
    --amber: #ffcf5a;
    --danger: #ff5d6c;
    --shadow: 0 24px 70px rgba(0, 0, 0, .36);
}

html[data-theme="light"] {
    --bg: #eef5f8;
    --bg-2: #dfeaf0;
    --panel: rgba(255, 255, 255, .82);
    --panel-strong: rgba(255, 255, 255, .96);
    --line: rgba(21, 91, 116, .18);
    --line-strong: rgba(21, 127, 155, .36);
    --text: #10202d;
    --muted: #607386;
    --cyan: #087f9e;
    --green: #0f9f72;
    --magenta: #a33ea2;
    --amber: #a46e00;
    --danger: #c83f4d;
    --shadow: 0 22px 58px rgba(35, 53, 67, .14);
}
* { box-sizing: border-box; }
html { min-height: 100%; }
body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background:
        linear-gradient(90deg, rgba(36, 232, 255, .06) 1px, transparent 1px),
        linear-gradient(rgba(36, 232, 255, .045) 1px, transparent 1px),
        radial-gradient(circle at 18% 0%, rgba(255, 79, 216, .16), transparent 34%),
        radial-gradient(circle at 88% 14%, rgba(57, 245, 164, .14), transparent 30%),
        linear-gradient(145deg, #05070d 0%, #0b1020 48%, #101012 100%);
    background-size: 48px 48px, 48px 48px, auto, auto, auto;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(115deg, transparent 0 38%, rgba(255, 255, 255, .08) 46%, transparent 54% 100%);
    animation: reflectionSweep 9s ease-in-out infinite;
    opacity: .58;
    z-index: 0;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { color: inherit; }
body.modal-open { overflow: hidden; }

.screen-glow { position: fixed; inset: 0; pointer-events: none; z-index: 0; background: radial-gradient(circle at 50% 0%, rgba(36, 232, 255, .08), transparent 45%); }
.topbar {
    position: sticky;
    top: 0;
    z-index: 10;
    min-height: 76px;
    display: grid;
    grid-template-columns: minmax(300px, 1fr) auto minmax(180px, 1fr);
    align-items: center;
    gap: 20px;
    padding: 14px 28px;
    border-bottom: 1px solid var(--line);
    background: rgba(5, 7, 13, .82);
    backdrop-filter: blur(18px);
}
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(36, 232, 255, .22), rgba(255, 79, 216, .22));
    box-shadow: inset 0 0 22px rgba(36, 232, 255, .16), 0 0 28px rgba(36, 232, 255, .12);
    font-weight: 900;
}
.brand strong, .brand small { display: block; }
.brand strong { font-size: 15px; }
.brand small { color: var(--muted); font-size: 12px; }
.topnav {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    justify-self: center;
    padding: 5px;
    /* border: 1px solid rgba(124, 240, 255, .12); */
    border-radius: 14px;
    background: rgba(255, 255, 255, .035);
}
.topnav a {
    position: relative;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 20px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: var(--muted);
    font-weight: 750;
    transition: .22s ease;
    white-space: nowrap;
}
.topnav a::after {
    content: "";
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 7px;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--cyan), var(--green));
    transform: scaleX(0);
    transform-origin: center;
    transition: .22s ease;
}
.topnav a.active, .topnav a:hover {
    color: var(--text);
    border-color: rgba(36, 232, 255, .32);
    background: rgba(36, 232, 255, .11);
    box-shadow: inset 0 0 18px rgba(36, 232, 255, .08), 0 0 22px rgba(36, 232, 255, .08);
}
.topnav a.active::after, .topnav a:hover::after { transform: scaleX(1); }
.user-menu { position: relative; justify-self: end; }
.user-menu-button {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 5px 12px 5px 5px;
    color: var(--text);
    background: rgba(255, 255, 255, .055);
    cursor: pointer;
    font-weight: 850;
}
.user-menu-button:hover, .user-menu.open .user-menu-button {
    border-color: var(--line-strong);
    background: rgba(36, 232, 255, .1);
}
.user-avatar {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    color: #041018;
    background: linear-gradient(135deg, var(--cyan), var(--green));
    font-weight: 950;
    box-shadow: 0 0 22px rgba(36, 232, 255, .22);
}
.user-avatar.large { width: 44px; height: 44px; border-radius: 12px; }
.chevron { color: var(--muted); font-size: 16px; line-height: 1; }
.user-dropdown {
    position: absolute;
    right: 0;
    top: calc(100% + 12px);
    width: 280px;
    display: none;
    padding: 12px;
    border: 1px solid var(--line-strong);
    border-radius: 14px;
    background: rgba(8, 17, 31, .98);
    box-shadow: 0 24px 70px rgba(0, 0, 0, .42), inset 0 0 44px rgba(36, 232, 255, .06);
    backdrop-filter: blur(16px);
}
.user-menu.open .user-dropdown { display: grid; gap: 10px; animation: dropdownIn .16s ease-out; }
.dropdown-user {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 10px;
    align-items: center;
    padding: 8px;
    border: 1px solid rgba(124, 240, 255, .12);
    border-radius: 12px;
    background: rgba(255, 255, 255, .04);
}
.dropdown-user strong, .dropdown-user small { display: block; }
.dropdown-user small { margin-top: 2px; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.dropdown-logout {
    width: 100%;
    min-height: 42px;
    border: 1px solid rgba(255, 93, 108, .36);
    border-radius: 12px;
    color: var(--text);
    background: rgba(255, 93, 108, .12);
    cursor: pointer;
    font-weight: 900;
}
.dropdown-logout:hover { background: rgba(255, 93, 108, .22); }
.main { position: relative; z-index: 1;  /* width: min(1500px, 100%);*/ margin: 0 auto; padding: 28px; }

.page-head { margin-bottom: 20px; }
.ai-hero {
    min-height: 220px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 250px;
    align-items: center;
    gap: 24px;
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(15, 26, 43, .94), rgba(10, 14, 24, .76));
    box-shadow: var(--shadow), inset 0 0 55px rgba(36, 232, 255, .05);
    overflow: hidden;
    position: relative;
}
.ai-hero::after, .holo-panel::after {
    content: "";
    position: absolute;
    inset: -80% -35%;
    background: linear-gradient(110deg, transparent 42%, rgba(255, 255, 255, .12), transparent 58%);
    transform: translateX(-40%) rotate(7deg);
    animation: glassSweep 7s ease-in-out infinite;
    pointer-events: none;
}
.compact-hero { min-height: 190px; }
.eyebrow { text-transform: uppercase; font-size: 12px; letter-spacing: 0; color: var(--cyan); font-weight: 900; }
.eyebrowh2 { text-transform: uppercase; font-size: 22px; letter-spacing: 0; color: var(--cyan); font-weight: 700; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(34px, 5vw, 64px); line-height: 1; font-weight: 900; }
h2 { font-size: 22px; }
h3 { font-size: 18px; }
p { color: var(--muted); line-height: 1.62; }
.page-head p { max-width: 760px; margin-top: 10px; }
.hero-orbit { width: 210px; aspect-ratio: 1; border: 1px solid rgba(36, 232, 255, .28); border-radius: 50%; position: relative; justify-self: end; animation: rotate 18s linear infinite; }
.hero-orbit::before, .hero-orbit::after { content: ""; position: absolute; inset: 23px; border: 1px dashed rgba(255, 79, 216, .35); border-radius: 50%; }
.hero-orbit::after { inset: 68px; border-color: rgba(57, 245, 164, .5); border-style: solid; }
.hero-orbit span { position: absolute; width: 9px; height: 9px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 20px var(--cyan); }
.hero-orbit span:nth-child(1) { top: 18px; left: 95px; }
.hero-orbit span:nth-child(2) { right: 20px; top: 102px; background: var(--magenta); box-shadow: 0 0 20px var(--magenta); }
.hero-orbit span:nth-child(3) { left: 50px; bottom: 34px; background: var(--green); box-shadow: 0 0 20px var(--green); }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.metric, .panel {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--panel);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}
.metric {
    min-height: 132px;
    padding: 18px;
    display: grid;
    gap: 10px;
    text-align: left;
    position: relative;
    overflow: hidden;
}
.metric::before { content: ""; position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, var(--cyan), var(--green), var(--magenta)); opacity: .8; }
.metric span { color: var(--muted); }
.metric strong { font-size: 40px; line-height: 1; }
.metric small { color: var(--green); font-weight: 800; }
.clickable { cursor: pointer; }
.clickable:hover { border-color: var(--line-strong); transform: translateY(-1px); }

.content-grid { display: grid; gap: 18px; margin-bottom: 18px; }
.content-grid.two { grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr); }
.panel { padding: 20px; margin-bottom: 18px; position: relative; overflow: hidden; }
.holo-panel { background: linear-gradient(145deg, rgba(12, 22, 38, .88), rgba(7, 11, 20, .78)); }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 16px; }
.ghost-button, .mini-button, .filter-row button, .login-panel button {
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    color: var(--text);
    background: linear-gradient(135deg, rgba(36, 232, 255, .22), rgba(255, 79, 216, .14));
    padding: 10px 14px;
    cursor: pointer;
    box-shadow: inset 0 0 18px rgba(36, 232, 255, .08);
}
.ghost-button { background: rgba(255, 255, 255, .04); color: var(--text); }
.mini-button { padding: 3px 11px; }
.filter-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.filter-row select, .login-panel input {
    min-height: 43px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
    background: rgba(5, 9, 18, .78);
    padding: 10px 12px;
    outline: none;
}
.filter-row select:focus, .login-panel input:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(36, 232, 255, .12); }

.bar-list, .analysis-list, .profile-list { display: grid; gap: 10px; }
.bar-row { display: grid; grid-template-columns: 160px 1fr 76px; gap: 12px; align-items: center; font-size: 14px; }
.bar-row div { height: 10px; border-radius: 999px; background: rgba(255, 255, 255, .08); overflow: hidden; }
.bar-row i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--green), var(--amber)); box-shadow: 0 0 18px rgba(36, 232, 255, .45); }
.analysis-item, .profile-row, .type-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .045);
    padding: 14px;
    text-align: left;
    display: grid;
    gap: 5px;
    transition: .22s ease;
}
.analysis-item, .profile-row { cursor: pointer; }
.analysis-item:hover, .profile-row:hover, .type-card:hover { border-color: var(--line-strong); background: rgba(36, 232, 255, .08); transform: translateY(-1px); }
.analysis-item span, .profile-row span, .route-card span, .type-card span { color: var(--cyan); font-size: 12px; text-transform: uppercase; font-weight: 900; }
.analysis-item small, .profile-row small, .type-card small { color: var(--muted); }
.profile-row { grid-template-columns: 44px 1fr; align-items: center; }
.profile-row img { grid-row: span 3; width: 44px; height: 52px; border-radius: 8px; object-fit: cover; border: 1px solid var(--line-strong); }
.compact-list { max-height: 62vh; overflow: auto; padding-right: 4px; }
.type-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }

.route-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.route-card { display: grid; grid-template-columns: 210px 1fr; min-height: 180px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: rgba(255, 255, 255, .045); position: relative; }
.route-card img { width: 100%; height: 100%; min-height: 180px; object-fit: cover; filter: saturate(1.1) contrast(1.05); }
.route-card > div:not(.route-leaflet-map) { padding: 16px; display: grid; gap: 8px; align-content: start; }
.route-large { grid-template-columns: minmax(270px, .9fr) 1fr; }
.ai-map-card::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent, rgba(36, 232, 255, .12)); pointer-events: none; mix-blend-mode: screen; }
meter { width: 100%; height: 10px; accent-color: var(--cyan); }
.checkline { display: flex; align-items: center; gap: 8px; color: var(--muted); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; }
table { width: 100%; border-collapse: collapse; min-width: 860px; background: rgba(5, 9, 18, .52); }
th, td { padding: 13px 12px; border-bottom: 1px solid rgba(124, 240, 255, .12); text-align: left; vertical-align: top; font-size: 14px; }
th { color: var(--cyan); background: rgba(36, 232, 255, .08); }
tr:hover td { background: rgba(36, 232, 255, .045); }
.pager { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; }
.pager-link { min-width: 38px; min-height: 38px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 255, 255, .05); color: var(--text); padding: 0 12px; }
.pager-link.active { border-color: var(--cyan); background: rgba(36, 232, 255, .18); box-shadow: 0 0 22px rgba(36, 232, 255, .18); }
.pager-link.disabled { opacity: .42; pointer-events: none; }

.modal { position: fixed; inset: 0; display: none; place-items: center; padding: 22px; z-index: 30; background: rgba(0, 0, 0, .62); backdrop-filter: blur(10px); }
.modal.open { display: grid; animation: modalFade .18s ease-out; }
.modal-box {
    width: min(660px, 100%);
    max-height: 84vh;
    overflow: hidden;
    position: relative;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    padding: 26px;
    background: linear-gradient(145deg, rgba(8, 17, 31, .98), rgba(15, 26, 43, .95));
    box-shadow: 0 0 0 1px rgba(255, 255, 255, .05), 0 28px 90px rgba(0, 0, 0, .55), inset 0 0 70px rgba(36, 232, 255, .08);
    animation: modalRise .22s ease-out;
}
.modal-box.wide { width: min(940px, 100%); }
.modal-box > * { position: relative; z-index: 1; }
.modal-box .modal-close, .modal-box .modal-scan { position: absolute; }
.profile-dialog { display: grid; grid-template-columns: 190px 1fr; gap: 22px; align-items: start; }
.profile-image { width: 190px; aspect-ratio: 1 / 1.18; object-fit: cover; border: 1px solid var(--line-strong); border-radius: 8px; box-shadow: 0 0 34px rgba(36, 232, 255, .18); }
.profile-detail { display: grid; gap: 12px; }
.modal-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.modal-meta span { border: 1px solid var(--line); border-radius: 8px; padding: 10px; color: var(--muted); background: rgba(255, 255, 255, .04); }
.modal-meta strong { display: block; color: var(--text); margin-top: 4px; }
.modal-close { position: absolute; top: 12px; right: 12px; z-index: 2; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 8px; background: rgba(255, 255, 255, .08); color: var(--text); cursor: pointer; font-size: 22px; }
.modal-scan { position: absolute; inset: 0; pointer-events: none; background: repeating-linear-gradient(180deg, rgba(36, 232, 255, .06) 0 1px, transparent 1px 9px); opacity: .42; animation: scanLines 4s linear infinite; }

.login-body { min-height: 100vh; display: grid; place-items: center; padding: 28px; background: #05070d; color: var(--text); }
.login-shell { width: min(1120px, 100%); min-height: 660px; display: grid; grid-template-columns: 1fr 430px; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: rgba(10, 16, 29, .86); box-shadow: var(--shadow); }
.login-visual { position: relative; overflow: hidden; background: linear-gradient(145deg, rgba(7, 15, 28, .98), rgba(14, 24, 39, .98)); }
.scan-grid { position: absolute; inset: 0; background-image: linear-gradient(rgba(36, 232, 255, .1) 1px, transparent 1px), linear-gradient(90deg, rgba(36, 232, 255, .1) 1px, transparent 1px); background-size: 42px 42px; animation: scan 8s linear infinite; }
.cinema-reflection { position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.2) 47%, transparent 56%); animation: reflectionSweep 5s ease-in-out infinite; }
.pulse-core { position: absolute; width: 166px; height: 166px; border: 1px solid rgba(36, 232, 255, .64); border-radius: 50%; left: calc(50% - 83px); top: calc(50% - 83px); box-shadow: inset 0 0 46px rgba(36, 232, 255, .12); animation: pulse 2.6s ease-in-out infinite; }
.orbital { position: absolute; border: 1px solid rgba(255, 79, 216, .46); border-radius: 50%; inset: 20%; animation: rotate 14s linear infinite; }
.orbital-two { inset: 31%; border-color: rgba(57, 245, 164, .42); animation-duration: 9s; animation-direction: reverse; }
.intel-card { position: absolute; max-width: 230px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: rgba(5, 9, 18, .46); backdrop-filter: blur(10px); font-size: 13px; box-shadow: 0 0 28px rgba(36, 232, 255, .12); }
.floating-card { animation: float 3.4s ease-in-out infinite; }
.floating-card.one { left: 8%; top: 18%; }
.floating-card.two { right: 9%; top: 43%; animation-delay: .7s; }
.floating-card.three { left: 18%; bottom: 18%; animation-delay: 1.2s; }
.login-panel { padding: 42px; display: grid; gap: 18px; align-content: center; background: linear-gradient(145deg, rgba(10, 16, 29, .96), rgba(17, 22, 34, .95)); }
.login-panel h1 { font-size: 42px; line-height: 1.02; }
.auth-error { border: 1px solid rgba(255, 93, 108, .45); border-radius: 8px; padding: 11px 12px; color: #ffd8dd; background: rgba(255, 93, 108, .12); }
.login-panel label { display: grid; gap: 7px; color: var(--muted); font-weight: 800; }
.remember-row { grid-template-columns: auto 1fr; align-items: center; justify-content: start; }
.remember-row input { min-height: auto; width: 16px; height: 16px; padding: 0; }
.login-panel button { min-height: 49px; background: linear-gradient(135deg, rgba(36,232,255,.28), rgba(255,79,216,.24)); }

@keyframes scan { to { background-position: 42px 42px; } }
@keyframes scanLines { to { background-position-y: 80px; } }
@keyframes rotate { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { transform: scale(1.15); box-shadow: 0 0 66px rgba(36, 232, 255, .3), inset 0 0 46px rgba(255, 79, 216, .12); } }
@keyframes float { 50% { transform: translateY(-12px); } }
@keyframes reflectionSweep { 0%, 100% { transform: translateX(-60%); opacity: .12; } 45%, 55% { opacity: .55; } 100% { transform: translateX(60%); } }
@keyframes glassSweep { 0%, 30% { transform: translateX(-55%) rotate(7deg); opacity: 0; } 45% { opacity: .8; } 70%, 100% { transform: translateX(55%) rotate(7deg); opacity: 0; } }
@keyframes dropdownIn { from { transform: translateY(-6px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes modalFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalRise { from { transform: translateY(16px) scale(.98); opacity: .7; } to { transform: translateY(0) scale(1); opacity: 1; } }
@keyframes blink { 50% { opacity: .35; } }

@media (max-width: 1040px) {
    .topbar { grid-template-columns: 1fr; justify-items: stretch; }
    .topnav { justify-self: stretch; overflow-x: auto; }
    .user-menu { justify-self: start; }
    .ai-hero, .login-shell, .content-grid.two, .route-grid, .metric-grid { grid-template-columns: 1fr; }
    .hero-orbit { justify-self: start; width: 160px; }
    .route-card, .route-large, .profile-dialog { grid-template-columns: 1fr; }
    .profile-image { width: min(220px, 100%); }
}

@media (max-width: 640px) {
    .main { padding: 16px; }
    .topbar { padding: 12px 16px; }
    .brand small, .user-menu-label { display: none; }
    .topnav { gap: 4px; padding: 4px; }
    .topnav a { padding: 0 12px; min-height: 40px; white-space: nowrap; }
    .user-dropdown { left: 0; right: auto; width: min(280px, calc(100vw - 32px)); }
    .ai-hero, .panel, .modal-box, .login-panel { padding: 18px; }
    .bar-row, .modal-meta, .type-grid { grid-template-columns: 1fr; }
    .login-visual { min-height: 360px; }
}
/* Theme and responsive refinements */
.user-menu-button.icon-only {
    width: 48px;
    height: 48px;
    min-height: 48px;
    justify-content: center;
    padding: 5px;
    border-radius: 15px;
}
.user-menu-button.icon-only .user-avatar { width: 36px; height: 36px; }
.theme-switch {
    display: grid;
    gap: 9px;
    padding: 10px;
    border: 1px solid rgba(124, 240, 255, .12);
    border-radius: 12px;
    background: rgba(255, 255, 255, .04);
}
.theme-switch > span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 850;
    text-transform: uppercase;
}
.theme-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 7px;
}
.theme-options button {
    min-height: 38px;
    border: 1px solid var(--line);
    border-radius: 10px;
    color: var(--muted);
    background: rgba(255, 255, 255, .045);
    cursor: pointer;
    font-weight: 850;
}
.theme-options button.active,
.theme-options button:hover {
    color: var(--text);
    border-color: var(--line-strong);
    background: rgba(36, 232, 255, .14);
}

html[data-theme="light"] body {
    background:
        linear-gradient(90deg, rgba(8, 127, 158, .08) 1px, transparent 1px),
        linear-gradient(rgba(8, 127, 158, .06) 1px, transparent 1px),
        radial-gradient(circle at 18% 0%, rgba(163, 62, 162, .12), transparent 34%),
        radial-gradient(circle at 88% 14%, rgba(15, 159, 114, .12), transparent 30%),
        linear-gradient(145deg, #eef5f8 0%, #e7f0f4 48%, #f8fbfc 100%);
    background-size: 48px 48px, 48px 48px, auto, auto, auto;
}
html[data-theme="light"] body::before { background: linear-gradient(115deg, transparent 0 38%, rgba(255, 255, 255, .55) 46%, transparent 54% 100%); opacity: .45; }
html[data-theme="light"] .screen-glow { background: radial-gradient(circle at 50% 0%, rgba(8, 127, 158, .12), transparent 45%); }
html[data-theme="light"] .topbar,
html[data-theme="light"] .user-dropdown,
html[data-theme="light"] .modal-box {
    background: rgba(255, 255, 255, .9);
}
html[data-theme="light"] .topnav,
html[data-theme="light"] .user-menu-button,
html[data-theme="light"] .dropdown-user,
html[data-theme="light"] .theme-switch,
html[data-theme="light"] .analysis-item,
html[data-theme="light"] .profile-row,
html[data-theme="light"] .type-card,
html[data-theme="light"] .route-card,
html[data-theme="light"] .modal-meta span,
html[data-theme="light"] .pager-link {
    background: rgba(255, 255, 255, .68);
}
html[data-theme="light"] .ai-hero,
html[data-theme="light"] .holo-panel,
html[data-theme="light"] .metric,
html[data-theme="light"] .panel {
    background: linear-gradient(145deg, rgba(255, 255, 255, .9), rgba(238, 247, 250, .78));
}
html[data-theme="light"] .filter-row select,
html[data-theme="light"] .login-panel input,
html[data-theme="light"] table {
    color: var(--text);
    background: rgba(255, 255, 255, .82);
}
html[data-theme="light"] th { background: rgba(8, 127, 158, .1); }
html[data-theme="light"] tr:hover td { background: rgba(8, 127, 158, .055); }
html[data-theme="light"] .login-body { background: #eef5f8; }
html[data-theme="light"] .login-shell,
html[data-theme="light"] .login-panel {
    background: linear-gradient(145deg, rgba(255, 255, 255, .95), rgba(234, 245, 249, .92));
}
html[data-theme="light"] .login-visual { background: linear-gradient(145deg, rgba(230, 244, 249, .98), rgba(204, 231, 238, .98)); }
html[data-theme="light"] .intel-card { background: rgba(255, 255, 255, .62); }
html[data-theme="light"] .modal { background: rgba(218, 231, 238, .62); }
html[data-theme="light"] .profile-image,
html[data-theme="light"] .profile-row img { background: #dcecf2; }
html[data-theme="light"] .user-avatar { color: #ffffff; background: linear-gradient(135deg, #087f9e, #0f9f72); }

@media (max-width: 1180px) {
    .topbar {
        grid-template-columns: minmax(220px, 1fr) auto;
        grid-template-areas:
            "brand user"
            "nav nav";
        align-items: center;
    }
    .brand { grid-area: brand; }
    .topnav { grid-area: nav; justify-self: stretch; overflow-x: auto; scrollbar-width: thin; }
    .user-menu { grid-area: user; justify-self: end; }
}

@media (max-width: 760px) {
    .topbar { gap: 12px; }
    .brand strong { font-size: 13px; }
    .brand-mark { width: 42px; height: 42px; }
    .topnav { justify-content: flex-start; }
    .topnav a { min-height: 38px; padding: 0 11px; font-size: 13px; }
    .user-menu-button.icon-only { width: 44px; height: 44px; min-height: 44px; }
    .user-dropdown { right: 0; left: auto; width: min(286px, calc(100vw - 24px)); }
    .metric { min-height: 112px; }
    .metric strong { font-size: 32px; }
    h1 { font-size: clamp(30px, 10vw, 42px); }
}

@media (max-width: 420px) {
    .topbar { padding: 10px 12px; }
    .brand span:last-child { max-width: 210px; }
    .brand strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .topnav a { padding: 0 10px; }
    .user-dropdown { right: -2px; }
}
/* Rotating world animation for login visual */
.globe-stage {
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(360px, 54vw);
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    display: grid;
    place-items: center;
    filter: drop-shadow(0 0 34px rgba(36, 232, 255, .2));
}
.world-globe {
    position: relative;
    width: 56%;
    aspect-ratio: 1;
    border-radius: 50%;
    overflow: hidden;
    border: 1px solid rgba(124, 240, 255, .55);
    background:
        radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .92), rgba(36, 232, 255, .28) 14%, transparent 28%),
        radial-gradient(circle at 62% 58%, rgba(57, 245, 164, .28), transparent 42%),
        linear-gradient(145deg, #06243a 0%, #0b5f78 42%, #061526 100%);
    box-shadow:
        inset -32px -18px 42px rgba(0, 0, 0, .42),
        inset 18px 12px 28px rgba(255, 255, 255, .12),
        0 0 44px rgba(36, 232, 255, .34);
}
.world-globe::before {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    background: radial-gradient(circle at 34% 28%, rgba(255, 255, 255, .45), transparent 18%), linear-gradient(90deg, rgba(255,255,255,.08), transparent 35%, rgba(0,0,0,.22));
    z-index: 4;
    pointer-events: none;
}
.world-globe::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 50%;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), inset 0 0 30px rgba(36,232,255,.2);
    z-index: 5;
    pointer-events: none;
}
.globe-map {
    position: absolute;
    top: 11%;
    bottom: 11%;
    left: -105%;
    width: 310%;
    opacity: .92;
    background:
        radial-gradient(ellipse at 11% 38%, rgba(57,245,164,.92) 0 5%, transparent 5.5%),
        radial-gradient(ellipse at 18% 54%, rgba(57,245,164,.9) 0 8%, transparent 8.5%),
        radial-gradient(ellipse at 31% 28%, rgba(57,245,164,.86) 0 11%, transparent 11.5%),
        radial-gradient(ellipse at 41% 48%, rgba(57,245,164,.88) 0 7%, transparent 7.5%),
        radial-gradient(ellipse at 51% 34%, rgba(57,245,164,.9) 0 12%, transparent 12.5%),
        radial-gradient(ellipse at 64% 56%, rgba(57,245,164,.84) 0 8%, transparent 8.5%),
        radial-gradient(ellipse at 74% 28%, rgba(57,245,164,.9) 0 10%, transparent 10.5%),
        radial-gradient(ellipse at 83% 52%, rgba(57,245,164,.86) 0 13%, transparent 13.5%),
        radial-gradient(ellipse at 94% 40%, rgba(57,245,164,.9) 0 7%, transparent 7.5%);
    filter: blur(.2px);
    animation: worldRotate 8s linear infinite;
    z-index: 2;
}
.globe-grid-lines {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background:
        repeating-linear-gradient(90deg, rgba(255,255,255,.16) 0 1px, transparent 1px 22px),
        repeating-linear-gradient(0deg, rgba(255,255,255,.12) 0 1px, transparent 1px 26px);
    mix-blend-mode: screen;
    opacity: .38;
    z-index: 3;
}
.globe-glow {
    position: absolute;
    inset: -12%;
    border-radius: 50%;
    background: radial-gradient(circle, transparent 45%, rgba(36, 232, 255, .18) 58%, transparent 72%);
    animation: globePulse 2.8s ease-in-out infinite;
    z-index: 1;
}
.globe-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(36, 232, 255, .32);
    pointer-events: none;
}
.ring-one {
    width: 78%;
    aspect-ratio: 1;
    transform: rotateX(68deg) rotateZ(-18deg);
    animation: ringSpinOne 6.5s linear infinite;
}
.ring-two {
    width: 92%;
    aspect-ratio: 1;
    border-color: rgba(255, 79, 216, .28);
    transform: rotateX(70deg) rotateZ(28deg);
    animation: ringSpinTwo 9s linear infinite reverse;
}

html[data-theme="light"] .world-globe {
    background:
        radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .98), rgba(8, 127, 158, .28) 14%, transparent 28%),
        radial-gradient(circle at 62% 58%, rgba(15, 159, 114, .26), transparent 42%),
        linear-gradient(145deg, #d7f4fb 0%, #6dbccc 46%, #18546a 100%);
    box-shadow: inset -28px -16px 38px rgba(20, 60, 72, .28), inset 18px 12px 28px rgba(255, 255, 255, .25), 0 0 38px rgba(8, 127, 158, .24);
}
html[data-theme="light"] .globe-map { filter: saturate(.95); }

@keyframes worldRotate {
    from { transform: translateX(0); }
    to { transform: translateX(33.33%); }
}
@keyframes globePulse {
    50% { transform: scale(1.08); opacity: .76; }
}
@keyframes ringSpinOne {
    from { transform: rotateX(68deg) rotateZ(-18deg) rotate(0deg); }
    to { transform: rotateX(68deg) rotateZ(-18deg) rotate(360deg); }
}
@keyframes ringSpinTwo {
    from { transform: rotateX(70deg) rotateZ(28deg) rotate(0deg); }
    to { transform: rotateX(70deg) rotateZ(28deg) rotate(360deg); }
}

@media (max-width: 760px) {
    .globe-stage { width: min(300px, 72vw); }
}
.gif-globe {
    background: transparent;
    border-color: rgba(124, 240, 255, .62);
}
.gif-globe img {
    position: absolute;
    inset: -8%;
    width: 116%;
    height: 116%;
    object-fit: contain;
    z-index: 2;
    filter: saturate(1.14) contrast(1.08) drop-shadow(0 0 14px rgba(36, 232, 255, .35));
}
.gif-globe .globe-map { display: none; }
.gif-globe .globe-grid-lines {
    z-index: 3;
    opacity: .22;
    mix-blend-mode: screen;
}
.gif-globe .globe-glow { z-index: 1; }
html[data-theme="light"] .gif-globe img {
    filter: saturate(1.05) contrast(1.03) drop-shadow(0 0 12px rgba(8, 127, 158, .22));
}
/* Holographic video globe for the login experience */
.video-globe-stage {
    width: min(560px, 82%);
    isolation: isolate;
}
.hologram-earth-video {
    width: min(500px, 100%);
    aspect-ratio: 1;
    display: block;
    border-radius: 50%;
    object-fit: cover;
    background: radial-gradient(circle, rgba(36, 232, 255, .2), transparent 64%);
    box-shadow:
        0 0 30px rgba(36, 232, 255, .3),
        0 0 92px rgba(36, 232, 255, .18),
        inset 0 0 38px rgba(57, 245, 164, .16);
    filter: saturate(1.28) contrast(1.12) brightness(.98);
    -webkit-mask-image: radial-gradient(circle, #000 0 61%, rgba(0, 0, 0, .78) 66%, transparent 73%);
    mask-image: radial-gradient(circle, #000 0 61%, rgba(0, 0, 0, .78) 66%, transparent 73%);
    position: relative;
    z-index: 2;
}
.video-globe-mask {
    position: absolute;
    inset: 9%;
    border-radius: 50%;
    z-index: 3;
    pointer-events: none;
    border: 1px solid rgba(124, 240, 255, .52);
    background:
        radial-gradient(circle at 32% 24%, rgba(255, 255, 255, .32), transparent 16%),
        repeating-linear-gradient(0deg, rgba(124, 240, 255, .1) 0 1px, transparent 1px 10px);
    mix-blend-mode: screen;
    animation: scanLines 5s linear infinite;
}
.video-globe-mask::before,
.video-globe-mask::after {
    content: "";
    position: absolute;
    inset: 13%;
    border-radius: 50%;
    border: 1px solid rgba(57, 245, 164, .28);
    transform: rotateX(68deg) rotateZ(-16deg);
}
.video-globe-mask::after {
    inset: 26%;
    border-color: rgba(255, 79, 216, .24);
    transform: rotateX(70deg) rotateZ(28deg);
}
.video-globe-reflection {
    position: absolute;
    inset: 4%;
    z-index: 4;
    border-radius: 50%;
    pointer-events: none;
    background:
        linear-gradient(112deg, transparent 22%, rgba(255, 255, 255, .34) 42%, transparent 54%),
        radial-gradient(circle at 50% 50%, transparent 49%, rgba(36, 232, 255, .22) 64%, transparent 73%);
    mix-blend-mode: screen;
    opacity: .42;
    animation: reflectionSweep 5.8s ease-in-out infinite;
}
.video-globe-stage .ring-one { width: 86%; }
.video-globe-stage .ring-two { width: 100%; }
html[data-theme="light"] .hologram-earth-video {
    filter: saturate(1.18) contrast(1.06) brightness(1.08);
    box-shadow: 0 0 26px rgba(8, 127, 158, .24), 0 0 78px rgba(8, 127, 158, .14);
}
html[data-theme="light"] .video-globe-mask {
    border-color: rgba(8, 127, 158, .42);
    background:
        radial-gradient(circle at 32% 24%, rgba(255, 255, 255, .48), transparent 16%),
        repeating-linear-gradient(0deg, rgba(8, 127, 158, .12) 0 1px, transparent 1px 10px);
}
@media (max-width: 760px) {
    .video-globe-stage { width: min(430px, 86vw); }
    .hologram-earth-video { width: min(390px, 100%); }
}
/* GIF-only login globe override */
.gif-globe-stage {
    width: min(560px, 82%);
    isolation: isolate;
}
.hologram-earth-gif {
    width: min(500px, 100%);
    aspect-ratio: 1;
    display: block;
    border-radius: 50%;
    object-fit: cover;
    background: radial-gradient(circle, rgba(36, 232, 255, .18), rgba(5, 7, 13, .4) 70%);
    box-shadow:
        0 0 26px rgba(36, 232, 255, .32),
        0 0 92px rgba(36, 232, 255, .2),
        inset 0 0 40px rgba(57, 245, 164, .16);
    filter: saturate(1.2) contrast(1.08) brightness(.96) hue-rotate(160deg);
    -webkit-mask-image: radial-gradient(circle, #000 0 62%, rgba(0, 0, 0, .82) 68%, transparent 75%);
    mask-image: radial-gradient(circle, #000 0 62%, rgba(0, 0, 0, .82) 68%, transparent 75%);
    position: relative;
    z-index: 2;
}
.gif-globe-mask {
    inset: 7%;
}
.gif-globe-reflection {
    inset: 3%;
}
.gif-globe-stage .ring-one { width: 86%; }
.gif-globe-stage .ring-two { width: 100%; }
html[data-theme="light"] .hologram-earth-gif {
    filter: saturate(1.08) contrast(1.03) brightness(1.04) hue-rotate(150deg);
    box-shadow: 0 0 24px rgba(8, 127, 158, .24), 0 0 76px rgba(8, 127, 158, .14);
}
@media (max-width: 760px) {
    .gif-globe-stage { width: min(430px, 86vw); }
    .hologram-earth-gif { width: min(390px, 100%); }
}
/* Earth-only cinematic login image */
.earth-only-visual {
    display: grid;
    place-items: center;
    background:
        radial-gradient(circle at 50% 45%, rgba(36, 232, 255, .14), transparent 36%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, .06), transparent 48%),
        linear-gradient(145deg, rgba(2, 7, 18, .98), rgba(6, 15, 32, .98));
}
.earth-only-stage {
    width: min(520px, 82%);
    aspect-ratio: 1;
    display: grid;
    place-items: center;
}
.cinematic-earth-gif {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    border-radius: 50%;
    filter: saturate(1.08) contrast(1.06) brightness(.94) drop-shadow(0 0 34px rgba(56, 171, 255, .34));
    box-shadow: 0 0 90px rgba(36, 232, 255, .16);
}
html[data-theme="light"] .earth-only-visual {
    background:
        radial-gradient(circle at 50% 45%, rgba(8, 127, 158, .12), transparent 36%),
        radial-gradient(circle at 50% 50%, rgba(255, 255, 255, .48), transparent 50%),
        linear-gradient(145deg, rgba(231, 245, 250, .98), rgba(203, 229, 239, .98));
}
html[data-theme="light"] .cinematic-earth-gif {
    filter: saturate(1.04) contrast(1.02) brightness(1.02) drop-shadow(0 0 28px rgba(8, 127, 158, .22));
}
@media (max-width: 760px) {
    .earth-only-stage { width: min(390px, 82vw); }
}
/* Reference-style navy cinematic Earth GIF */
.earth-only-visual {
    display: block;
    background: #020816;
}
.earth-only-stage {
    width: 100%;
    height: 100%;
    aspect-ratio: auto;
    overflow: hidden;
    display: block;
    position: relative;
}
.cinematic-earth-gif {
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: 78% center;
    border-radius: 0;
    filter: saturate(1.08) contrast(1.06) brightness(.92);
    box-shadow: none;
}
html[data-theme="light"] .earth-only-visual {
    background: #06182d;
}
html[data-theme="light"] .cinematic-earth-gif {
    filter: saturate(1.02) contrast(1.02) brightness(.98);
}
@media (max-width: 1040px) {
    .earth-only-stage { min-height: 360px; }
    .cinematic-earth-gif { object-position: 78% center; }
}
@media (max-width: 640px) {
    .earth-only-stage { min-height: 340px; }
    .cinematic-earth-gif { object-position: 82% center; }
}
/* Custom no-text navy Earth animation */
.cinematic-earth-gif {
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center;
    border-radius: 0;
    filter: saturate(1.08) contrast(1.06) brightness(.96);
    box-shadow: none;
}
[data-repatriation-results] {
    transition: opacity .18s ease, filter .18s ease;
}
[data-repatriation-results].is-loading {
    opacity: .58;
    filter: saturate(.8);
    pointer-events: none;
}
.filter-status {
    min-height: 43px;
    display: inline-flex;
    align-items: center;
    color: var(--green);
    font-size: 13px;
    font-weight: 800;
}
.empty-cell {
    text-align: center;
    color: var(--muted);
    padding: 26px 12px;
}
[data-filter-results] {
    transition: opacity .18s ease, filter .18s ease;
}
[data-filter-results].is-loading {
    opacity: .58;
    filter: saturate(.8);
    pointer-events: none;
}
.empty-card {
    cursor: default;
}
.empty-card:hover {
    transform: none;
}
/* Real heat-map card */
.heat-map-card {
    gap: 10px;
    padding: 14px;
    overflow: hidden;
}
.heat-map-card:hover .heat-map-visual img {
    transform: scale(1.035);
}
.heat-map-visual {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid rgba(124, 240, 255, .18);
    border-radius: 8px;
    background: #07121f;
    box-shadow: inset 0 0 36px rgba(36, 232, 255, .08), 0 18px 34px rgba(0, 0, 0, .18);
}
.heat-map-visual::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(36, 232, 255, .12) 1px, transparent 1px),
        linear-gradient(rgba(36, 232, 255, .1) 1px, transparent 1px),
        radial-gradient(circle at 26% 34%, rgba(255, 79, 216, .22), transparent 16%),
        radial-gradient(circle at 35% 28%, rgba(255, 207, 90, .2), transparent 18%),
        radial-gradient(circle at 72% 58%, rgba(57, 245, 164, .24), transparent 18%);
    background-size: 34px 34px, 34px 34px, auto, auto, auto;
    mix-blend-mode: screen;
}
.heat-map-visual::after {
    content: "";
    position: absolute;
    inset: -45%;
    z-index: 3;
    pointer-events: none;
    background: linear-gradient(110deg, transparent 42%, rgba(255, 255, 255, .18), transparent 56%);
    animation: glassSweep 7s ease-in-out infinite;
}
.heat-map-visual img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 54% 44%;
    filter: saturate(1.12) contrast(1.08) brightness(.62) hue-rotate(172deg);
    transition: transform .32s ease;
}
.heat-zone {
    position: absolute;
    z-index: 4;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, rgba(255, 207, 90, .85) 0 9%, rgba(255, 93, 108, .45) 22%, rgba(255, 79, 216, .2) 42%, transparent 70%);
    box-shadow: 0 0 34px rgba(255, 93, 108, .28);
    animation: heatPulse 2.4s ease-in-out infinite;
    pointer-events: none;
}
.zone-europe { left: 32%; top: 27%; width: 128px; height: 128px; animation-delay: .25s; }
.zone-italy { left: 25%; top: 39%; width: 92px; height: 92px; animation-delay: .65s; }
.zone-bay { left: 74%; top: 57%; width: 118px; height: 118px; animation-delay: 1s; }
.map-pin {
    position: absolute;
    z-index: 5;
    transform: translate(-50%, -50%);
    padding: 6px 8px;
    border: 1px solid rgba(124, 240, 255, .42);
    border-radius: 8px;
    color: #eef7ff;
    background: rgba(5, 12, 24, .76);
    box-shadow: 0 0 20px rgba(36, 232, 255, .2);
    font-size: 11px;
    line-height: 1;
    white-space: nowrap;
    backdrop-filter: blur(8px);
}
.map-pin::before {
    content: "";
    position: absolute;
    left: 50%;
    top: calc(100% + 5px);
    width: 8px;
    height: 8px;
    transform: translateX(-50%);
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 14px var(--cyan), 0 0 30px rgba(57, 245, 164, .4);
}
.pin-europe { left: 34%; top: 18%; }
.pin-italy { left: 24%; top: 31%; }
.pin-bay { left: 73%; top: 46%; }
html[data-theme="light"] .heat-map-visual {
    background: #e8f2f7;
    box-shadow: inset 0 0 28px rgba(8, 127, 158, .1), 0 14px 28px rgba(35, 53, 67, .12);
}
html[data-theme="light"] .heat-map-visual img {
    filter: saturate(1.02) contrast(1.02) brightness(.88) hue-rotate(160deg);
}
html[data-theme="light"] .map-pin {
    color: #10202d;
    background: rgba(255, 255, 255, .78);
    border-color: rgba(21, 127, 155, .34);
}
@keyframes heatPulse {
    0%, 100% { opacity: .55; transform: translate(-50%, -50%) scale(.88); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.15); }
}
@media (max-width: 640px) {
    .map-pin { font-size: 10px; padding: 5px 7px; }
    .zone-europe { width: 104px; height: 104px; }
    .zone-italy { width: 74px; height: 74px; }
    .zone-bay { width: 96px; height: 96px; }
}
/* Dynamic database-driven SVG heat map */
.dynamic-heat-map {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid rgba(124, 240, 255, .18);
    border-radius: 8px;
    background: #07121f;
    box-shadow: inset 0 0 36px rgba(36, 232, 255, .08), 0 18px 34px rgba(0, 0, 0, .18);
}
.dynamic-heat-map::after {
    content: "";
    position: absolute;
    inset: -45%;
    z-index: 5;
    pointer-events: none;
    background: linear-gradient(110deg, transparent 42%, rgba(255, 255, 255, .16), transparent 56%);
    animation: glassSweep 7s ease-in-out infinite;
}
.heat-world-svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}
.heat-grid-lines line {
    stroke: rgba(124, 240, 255, .13);
    stroke-width: 1;
}
.heat-land path {
    fill: rgba(29, 94, 115, .56);
    stroke: rgba(124, 240, 255, .24);
    stroke-width: 1.5;
    filter: drop-shadow(0 0 12px rgba(36, 232, 255, .1));
}
.heat-route-lines path {
    fill: none;
    stroke: rgba(57, 245, 164, .42);
    stroke-width: 2;
    stroke-dasharray: 8 9;
    animation: routeDash 4s linear infinite;
}
.dynamic-heat-marker {
    position: absolute;
    left: var(--x);
    top: var(--y);
    z-index: 6;
    width: var(--size);
    height: var(--size);
    border: 0;
    border-radius: 999px;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, color-mix(in srgb, var(--hot) 82%, white 18%) 0 8%, color-mix(in srgb, var(--hot) 46%, transparent) 24%, transparent 69%);
    box-shadow: 0 0 30px color-mix(in srgb, var(--hot) 36%, transparent);
    cursor: pointer;
    animation: heatPulse 2.4s ease-in-out infinite;
}
.heat-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: var(--hot);
    box-shadow: 0 0 16px var(--hot), 0 0 34px color-mix(in srgb, var(--hot) 60%, transparent);
}
.heat-label {
    position: absolute;
    left: 50%;
    bottom: calc(100% - 4px);
    min-width: 128px;
    transform: translateX(-50%) translateY(6px);
    display: grid;
    gap: 3px;
    padding: 8px 9px;
    border: 1px solid rgba(124, 240, 255, .36);
    border-radius: 8px;
    color: #eef7ff;
    background: rgba(5, 12, 24, .82);
    box-shadow: 0 0 20px rgba(36, 232, 255, .18);
    opacity: 0;
    pointer-events: none;
    transition: .18s ease;
    backdrop-filter: blur(8px);
}
.heat-label strong { font-size: 11px; line-height: 1.1; }
.heat-label small { color: #a9bdcf; font-size: 10px; line-height: 1.2; }
.dynamic-heat-marker:hover,
.dynamic-heat-marker:focus-visible {
    z-index: 7;
    outline: none;
}
.dynamic-heat-marker:hover .heat-label,
.dynamic-heat-marker:focus-visible .heat-label {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.heat-map-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    margin-top: 8px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
    text-transform: uppercase;
}
.heat-map-legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend-dot { width: 9px; height: 9px; border-radius: 50%; box-shadow: 0 0 14px currentColor; }
.legend-dot.critical { color: var(--danger); background: var(--danger); }
.legend-dot.high { color: var(--amber); background: var(--amber); }
.legend-dot.watch { color: var(--green); background: var(--green); }
html[data-theme="light"] .dynamic-heat-map {
    background: #e8f2f7;
    box-shadow: inset 0 0 28px rgba(8, 127, 158, .1), 0 14px 28px rgba(35, 53, 67, .12);
}
html[data-theme="light"] .heat-world-svg rect { fill: #dbeaf1; }
html[data-theme="light"] .heat-land path { fill: rgba(81, 146, 160, .52); stroke: rgba(21, 127, 155, .3); }
html[data-theme="light"] .heat-label { color: #10202d; background: rgba(255, 255, 255, .86); border-color: rgba(21, 127, 155, .34); }
html[data-theme="light"] .heat-label small { color: #607386; }
@keyframes routeDash { to { stroke-dashoffset: -34; } }
/* Real Leaflet map heat map */
.real-heat-map {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 300px;
    overflow: hidden;
    border: 1px solid rgba(124, 240, 255, .2);
    border-radius: 8px;
    background: #07121f;
    box-shadow: inset 0 0 36px rgba(36, 232, 255, .08), 0 18px 34px rgba(0, 0, 0, .18);
}
.leaflet-heat-map {
    width: 100%;
    height: 100%;
    min-height: inherit;
    background: #07121f;
    z-index: 1;
}
.real-heat-map::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 401;
    pointer-events: none;
    background:
        linear-gradient(90deg, rgba(36, 232, 255, .08) 1px, transparent 1px),
        linear-gradient(rgba(36, 232, 255, .07) 1px, transparent 1px),
        radial-gradient(circle at 72% 45%, rgba(57, 245, 164, .12), transparent 28%);
    background-size: 42px 42px, 42px 42px, auto;
    mix-blend-mode: screen;
}
.real-heat-map .leaflet-tile-pane {
    filter: saturate(.72) contrast(1.08) brightness(.62) hue-rotate(168deg);
}
.real-heat-map .leaflet-control-zoom a,
.real-heat-map .leaflet-control-attribution {
    color: var(--text);
    background: rgba(5, 12, 24, .82);
    border-color: rgba(124, 240, 255, .24);
}
.real-heat-map .leaflet-control-attribution a { color: var(--cyan); }
.real-heat-map .leaflet-popup-content-wrapper,
.real-heat-map .leaflet-popup-tip {
    color: var(--text);
    background: rgba(8, 17, 31, .96);
    border: 1px solid rgba(124, 240, 255, .22);
    box-shadow: 0 18px 34px rgba(0, 0, 0, .28);
}
.real-heat-map .leaflet-popup-content { margin: 12px 14px; line-height: 1.45; }
.leaflet-heat-circle {
    animation: leafletHeatPulse 2.4s ease-in-out infinite;
}
.leaflet-heat-dot {
    filter: drop-shadow(0 0 10px currentColor);
}
html[data-theme="light"] .real-heat-map {
    background: #e8f2f7;
    box-shadow: inset 0 0 28px rgba(8, 127, 158, .1), 0 14px 28px rgba(35, 53, 67, .12);
}
html[data-theme="light"] .real-heat-map .leaflet-tile-pane {
    filter: saturate(.82) contrast(1.02) brightness(.95);
}
html[data-theme="light"] .real-heat-map .leaflet-control-zoom a,
html[data-theme="light"] .real-heat-map .leaflet-control-attribution,
html[data-theme="light"] .real-heat-map .leaflet-popup-content-wrapper,
html[data-theme="light"] .real-heat-map .leaflet-popup-tip {
    color: #10202d;
    background: rgba(255, 255, 255, .9);
    border-color: rgba(21, 127, 155, .26);
}
@keyframes leafletHeatPulse {
    0%, 100% { opacity: .55; }
    50% { opacity: .95; }
}
@media (max-width: 640px) {
    .real-heat-map { min-height: 260px; }
}
/* Compact page title bar */
.page-head.ai-hero,
.page-head.ai-hero.compact-hero {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 14px 18px;
    margin-bottom: 14px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(13, 22, 38, .9), rgba(8, 13, 24, .72));
    box-shadow: 0 14px 36px rgba(0, 0, 0, .22), inset 0 0 34px rgba(36, 232, 255, .04);
}
.page-head.ai-hero::after {
    opacity: .32;
}
.page-head.ai-hero .eyebrow {
    display: inline-flex;
    margin-bottom: 5px;
    font-size: 11px;
}
.page-head.ai-hero h1 {
    font-size: clamp(24px, 3vw, 34px);
    line-height: 1.05;
}
.page-head.ai-hero p {
    max-width: 850px;
    margin-top: 5px;
    font-size: 14px;
    line-height: 1.45;
}
.page-head.ai-hero .hero-orbit {
    width: 76px;
    justify-self: end;
    opacity: .92;
}
.page-head.ai-hero .hero-orbit::before { inset: 12px; }
.page-head.ai-hero .hero-orbit::after { inset: 25px; }
.page-head.ai-hero .hero-orbit span {
    width: 6px;
    height: 6px;
}
.page-head.ai-hero .hero-orbit span:nth-child(1) { top: 7px; left: 35px; }
.page-head.ai-hero .hero-orbit span:nth-child(2) { right: 8px; top: 37px; }
.page-head.ai-hero .hero-orbit span:nth-child(3) { left: 20px; bottom: 12px; }
html[data-theme="light"] .page-head.ai-hero,
html[data-theme="light"] .page-head.ai-hero.compact-hero {
    background: linear-gradient(135deg, rgba(255, 255, 255, .9), rgba(238, 247, 250, .78));
    box-shadow: 0 12px 28px rgba(35, 53, 67, .12), inset 0 0 28px rgba(8, 127, 158, .04);
}
@media (max-width: 760px) {
    .page-head.ai-hero,
    .page-head.ai-hero.compact-hero {
        grid-template-columns: 1fr;
        padding: 14px;
        gap: 10px;
    }
    .page-head.ai-hero .hero-orbit {
        width: 58px;
        justify-self: start;
    }
    .page-head.ai-hero p {
        font-size: 13px;
    }
}

/* Statistical dashboard and compact smuggling intelligence layout */
.content-grid.two { align-items: start; }
.dashboard-stat-shell {
    display: grid;
    grid-template-columns: minmax(0, .95fr) minmax(420px, 1.05fr);
    gap: 18px;
    align-items: start;
    margin-bottom: 18px;
}
.dashboard-chart-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    align-items: start;
}
.dashboard-map-panel .real-heat-map,
.smuggling-map-panel .real-heat-map {
    min-height: 360px;
}
.map-footnote {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: 12px;
    color: var(--muted);
    font-size: 13px;
}
.map-footnote strong { color: var(--text); }
.chart-panel { min-height: 0; }
.compact-chart-panel { align-self: start; }
.chart-bars .bar-row {
    grid-template-columns: minmax(120px, 170px) minmax(90px, 1fr) 68px;
}
.compact-bars .bar-row {
    grid-template-columns: minmax(120px, 165px) minmax(80px, 1fr) 62px;
    font-size: 13px;
}
.donut-wrap {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
}
.donut-chart {
    width: 150px;
    aspect-ratio: 1;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: conic-gradient(var(--cyan) 0 var(--traffic), var(--magenta) var(--traffic) 100%);
    box-shadow: inset 0 0 26px rgba(0, 0, 0, .34), 0 0 34px rgba(36, 232, 255, .12);
    position: relative;
}
.donut-chart::after {
    content: "";
    position: absolute;
    inset: 22px;
    border-radius: 50%;
    background: var(--panel-strong);
    box-shadow: inset 0 0 24px rgba(36, 232, 255, .08);
}
.donut-chart span {
    position: relative;
    z-index: 1;
    font-size: 26px;
    font-weight: 950;
}
.chart-legend-list {
    display: grid;
    gap: 10px;
}
.chart-legend-list div {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 9px;
    color: var(--muted);
    font-size: 13px;
}
.chart-legend-list strong { color: var(--text); }
.column-chart {
    min-height: 210px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(74px, 1fr));
    gap: 12px;
    align-items: end;
    padding-top: 12px;
}
.column-bar {
    min-height: 190px;
    display: grid;
    grid-template-rows: 1fr auto auto auto;
    gap: 6px;
    align-items: end;
    text-align: center;
    color: var(--muted);
    font-size: 12px;
}
.column-bar i {
    width: 100%;
    height: var(--height);
    min-height: 28px;
    border-radius: 8px 8px 3px 3px;
    background: linear-gradient(180deg, var(--cyan), var(--green), var(--amber));
    box-shadow: 0 0 22px rgba(36, 232, 255, .24);
}
.column-bar strong { color: var(--text); font-size: 18px; }
.column-bar span { color: var(--cyan); font-weight: 900; }
.status-grid-chart,
.route-type-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}
.status-tile,
.route-type-tile {
    min-height: 96px;
    display: grid;
    gap: 7px;
    align-content: center;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .045);
}
.status-tile span,
.route-type-tile span {
    color: var(--cyan);
    font-size: 12px;
    text-transform: uppercase;
    font-weight: 900;
}
.status-tile strong,
.route-type-tile strong {
    font-size: 28px;
    line-height: 1;
}
.status-tile small,
.route-type-tile small { color: var(--muted); }
.smuggling-intel-stack {
    display: grid;
    gap: 18px;
    margin-bottom: 18px;
}
.smuggling-analytics-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(360px, .9fr);
    gap: 18px;
    align-items: start;
}
.analysis-chip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 10px;
}
.analysis-chip {
    min-height: 112px;
    display: grid;
    gap: 7px;
    align-content: start;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: var(--text);
    background: rgba(255, 255, 255, .045);
    text-align: left;
    cursor: pointer;
    transition: .22s ease;
}
.analysis-chip:hover {
    border-color: var(--line-strong);
    background: rgba(36, 232, 255, .08);
    transform: translateY(-1px);
}
.analysis-chip span {
    color: var(--cyan);
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 900;
}
.analysis-chip small { color: var(--muted); }
.route-workspace-panel .route-grid {
    grid-template-columns: repeat(auto-fit, minmax(460px, 1fr));
}
html[data-theme="light"] .donut-chart::after,
html[data-theme="light"] .status-tile,
html[data-theme="light"] .route-type-tile,
html[data-theme="light"] .analysis-chip {
    background: rgba(255, 255, 255, .62);
}
@media (max-width: 1180px) {
    .dashboard-stat-shell,
    .dashboard-chart-grid,
    .smuggling-analytics-grid {
        grid-template-columns: 1fr 1fr;
    }
    .dashboard-map-panel { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
    .dashboard-stat-shell,
    .dashboard-chart-grid,
    .smuggling-analytics-grid,
    .donut-wrap {
        grid-template-columns: 1fr;
    }
    .dashboard-map-panel .real-heat-map,
    .smuggling-map-panel .real-heat-map {
        min-height: 280px;
    }
    .route-workspace-panel .route-grid {
        grid-template-columns: 1fr;
    }
    .chart-bars .bar-row,
    .compact-bars .bar-row {
        grid-template-columns: 1fr;
        gap: 7px;
    }
    .status-grid-chart,
    .route-type-grid {
        grid-template-columns: 1fr;
    }
    .donut-chart { width: 132px; }
}
/* Deportee Excel and RCMS statistical chart panels */
.deportee-stat-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(360px, .75fr);
    gap: 18px;
    align-items: start;
    margin-bottom: 18px;
}
.panel-total {
    color: var(--green);
    font-size: 22px;
    line-height: 1;
}
.horizontal-column-chart {
    min-height: 300px;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(44px, 1fr);
    gap: 8px;
    align-items: end;
    overflow-x: auto;
    padding: 12px 4px 6px;
    scrollbar-width: thin;
}
.wide-column {
    min-width: 44px;
    min-height: 270px;
    display: grid;
    grid-template-rows: 1fr auto auto;
    gap: 6px;
    align-items: end;
    text-align: center;
    color: var(--muted);
    font-size: 11px;
}
.wide-column i {
    width: 100%;
    height: var(--height);
    min-height: 18px;
    border-radius: 7px 7px 3px 3px;
    background: linear-gradient(180deg, var(--cyan), var(--green));
    box-shadow: 0 0 18px rgba(36, 232, 255, .22);
}
.wide-column strong {
    color: var(--text);
    font-size: 12px;
}
.wide-column span {
    max-width: 52px;
    min-height: 56px;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    justify-self: center;
}
.rcms-year-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}
.rcms-year-card {
    min-height: 178px;
    display: grid;
    gap: 9px;
    align-content: center;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .045);
}
.rcms-year-card span {
    color: var(--cyan);
    font-size: 12px;
    text-transform: uppercase;
    font-weight: 900;
}
.rcms-year-card strong {
    font-size: 38px;
    line-height: 1;
}
.rcms-year-card small { color: var(--muted); }
.rcms-split-bar {
    height: 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .08);
    overflow: hidden;
    position: relative;
}
.rcms-split-bar i,
.rcms-split-bar b {
    position: absolute;
    inset: 0 auto 0 0;
    border-radius: inherit;
}
.rcms-split-bar i {
    background: linear-gradient(90deg, rgba(36, 232, 255, .72), rgba(57, 245, 164, .72));
}
.rcms-split-bar b {
    height: 4px;
    top: 4px;
    background: var(--amber);
    box-shadow: 0 0 12px rgba(255, 207, 90, .42);
}
.dashboard-district-panel,
.dashboard-arrival-country-panel,
.rcms-trend-panel { min-height: 0; }
html[data-theme="light"] .rcms-year-card {
    background: rgba(255, 255, 255, .62);
}
@media (max-width: 1180px) {
    .deportee-stat-grid { grid-template-columns: 1fr; }
    .rcms-year-grid { grid-template-columns: repeat(3, minmax(180px, 1fr)); overflow-x: auto; }
}
@media (max-width: 760px) {
    .horizontal-column-chart {
        grid-auto-columns: 42px;
        min-height: 260px;
    }
    .wide-column { min-height: 230px; }
    .rcms-year-grid { grid-template-columns: 1fr; }
}
/* Clear dashboard section grouping */
.dashboard-section-block {
    position: relative;
    margin-bottom: 22px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: linear-gradient(145deg, rgba(7, 12, 22, .42), rgba(12, 22, 38, .3));
    box-shadow: 0 18px 44px rgba(0, 0, 0, .16), inset 0 0 34px rgba(36, 232, 255, .035);
}
.dashboard-section-block::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 3px;
    border-radius: 10px 10px 0 0;
    background: linear-gradient(90deg, var(--cyan), var(--green));
}
.trafficking-block::before { background: linear-gradient(90deg, var(--cyan), var(--green)); }
.smuggling-block::before { background: linear-gradient(90deg, var(--magenta), var(--amber)); }
.source-data-block::before { background: linear-gradient(90deg, var(--cyan), var(--magenta), var(--amber)); }
.section-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}
.section-title-row h2 {
    margin-top: 4px;
    font-size: clamp(20px, 2.2vw, 28px);
}
.section-metrics { margin-bottom: 18px; }
.section-chart-grid {
    display: grid;
    grid-template-columns: 1.15fr 1fr .85fr;
    gap: 18px;
    align-items: start;
}
.smuggling-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(420px, 1.08fr) minmax(360px, .92fr);
    gap: 18px;
    align-items: start;
}
.smuggling-side-charts {
    display: grid;
    gap: 18px;
}
.slim-column-chart {
    min-height: 180px;
}
.slim-column-chart .column-bar {
    min-height: 160px;
}
.source-data-block .deportee-stat-grid,
.source-data-block .dashboard-stat-shell {
    margin-bottom: 0;
}
.source-stat-shell {
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
}
.trafficking-block .metric::before {
    background: linear-gradient(90deg, var(--cyan), var(--green));
}
.smuggling-block .metric::before {
    background: linear-gradient(90deg, var(--magenta), var(--amber));
}
html[data-theme="light"] .dashboard-section-block {
    background: linear-gradient(145deg, rgba(255, 255, 255, .64), rgba(238, 247, 250, .42));
    box-shadow: 0 16px 34px rgba(35, 53, 67, .1), inset 0 0 28px rgba(8, 127, 158, .035);
}
@media (max-width: 1180px) {
    .section-chart-grid,
    .smuggling-dashboard-grid,
    .source-stat-shell {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 760px) {
    .dashboard-section-block {
        padding: 14px;
        margin-bottom: 16px;
    }
    .section-title-row {
        align-items: stretch;
        flex-direction: column;
    }
    .section-title-row .ghost-button {
        width: max-content;
    }
}
/* Balanced source-data cards and compact district chart */
.source-card-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
    gap: 14px;
    align-items: start;
}
.source-card-wide {
    grid-column: 1 / -1;
}
.source-side-stack {
    display: grid;
    gap: 14px;
    align-items: start;
}
.source-card-grid .panel {
    margin-bottom: 0;
}
.source-data-block .district-compact-chart {
    min-height: 238px;
    grid-auto-columns: minmax(24px, 1fr);
    gap: 5px;
    overflow-x: hidden;
    padding: 8px 2px 2px;
}
.source-data-block .district-compact-chart .wide-column {
    min-width: 24px;
    min-height: 220px;
    grid-template-rows: auto 1fr auto;
    gap: 4px;
    font-size: 10px;
}
.source-data-block .district-compact-chart .wide-column strong {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    justify-self: center;
    align-self: end;
    min-height: 28px;
    color: var(--text);
    font-size: 10px;
    line-height: 1;
}
.source-data-block .district-compact-chart .wide-column i {
    width: min(100%, 28px);
    justify-self: center;
    min-height: 16px;
    border-radius: 6px 6px 2px 2px;
}
.source-data-block .district-compact-chart .wide-column span {
    max-width: 36px;
    min-height: 52px;
    font-size: 9px;
}
.compact-rcms-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.compact-rcms-grid .rcms-year-card {
    min-height: 138px;
    padding: 12px;
}
.compact-rcms-grid .rcms-year-card strong {
    font-size: 30px;
}
@media (max-width: 1180px) {
    .source-card-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 760px) {
    .source-data-block .district-compact-chart {
        grid-auto-columns: minmax(24px, 1fr);
        min-height: 230px;
    }
    .source-data-block .district-compact-chart .wide-column {
        min-height: 212px;
    }
    .compact-rcms-grid {
        grid-template-columns: 1fr;
    }
}
/* Show every district summary without cutting off bars */
.source-data-block .district-compact-chart {
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fit, minmax(9px, 1fr));
    gap: 3px;
    overflow-x: visible;
}
.source-data-block .district-compact-chart .wide-column {
    min-width: 0;
    gap: 3px;
}
.source-data-block .district-compact-chart .wide-column i {
    width: min(100%, 16px);
}
.source-data-block .district-compact-chart .wide-column strong {
    font-size: 9px;
}
.source-data-block .district-compact-chart .wide-column span {
    max-width: 22px;
    min-height: 48px;
    font-size: 8px;
}
@media (max-width: 760px) {
    .source-data-block .district-compact-chart {
        grid-template-columns: repeat(auto-fit, minmax(8px, 1fr));
        gap: 2px;
    }
    .source-data-block .district-compact-chart .wide-column i {
        width: min(100%, 12px);
    }
}
/* Top district chart with all-district modal */
.district-panel-head {
    align-items: flex-start;
}
.panel-actions {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.icon-action-button {
    width: 38px;
    height: 38px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    color: var(--cyan);
    background: rgba(36, 232, 255, .08);
    cursor: pointer;
    box-shadow: inset 0 0 16px rgba(36, 232, 255, .08), 0 0 18px rgba(36, 232, 255, .08);
}
.icon-action-button:hover {
    color: var(--text);
    background: rgba(36, 232, 255, .16);
    transform: translateY(-1px);
}
.icon-action-button svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.source-data-block .district-compact-chart {
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: minmax(30px, 1fr);
    gap: 7px;
    overflow-x: hidden;
}
.source-data-block .district-compact-chart .wide-column i {
    width: min(100%, 24px);
}
.source-data-block .district-compact-chart .wide-column span {
    max-width: 34px;
    font-size: 9px;
}
.district-modal-box {
    width: min(980px, 100%);
}
.district-modal-summary {
    display: grid;
    grid-template-columns: auto 1fr auto 1fr;
    gap: 8px 10px;
    align-items: baseline;
    margin: 14px 0;
    color: var(--muted);
}
.district-modal-summary strong {
    color: var(--green);
    font-size: 24px;
    line-height: 1;
}
.district-modal-list {
    max-height: min(58vh, 560px);
    overflow: auto;
    display: grid;
    gap: 8px;
    padding-right: 4px;
}
.district-modal-row {
    display: grid;
    grid-template-columns: minmax(150px, 220px) minmax(120px, 1fr) 72px;
    gap: 12px;
    align-items: center;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .04);
}
.district-modal-row span {
    color: var(--text);
    font-weight: 800;
}
.district-modal-row div {
    height: 9px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, .08);
}
.district-modal-row i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cyan), var(--green), var(--amber));
    box-shadow: 0 0 14px rgba(36, 232, 255, .35);
}
.district-modal-row strong {
    text-align: right;
    color: var(--green);
}
html[data-theme="light"] .icon-action-button,
html[data-theme="light"] .district-modal-row {
    background: rgba(255, 255, 255, .68);
}
@media (max-width: 760px) {
    .district-panel-head {
        align-items: stretch;
    }
    .panel-actions {
        justify-content: space-between;
    }
    .source-data-block .district-compact-chart {
        grid-auto-columns: minmax(26px, 1fr);
        gap: 5px;
    }
    .district-modal-summary {
        grid-template-columns: auto 1fr;
    }
    .district-modal-row {
        grid-template-columns: 1fr;
        gap: 7px;
    }
    .district-modal-row strong {
        text-align: left;
    }
}
/* Denser top district chart and country all-view action */
.source-data-block .district-tight-chart {
    min-height: 186px;
    align-items: end;
    padding: 2px 8px 0;
    grid-auto-columns: minmax(22px, 1fr);
    gap: 5px;
}
.source-data-block .district-tight-chart .wide-column {
    min-height: 170px;
    grid-template-rows: auto 1fr auto;
    gap: 2px;
}
.source-data-block .district-tight-chart .wide-column strong {
    min-height: 24px;
    font-size: 9px;
    opacity: .95;
}
.source-data-block .district-tight-chart .wide-column i {
    width: min(100%, 20px);
    min-height: 14px;
    box-shadow: 0 0 16px rgba(36, 232, 255, .18);
}
.source-data-block .district-tight-chart .wide-column span {
    max-width: 28px;
    min-height: 42px;
    font-size: 8px;
}
.source-card-wide .panel-head {
    margin-bottom: 8px;
}
.source-country-card .panel-head {
    align-items: flex-start;
}
.source-country-card .compact-bars .bar-row {
    grid-template-columns: minmax(145px, 180px) minmax(90px, 1fr) 58px;
    gap: 10px;
    font-size: 12px;
}
@media (max-width: 760px) {
    .source-data-block .district-tight-chart {
        min-height: 174px;
        grid-auto-columns: minmax(18px, 1fr);
    }
    .source-data-block .district-tight-chart .wide-column {
        min-height: 160px;
    }
    .source-data-block .district-tight-chart .wide-column i {
        width: min(100%, 15px);
    }
}
/* Ranked district chart replacement */
.district-ranked-chart {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 14px;
    align-items: start;
}
.district-rank-row {
    min-height: 36px;
    display: grid;
    grid-template-columns: 28px minmax(110px, 170px) minmax(110px, 1fr) 54px;
    gap: 10px;
    align-items: center;
    padding: 8px 10px;
    border: 1px solid rgba(124, 240, 255, .12);
    border-radius: 8px;
    background: rgba(255, 255, 255, .035);
}
.district-rank-row span {
    width: 24px;
    height: 24px;
    display: grid;
    place-items: center;
    border-radius: 7px;
    color: var(--cyan);
    background: rgba(36, 232, 255, .1);
    font-size: 11px;
    font-weight: 950;
}
.district-rank-row strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 13px;
}
.district-rank-row div {
    height: 9px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, .08);
}
.district-rank-row i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cyan), var(--green), var(--amber));
    box-shadow: 0 0 14px rgba(36, 232, 255, .34);
}
.district-rank-row b {
    color: var(--green);
    text-align: right;
    font-size: 13px;
}
.source-card-wide .district-ranked-chart {
    margin-top: 4px;
}
html[data-theme="light"] .district-rank-row {
    background: rgba(255, 255, 255, .66);
}
@media (max-width: 960px) {
    .district-ranked-chart {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 640px) {
    .district-rank-row {
        grid-template-columns: 28px minmax(0, 1fr) 50px;
    }
    .district-rank-row div {
        grid-column: 2 / -1;
        width: 100%;
    }
}
/* Restore vertical Top 10 district chart */
.source-data-block .district-top10-chart {
    min-height: 230px;
    display: grid;
    grid-auto-flow: column;
    grid-template-columns: none;
    grid-auto-columns: minmax(46px, 1fr);
    gap: 14px;
    align-items: end;
    overflow: hidden;
    padding: 8px 12px 0;
}
.source-data-block .district-top10-chart .wide-column {
    min-width: 0;
    min-height: 210px;
    display: grid;
    grid-template-rows: auto 1fr auto;
    gap: 5px;
    align-items: end;
    text-align: center;
}
.source-data-block .district-top10-chart .wide-column strong {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    justify-self: center;
    min-height: 26px;
    color: var(--text);
    font-size: 10px;
    line-height: 1;
}
.source-data-block .district-top10-chart .wide-column i {
    width: min(100%, 34px);
    justify-self: center;
    min-height: 18px;
    border-radius: 7px 7px 3px 3px;
    background: linear-gradient(180deg, var(--cyan), var(--green));
    box-shadow: 0 0 18px rgba(36, 232, 255, .24);
}
.source-data-block .district-top10-chart .wide-column span {
    max-width: 42px;
    min-height: 54px;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    justify-self: center;
    color: var(--muted);
    font-size: 9px;
}
@media (max-width: 760px) {
    .source-data-block .district-top10-chart {
        grid-auto-columns: minmax(30px, 1fr);
        gap: 8px;
        min-height: 210px;
    }
    .source-data-block .district-top10-chart .wide-column {
        min-height: 190px;
    }
    .source-data-block .district-top10-chart .wide-column i {
        width: min(100%, 22px);
    }
}
/* Two-layer source data layout */
.source-layer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}
.source-layer {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
    gap: 16px;
    align-items: stretch;
}
.source-layer .panel {
    margin-bottom: 0;
}
.source-layer-top .dashboard-district-panel,
.source-layer-top .rcms-trend-panel,
.source-layer-bottom .source-country-card,
.source-layer-bottom .rcms-positive-panel {
    min-height: 0;
}
.source-layer-top .rcms-trend-panel {
    display: grid;
    align-content: start;
}
.source-layer-top .compact-rcms-grid {
    grid-template-columns: 1fr;
    gap: 10px;
}
.source-layer-top .rcms-year-card {
    min-height: 86px;
    grid-template-columns: minmax(120px, .65fr) auto minmax(120px, 1fr);
    align-items: center;
    align-content: center;
    column-gap: 12px;
}
.source-layer-top .rcms-year-card span,
.source-layer-top .rcms-year-card small,
.source-layer-top .rcms-year-card .rcms-split-bar {
    min-width: 0;
}
.source-layer-top .rcms-year-card strong {
    font-size: 30px;
}
.source-layer-top .rcms-year-card .rcms-split-bar {
    grid-column: 3;
}
@media (max-width: 1180px) {
    .source-layer {
        grid-template-columns: 1fr;
    }
    .source-layer-top .compact-rcms-grid {
        grid-template-columns: repeat(3, minmax(180px, 1fr));
        overflow-x: auto;
    }
    .source-layer-top .rcms-year-card {
        min-height: 138px;
        grid-template-columns: 1fr;
    }
    .source-layer-top .rcms-year-card .rcms-split-bar {
        grid-column: auto;
    }
}
@media (max-width: 760px) {
    .source-layer-grid,
    .source-layer {
        gap: 12px;
    }
    .source-layer-top .compact-rcms-grid {
        grid-template-columns: 1fr;
    }
}
/* Requested source-data row pairing */
.source-layer-top {
    grid-template-columns: minmax(360px, .92fr) minmax(0, 1.08fr);
}
.source-layer-bottom {
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
}
@media (max-width: 1180px) {
    .source-layer-top,
    .source-layer-bottom {
        grid-template-columns: 1fr;
    }
}
/* Four-card source data grid */
.source-four-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(360px, .95fr);
    gap: 16px;
    align-items: stretch;
}
.source-four-grid .panel {
    margin-bottom: 0;
}
.source-four-grid .source-card-wide {
    grid-column: auto;
}
.source-four-grid .source-rcms-card .compact-rcms-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
.source-four-grid .source-rcms-card .rcms-year-card {
    min-height: 136px;
}
@media (max-width: 1180px) {
    .source-four-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 760px) {
    .source-four-grid {
        gap: 12px;
    }
    .source-four-grid .source-rcms-card .compact-rcms-grid {
        grid-template-columns: 1fr;
    }
}
/* Source intelligence v2 layout */
.source-intel-v2 .source-kpi-strip {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}
.source-kpi-strip article {
    min-height: 82px;
    display: grid;
    gap: 4px;
    align-content: center;
    padding: 12px 14px;
    border: 1px solid rgba(124, 240, 255, .14);
    border-radius: 8px;
    background: rgb(11 20 33)
}
.source-kpi-strip span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}
.source-kpi-strip strong {
    color: var(--green);
    font-size: 26px;
    line-height: 1;
}
.source-kpi-strip small { color: var(--muted); }
.source-arrival-grid,
.source-rcms-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(360px, .92fr);
    gap: 16px;
    align-items: stretch;
    margin-bottom: 16px;
}
.source-rcms-grid { margin-bottom: 0; }
.source-arrival-grid .panel,
.source-rcms-grid .panel { margin-bottom: 0; }
.source-country-wide .source-country-bars .bar-row,
.source-positive-card .bar-row {
    grid-template-columns: minmax(150px, 200px) minmax(120px, 1fr) 64px;
}
.source-district-bubble-card {
    display: grid;
    align-content: start;
}
.district-bubble-chart {
    min-height: 292px;
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    align-items: center;
    padding: 4px 2px 0;
}
.district-bubble-item {
    min-width: 0;
    display: grid;
    gap: 8px;
    justify-items: center;
    text-align: center;
}
.district-bubble {
    width: var(--size);
    height: var(--size);
    max-width: 98px;
    max-height: 98px;
    min-width: 42px;
    min-height: 42px;
    display: grid;
    place-items: center;
    border: 1px solid rgba(124, 240, 255, .28);
    border-radius: 50%;
    background: radial-gradient(circle at 32% 28%, rgba(255,255,255,.26), rgba(36,232,255,.62) 32%, rgba(57,245,164,.68) 72%);
    box-shadow: 0 0 22px rgba(36, 232, 255, .22), inset 0 0 20px rgba(5, 7, 13, .22);
}
.district-bubble strong {
    color: #041018;
    font-size: 12px;
    font-weight: 950;
}
.district-bubble-item span {
    max-width: 92px;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.source-rcms-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
html[data-theme="light"] .source-kpi-strip article {
    background: rgba(255, 255, 255, .66);
}
@media (max-width: 1180px) {
    .source-arrival-grid,
    .source-rcms-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 820px) {
    .source-intel-v2 .source-kpi-strip {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .district-bubble-chart {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        min-height: 0;
    }
    .source-rcms-cards {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 560px) {
    .source-intel-v2 .source-kpi-strip {
        grid-template-columns: 1fr;
    }
}
/* District pie chart variant */
.district-pie-layout {
    min-height: 292px;
    display: grid;
    grid-template-columns: minmax(190px, .78fr) minmax(0, 1fr);
    gap: 18px;
    align-items: center;
}
.district-pie-chart {
    width: min(230px, 100%);
    aspect-ratio: 1;
    justify-self: center;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: conic-gradient(var(--segments));
    box-shadow: 0 0 34px rgba(36, 232, 255, .2), inset 0 0 26px rgba(0, 0, 0, .34);
    position: relative;
}
.district-pie-chart::before {
    content: "";
    position: absolute;
    inset: 28px;
    border-radius: 50%;
    background: var(--panel-strong);
    box-shadow: inset 0 0 24px rgba(36, 232, 255, .08);
}
.district-pie-chart span {
    position: relative;
    z-index: 1;
    display: grid;
    gap: 4px;
    justify-items: center;
    color: var(--text);
    font-size: 13px;
    font-weight: 950;
    text-transform: uppercase;
}
.district-pie-chart small {
    color: var(--green);
    font-size: 26px;
    line-height: 1;
}
.district-pie-legend {
    display: grid;
    gap: 3px;
}
.district-pie-legend div {
    min-width: 0;
    display: grid;
    grid-template-columns: 10px minmax(0, 1fr) auto;
    gap: 9px;
    align-items: center;
    padding: 7px 9px;
    border: 1px solid rgba(124, 240, 255, .1);
    border-radius: 8px;
    background: rgba(255, 255, 255, .035);
}
.district-pie-legend i {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--slice);
    box-shadow: 0 0 12px var(--slice);
}
.district-pie-legend span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--text);
    font-size: 12px;
    font-weight: 850;
}
.district-pie-legend strong {
    color: var(--green);
    font-size: 12px;
}
html[data-theme="light"] .district-pie-chart::before,
html[data-theme="light"] .district-pie-legend div {
    background: rgba(255, 255, 255, .72);
}
@media (max-width: 820px) {
    .district-pie-layout {
        grid-template-columns: 1fr;
        min-height: 0;
    }
    .district-pie-chart {
        width: min(210px, 78vw);
    }
}
/* RCMS positives vertical signal chart */
.positive-column-chart {
    min-height: 292px;
    display: grid;
    grid-template-columns: repeat(10, minmax(0, 1fr));
    gap: 10px;
    align-items: end;
    padding: 14px 4px 0;
}
.positive-column {
    min-width: 0;
    height: 260px;
    display: grid;
    grid-template-rows: 34px 1fr 76px;
    gap: 7px;
    align-items: end;
    justify-items: center;
    text-align: center;
}
.positive-column strong {
    align-self: end;
    color: var(--amber);
    font-size: 12px;
    font-weight: 950;
    line-height: 1;
    text-shadow: 0 0 14px rgba(255, 207, 90, .25);
}
.positive-column i {
    /* width: min(100%, 34px); */
    width: min(100%);
    height: var(--height);
    min-height: 20px;
    align-self: end;
    border-radius: 10px 10px 4px 4px;
    background: linear-gradient(180deg, #ff4fd8 0%, #ffcf5a 44%, #39f5a4 100%);
    box-shadow: 0 0 20px rgba(255, 79, 216, .18), 0 0 18px rgba(57, 245, 164, .14), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.positive-column span {
    max-width: 74px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 850;
    line-height: 1.15;
    overflow: hidden;
    text-overflow: ellipsis;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    white-space: nowrap;
}
html[data-theme="light"] .positive-column i {
    box-shadow: 0 8px 18px rgba(13, 54, 86, .12), inset 0 1px 0 rgba(255, 255, 255, .5);
}
@media (max-width: 820px) {
    .positive-column-chart {
        grid-template-columns: repeat(5, minmax(0, 1fr));
        min-height: 0;
    }
    .positive-column {
        height: 220px;
    }
}
@media (max-width: 520px) {
    .positive-column-chart {
        gap: 7px;
    }
    .positive-column {
        grid-template-rows: 28px 1fr 64px;
        height: 190px;
    }
    .positive-column i {
        width: min(100%, 26px);
    }
    .positive-column strong,
    .positive-column span {
        font-size: 9px;
    }
}
/* RCMS year trend vertical timeline */
.source-rcms-card .source-rcms-cards {
    grid-template-columns: 1fr;
    gap: 10px;
    position: relative;
}
.source-rcms-card .source-rcms-cards::before {
    content: "";
    position: absolute;
    top: 12px;
    bottom: 12px;
    left: 11px;
    width: 1px;
    background: linear-gradient(180deg, rgba(36, 232, 255, .55), rgba(57, 245, 164, .34), rgba(255, 207, 90, .2));
    box-shadow: 0 0 12px rgba(36, 232, 255, .18);
}
.source-rcms-card .rcms-year-card {
    min-height: 82px;
    grid-template-columns: minmax(135px, .65fr) auto minmax(150px, 1fr);
    column-gap: 14px;
    align-items: center;
    align-content: center;
    padding: 13px 14px 13px 30px;
    position: relative;
}
.source-rcms-card .rcms-year-card::before {
    content: "";
    position: absolute;
    left: 6px;
    top: 50%;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 16px rgba(36, 232, 255, .55);
    transform: translateY(-50%);
}
.source-rcms-card .rcms-year-card span,
.source-rcms-card .rcms-year-card small,
.source-rcms-card .rcms-year-card .rcms-split-bar {
    min-width: 0;
}
.source-rcms-card .rcms-year-card strong {
    font-size: 28px;
    justify-self: end;
}
.source-rcms-card .rcms-year-card small {
    justify-self: start;
}
.source-rcms-card .rcms-year-card .rcms-split-bar {
    grid-column: 3;
    width: 100%;
}
@media (max-width: 640px) {
    .source-rcms-card .source-rcms-cards::before {
        left: 10px;
    }
    .source-rcms-card .rcms-year-card {
        grid-template-columns: 1fr;
        gap: 8px;
        min-height: 112px;
        padding-left: 30px;
    }
    .source-rcms-card .rcms-year-card strong {
        justify-self: start;
    }
    .source-rcms-card .rcms-year-card .rcms-split-bar {
        grid-column: auto;
    }
}
/* Modal report table and PDF action */
.modal-report-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding-right: 44px;
}
.pdf-action-button {
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    padding: 8px 13px;
    color: #061218;
    background: linear-gradient(135deg, var(--cyan), var(--green));
    font-weight: 950;
    cursor: pointer;
    box-shadow: 0 0 22px rgba(36, 232, 255, .18);
}
.pdf-action-button:hover {
    transform: translateY(-1px);
    filter: brightness(1.06);
}
.pdf-action-button svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.report-table-wrap {
    max-height: min(58vh, 560px);
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .035);
}
.report-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 560px;
}
.report-table th,
.report-table td {
    padding: 11px 13px;
    border-bottom: 1px solid rgba(124, 240, 255, .13);
    text-align: left;
    vertical-align: middle;
}
.report-table th {
    position: sticky;
    top: 0;
    z-index: 2;
    color: var(--cyan);
    background: rgba(7, 15, 28, .96);
    font-size: 12px;
    font-weight: 950;
    text-transform: uppercase;
}
.report-table td {
    color: var(--text);
    font-weight: 760;
}
.report-table td:first-child,
.report-table td:nth-child(3),
.report-table td:nth-child(4) {
    width: 110px;
    text-align: right;
    color: var(--green);
    font-weight: 950;
}
.report-table td:first-child {
    width: 62px;
    color: var(--muted);
}
.report-table tbody tr:hover {
    background: rgba(36, 232, 255, .07);
}
html[data-theme="light"] .report-table-wrap {
    background: rgba(255, 255, 255, .72);
}
html[data-theme="light"] .report-table th {
    background: rgba(235, 247, 251, .98);
}
@media (max-width: 760px) {
    .modal-report-head {
        display: grid;
        padding-right: 42px;
    }
    .pdf-action-button {
        justify-self: start;
    }
    .report-table-wrap {
        max-height: min(56vh, 520px);
    }
}
.pdf-action-button { text-decoration: none; }
/* Hover feedback for district hotspot chart */
.district-pie-chart,
.district-pie-legend div {
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease, filter .18s ease;
}
.district-pie-chart:hover {
    transform: translateY(-2px) scale(1.025);
    filter: saturate(1.15) brightness(1.06);
    box-shadow: 0 0 46px rgba(36, 232, 255, .34), 0 0 24px rgba(57, 245, 164, .2), inset 0 0 28px rgba(0, 0, 0, .34);
}
.district-pie-legend div:hover {
    transform: translateX(4px);
    border-color: var(--line-strong);
    background: rgba(36, 232, 255, .09);
    box-shadow: 0 0 22px rgba(36, 232, 255, .12), inset 0 0 18px rgba(255, 255, 255, .03);
}
.district-pie-legend div:hover i {
    transform: scale(1.35);
    box-shadow: 0 0 18px var(--slice), 0 0 28px rgba(36, 232, 255, .18);
}
.district-pie-legend div:hover span,
.district-pie-legend div:hover strong {
    color: var(--green);
}
.district-pie-legend i {
    transition: transform .18s ease, box-shadow .18s ease;
}
html[data-theme="light"] .district-pie-legend div:hover {
    background: rgba(255, 255, 255, .92);
    box-shadow: 0 10px 24px rgba(13, 54, 86, .10);
}
/* Real Leaflet route maps inside Human smuggling route cards */
.route-card .route-leaflet-map {
    width: 100%;
    height: 100%;
    min-height: 214px;
    position: relative;
    overflow: hidden;
    background: #dbe7ee;
    filter: saturate(1.08) contrast(1.02);
}
.route-card .route-leaflet-map::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 401;
    pointer-events: none;
    background: linear-gradient(135deg, rgba(36, 232, 255, .08), transparent 38%, rgba(255, 79, 216, .08));
    mix-blend-mode: screen;
}
.route-card .route-leaflet-map.is-route-map-loading::before {
    content: attr(data-route-map-loading);
    position: absolute;
    inset: 0;
    z-index: 500;
    display: grid;
    place-items: center;
    color: var(--text);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0;
    text-transform: uppercase;
    background: radial-gradient(circle at 50% 44%, rgba(36, 232, 255, .18), rgba(5, 12, 22, .82) 42%, rgba(2, 7, 15, .92));
    backdrop-filter: blur(4px);
}
.route-card .route-leaflet-map.is-route-map-loading::after {
    z-index: 501;
    background:
        radial-gradient(circle, transparent 56%, rgba(36, 232, 255, .32) 57%, transparent 62%),
        conic-gradient(from 0deg, transparent, rgba(36, 232, 255, .95), rgba(255, 207, 90, .85), transparent 58%);
    width: 74px;
    height: 74px;
    inset: calc(50% - 74px) auto auto calc(50% - 37px);
    border-radius: 50%;
    mix-blend-mode: screen;
    animation: routeMapLoaderSpin 1s linear infinite;
}
@keyframes routeMapLoaderSpin {
    to { transform: rotate(360deg); }
}
.route-card .route-leaflet-map .leaflet-tile-pane {
    filter: saturate(.88) contrast(.92) brightness(.96);
}
.route-direction-line {
    filter: drop-shadow(0 0 4px rgba(255, 56, 79, .58));
}
.route-shadow-line {
    filter: blur(1px);
}
.route-stop-dot {
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, .8));
}
.route-stop-label {
    border: 1px solid rgba(36, 232, 255, .42);
    border-radius: 6px;
    padding: 3px 6px;
    color: #eaf7ff;
    background: rgba(5, 12, 22, .82);
    box-shadow: 0 0 12px rgba(36, 232, 255, .22);
    font-size: 10px;
    font-weight: 900;
}
.route-stop-label::before {
    display: none;
}
.route-arrow-icon {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    pointer-events: none;
}
.route-arrow-icon span {
    width: 0;
    height: 0;
    display: block;
    border-top: 6px solid transparent;
    border-bottom: 6px solid transparent;
    border-left: 16px solid var(--route-arrow-color, #ff263d);
    filter: drop-shadow(0 0 5px var(--route-arrow-color, rgba(255, 38, 61, .95)));
    transform-origin: 50% 50%;
}
html[data-theme="light"] .route-stop-label {
    color: #082032;
    background: rgba(255, 255, 255, .9);
}
@media (max-width: 760px) {
    .route-card .route-leaflet-map {
        min-height: 240px;
    }
}
/* Route workspace redesign and in-page fullscreen focus */
.route-workspace-panel {
    position: relative;
    overflow: visible;
}
.route-workspace-panel .route-grid {
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    align-items: stretch;
    gap: 16px;
}
.route-workspace-panel .route-card,
.route-workspace-panel .route-large {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(250px, 1fr) auto;
    min-height: 475px;
    border-color: rgba(124, 240, 255, .24);
    background: linear-gradient(145deg, rgba(10, 18, 33, .84), rgba(16, 42, 52, .66));
    box-shadow: 0 18px 42px rgba(0, 0, 0, .22), inset 0 0 24px rgba(36, 232, 255, .04);
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.route-workspace-panel .route-card:hover {
    transform: translateY(-3px);
    border-color: var(--line-strong);
    box-shadow: 0 22px 50px rgba(0, 0, 0, .26), 0 0 26px rgba(36, 232, 255, .12);
}
.route-card .route-card-body {
    padding: 16px;
    display: grid;
    gap: 10px;
    align-content: start;
}
.route-card-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.route-fullscreen-button {
    width: 36px;
    height: 36px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    color: var(--cyan);
    background: rgba(36, 232, 255, .08);
    cursor: pointer;
    box-shadow: inset 0 0 14px rgba(36, 232, 255, .06);
}
.route-fullscreen-button:hover {
    color: var(--text);
    background: rgba(36, 232, 255, .18);
    transform: translateY(-1px);
}
.route-fullscreen-button svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.route-workspace-panel .route-card .route-leaflet-map {
    min-height: 250px;
    border-bottom: 1px solid rgba(124, 240, 255, .18);
}
body.route-fullscreen-open {
    overflow: hidden;
}
body.route-fullscreen-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 70;
    background: rgba(1, 6, 14, .76);
    backdrop-filter: blur(8px);
}
.route-card.is-route-fullscreen {
    position: fixed;
    inset: 92px 24px 24px;
    z-index: 80;
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(340px, .55fr);
    grid-template-rows: 1fr;
    min-height: 0;
    overflow: hidden;
    transform: none !important;
    border-color: var(--line-strong);
    background: linear-gradient(145deg, rgba(7, 13, 27, .96), rgba(9, 36, 43, .94));
    box-shadow: 0 28px 80px rgba(0, 0, 0, .52), 0 0 34px rgba(36, 232, 255, .16);
}
.route-card.is-route-fullscreen .route-leaflet-map {
    min-height: 100%;
    height: 100%;
    border-right: 1px solid rgba(124, 240, 255, .2);
    border-bottom: 0;
}
.route-card.is-route-fullscreen .route-card-body {
    padding: 24px;
    align-content: center;
}
.route-card.is-route-fullscreen .route-card-body h3 {
    font-size: clamp(24px, 3vw, 38px);
    line-height: 1.05;
}
.route-card.is-route-fullscreen .route-card-body p {
    font-size: 16px;
    line-height: 1.7;
}
.route-card.is-route-fullscreen .route-fullscreen-button svg path:first-child,
.route-card.is-route-fullscreen .route-fullscreen-button svg path:nth-child(2),
.route-card.is-route-fullscreen .route-fullscreen-button svg path:nth-child(3),
.route-card.is-route-fullscreen .route-fullscreen-button svg path:nth-child(4) {
    stroke-width: 2.4;
}
html[data-theme="light"] .route-workspace-panel .route-card,
html[data-theme="light"] .route-card.is-route-fullscreen {
    background: rgba(255, 255, 255, .86);
}
@media (max-width: 980px) {
    .route-card.is-route-fullscreen {
        inset: 82px 14px 14px;
        grid-template-columns: 1fr;
        grid-template-rows: minmax(0, 1fr) auto;
    }
    .route-card.is-route-fullscreen .route-leaflet-map {
        min-height: 48vh;
        border-right: 0;
        border-bottom: 1px solid rgba(124, 240, 255, .2);
    }
}
@media (max-width: 520px) {
    .route-workspace-panel .route-grid {
        grid-template-columns: 1fr;
    }
    .route-workspace-panel .route-card,
    .route-workspace-panel .route-large {
        min-height: 430px;
    }
    .route-card.is-route-fullscreen {
        inset: 76px 8px 8px;
    }
}
/* Route cards final sizing and fullscreen reliability */
.route-workspace-panel,
.route-workspace-panel [data-route-results],
.route-workspace-panel .route-grid {
    max-width: 100%;
    overflow-x: clip;
}
.route-workspace-panel .route-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
    align-items: stretch;
}
.route-workspace-panel .route-card,
.route-workspace-panel .route-large {
    min-width: 0;
    grid-template-rows: 280px minmax(0, 1fr);
    min-height: 540px;
    height: 100%;
}
.route-workspace-panel .route-card .route-leaflet-map {
    height: 280px;
    min-height: 280px;
    max-height: 280px;
}
.route-card .route-card-body,
.route-card .route-card-body > * {
    min-width: 0;
}
.route-card .route-card-body p {
    overflow-wrap: anywhere;
}
.route-card-toolbar,
.route-fullscreen-button {
    position: relative;
    z-index: 6;
}
body.route-fullscreen-open::after {
    z-index: 9990;
}
.route-card.is-route-fullscreen {
    position: fixed !important;
    inset: 88px 22px 22px !important;
    z-index: 10000 !important;
    width: auto !important;
    height: auto !important;
    max-height: none !important;
    grid-template-columns: minmax(0, 1.45fr) minmax(340px, .55fr) !important;
    grid-template-rows: minmax(0, 1fr) !important;
    min-height: 0 !important;
}
.route-card.is-route-fullscreen .route-leaflet-map {
    height: 100% !important;
    min-height: 100% !important;
    max-height: none !important;
}
.route-card.is-route-fullscreen .route-card-body {
    min-height: 0;
    overflow-y: auto;
}
@media (max-width: 1180px) {
    .route-workspace-panel .route-grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 980px) {
    .route-card.is-route-fullscreen {
        inset: 78px 12px 12px !important;
        grid-template-columns: 1fr !important;
        grid-template-rows: minmax(0, 1fr) auto !important;
    }
    .route-card.is-route-fullscreen .route-leaflet-map {
        height: 52vh !important;
        min-height: 52vh !important;
    }
}
@media (max-width: 560px) {
    .route-workspace-panel .route-card,
    .route-workspace-panel .route-large {
        grid-template-rows: 240px minmax(0, 1fr);
        min-height: 500px;
    }
    .route-workspace-panel .route-card .route-leaflet-map {
        height: 240px;
        min-height: 240px;
        max-height: 240px;
    }
}
/* Route fullscreen overlay fix */
body.route-fullscreen-open::after {
    display: none !important;
}
.route-fullscreen-overlay {
    position: fixed;
    inset: 0;
    z-index: 9998;
    display: none;
    border: 0;
    padding: 0;
    background: rgba(1, 6, 14, .76);
    backdrop-filter: blur(8px);
    cursor: zoom-out;
}
.route-fullscreen-overlay.open {
    display: block;
}
.route-card.is-route-fullscreen {
    z-index: 10002 !important;
}
.route-card.is-route-fullscreen::before {
    pointer-events: none;
}
.route-card.is-route-fullscreen .route-fullscreen-button {
    z-index: 10004;
}
/* Stable fullscreen Leaflet viewport sizing */
.route-card.is-route-fullscreen {
    height: calc(100vh - 110px) !important;
    max-height: calc(100vh - 110px) !important;
}
.route-card.is-route-fullscreen .route-leaflet-map,
.route-card.is-route-fullscreen .leaflet-container {
    width: 100% !important;
    height: calc(100vh - 110px) !important;
    min-height: calc(100vh - 110px) !important;
    max-height: calc(100vh - 110px) !important;
    background: #d8e9f2;
}
.route-card.is-route-fullscreen .leaflet-map-pane,
.route-card.is-route-fullscreen .leaflet-tile-pane,
.route-card.is-route-fullscreen .leaflet-overlay-pane,
.route-card.is-route-fullscreen .leaflet-marker-pane,
.route-card.is-route-fullscreen .leaflet-tooltip-pane {
    will-change: transform;
}
@media (max-width: 980px) {
    .route-card.is-route-fullscreen {
        height: calc(100vh - 90px) !important;
        max-height: calc(100vh - 90px) !important;
    }
    .route-card.is-route-fullscreen .route-leaflet-map,
    .route-card.is-route-fullscreen .leaflet-container {
        height: 56vh !important;
        min-height: 56vh !important;
        max-height: 56vh !important;
    }
}
/* Balanced Human Smuggling intelligence board */
.smuggling-intel-stack {
    grid-template-columns: minmax(400px, .88fr) minmax(420px, 1.12fr);
    align-items: start;
}
.smuggling-map-panel {
    align-self: start;
    padding-bottom: 14px;
}
.smuggling-map-panel .panel-head,
.smuggling-analytics-grid .panel-head {
    margin-bottom: 10px;
}
.smuggling-map-panel .real-heat-map {
    aspect-ratio: auto;
    height: clamp(260px, 29vw, 335px);
    min-height: 260px;
}
.smuggling-map-panel .heat-map-legend {
    margin-top: 7px;
}
.smuggling-map-panel .map-footnote {
    margin-top: 9px;
    padding-top: 9px;
    border-top: 1px solid rgba(124, 240, 255, .12);
}
.smuggling-analytics-grid {
    grid-template-columns: 1fr;
    gap: 14px;
}
.smuggling-analytics-grid .panel {
    padding: 16px;
}
.smuggling-analytics-grid .analysis-chip-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.smuggling-analytics-grid .analysis-chip {
    min-height: 92px;
    padding: 12px;
}
.smuggling-analytics-grid .compact-bars {
    max-height: 300px;
    overflow: auto;
    padding-right: 6px;
}
.smuggling-analytics-grid .compact-bars::-webkit-scrollbar {
    width: 7px;
}
.smuggling-analytics-grid .compact-bars::-webkit-scrollbar-thumb {
    background: rgba(36, 232, 255, .28);
    border-radius: 999px;
}
@media (max-width: 1180px) {
    .smuggling-intel-stack {
        grid-template-columns: 1fr;
    }
    .smuggling-analytics-grid {
        grid-template-columns: minmax(0, 1fr) minmax(340px, .9fr);
    }
    .smuggling-map-panel .real-heat-map {
        height: clamp(280px, 42vw, 390px);
    }
}
@media (max-width: 760px) {
    .smuggling-analytics-grid,
    .smuggling-analytics-grid .analysis-chip-grid {
        grid-template-columns: 1fr;
    }
    .smuggling-map-panel .real-heat-map {
        height: 280px;
        min-height: 280px;
    }
    .smuggling-analytics-grid .compact-bars {
        max-height: none;
    }
}
/* Dynamic smuggling analysis details */
.analysis-modal-metric {
    display: inline-flex;
    width: fit-content;
    margin: 8px 0 10px;
    padding: 8px 11px;
    border: 1px solid rgba(57, 245, 164, .28);
    border-radius: 8px;
    color: var(--green);
    background: rgba(57, 245, 164, .08);
    font-size: 13px;
    font-weight: 950;
}
.analysis-detail-modal p {
    color: var(--muted);
    line-height: 1.65;
}
.analysis-detail-table-wrap {
    margin-top: 14px;
    max-height: min(48vh, 430px);
}
.analysis-detail-table {
    min-width: 720px;
}
.analysis-detail-table td:nth-child(2) {
    color: var(--text);
    font-weight: 900;
}
.analysis-detail-table td:nth-child(3) {
    color: var(--green);
    font-weight: 950;
    white-space: nowrap;
}
.analysis-detail-table td:nth-child(4) {
    color: var(--muted);
    font-weight: 700;
    line-height: 1.45;
}
.analysis-chip strong {
    line-height: 1.25;
}
.analysis-chip small {
    color: var(--green);
    font-weight: 900;
}
html[data-theme="light"] .analysis-modal-metric {
    background: rgba(15, 159, 114, .1);
}
@media (max-width: 760px) {
    .analysis-detail-table {
        min-width: 620px;
    }
}
/* Interactive district donut center label */
.district-pie-chart span b {
    max-width: 108px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 12px;
    line-height: 1.1;
}
.district-pie-chart span small,
.district-pie-chart span b {
    transition: color .18s ease, transform .18s ease;
}
.district-pie-chart.is-pie-focused span b {
    color: var(--cyan);
    transform: translateY(-1px);
}
.district-pie-chart.is-pie-focused span small {
    color: var(--green);
    transform: scale(1.05);
}
.district-pie-chart.is-pie-focused {
    filter: saturate(1.18) brightness(1.07);
}
.district-pie-legend div[data-district-pie-item] {
    cursor: pointer;
}
/* Compact centered route pressure chart */
.smuggling-side-charts .slim-column-chart {
    min-height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 18px 10px 10px;
}
.smuggling-side-charts .slim-column-chart .column-bar {
    width: min(190px, 38%);
    max-width: 190px;
    min-width: 132px;
    min-height: 176px;
    display: grid;
    grid-template-rows: 1fr auto auto auto;
    justify-items: center;
    align-items: end;
    gap: 7px;
}
.smuggling-side-charts .slim-column-chart .column-bar i {
    width: 100%;
    max-width: 178px;
    height: min(var(--height), 92px);
    min-height: 54px;
    border-radius: 8px 8px 3px 3px;
    background: linear-gradient(180deg, #1df2ff 0%, #5377ff 48%, #000000 100%);
    box-shadow: 0 0 24px rgba(36, 232, 255, .22), 0 16px 28px rgba(255, 79, 216, .14);
}
.smuggling-side-charts .slim-column-chart .column-bar strong,
.smuggling-side-charts .slim-column-chart .column-bar span,
.smuggling-side-charts .slim-column-chart .column-bar small {
    width: 100%;
    text-align: center;
}
.smuggling-side-charts .slim-column-chart .column-bar strong {
    color: var(--text);
    font-size: 18px;
    line-height: 1;
}
.smuggling-side-charts .slim-column-chart .column-bar span {
    color: var(--cyan);
    font-size: 12px;
}
.smuggling-side-charts .slim-column-chart .column-bar small {
    max-width: 150px;
    color: var(--muted);
    font-size: 10px;
    line-height: 1.25;
}
html[data-theme="light"] .smuggling-side-charts .slim-column-chart .column-bar i {
    background: linear-gradient(180deg, #087f9e 0%, #5b7cff 48%, #d946b8 100%);
    box-shadow: 0 12px 24px rgba(8, 127, 158, .15);
}
@media (max-width: 520px) {
    .smuggling-side-charts .slim-column-chart {
        gap: 8px;
        padding-inline: 0;
    }
    .smuggling-side-charts .slim-column-chart .column-bar {
        min-width: 112px;
    }
}
/* RCMS positive country label safety */
.source-positive-card .positive-column-chart {
    min-height: 330px;
    padding: 14px 6px 6px;
}
.source-positive-card .positive-column {
    height: 292px;
    grid-template-rows: 30px minmax(88px, 1fr) 70px;
    gap: 6px;
}
.source-positive-card .positive-column i {
    width: min(100%, 70px);
    max-width: 70px;
}
.source-positive-card .positive-column span {
    max-width: 118px;
    max-height: 110px;
    display: block;
    overflow: hidden;
    color: var(--muted);
    font-size: clamp(8px, .72vw, 10px);
    line-height: 1.08;
    text-overflow: ellipsis;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    white-space: nowrap;
    letter-spacing: .2px;
}
.source-positive-card .positive-column:hover span {
    color: var(--green);
}
@media (max-width: 820px) {
    .source-positive-card .positive-column-chart {
        min-height: 0;
    }
    .source-positive-card .positive-column {
        height: 250px;
        grid-template-rows: 28px minmax(72px, 1fr) 104px;
    }
    .source-positive-card .positive-column span {
        max-height: 98px;
        font-size: 9px;
    }
}
@media (max-width: 520px) {
    .source-positive-card .positive-column {
        height: 214px;
        grid-template-rows: 26px minmax(58px, 1fr) 90px;
    }
    .source-positive-card .positive-column span {
        max-height: 84px;
        font-size: 8px;
    }
}
/* Scalable criminal profile table */
.criminal-table-shell {
    display: grid;
    gap: 12px;
}
.criminal-table-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.criminal-table-summary div {
    min-width: 150px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .04);
}
.criminal-table-summary span {
    display: block;
    color: var(--muted);
    font-size: 11px;
    font-weight: 850;
    text-transform: uppercase;
}
.criminal-table-summary strong {
    display: block;
    margin-top: 3px;
    color: var(--green);
    font-size: 22px;
    line-height: 1;
}
.criminal-table-wrap {
    max-height: 520px;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, .025);
}
.criminal-profile-table {
    min-width: 920px;
    width: 100%;
    border-collapse: collapse;
    background: transparent;
}
.criminal-profile-table th {
    position: sticky;
    top: 0;
    z-index: 2;
    background: rgba(7, 15, 28, .97);
}
.criminal-profile-table tr {
    cursor: pointer;
}
.criminal-profile-table td,
.criminal-profile-table th {
    padding: 11px 12px;
}
.criminal-profile-table tbody tr:hover td {
    background: rgba(36, 232, 255, .075);
}
.criminal-profile-cell {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
}
.criminal-profile-cell img {
    width: 40px;
    height: 44px;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    background: rgba(36, 232, 255, .08);
}
.criminal-profile-cell strong,
.criminal-profile-cell small {
    display: block;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.criminal-profile-cell strong {
    color: var(--text);
    font-weight: 950;
}
.criminal-profile-cell small {
    color: var(--muted);
    font-size: 12px;
}
.criminal-risk-cell {
    min-width: 120px;
    display: grid;
    gap: 5px;
}
.criminal-risk-cell strong {
    color: var(--green);
    font-size: 13px;
}
.criminal-risk-cell span {
    height: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, .09);
}
.criminal-risk-cell i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--cyan), var(--green), var(--amber));
}
.criminal-pager {
    margin-top: 0;
}
html[data-theme="light"] .criminal-table-summary div,
html[data-theme="light"] .criminal-table-wrap {
    background: rgba(255, 255, 255, .62);
}
html[data-theme="light"] .criminal-profile-table th {
    background: rgba(235, 247, 251, .98);
}
@media (max-width: 760px) {
    .criminal-table-summary div {
        min-width: 0;
        flex: 1 1 140px;
    }
    .criminal-table-wrap {
        max-height: 62vh;
    }
}
/* Scalable trafficker table alignment */
.trafficker-table-wrap {
    max-height: 500px;
}
.trafficker-profile-table td:nth-child(2),
.trafficker-profile-table td:nth-child(3),
.trafficker-profile-table td:nth-child(4) {
    white-space: nowrap;
}
.trafficker-table-shell .criminal-table-summary div {
    min-width: 165px;
}
@media (max-width: 760px) {
    .trafficker-table-wrap {
        max-height: 62vh;
    }
}
/* No-scroll trafficker table fit */
.trafficker-table-wrap {
    overflow-x: hidden;
}
.trafficker-profile-table {
    min-width: 0;
    table-layout: fixed;
}
.trafficker-profile-table th,
.trafficker-profile-table td {
    padding: 10px 9px;
}
.trafficker-profile-table th:nth-child(1),
.trafficker-profile-table td:nth-child(1) { width: 46%; }
.trafficker-profile-table th:nth-child(2),
.trafficker-profile-table td:nth-child(2) { width: 18%; }
.trafficker-profile-table th:nth-child(3),
.trafficker-profile-table td:nth-child(3) { width: 22%; }
.trafficker-profile-table th:nth-child(4),
.trafficker-profile-table td:nth-child(4) { width: 14%; }
.trafficker-profile-table td,
.trafficker-profile-table th {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}
.trafficker-profile-table .criminal-profile-cell {
    grid-template-columns: 40px minmax(0, 1fr);
}
.trafficker-profile-table td:nth-child(2),
.trafficker-profile-table td:nth-child(3),
.trafficker-profile-table td:nth-child(4) {
    white-space: nowrap;
}
@media (max-width: 760px) {
    .trafficker-profile-table th:nth-child(1),
    .trafficker-profile-table td:nth-child(1) { width: 52%; }
    .trafficker-profile-table th:nth-child(2),
    .trafficker-profile-table td:nth-child(2) { width: 20%; }
    .trafficker-profile-table th:nth-child(3),
    .trafficker-profile-table td:nth-child(3) { width: 28%; }
    .trafficker-profile-table th:nth-child(4),
    .trafficker-profile-table td:nth-child(4) { display: none; }
}
/* Grid plus action icon */
.icon-action-button svg rect {
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}
.icon-action-button svg path {
    stroke-width: 2.2;
}
/* Softer light mode review palette
   Review/undo: remove this block to restore the earlier light palette. */
html[data-theme="light"] {
    --bg: #dfe8ee;
    --bg-2: #d4e0e8;
    --panel: rgba(226, 236, 243, .82);
    --panel-strong: rgba(217, 230, 238, .94);
    --line: rgba(42, 89, 112, .20);
    --line-strong: rgba(15, 118, 146, .36);
    --text: #142636;
    --muted: #64798b;
    --cyan: #087f9e;
    --green: #168f6c;
    --magenta: #975487;
    --amber: #93741d;
    --danger: #b94d59;
    --shadow: 0 20px 54px rgba(35, 55, 70, .16);
}

html[data-theme="light"] body {
    color: var(--text);
    background:
        linear-gradient(90deg, rgba(8, 127, 158, .075) 1px, transparent 1px),
        linear-gradient(rgba(8, 127, 158, .06) 1px, transparent 1px),
        radial-gradient(circle at 16% 0%, rgba(151, 84, 135, .14), transparent 34%),
        radial-gradient(circle at 88% 14%, rgba(22, 143, 108, .12), transparent 30%),
        linear-gradient(145deg, #e4edf2 0%, #d8e4eb 50%, #dce6ec 100%);
}

html[data-theme="light"] body::before {
    opacity: .28;
    background: linear-gradient(115deg, transparent 0 39%, rgba(255, 255, 255, .32) 47%, transparent 55% 100%);
}

html[data-theme="light"] .screen-glow {
    background:
        radial-gradient(circle at 50% 0%, rgba(8, 127, 158, .10), transparent 42%),
        radial-gradient(circle at 90% 18%, rgba(22, 143, 108, .08), transparent 30%);
}

html[data-theme="light"] main {
    background: linear-gradient(90deg, rgba(151, 84, 135, .08), rgba(8, 127, 158, .07));
}

html[data-theme="light"] .topbar,
html[data-theme="light"] .user-dropdown,
html[data-theme="light"] .modal-box {
    background: rgba(220, 232, 240, .93);
    border-color: rgba(42, 89, 112, .24);
    box-shadow: 0 18px 46px rgba(38, 58, 73, .14);
}

html[data-theme="light"] .topnav,
html[data-theme="light"] .user-menu-button,
html[data-theme="light"] .dropdown-user,
html[data-theme="light"] .theme-switch,
html[data-theme="light"] .filter-row select,
html[data-theme="light"] .pager-link,
html[data-theme="light"] .ghost-button,
html[data-theme="light"] .mini-button,
html[data-theme="light"] .icon-action-button {
    background: rgba(211, 226, 235, .82);
    border-color: rgba(27, 103, 129, .28);
}

html[data-theme="light"] .ai-hero,
html[data-theme="light"] .holo-panel,
html[data-theme="light"] .metric,
html[data-theme="light"] .panel,
html[data-theme="light"] .dashboard-section-block,
html[data-theme="light"] .analysis-item,
html[data-theme="light"] .analysis-chip,
html[data-theme="light"] .type-card,
html[data-theme="light"] .status-tile,
html[data-theme="light"] .route-type-tile,
html[data-theme="light"] .profile-row,
html[data-theme="light"] .route-card,
html[data-theme="light"] .criminal-table-wrap,
html[data-theme="light"] .criminal-table-summary div,
html[data-theme="light"] .report-table-wrap {
    background: linear-gradient(145deg, rgba(225, 236, 243, .88), rgba(205, 221, 232, .76));
    border-color: rgba(42, 89, 112, .22);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 18px 44px rgba(38, 58, 73, .10);
}

html[data-theme="light"] .metric:hover,
html[data-theme="light"] .panel:hover,
html[data-theme="light"] .type-card:hover,
html[data-theme="light"] .profile-row:hover,
html[data-theme="light"] .route-card:hover,
html[data-theme="light"] .analysis-chip:hover,
html[data-theme="light"] .icon-action-button:hover {
    border-color: rgba(8, 127, 158, .46);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .62), 0 20px 48px rgba(8, 127, 158, .16);
}

html[data-theme="light"] table,
html[data-theme="light"] .report-table,
html[data-theme="light"] .criminal-profile-table {
    color: var(--text);
    background: rgba(220, 232, 240, .76);
}

html[data-theme="light"] th,
html[data-theme="light"] .report-table th,
html[data-theme="light"] .criminal-profile-table th {
    color: #075f78;
    background: rgba(199, 218, 230, .95);
}

html[data-theme="light"] td,
html[data-theme="light"] .report-table td,
html[data-theme="light"] .criminal-profile-table td {
    border-color: rgba(42, 89, 112, .14);
}

html[data-theme="light"] tr:hover td,
html[data-theme="light"] .report-table tbody tr:hover td,
html[data-theme="light"] .criminal-profile-table tbody tr:hover td {
    background: rgba(8, 127, 158, .08);
}

html[data-theme="light"] .login-body {
    background: #dfe8ee;
}

html[data-theme="light"] .login-card,
html[data-theme="light"] .login-visual,
html[data-theme="light"] .login-panel {
    background: linear-gradient(145deg, rgba(225, 236, 243, .94), rgba(206, 222, 232, .88));
    border-color: rgba(42, 89, 112, .22);
}

html[data-theme="light"] .login-panel input,
html[data-theme="light"] input,
html[data-theme="light"] select {
    color: var(--text);
    background: rgba(232, 240, 245, .94);
    border-color: rgba(27, 103, 129, .28);
}

html[data-theme="light"] .real-heat-map,
html[data-theme="light"] .route-card .route-leaflet-map,
html[data-theme="light"] .leaflet-container {
    filter: saturate(.82) contrast(.94) brightness(.95);
}

html[data-theme="light"] .brand-mark,
html[data-theme="light"] .account-avatar {
    background: linear-gradient(135deg, rgba(8, 127, 158, .20), rgba(151, 84, 135, .18));
}
/* End softer light mode review palette */
/* Mobile modal viewport layer fix
   Modals are portaled to body in JS, so this layer is screen-wide, not section-wide. */
body.modal-open {
    overflow: hidden;
}

body.modal-open .topbar {
    z-index: 5;
    pointer-events: none;
}

.modal {
    position: fixed !important;
    inset: 0 !important;
    z-index: 10020;
    width: 100vw;
    min-height: 100vh;
    height: 100dvh;
    place-items: center;
    padding: 22px;
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.modal.open {
    display: grid;
}

.modal-box,
.modal-box.wide,
.district-modal-box {
    margin: 0 auto;
}

@media (max-width: 760px) {
    .modal {
        padding: max(16px, env(safe-area-inset-top)) 10px 16px;
    }

    .modal-box,
    .modal-box.wide,
    .district-modal-box {
        width: min(100%, 520px);
        max-width: 100%;
        max-height: none;
        padding: 52px 16px 18px;
        overflow: visible;
    }

    .modal-close {
        position: absolute;
        top: 10px;
        right: 10px;
        z-index: 8;
        margin: 0;
        float: none;
    }

    .profile-dialog {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .profile-image {
        width: min(220px, 72vw);
        max-height: 230px;
        justify-self: center;
    }

    .modal-meta {
        grid-template-columns: 1fr;
    }
}

@media (max-height: 620px) {
    .modal {
        place-items: start center;
    }
}/* End mobile modal viewport layer fix */
/* Mobile repatriation table compact view */
.mobile-name {
    display: none;
}

.repatriation-table td,
.repatriation-table th {
    vertical-align: middle;
}

.repatriation-table td:first-child {
    font-weight: 900;
    color: var(--green);
}

@media (max-width: 760px) {
    .repatriation-table-wrap {
        overflow-x: hidden;
    }

    .repatriation-table {
        min-width: 0;
        table-layout: fixed;
    }

    .repatriation-table th,
    .repatriation-table td {
        padding: 12px 8px;
        font-size: 12px;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .repatriation-table th:nth-child(1),
    .repatriation-table td:nth-child(1) {
        width: 34%;
    }

    .repatriation-table th:nth-child(2),
    .repatriation-table td:nth-child(2) {
        width: 44%;
    }

    .repatriation-table th:nth-child(6),
    .repatriation-table td:nth-child(6) {
        width: 22%;
        text-align: right;
    }

    .repatriation-table th:nth-child(3),
    .repatriation-table td:nth-child(3),
    .repatriation-table th:nth-child(4),
    .repatriation-table td:nth-child(4),
    .repatriation-table th:nth-child(5),
    .repatriation-table td:nth-child(5) {
        display: none;
    }

    .repatriation-table .desktop-name {
        display: none;
    }

    .repatriation-table .mobile-name {
        display: inline-block;
        max-width: 100%;
        overflow: hidden;
        text-overflow: ellipsis;
        vertical-align: bottom;
    }

    .repatriation-table .compact-view-button {
        width: 100%;
        min-height: 34px;
        padding: 0 8px;
        justify-content: center;
    }

    .repatriation-table .empty-cell {
        white-space: normal;
        text-align: center;
    }
}
/* End mobile repatriation table compact view */
/* PDF actions across monitoring pages */
.partial-report-toolbar {
    display: flex;
    justify-content: flex-end;
    margin: 0 0 12px;
}

.criminal-table-summary .pdf-action-button {
    margin-left: auto;
    align-self: stretch;
}

.modal-report-head.compact {
    align-items: center;
    margin-bottom: 10px;
}

.route-card-toolbar {
    display: flex;
    align-items: center;
    gap: 8px;
}

.route-card-toolbar > span {
    margin-right: auto;
}

.route-card-pdf {
    width: 36px;
    height: 36px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 8px;
    color: var(--cyan);
    background: rgba(36, 232, 255, .08);
}

.route-card-pdf:hover {
    border-color: var(--cyan);
    background: rgba(36, 232, 255, .14);
}

.route-card-pdf svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

@media (max-width: 760px) {
    .partial-report-toolbar,
    .criminal-table-summary .pdf-action-button {
        justify-content: stretch;
        width: 100%;
    }

    .partial-report-toolbar .pdf-action-button,
    .criminal-table-summary .pdf-action-button {
        width: 100%;
        justify-content: center;
    }
}
/* End PDF actions across monitoring pages */
/* PDF icon-only action buttons */
.pdf-action-button {
    width: 42px;
    min-width: 42px;
    height: 42px;
    min-height: 42px;
    padding: 0;
    justify-content: center;
    gap: 0;
    font-size: 0;
    border-radius: 10px;
}

.pdf-action-button svg {
    width: 19px;
    height: 19px;
}

.criminal-table-summary .pdf-action-button {
    align-self: center;
}

@media (max-width: 760px) {
    .partial-report-toolbar,
    .criminal-table-summary .pdf-action-button {
        width: auto;
        justify-content: flex-end;
    }

    .partial-report-toolbar .pdf-action-button,
    .criminal-table-summary .pdf-action-button {
        width: 42px;
        min-width: 42px;
        justify-content: center;
    }
}
/* End PDF icon-only action buttons */

/* Source-style trafficker profile fields */
.trafficker-profile-table th:nth-child(1),
.trafficker-profile-table td:nth-child(1) { width: 42%; }
.trafficker-profile-table th:nth-child(2),
.trafficker-profile-table td:nth-child(2) { width: 9%; }
.trafficker-profile-table th:nth-child(3),
.trafficker-profile-table td:nth-child(3) { width: 17%; }
.trafficker-profile-table th:nth-child(4),
.trafficker-profile-table td:nth-child(4) { width: 19%; }
.trafficker-profile-table th:nth-child(5),
.trafficker-profile-table td:nth-child(5) { width: 13%; }
.trafficker-profile-table td:nth-child(2),
.trafficker-profile-table td:nth-child(3),
.trafficker-profile-table td:nth-child(4),
.trafficker-profile-table td:nth-child(5) {
    white-space: nowrap;
}
.trafficker-profile-dialog .profile-detail p strong {
    color: var(--text);
}
.source-note {
    padding-top: 8px;
    border-top: 1px solid var(--line);
    font-size: 12px;
}
@media (max-width: 760px) {
    .trafficker-profile-table th:nth-child(1),
    .trafficker-profile-table td:nth-child(1) { width: 54%; }
    .trafficker-profile-table th:nth-child(2),
    .trafficker-profile-table td:nth-child(2) { width: 14%; }
    .trafficker-profile-table th:nth-child(3),
    .trafficker-profile-table td:nth-child(3) { width: 32%; }
    .trafficker-profile-table th:nth-child(4),
    .trafficker-profile-table td:nth-child(4),
    .trafficker-profile-table th:nth-child(5),
    .trafficker-profile-table td:nth-child(5) { display: none; }
}
/* End source-style trafficker profile fields */
/* Trafficker case-count column */
.trafficker-profile-table th:nth-child(1),
.trafficker-profile-table td:nth-child(1) { width: 38%; }
.trafficker-profile-table th:nth-child(2),
.trafficker-profile-table td:nth-child(2) { width: 8%; }
.trafficker-profile-table th:nth-child(3),
.trafficker-profile-table td:nth-child(3) { width: 16%; }
.trafficker-profile-table th:nth-child(4),
.trafficker-profile-table td:nth-child(4) { width: 17%; }
.trafficker-profile-table th:nth-child(5),
.trafficker-profile-table td:nth-child(5) { width: 9%; }
.trafficker-profile-table th:nth-child(6),
.trafficker-profile-table td:nth-child(6) { width: 12%; }
.trafficker-profile-table td:nth-child(2),
.trafficker-profile-table td:nth-child(3),
.trafficker-profile-table td:nth-child(4),
.trafficker-profile-table td:nth-child(5),
.trafficker-profile-table td:nth-child(6) {
    white-space: nowrap;
}
@media (max-width: 760px) {
    .trafficker-profile-table th:nth-child(1),
    .trafficker-profile-table td:nth-child(1) { width: 52%; }
    .trafficker-profile-table th:nth-child(2),
    .trafficker-profile-table td:nth-child(2) { width: 14%; }
    .trafficker-profile-table th:nth-child(3),
    .trafficker-profile-table td:nth-child(3) { width: 34%; }
    .trafficker-profile-table th:nth-child(4),
    .trafficker-profile-table td:nth-child(4),
    .trafficker-profile-table th:nth-child(5),
    .trafficker-profile-table td:nth-child(5),
    .trafficker-profile-table th:nth-child(6),
    .trafficker-profile-table td:nth-child(6) { display: none; }
}
/* End trafficker case-count column */
/* Slim trafficker table after removing guessed fields */
.trafficker-profile-table th:nth-child(1),
.trafficker-profile-table td:nth-child(1) { width: 42%; }
.trafficker-profile-table th:nth-child(2),
.trafficker-profile-table td:nth-child(2) { width: 10%; }
.trafficker-profile-table th:nth-child(3),
.trafficker-profile-table td:nth-child(3) { width: 18%; }
.trafficker-profile-table th:nth-child(4),
.trafficker-profile-table td:nth-child(4) { width: 20%; }
.trafficker-profile-table th:nth-child(5),
.trafficker-profile-table td:nth-child(5) { width: 10%; }
.trafficker-profile-table td:nth-child(2),
.trafficker-profile-table td:nth-child(3),
.trafficker-profile-table td:nth-child(4),
.trafficker-profile-table td:nth-child(5) {
    white-space: nowrap;
}
@media (max-width: 760px) {
    .trafficker-profile-table th:nth-child(1),
    .trafficker-profile-table td:nth-child(1) { width: 54%; }
    .trafficker-profile-table th:nth-child(2),
    .trafficker-profile-table td:nth-child(2) { width: 14%; }
    .trafficker-profile-table th:nth-child(3),
    .trafficker-profile-table td:nth-child(3) { width: 32%; }
    .trafficker-profile-table th:nth-child(4),
    .trafficker-profile-table td:nth-child(4),
    .trafficker-profile-table th:nth-child(5),
    .trafficker-profile-table td:nth-child(5) { display: none; }
}
/* End slim trafficker table */
.source-rcms-grid.trafficking-rcms-section { margin-bottom: 18px; }
.source-data-block .source-rcms-grid.trafficking-rcms-section { margin-bottom: 0; }
.rcms-table-section { margin-bottom: 18px; }
.rcms-table-wrap { max-height: 360px; overflow: auto; }
.rcms-summary-table td:nth-child(3), .rcms-summary-table td:nth-child(4), .rcms-summary-table td:nth-child(5) { text-align: right; font-weight: 800; }
.rcms-summary-table td:nth-child(2) { font-weight: 800; color: var(--text); }
.critical-analysis-section {
    margin-bottom: 18px;
    padding: 18px;
    border: 1px solid rgba(124, 240, 255, .16);
    border-radius: 8px;
    background: rgba(255, 255, 255, .025);
}
.critical-analysis-title {
    margin-bottom: 14px;
}
.critical-analysis-section .smuggling-intel-stack {
    margin-bottom: 0;
}
html[data-theme="light"] .critical-analysis-section {
    background: rgba(255, 255, 255, .5);
    border-color: rgba(14, 116, 144, .18);
}
@media (max-width: 760px) {
    .critical-analysis-section {
        padding: 12px;
    }
}
.critical-analysis-board {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    align-self: stretch;
}
.critical-analysis-card {
    min-height: 330px;
    display: grid;
    grid-template-rows: auto 1fr;
    gap: 16px;
    padding: 16px;
    overflow: hidden;
}
.critical-card-head {
    min-height: 88px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 16px;
    border: 1px solid rgba(124, 240, 255, .2);
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(36, 232, 255, .08), rgba(57, 245, 164, .035));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05);
}
.critical-card-head span,
.critical-card-head strong {
    color: var(--cyan);
    font-size: 11px;
    font-weight: 900;
    line-height: 1;
    text-transform: uppercase;
}
.critical-card-body {
    min-height: 190px;
    display: grid;
    align-items: stretch;
}
.critical-analysis-list {
    display: grid;
    gap: 10px;
    align-content: start;
}
.critical-analysis-row {
    display: grid;
    grid-template-columns: minmax(120px, 1fr) auto;
    gap: 8px 14px;
    padding: 12px;
    border: 1px solid rgba(124, 240, 255, .14);
    border-radius: 8px;
    background: rgba(255, 255, 255, .035);
}
.critical-analysis-row span {
    color: var(--text);
    font-weight: 800;
}
.critical-analysis-row strong {
    color: var(--green);
    font-weight: 900;
}
.critical-analysis-row small {
    grid-column: 1 / -1;
    color: var(--muted);
}
.analysis-empty-box {
    min-height: 185px;
    display: grid;
    place-items: center;
    align-self: stretch;
    border: 1px solid rgba(124, 240, 255, .16);
    border-radius: 8px;
    color: var(--muted);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
    background: rgba(255, 255, 255, .035);
}
.analysis-empty-box::before {
    content: "";
    width: 34px;
    height: 34px;
    margin-bottom: 10px;
    border-radius: 50%;
    border: 1px solid rgba(36, 232, 255, .28);
    background: radial-gradient(circle, rgba(36, 232, 255, .16), rgba(57, 245, 164, .05));
    box-shadow: 0 0 22px rgba(36, 232, 255, .08);
}
html[data-theme="light"] .critical-card-head,
html[data-theme="light"] .critical-analysis-row,
html[data-theme="light"] .analysis-empty-box {
    background: rgba(255, 255, 255, .68);
}
html[data-theme="light"] .analysis-empty-box {
    border-color: rgba(14, 116, 144, .18);
    color: rgba(51, 65, 85, .78);
}
@media (max-width: 1180px) {
    .critical-analysis-board {
        grid-template-columns: 1fr 1fr;
    }
}
@media (max-width: 760px) {
    .critical-analysis-board {
        grid-template-columns: 1fr;
    }
    .critical-analysis-card {
        min-height: 0;
    }
}
/* Critical Analysis unified three-card layout */
.critical-analysis-section .smuggling-intel-stack {
    display: grid;
    grid-template-columns: minmax(420px, 1.4fr) repeat(2, minmax(260px, 1fr));
    gap: 14px;
    align-items: stretch;
    margin-bottom: 0;
}
.critical-analysis-section .smuggling-map-panel,
.critical-analysis-section .critical-analysis-card {
    min-height: 445px;
    height: 100%;
}
.critical-analysis-section .smuggling-map-panel {
    display: grid;
    grid-template-rows: auto 1fr auto;
}
.critical-analysis-section .smuggling-map-panel .real-heat-map {
    height: auto;
    min-height: 0;
}
.critical-analysis-section .critical-analysis-card {
    display: grid;
    grid-template-rows: auto 1fr;
    gap: 14px;
    padding: 16px;
}
.critical-analysis-section .critical-card-head {
    min-height: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}
.critical-analysis-section .critical-card-head span,
.critical-analysis-section .critical-card-head strong {
    display: inline;
    margin-right: 8px;
    color: var(--cyan);
    font-size: 11px;
    font-weight: 900;
    line-height: 1.1;
    text-transform: uppercase;
}
.critical-analysis-section .critical-card-body {
    min-height: 0;
    display: grid;
    align-content: start;
}
.analysis-empty-inline {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    padding: 9px 11px;
    border: 1px solid rgba(124, 240, 255, .16);
    border-radius: 8px;
    color: var(--muted);
    background: rgba(255, 255, 255, .035);
    font-size: 12px;
    font-weight: 800;
}
.analysis-empty-inline::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--cyan);
    box-shadow: 0 0 14px rgba(36, 232, 255, .35);
}
html[data-theme="light"] .analysis-empty-inline {
    background: rgba(255, 255, 255, .72);
    border-color: rgba(14, 116, 144, .18);
}
@media (max-width: 1180px) {
    .critical-analysis-section .smuggling-intel-stack {
        grid-template-columns: 1fr;
    }
    .critical-analysis-section .smuggling-map-panel,
    .critical-analysis-section .critical-analysis-card {
        min-height: 0;
    }
    .critical-analysis-section .smuggling-map-panel .real-heat-map {
        min-height: 280px;
    }
}
.rcms-click-table tbody tr {
    cursor: pointer;
    transition: background .18s ease, transform .18s ease;
}
.rcms-click-table tbody tr:hover td {
    background: rgba(36, 232, 255, .08);
}
.rcms-click-table tbody tr:active {
    transform: translateY(1px);
}