@import url("https://cdn.jsdelivr.net/npm/@fontsource/inter@5.0.18/latin-400.css");
@import url("https://cdn.jsdelivr.net/npm/@fontsource/inter@5.0.18/latin-500.css");
@import url("https://cdn.jsdelivr.net/npm/@fontsource/inter@5.0.18/latin-600.css");
@import url("https://cdn.jsdelivr.net/npm/@fontsource/inter@5.0.18/latin-700.css");

@font-face {
    font-family: "Kantumruy Pro";
    src: url("/fonts/KantumruyPro-Regular.ttf") format("truetype");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: "Kantumruy Pro";
    src: url("/fonts/KantumruyPro-Bold.ttf") format("truetype");
    font-style: normal;
    font-weight: 700;
    font-display: swap;
}

:root {
    color-scheme: light;
    --ink: 220 23% 17%;
    --muted: 220 10% 46%;
    --canvas: 220 17% 96.5%;
    --surface: 0 0% 100%;
    --surface-raised: 220 20% 98%;
    --line: 220 16% 91.4%;
    --navy: 220 23% 17%;
    --navy-soft: 220 21% 21%;
    --accent: 221 78% 52%;
    --accent-hover: 222 77% 44%;
    --accent-foreground: #fff;
    --danger: 2 65% 48%;
    --danger-bg: 2 62% 45%;
    --warning: 34 75% 39%;
    --warning-bg: 43 90% 55%;
    --success: 151 47% 36%;
    --success-bg: 151 46% 34%;
    --info: 201 66% 40%;
    --info-bg: 201 62% 38%;
    --risk-high-ink: #a45117;
    --risk-high-bg: 25 80% 52%;
    --risk-medium-ink: #82600d;
    --risk-medium-bg: 44 87% 45%;
    --risk-critical-bg: 2 62% 45%;
    --risk-low-bg: 151 46% 34%;
    --shadow: 220 27% 18%;
    --primary-color: #245fda;
    --primary-hover: #1b4fc3;
    --danger-color: #c8443e;
    --warning-color: #a86f17;
    --success-color: #2e8158;
    --info-color: #287ca4;
    --font-ui: "Inter", "Google Sans", "Kantumruy Pro", system-ui, sans-serif;
    --font-display: "Inter", "Google Sans", "Kantumruy Pro", system-ui, sans-serif;
}

html[data-bs-theme="dark"] {
    color-scheme: dark;
    --ink: 218 22% 91%;
    --muted: 218 12% 65%;
    --canvas: 222 19% 11%;
    --surface: 221 18% 15%;
    --surface-raised: 221 17% 18%;
    --line: 220 14% 27%;
    --navy: 222 22% 9%;
    --navy-soft: 222 19% 14%;
    --accent: 220 83% 66%;
    --accent-hover: 220 84% 72%;
    --accent-foreground: #101b34;
    --danger: 2 69% 67%;
    --danger-bg: 2 58% 39%;
    --warning: 39 79% 65%;
    --warning-bg: 39 68% 43%;
    --success: 151 47% 58%;
    --success-bg: 151 43% 30%;
    --info: 199 68% 66%;
    --info-bg: 199 56% 34%;
    --risk-high-ink: #ffb77c;
    --risk-high-bg: 25 80% 52%;
    --risk-medium-ink: #f3d17a;
    --risk-medium-bg: 44 87% 45%;
    --risk-critical-bg: 2 58% 39%;
    --risk-low-bg: 151 43% 30%;
    --shadow: 225 40% 3%;
    --primary-color: #7197ff;
    --primary-hover: #8aa9ff;
    --danger-color: #e27871;
    --warning-color: #e0ad58;
    --success-color: #64bd8e;
    --info-color: #6ab4d4;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
    margin: 0;
    background: hsl(var(--canvas));
    color: hsl(var(--ink));
    font-family: var(--font-ui);
    font-size: .94rem;
    line-height: 1.5;
    overflow-x: clip;
    transition: background-color .18s ease, color .18s ease;
}
h1, h2, h3, h4, h5, h6 { color: hsl(var(--ink)); font-family: var(--font-display); font-weight: 690; letter-spacing: -.025em; }
h2 { font-size: clamp(1.45rem, 2.4vw, 1.9rem); }
a { color: hsl(var(--accent)); }
a:hover { color: hsl(var(--accent-hover)); }
.text-muted { color: hsl(var(--muted)) !important; }
.text-primary { color: hsl(var(--accent)) !important; }
.text-info { color: hsl(var(--info)) !important; }
.text-success { color: hsl(var(--success)) !important; }
.text-warning { color: hsl(var(--warning)) !important; }
.text-danger { color: hsl(var(--danger)) !important; }
.bg-light { background-color: hsl(var(--surface-raised)) !important; }
.bg-primary { color:var(--accent-foreground) !important; background-color:hsl(var(--accent)) !important; }
.bg-info { color:#fff !important; background-color:hsl(var(--info-bg)) !important; }
.bg-success { color:#fff !important; background-color:hsl(var(--success-bg)) !important; }
.bg-danger { color:#fff !important; background-color:hsl(var(--danger-bg)) !important; }
.bg-warning { color:#18231f !important; background-color:hsl(var(--warning-bg)) !important; }
.text-white { color: #fff !important; }

.sidebar {
    position: fixed;
    z-index: 1040;
    inset: 0 auto 0 0;
    display: flex;
    flex-direction: column;
    min-height: 100dvh;
    overflow-y: auto;
}
.brand-lockup { display:flex; align-items:center; gap:12px; padding: 9px 13px 22px; border-bottom:1px solid rgb(255 255 255 / .1); }
.brand-mark { width:38px; height:38px; display:grid; place-items:center; border-radius:12px; color:var(--accent-foreground); background:hsl(var(--accent)); font-size:1rem; }
.brand-name { font-weight:730; letter-spacing:-.025em; color:#f4f7fa; line-height:1.15; }
.brand-caption { margin-top:3px; color:#aab8c5; font-size:.7rem; letter-spacing:.075em; text-transform:uppercase; }
.user-info { margin: 16px 4px 14px; padding:13px 12px; border:1px solid rgb(255 255 255 / .09); border-radius:12px; background:rgb(255 255 255 / .045); }
.user-avatar { display:grid; flex:0 0 38px; width:38px; height:38px; place-items:center; border-radius:50%; background:#34495b; color:#e6f4ef; font-weight:700; text-transform:uppercase; }
.user-info .user-name { color:#f3f6f9; font-size:.91rem; font-weight:650; overflow-wrap:anywhere; }
.user-info .user-role { color:#aebbc8; font-size:.78rem; margin-top:2px; }
.sidebar-label { padding: 9px 14px 6px; color:#8193a3; font-size:.68rem; font-weight:700; letter-spacing:.11em; text-transform:uppercase; }
.sidebar .nav-link { display:flex; align-items:center; gap:12px; margin:2px 4px; padding:10px 12px; border-radius:9px; color:#bac6d1; font-size:.88rem; font-weight:550; transition:background-color .16s ease,color .16s ease, transform .16s ease; }
.sidebar .nav-link i { width:18px; text-align:center; font-size:.95rem; color:#91a2b1; }
.sidebar .nav-link:hover { background:rgb(255 255 255 / .075); color:#fff; transform:translateX(2px); }
.sidebar .nav-link:hover i, .sidebar .nav-link.active i { color:#a9ead8; }
.sidebar .nav-link.active { background:rgb(45 146 121 / .23); box-shadow:inset 3px 0 hsl(var(--accent)); color:#fff; }
.sidebar-bottom { margin-top:auto; padding:10px 4px 2px; border-top:1px solid rgb(255 255 255 / .1); }
.sidebar-actions { display:flex; gap:8px; padding:8px 4px 12px; }
.sidebar .theme-toggle { flex:1; border:1px solid rgb(255 255 255 / .16); color:#dce5eb; }
.sidebar .theme-toggle:hover { color:white; border-color:rgb(255 255 255 / .32); background:rgb(255 255 255 / .08); }
.sidebar .logout-link { border-color:rgb(255 255 255 / .22); color:#e1e8ed; }
.sidebar .logout-link:hover { background:rgb(255 255 255 / .1); color:#fff; }
.mobile-topbar { display:none; }
.main-content > .d-flex:first-child, .page-heading { gap:16px; }
.main-content > .d-flex:first-child h2, .main-content > h2 { margin-bottom:0; }

.card { color:hsl(var(--ink)); border:1px solid hsl(var(--line)); border-radius:14px; background:hsl(var(--surface)); box-shadow:0 4px 18px hsl(var(--shadow) / .045); margin-bottom:20px; }
.card-header { padding:15px 19px; color:hsl(var(--ink)); background:hsl(var(--surface)); border-bottom:1px solid hsl(var(--line)); border-radius:14px 14px 0 0 !important; font-weight:650; }
.card-body { padding:19px; }
.card-title { color:hsl(var(--ink)); }
.stat-loading { display:inline-block; width:84px; height:2.1rem; border-radius:7px; vertical-align:middle; background:linear-gradient(90deg,hsl(var(--line)),hsl(var(--surface-raised)),hsl(var(--line))); background-size:200% 100%; animation:stat-shimmer 1.4s ease-in-out infinite; }
@keyframes stat-shimmer { to { background-position:-200% 0; } }

.btn { border-radius:8px; font-weight:600; transition:background-color .15s ease,border-color .15s ease,color .15s ease,transform .15s ease; }
.btn-primary { --bs-btn-bg:hsl(var(--accent)); --bs-btn-border-color:hsl(var(--accent)); --bs-btn-hover-bg:hsl(var(--accent-hover)); --bs-btn-hover-border-color:hsl(var(--accent-hover)); --bs-btn-active-bg:hsl(var(--accent-hover)); --bs-btn-active-border-color:hsl(var(--accent-hover)); --bs-btn-color:var(--accent-foreground); --bs-btn-hover-color:var(--accent-foreground); background:hsl(var(--accent)); border-color:hsl(var(--accent)); color:var(--accent-foreground); }
.btn-primary:hover { background:hsl(var(--accent-hover)); border-color:hsl(var(--accent-hover)); color:var(--accent-foreground); }
.btn-outline-primary { --bs-btn-color:hsl(var(--accent)); --bs-btn-border-color:hsl(var(--accent)); --bs-btn-hover-bg:hsl(var(--accent)); --bs-btn-hover-border-color:hsl(var(--accent)); --bs-btn-hover-color:var(--accent-foreground); }
.btn-outline-secondary { --bs-btn-color:hsl(var(--muted)); --bs-btn-border-color:hsl(var(--line)); --bs-btn-hover-bg:hsl(var(--surface-raised)); --bs-btn-hover-color:hsl(var(--ink)); --bs-btn-hover-border-color:hsl(var(--line)); }
.btn-outline-info { --bs-btn-color:hsl(var(--info)); --bs-btn-border-color:hsl(var(--info)); }
.form-control, .form-select, .input-group-text { min-height:42px; color:hsl(var(--ink)); background-color:hsl(var(--surface)); border-color:hsl(var(--line)); border-radius:8px; }
.form-control::placeholder { color:hsl(var(--muted)); opacity:1; }
.form-label { color:hsl(var(--ink)); font-size:.84rem; font-weight:620; }
.form-control:focus, .form-select:focus { color:hsl(var(--ink)); background-color:hsl(var(--surface)); border-color:hsl(var(--accent)); box-shadow:0 0 0 .22rem hsl(var(--accent) / .16); }
.form-check-input { background-color:hsl(var(--surface)); border-color:hsl(var(--line)); }
.form-check-input:checked { background-color:hsl(var(--accent)); border-color:hsl(var(--accent)); }
:focus-visible { outline:3px solid hsl(var(--accent) / .55) !important; outline-offset:2px; }

.table-responsive { max-width:100%; overflow:auto; border-radius:10px; }
.table { --bs-table-color:hsl(var(--ink)); --bs-table-bg:transparent; --bs-table-border-color:hsl(var(--line)); --bs-table-hover-bg:hsl(var(--accent) / .055); --bs-table-hover-color:hsl(var(--ink)); margin-bottom:0; vertical-align:middle; }
.table > :not(caption) > * > * { padding:12px 13px; }
.table thead th, .table th { position:sticky; top:0; z-index:2; background:hsl(var(--surface-raised)); color:hsl(var(--muted)); border-bottom:1px solid hsl(var(--line)); font-size:.73rem; font-weight:720; letter-spacing:.045em; text-transform:uppercase; white-space:nowrap; }
.table tbody tr:nth-child(even) { background:hsl(var(--surface-raised) / .58); }
.table tbody td { border-color:hsl(var(--line)); }
.table tbody td[colspan] { padding:24px 16px; color:hsl(var(--muted)) !important; background:hsl(var(--surface-raised)); text-align:center; }
.table tbody td[colspan] .text-danger { color:hsl(var(--danger)) !important; }
.table tbody td[colspan] .fa-spinner { color:hsl(var(--accent)); }
.table tbody td[colspan] .fa-exclamation-circle, .table tbody td[colspan] .fa-circle-exclamation { color:hsl(var(--danger)); }
.table code { color:hsl(var(--accent)); }
.risk-critical, .risk-high, .risk-medium, .risk-low { display:inline-flex; align-items:center; border-radius:999px; padding:4px 9px; font-size:.76rem; font-weight:700; white-space:nowrap; }
.risk-critical { color:hsl(var(--danger)); background:hsl(var(--danger) / .12); }
.risk-high { color:var(--risk-high-ink); background:hsl(var(--risk-high-bg) / .14); }
.risk-medium { color:var(--risk-medium-ink); background:hsl(var(--risk-medium-bg) / .17); }
.risk-low { color:hsl(var(--success)); background:hsl(var(--success) / .12); }
.bg-risk-critical { color:#fff !important; background-color:hsl(var(--risk-critical-bg)) !important; }
.bg-risk-high { color:#fff !important; background-color:#a94e0e !important; }
.bg-risk-medium { color:#fff !important; background-color:#806000 !important; }
.bg-risk-low { color:#fff !important; background-color:hsl(var(--risk-low-bg)) !important; }
.badge { font-weight:650; letter-spacing:.01em; }
.pagination { gap:5px; flex-wrap:wrap; }
.page-link { color:hsl(var(--accent)); background:hsl(var(--surface)); border-color:hsl(var(--line)); border-radius:7px !important; }
.page-item.active .page-link { background:hsl(var(--accent)); border-color:hsl(var(--accent)); }
.page-item.disabled .page-link { background:hsl(var(--surface-raised)); color:hsl(var(--muted)); }
.list-group-item { color:hsl(var(--ink)); background:transparent; border-color:hsl(var(--line)); }
.summary-box { border:1px solid hsl(var(--line)); background:hsl(var(--surface-raised)) !important; }
.modal-content { color:hsl(var(--ink)); background:hsl(var(--surface)); border:1px solid hsl(var(--line)); border-radius:14px; box-shadow:0 20px 70px hsl(var(--shadow) / .2); }
.modal-header, .modal-footer { border-color:hsl(var(--line)); }
.btn-close { filter:var(--bs-btn-close-filter, none); }
.alert { border:1px solid hsl(var(--line)); border-radius:10px; }
.app-toast { max-width:min(420px, calc(100vw - 2rem)); box-shadow:0 12px 34px hsl(var(--shadow) / .18); }
.loading-overlay { position:fixed; inset:0; z-index:9999; display:flex; align-items:center; justify-content:center; background:hsl(var(--canvas) / .82); backdrop-filter:blur(3px); }
.loading-overlay .loading-card { display:flex; align-items:center; gap:14px; padding:18px 22px; color:hsl(var(--ink)); background:hsl(var(--surface)); border:1px solid hsl(var(--line)); border-radius:12px; box-shadow:0 12px 40px hsl(var(--shadow) / .15); font-weight:600; }
.feedback-state { display:flex; min-height:190px; width:100%; flex-direction:column; align-items:center; justify-content:center; gap:10px; padding:22px; border:1px dashed hsl(var(--line)); border-radius:10px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); text-align:center; }
.feedback-state i { font-size:1.25rem; }
.feedback-state--loading i { color:hsl(var(--accent)); }
.feedback-state--error { color:hsl(var(--danger)); }
.feedback-state--empty i { color:hsl(var(--muted)); }
.image-modal { display:none; position:fixed; inset:0; z-index:9999; width:100%; height:100%; align-items:center; justify-content:center; background:rgb(8 15 23 / .94) !important; backdrop-filter:blur(6px); }
.image-modal-content { position:relative; max-width:90%; max-height:90%; padding:12px; border:1px solid rgb(255 255 255 / .16); border-radius:14px; background:#17232e; }
.image-modal-img { max-width:100%; max-height:85vh; border-radius:8px; box-shadow:0 0 30px rgb(0 0 0 / .5); }
.image-modal-close { top:-42px; right:2px; width:38px; height:38px; border-radius:50%; background:rgb(255 255 255 / .12) !important; font-size:28px !important; line-height:1; }
.error-message { color:hsl(var(--danger)); font-size:.84rem; margin-top:6px; display:none; }
.error-message.show { display:block; }
.chart-container { width:100%; min-width:0; }

body.auth-page { display:flex; min-height:100dvh; align-items:center; justify-content:center; padding:28px 18px; background:radial-gradient(ellipse at 12% 18%, hsl(var(--accent) / .12), transparent 32%), hsl(var(--canvas)); }
.login-card, .twofa-card { position:relative; width:100%; max-width:460px; padding:clamp(26px,5vw,42px); border:1px solid hsl(var(--line)); border-radius:18px; background:hsl(var(--surface)); box-shadow:0 22px 70px hsl(var(--shadow) / .12); animation:auth-arrive .42s ease-out both; }
.logo-section { text-align:center; margin-bottom:28px; }
.logo-section img { width:72px; height:72px; object-fit:contain; margin-bottom:15px; }
.twofa-logo { display:block; width:68px; height:68px; object-fit:contain; margin:0 auto 18px; }
.logo-section h2, .twofa-title { color:hsl(var(--ink)); font-size:1.7rem; font-weight:760; letter-spacing:-.045em; margin-bottom:5px; }
.logo-section p, .twofa-subtitle { color:hsl(var(--muted)); font-size:.9rem; }
.login-card .form-control { padding:11px 13px; }
.login-card .input-group .form-control { border-radius:8px 0 0 8px; }
.login-card .input-group .btn { border-color:hsl(var(--line)); border-radius:0 8px 8px 0; }
.btn-login { width:100%; margin-top:16px; padding:12px; font-size:.98rem; }
.divider { margin:24px 0 18px; border-top:1px solid hsl(var(--line)); }
.footer-text, .copyright { color:hsl(var(--muted)); text-align:center; font-size:.86rem; }
.copyright { margin:24px 0 0; font-size:.78rem; text-wrap:pretty; }
.twofa-card { text-align:center; }
.auth-theme-toggle { position:fixed; top:18px; right:18px; z-index:5; width:42px; height:42px; border-radius:50%; color:hsl(var(--ink)); background:hsl(var(--surface)); }
.twofa-icon { display:grid; width:74px; height:74px; place-items:center; margin:0 auto 19px; color:hsl(var(--accent)); background:hsl(var(--accent) / .12); border-radius:22px; font-size:1.9rem; }
.twofa-subtitle { margin:12px 0 25px; }
.code-input { min-height:64px; text-align:center; font-size:1.5rem; font-weight:700; letter-spacing:.6em; padding-left:.6em; }
.btn-verify { margin-top:19px; min-width:190px; padding:12px 22px; }
.back-link { display:block; margin-top:20px; color:hsl(var(--muted)); text-decoration:none; }
.back-link:hover { color:hsl(var(--accent)); }

@keyframes auth-arrive { from { opacity:0; transform:translateY(10px); } to { opacity:1; transform:translateY(0); } }
@media (max-width: 767.98px) {
    .sidebar { visibility:hidden; transform:translateX(-102%); transition:transform .22s ease,visibility 0s linear .22s; box-shadow:18px 0 45px rgb(12 21 30 / .24); }
    body.sidebar-open .sidebar { visibility:visible; transform:translateX(0); transition:transform .22s ease,visibility 0s; }
    body.sidebar-open:after { content:""; position:fixed; inset:0; z-index:1035; background:rgb(13 22 31 / .44); }
    .mobile-topbar { display:flex; position:sticky; top:0; z-index:1020; align-items:center; justify-content:space-between; gap:12px; margin:-18px -18px 22px; padding:12px 17px; background:hsl(var(--surface)); border-bottom:1px solid hsl(var(--line)); }
    .mobile-brand { display:flex; align-items:center; gap:9px; font-weight:700; color:hsl(var(--ink)); }
    .mobile-brand .brand-mark { width:33px; height:33px; border-radius:10px; font-size:.88rem; }
    .main-content > .d-flex:first-child { align-items:flex-start !important; flex-wrap:wrap; }
    .main-content > .d-flex:first-child h2 { font-size:1.42rem; }
    .main-content > .d-flex:first-child .btn-group { flex-wrap:wrap; }
    .card-body { padding:15px; }
    .table-responsive { margin-right:-4px; }
}
@media (max-width: 420px) {
    .table > :not(caption) > * > * { padding:10px 9px; }
    .btn-group > .btn { font-size:.78rem; padding:.4rem .55rem; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior:auto !important; animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/* Job Scam Watch — quiet security-console shell */
.brand-lockup { position:relative; min-height:46px; justify-content:center; gap:10px; padding:4px 0 14px; }
.sidebar:hover .brand-lockup, body.sidebar-pinned .brand-lockup { justify-content:flex-start; padding-inline:5px; }
.brand-lockup > div, .sidebar .user-info, .sidebar .sidebar-label, .sidebar .nav-link span, .sidebar .sidebar-bottom .ms-2, .sidebar .logout-link { display:none; }
.sidebar:hover .brand-lockup > div, body.sidebar-pinned .brand-lockup > div,
.sidebar:hover .user-info, body.sidebar-pinned .user-info,
.sidebar:hover .sidebar-label, body.sidebar-pinned .sidebar-label,
.sidebar:hover .nav-link span, body.sidebar-pinned .nav-link span,
.sidebar:hover .sidebar-bottom .ms-2, body.sidebar-pinned .sidebar-bottom .ms-2,
.sidebar:hover .logout-link, body.sidebar-pinned .logout-link { display:block; }
.brand-mark { width:32px; height:32px; border-radius:9px; }
.rail-pin { position:absolute; right:2px; top:8px; display:none; width:27px; height:27px; border:0; border-radius:7px; color:#bac6d1; background:transparent; }
.sidebar:hover .rail-pin, body.sidebar-pinned .rail-pin { display:grid; place-items:center; }
.rail-pin:hover { color:#fff; background:rgb(255 255 255 / .1); }
.sidebar .nav-link { position:relative; justify-content:center; gap:0; margin:3px 0; padding:11px 5px; border-radius:8px; }
.sidebar:hover .nav-link, body.sidebar-pinned .nav-link { justify-content:flex-start; gap:11px; padding-inline:10px; }
.sidebar .nav-link i { width:20px; font-size:1rem; }
.sidebar svg { width:18px; height:18px; flex:none; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.sidebar .brand-mark svg { width:21px; height:21px; }
.sidebar .nav-link svg { width:18px; height:18px; }
.sidebar .logout-link { align-items:center; justify-content:center; gap:9px; }
.sidebar:hover .logout-link, body.sidebar-pinned .logout-link { display:flex; justify-content:flex-start; }
.sidebar .theme-toggle svg { width:17px; height:17px; }
.sidebar .rail-pin svg { width:15px; height:15px; }
.mobile-topbar svg { width:19px; height:19px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.sidebar .sidebar-bottom { padding:8px 0; }
.sidebar .sidebar-actions { padding:6px 0 10px; }
.sidebar .theme-toggle { display:flex; justify-content:center; min-width:38px; }
.sidebar:hover .theme-toggle, body.sidebar-pinned .theme-toggle { justify-content:flex-start; }
.main-content > .row, .main-content > .card, .main-content > .alert { max-width:100%; }
.command-search { display:flex; width:min(260px, 29vw); align-items:center; gap:9px; color:hsl(var(--muted)); }
.command-search > i { font-size:.8rem; }
.command-search input { width:100%; min-width:0; border:0; outline:0; color:hsl(var(--ink)); background:transparent; font:inherit; font-size:.8rem; }
.command-search input::placeholder { color:hsl(var(--muted)); opacity:.9; }
.command-search kbd { flex:none; padding:3px 6px; border:1px solid hsl(var(--line)); border-radius:5px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); font:500 .68rem var(--font-ui); }
.system-status { display:flex; align-items:center; gap:7px; padding:0 10px; border-left:1px solid hsl(var(--line)); color:hsl(var(--muted)); font-size:.73rem; white-space:nowrap; }
.status-dot { width:7px; height:7px; border-radius:50%; background:#32996b; box-shadow:0 0 0 3px rgb(50 153 107 / .12); }
.command-control { display:grid; width:30px; height:30px; place-items:center; border:0; border-radius:7px; color:hsl(var(--muted)); background:transparent; }
.command-control:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.card-header { padding:13px 16px; font-size:.88rem; }
.card-body { padding:16px; }
.btn { --bs-btn-font-size:.82rem; }
.table { font-size:.78rem; }
.table > :not(caption) > * > * { padding:10px 9px; }
.table thead th { font-size:.66rem; letter-spacing:.04em; }
.modal-backdrop.show { opacity:.42; }
.login-card, .twofa-card { border-radius:14px; box-shadow:0 16px 48px hsl(var(--shadow) / .1); }
.login-card:before, .twofa-card:before { height:3px; }
.brand-name { letter-spacing:-.035em; }
.page-heading { display:flex; align-items:flex-end; justify-content:space-between; margin-bottom:22px; }
.page-eyebrow { margin:0 0 5px; color:hsl(var(--muted)); font-size:.68rem; font-weight:700; letter-spacing:.11em; text-transform:uppercase; }
.segmented-control { display:inline-flex; gap:3px; padding:3px; border:1px solid hsl(var(--line)); border-radius:9px; background:hsl(var(--surface-raised)); }
.segmented-control button { border:0; padding:6px 11px; border-radius:6px; background:transparent; color:hsl(var(--muted)); font-size:.77rem; font-weight:600; }
.segmented-control button.active { color:hsl(var(--ink)); background:hsl(var(--surface)); box-shadow:0 1px 3px hsl(var(--shadow) / .12); }
.table tbody tr { cursor:pointer; }
body.auth-page .workspace-commandbar { display:none; }
.chart-actions { display:inline-flex; gap:5px; }
.chart-actions .btn { padding:4px 7px; font-size:.68rem; }
.report-detail-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:0 20px; margin:0; }
.report-detail-grid > div { padding:11px 0; border-bottom:1px solid hsl(var(--line)); }
.report-detail-grid dt { margin-bottom:4px; color:hsl(var(--muted)); font-size:.69rem; font-weight:650; letter-spacing:.05em; text-transform:uppercase; }
.report-detail-grid dd { margin:0; overflow-wrap:anywhere; white-space:pre-wrap; }
#dataTable { table-layout:fixed; }
#dataTable th, #dataTable td { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#dataTable th:nth-child(1), #dataTable td:nth-child(1) { width:15%; }
#dataTable th:nth-child(2), #dataTable td:nth-child(2) { width:14%; }
#dataTable th:nth-child(3), #dataTable td:nth-child(3) { width:14%; }
#dataTable th:nth-child(4), #dataTable td:nth-child(4) { width:12%; }
#dataTable th:nth-child(5), #dataTable td:nth-child(5) { width:27%; }
#dataTable th:nth-child(11), #dataTable td:nth-child(11) { width:18%; }
@media (min-width: 768px) {
    #dataTable th:nth-child(n+6):nth-child(-n+10), #dataTable td:nth-child(n+6):nth-child(-n+10) { display:none; }
    #dataTable .btn { padding:4px 6px; }
}

@media (max-width: 767.98px) {
    .sidebar { padding:18px 12px 14px; }
    .sidebar .brand-lockup { justify-content:flex-start; padding:9px 13px 22px; }
    .sidebar .brand-lockup > div, .sidebar .user-info, .sidebar .sidebar-label, .sidebar .nav-link span, .sidebar .sidebar-bottom .ms-2, .sidebar .logout-link { display:block; }
    .sidebar .nav-link { justify-content:flex-start; gap:12px; margin:2px 4px; padding:10px 12px; }
    .rail-pin { display:none !important; }
    .command-search { flex:1; width:auto; }
    .system-status { padding:0 7px; font-size:.68rem; }
    .mobile-topbar { position:fixed; inset:0 0 auto; margin:0; padding:9px 14px; }
    .main-content > .d-flex:first-child { margin-top:4px; }
    .report-detail-grid { grid-template-columns:1fr; }
    #dataTable { min-width:0; }
}
@media (max-width: 420px) {
    .command-search { gap:6px; }
    .command-search kbd { display:none; }
    .system-status { font-size:0; gap:0; border-left:0; padding:0 4px; }
    .system-status .status-dot { width:8px; height:8px; }
    .page-heading { align-items:flex-start; flex-direction:column; }
}

/* Reference console: a white icon rail, quiet surfaces, and a single blue accent. */
:root {
    --accent: 230 63% 51%;
    --accent-hover: 230 63% 43%;
    --primary-color: #3451d1;
    --primary-hover: #293fb0;
}
html[data-bs-theme="dark"] {
    --accent: 226 91% 70%;
    --accent-hover: 226 92% 76%;
    --primary-color: #82a0ff;
    --primary-hover: #9cb3ff;
}
.sidebar {
    overflow-x:hidden;
    color:hsl(var(--ink));
    background:hsl(var(--surface));
    border-right:1px solid hsl(var(--line));
    box-shadow:none;
    transition:width .2s ease, transform .22s ease;
}
.brand-lockup { position:relative; min-height:46px; justify-content:center; gap:10px; padding:4px 0 14px; border-color:hsl(var(--line)); }
.sidebar:hover .brand-lockup, body.sidebar-pinned .brand-lockup { justify-content:flex-start; padding-inline:5px; }
.brand-lockup > div, .sidebar .user-info, .sidebar .sidebar-label, .sidebar .nav-link span, .sidebar .sidebar-bottom .ms-2, .sidebar .logout-link { display:none; }
.sidebar:hover .brand-lockup > div, body.sidebar-pinned .brand-lockup > div,
.sidebar:hover .user-info, body.sidebar-pinned .user-info,
.sidebar:hover .sidebar-label, body.sidebar-pinned .sidebar-label,
.sidebar:hover .nav-link span, body.sidebar-pinned .nav-link span,
.sidebar:hover .sidebar-bottom .ms-2, body.sidebar-pinned .sidebar-bottom .ms-2,
.sidebar:hover .logout-link, body.sidebar-pinned .logout-link { display:block; }
.sidebar .brand-name { color:hsl(var(--ink)); }
.sidebar .brand-caption { color:hsl(var(--muted)); }
.sidebar .brand-mark { color:white; background:#3451d1; }
.sidebar .user-info { margin:12px 3px; padding:10px; border-color:hsl(var(--line)); background:hsl(var(--surface-raised)); }
.sidebar .user-info .user-name { color:hsl(var(--ink)); }
.sidebar .user-info .user-role { color:hsl(var(--muted)); }
.sidebar .user-avatar { background:#3451d1; color:white; }
.sidebar .sidebar-label { color:hsl(var(--muted)); }
.sidebar .nav-link { position:relative; justify-content:center; gap:0; margin:3px 0; padding:11px 5px; border-radius:8px; color:hsl(var(--muted)); }
.sidebar:hover .nav-link, body.sidebar-pinned .nav-link { justify-content:flex-start; gap:11px; padding-inline:10px; }
.sidebar .nav-link:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); transform:none; }
.sidebar .nav-link svg { width:18px; height:18px; flex:none; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.sidebar .nav-link.active { color:#3451d1; background:#edf1ff; box-shadow:inset 3px 0 #3451d1; }
html[data-bs-theme="dark"] .sidebar .nav-link.active { color:#a9bcff; background:#242f51; box-shadow:inset 3px 0 #82a0ff; }
.sidebar .nav-link.active svg { color:inherit; }
.sidebar .sidebar-bottom { padding:8px 0; border-color:hsl(var(--line)); }
.sidebar .sidebar-actions { padding:6px 0 10px; }
.sidebar .theme-toggle { display:flex; justify-content:center; min-width:38px; color:hsl(var(--muted)); border-color:transparent; }
.sidebar:hover .theme-toggle, body.sidebar-pinned .theme-toggle { justify-content:flex-start; }
.sidebar .theme-toggle:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.sidebar .logout-link { display:none; align-items:center; justify-content:center; gap:9px; color:hsl(var(--muted)); border-color:hsl(var(--line)); }
.sidebar:hover .logout-link, body.sidebar-pinned .logout-link { display:flex; justify-content:flex-start; }
.sidebar .logout-link:hover { color:hsl(var(--danger)); background:hsl(var(--surface-raised)); }
.sidebar svg, .mobile-topbar svg, .command-control svg, .command-search > svg {
    width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round;
}
.sidebar .brand-mark svg { width:21px; height:21px; }
.sidebar .rail-pin { position:absolute; right:2px; top:8px; display:none; width:27px; height:27px; border:0; border-radius:7px; color:hsl(var(--muted)); background:transparent; }
.sidebar:hover .rail-pin, body.sidebar-pinned .rail-pin { display:grid; place-items:center; }
.sidebar .rail-pin:hover { color:hsl(var(--accent)); background:hsl(var(--surface-raised)); }
.card-header { padding:13px 16px; font-size:.88rem; }
.card-body { padding:16px; }
.command-search { display:flex; width:min(260px, 29vw); align-items:center; gap:9px; color:hsl(var(--muted)); }
.command-search > svg { flex:none; width:15px; height:15px; }
.command-search input { width:100%; min-width:0; border:0; outline:0; color:hsl(var(--ink)); background:transparent; font:inherit; font-size:.8rem; }
.command-search input::placeholder { color:hsl(var(--muted)); opacity:.9; }
.command-search kbd { flex:none; padding:3px 6px; border:1px solid hsl(var(--line)); border-radius:5px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); font:500 .68rem var(--font-ui); }
.system-status { display:flex; align-items:center; gap:7px; padding:0 10px; border-left:1px solid hsl(var(--line)); color:hsl(var(--muted)); font-size:.73rem; white-space:nowrap; }
.status-dot { width:7px; height:7px; border-radius:50%; background:#25834f; box-shadow:0 0 0 3px rgb(37 131 79 / .12); }
.system-status[data-status="warning"] .status-dot { background:#a16207; box-shadow:0 0 0 3px rgb(161 98 7 / .13); }
.system-status[data-status="error"] .status-dot { background:#b91c1c; box-shadow:0 0 0 3px rgb(185 28 28 / .13); }
.system-status[data-status="error"] .status-label { color:#b91c1c; }
.system-status[data-status="warning"] .status-label { color:#a16207; }
.command-control { display:grid; width:30px; height:30px; place-items:center; border:0; border-radius:7px; color:hsl(var(--muted)); background:transparent; }
.command-control:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.command-palette { position:fixed; z-index:1050; top:61px; right:18px; width:min(380px, calc(100vw - 28px)); padding:8px; border:1px solid hsl(var(--line)); border-radius:12px; background:hsl(var(--surface)); box-shadow:0 16px 48px hsl(var(--shadow) / .18); }
.command-palette[hidden] { display:none; }
.command-palette-heading { padding:8px 10px 6px; color:hsl(var(--muted)); font-size:.68rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase; }
.command-palette > a { display:flex; justify-content:space-between; padding:9px 10px; border-radius:7px; color:hsl(var(--ink)); font-size:.84rem; text-decoration:none; }
.command-palette > a:hover, .command-palette > a:focus-visible { color:hsl(var(--accent)); background:hsl(var(--accent) / .08); }
.command-palette > a span, .command-palette-hint { color:hsl(var(--muted)); font-size:.72rem; }
.command-palette-hint { padding:9px 10px 5px; border-top:1px solid hsl(var(--line)); }
.page-heading { align-items:flex-start; margin-bottom:22px; }
.page-subtitle { margin:6px 0 0; color:hsl(var(--muted)); font-size:.84rem; }
.timestamp-display { display:inline-flex; flex-direction:column; min-width:max-content; line-height:1.35; }
.timestamp-viewer { color:hsl(var(--muted)); font-size:.68rem; }
.timestamp-unavailable { color:hsl(var(--muted)); }
.risk-critical::before { content:"▲"; margin-right:5px; font-size:.72em; }
.risk-high::before { content:"◆"; margin-right:5px; font-size:.72em; }
.risk-medium::before { content:"●"; margin-right:5px; font-size:.72em; }
.risk-low::before { content:"■"; margin-right:5px; font-size:.72em; }
.risk-critical, .risk-high, .risk-medium, .risk-low { padding:4px 8px; }
.location-found { color:#15803d; background:#f0fdf4; border:1px solid #86efac; }
.location-not-found { color:#b91c1c; background:#fef2f2; border:1px solid #fca5a5; }
.vt-clean { color:#15803d; background:#dcfce7; }
.vt-suspicious { color:#a16207; background:#fef3c7; }
.vt-malicious { color:#b91c1c; background:#fee2e2; }
.vt-unknown { color:#1d4ed8; background:#dbeafe; }
.report-detail-title { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; }
.report-detail-meta { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.report-detail-score { display:flex; align-items:center; gap:12px; margin:16px 0; }
.report-detail-score .progress { flex:1; height:8px; background:hsl(var(--line)); }
.report-screenshot-panel { padding:14px; border:1px solid hsl(var(--line)); border-radius:10px; background:hsl(var(--surface-raised)); }
.report-screenshot-panel img { display:block; max-width:100%; max-height:360px; margin:auto; object-fit:contain; cursor:zoom-in; }
.chart-actions .btn { padding:4px 7px; font-size:.68rem; }
#dataTable { table-layout:fixed; }
#dataTable th, #dataTable td { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
#dataTable th:nth-child(1), #dataTable td:nth-child(1) { width:13%; }
#dataTable th:nth-child(2), #dataTable td:nth-child(2) { width:11%; }
#dataTable th:nth-child(3), #dataTable td:nth-child(3) { width:10%; }
#dataTable th:nth-child(4), #dataTable td:nth-child(4) { width:8%; }
#dataTable th:nth-child(5), #dataTable td:nth-child(5) { width:23%; }
#dataTable th:nth-child(6), #dataTable td:nth-child(6) { width:12%; }
#dataTable th:nth-child(7), #dataTable td:nth-child(7) { width:11%; }
#dataTable th:nth-child(8), #dataTable td:nth-child(8) { width:6%; }
#dataTable th:nth-child(9), #dataTable td:nth-child(9) { width:10%; }
#dataTable th:nth-child(10), #dataTable td:nth-child(10) { width:6%; }
#dataTable th:nth-child(11), #dataTable td:nth-child(11) { width:10%; }
@media (min-width:768px) {
    #dataTable th:nth-child(n+6):nth-child(-n+10), #dataTable td:nth-child(n+6):nth-child(-n+10) { display:none; }
}
@media (max-width:767.98px) {
    .sidebar { padding:18px 12px 14px; }
    .sidebar .brand-lockup { justify-content:flex-start; padding:9px 13px 22px; }
    .sidebar .brand-lockup > div, .sidebar .user-info, .sidebar .sidebar-label, .sidebar .nav-link span, .sidebar .sidebar-bottom .ms-2, .sidebar .logout-link { display:block; }
    .sidebar .nav-link { justify-content:flex-start; gap:12px; margin:2px 4px; padding:10px 12px; }
    .rail-pin { display:none !important; }
    .command-search { flex:1; width:auto; }
    .system-status { padding:0 7px; font-size:.68rem; }
    .mobile-topbar { position:fixed; inset:0 0 auto; margin:0; padding:9px 14px; }
    .main-content > .d-flex:first-child { margin-top:4px; }
    .report-detail-grid { grid-template-columns:1fr; }
    #dataTable { min-width:0; }
}
@media (max-width:420px) {
    .command-search { gap:6px; }
    .command-search kbd { display:none; }
    .system-status { font-size:0; gap:0; border-left:0; padding:0 4px; }
    .system-status .status-dot { width:8px; height:8px; }
    .page-heading { align-items:flex-start; flex-direction:column; }
    .command-palette { top:103px; left:12px; right:12px; width:auto; }
}
.sidebar-user { display:flex; align-items:center; justify-content:center; gap:10px; min-width:0; padding:8px 4px; }
.sidebar:hover .sidebar-user, body.sidebar-pinned .sidebar-user { justify-content:flex-start; }
.sidebar .sidebar-user .user-avatar { width:32px; height:32px; flex-basis:32px; background:#3451d1; color:#fff; }
.sidebar-user-text { display:none; min-width:0; }
.sidebar:hover .sidebar-user-text, body.sidebar-pinned .sidebar-user-text { display:block; }
.sidebar-user-text .user-name { overflow:hidden; color:hsl(var(--ink)); font-size:.78rem; font-weight:650; text-overflow:ellipsis; white-space:nowrap; }
.sidebar-user-text .user-role { color:hsl(var(--muted)); font-size:.7rem; }
.sidebar .sidebar-actions { flex-direction:column; align-items:stretch; }
.sidebar .rail-pin { position:static; display:flex; align-items:center; justify-content:center; gap:8px; width:100%; min-height:36px; color:hsl(var(--muted)); }
.sidebar:hover .rail-pin, body.sidebar-pinned .rail-pin { display:flex; justify-content:flex-start; }
.sidebar .rail-pin span { display:none; }
.sidebar:hover .rail-pin span, body.sidebar-pinned .rail-pin span { display:inline; }
.sidebar .logout-link { display:flex !important; width:100%; min-height:36px; padding:8px; }
.sidebar .logout-link span { display:none !important; }
.sidebar:hover .logout-link span, body.sidebar-pinned .logout-link span { display:inline !important; }
.management-user { display:flex; align-items:center; gap:10px; min-width:170px; }
.management-avatar { display:grid; flex:none; width:34px; height:34px; place-items:center; border-radius:50%; background:#3451d1; color:#fff; font-size:.82rem; font-weight:700; }
.management-user strong, .management-user small { display:block; }
.management-user strong { color:hsl(var(--ink)); font-weight:650; }
.management-user small { color:hsl(var(--muted)); font-family:ui-monospace, SFMono-Regular, Menlo, monospace; font-size:.72rem; }
.password-form { max-width:520px; }
.password-strength { display:flex; gap:4px; margin:9px 0 5px; }
.password-strength span { height:4px; flex:1; border-radius:9px; background:hsl(var(--line)); }
.password-strength[data-strength="1"] span:nth-child(-n+1) { background:#b91c1c; }
.password-strength[data-strength="2"] span:nth-child(-n+2) { background:#c2410c; }
.password-strength[data-strength="3"] span:nth-child(-n+3) { background:#ca8a04; }
.password-strength[data-strength="4"] span:nth-child(-n+4) { background:#15803d; }
.timezone-note { padding:10px 12px; border:1px solid hsl(var(--line)); border-radius:8px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); font-size:.76rem; }
.profile-account-table th { width:30%; color:hsl(var(--muted)); font-size:.77rem; font-weight:600; }
.profile-account-table td { color:hsl(var(--ink)); }
.profile-account-table tr:last-child > * { border-bottom:0; }
.report-extracted-text { padding:12px; border:1px solid hsl(var(--line)); border-radius:8px; background:hsl(var(--surface-raised)); white-space:pre-wrap; overflow-wrap:anywhere; }
.report-detail-title { padding-bottom:12px; border-bottom:1px solid hsl(var(--line)); }
.report-score-section .progress-bar { background:#3451d1; }
.table tbody tr.row-selected { --bs-table-bg:hsl(var(--accent) / .1); --bs-table-color:hsl(var(--ink)); }
.request-empty { display:flex; min-height:220px; align-items:center; flex-direction:column; justify-content:center; padding:30px; text-align:center; }
.request-empty[hidden] { display:none; }
.request-empty-icon { display:grid; width:44px; height:44px; place-items:center; margin-bottom:12px; border:1px solid hsl(var(--line)); border-radius:12px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); }
.request-empty strong { color:hsl(var(--ink)); font-size:.96rem; }
.request-empty p { margin:5px 0 0; color:hsl(var(--muted)); font-size:.82rem; }
.most-reported-label { color:hsl(var(--muted)); font-size:.68rem; font-weight:700; letter-spacing:.1em; text-transform:uppercase; }
.most-reported-row { display:grid; grid-template-columns:26px minmax(0,1fr) minmax(48px,.7fr) 34px; align-items:center; gap:8px; padding:9px 0; border-bottom:1px solid hsl(var(--line)); list-style:none; }
.most-reported-row:last-child { border-bottom:0; }
.most-reported-row .rank-square { display:grid; width:24px; height:24px; place-items:center; border-radius:6px; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); font-size:.7rem; font-weight:700; }
.most-reported-row code { overflow:hidden; color:hsl(var(--ink)); font-size:.75rem; text-overflow:ellipsis; white-space:nowrap; }
.most-reported-row b { color:hsl(var(--ink)); font-size:.78rem; text-align:right; }
.rank-bar { height:5px; overflow:hidden; border-radius:9px; background:hsl(var(--line)); }
.rank-bar i { display:block; height:100%; border-radius:9px; background:#3451d1; }
.trend-down { color:#15803d; }
.trend-up { color:#b91c1c; }
.trend-flat { color:hsl(var(--muted)); }
.change-down h2 { color:#15803d; }
.change-up h2 { color:#b91c1c; }
.change-flat h2 { color:hsl(var(--muted)); }
.status-pill { padding:5px 9px; border-radius:999px; font-size:.74rem; }
.status-enabled { color:#15803d; background:#dcfce7; }
.status-not-enabled { color:#a16207; background:#fef3c7; }
.role-admin { color:#1d4ed8; background:#dbeafe; }
.role-moderator { color:#a16207; background:#fef3c7; }
.role-user { color:hsl(var(--muted)); background:hsl(var(--surface-raised)); }
.auth-brand { display:flex; flex-direction:column; align-items:center; gap:2px; margin:-7px 0 18px; }
.auth-brand strong { color:hsl(var(--ink)); font-size:1rem; }
.auth-brand small { color:hsl(var(--muted)); font-size:.76rem; }
html[data-bs-theme="dark"] .status-enabled { color:#86efac; background:#123522; }
html[data-bs-theme="dark"] .status-not-enabled, html[data-bs-theme="dark"] .role-moderator { color:#fde68a; background:#382b0f; }
html[data-bs-theme="dark"] .role-admin { color:#bfdbfe; background:#1c3150; }
html[data-bs-theme="dark"] .location-found { color:#86efac; background:#102b1d; border-color:#287344; }
html[data-bs-theme="dark"] .location-not-found { color:#fca5a5; background:#341a1a; border-color:#884242; }
html[data-bs-theme="dark"] .vt-clean { color:#86efac; background:#123522; }
html[data-bs-theme="dark"] .vt-suspicious { color:#fde68a; background:#382b0f; }
html[data-bs-theme="dark"] .vt-malicious { color:#fca5a5; background:#3b1d1d; }
html[data-bs-theme="dark"] .vt-unknown { color:#bfdbfe; background:#1c3150; }
@media (max-width:767.98px) {
    .sidebar-user { display:flex; }
    .sidebar-user-text { display:block; }
    .sidebar .sidebar-actions { flex-direction:row; }
    .sidebar .rail-pin { display:none !important; }
    .sidebar .logout-link span { display:inline !important; }
    .password-form { max-width:none; }
}
@media (min-width:768px) {
    body:not(.sidebar-pinned) .sidebar { padding-inline:4px; }
    body:not(.sidebar-pinned) .sidebar .brand-lockup { justify-content:center; padding-inline:0; }
    body:not(.sidebar-pinned) .sidebar:not(:hover) .brand-lockup > div,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .sidebar-label,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .nav-link span,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .sidebar-user-text,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .theme-toggle .ms-2,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .rail-pin span,
    body:not(.sidebar-pinned) .sidebar:not(:hover) .logout-link span { display:none; }
    body:not(.sidebar-pinned) .sidebar:not(:hover) .nav-link { justify-content:center; gap:0; }
    body:not(.sidebar-pinned) .sidebar:not(:hover) .sidebar-user { justify-content:center; }
    body:not(.sidebar-pinned) .sidebar:not(:hover) .logout-link { justify-content:center; }
    body.sidebar-pinned .sidebar { padding-inline:10px; }
}
@media (max-width:767.98px) {
    body:not(.sidebar-pinned) .sidebar .brand-lockup > div,
    body:not(.sidebar-pinned) .sidebar .sidebar-label,
    body:not(.sidebar-pinned) .sidebar .nav-link span,
    body:not(.sidebar-pinned) .sidebar .sidebar-user-text,
    body:not(.sidebar-pinned) .sidebar .logout-link span { display:block !important; }
    body:not(.sidebar-pinned) .sidebar .nav-link { justify-content:flex-start; gap:12px; }
    body:not(.sidebar-pinned) .sidebar .sidebar-user { justify-content:flex-start; }
    body:not(.sidebar-pinned) .sidebar .logout-link { justify-content:flex-start; }
}
body.auth-page .workspace-commandbar, body.auth-page .command-palette { display:none; }
@media (prefers-reduced-motion:reduce) {
    *,*::before,*::after { scroll-behavior:auto !important; animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}
.page-heading-actions { display:flex; align-items:center; gap:10px; }
.kpi-card .card { height:100%; margin:0; }
.attention-stack { display:flex; height:6px; margin:11px 0 8px; overflow:hidden; border-radius:99px; background:hsl(var(--line)); }
.attention-stack span { display:block; transition:width .2s ease; }
.attention-critical { background:#dc2626; }
.attention-high { background:#ea580c; }
.attention-other { background:hsl(var(--line)); }
.attention-legend { display:flex; flex-wrap:wrap; gap:8px; }
.attention-legend .risk-critical, .attention-legend .risk-high { padding:0; background:none; }
.attention-legend b { margin-left:3px; }
.risk-chart-layout { display:grid; grid-template-columns:minmax(170px,1fr) minmax(130px,.8fr); align-items:center; gap:12px; }
.risk-legend { display:flex; flex-direction:column; gap:7px; }
.risk-legend-row { display:flex; align-items:center; gap:8px; padding:8px 9px; border:1px solid hsl(var(--line)); border-radius:8px; color:hsl(var(--ink)); text-decoration:none; font-size:.76rem; }
.risk-legend-row:hover { background:hsl(var(--accent) / .07); }
.risk-legend-row b { margin-left:auto; color:hsl(var(--ink)); font-size:.84rem; }
.risk-legend-color { width:8px; height:8px; flex:none; border-radius:2px; }
.risk-color-critical { background:#dc2626; }
.risk-color-high { background:#ea580c; }
.risk-color-medium { background:#ca8a04; }
.risk-color-low { background:#16a34a; }
.data-filter-form { display:flex; align-items:center; gap:9px; }
.data-filter-form .search-field { flex:1 1 290px; min-width:210px; }
.data-filter-form .input-group-text { background:hsl(var(--surface-raised)); color:hsl(var(--muted)); }
.segmented-control { flex-wrap:wrap; }
.date-filter, .column-chooser { position:relative; }
.date-filter > summary, .column-chooser > summary { list-style:none; cursor:pointer; white-space:nowrap; }
.date-filter > summary::-webkit-details-marker, .column-chooser > summary::-webkit-details-marker { display:none; }
.date-filter-panel, .column-chooser-panel { position:absolute; z-index:20; top:calc(100% + 8px); right:0; width:245px; padding:14px; border:1px solid hsl(var(--line)); border-radius:10px; background:hsl(var(--surface)); box-shadow:0 12px 34px hsl(var(--shadow) / .16); }
.column-chooser-panel { display:flex; flex-direction:column; gap:10px; width:190px; }
.column-chooser-panel label { display:flex; align-items:center; gap:8px; color:hsl(var(--ink)); font-size:.78rem; }
.column-chooser-panel input { accent-color:#3451d1; }
.search-summary { color:hsl(var(--muted)); font-size:.88rem; }
.search-summary strong { color:hsl(var(--ink)); }
.column-hidden { display:none !important; }
#dataTable .column-visible { display:table-cell !important; }
@media (max-width:767.98px) {
    .page-heading-actions { width:100%; flex-wrap:wrap; }
    .data-filter-form { flex-wrap:wrap; }
    .data-filter-form .search-field { flex-basis:100%; }
    .risk-chart-layout { grid-template-columns:minmax(130px,1fr) minmax(100px,.75fr); gap:6px; }
}
@media (max-width:420px) {
    .risk-chart-layout { grid-template-columns:1fr; }
    .risk-legend { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
    .page-heading-actions { align-items:flex-start; }
}

/* Impeccable Operate pass: responsive shell, focused data tables, and complete report review. */
:root {
    --radius-control: 8px;
    --radius-card: 12px;
    --surface-shadow: 0 1px 2px hsl(var(--shadow) / .045);
}

html {
    scrollbar-color: hsl(var(--muted) / .55) hsl(var(--surface-raised));
    scrollbar-width: thin;
}
html ::selection { color:hsl(var(--ink)); background:hsl(var(--accent) / .24); }
body { overflow-x:clip; }
button, a, input, select, textarea, summary { -webkit-tap-highlight-color:transparent; }
:focus-visible { outline:3px solid hsl(var(--accent) / .68) !important; outline-offset:3px; }

.workspace-mobile-leading { display:none; }
.workspace-mobile-actions { display:flex; align-items:center; gap:5px; }
.command-search-trigger { display:none; }
.command-control { width:36px; height:36px; }
.command-control:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.system-status { border-left:0; padding:5px 9px; border-radius:999px; background:hsl(var(--surface-raised)); }
.system-status[data-status="error"] { background:hsl(var(--danger) / .1); }
.system-status[data-status="warning"] { background:hsl(var(--warning) / .12); }
.system-status .status-label { color:hsl(var(--ink)); }
.system-status[data-status="error"] .status-dot { background:#dc2626; box-shadow:0 0 0 3px rgb(220 38 38 / .14); }
.system-status[data-status="warning"] .status-dot { background:#d97706; box-shadow:0 0 0 3px rgb(217 119 6 / .16); }

.page-heading { display:flex; justify-content:space-between; gap:20px; }
.page-heading > div:first-child { min-width:0; }
.page-heading h2 { font-size:1.625rem; line-height:1.2; }
.page-subtitle { max-width:58ch; font-size:.88rem; line-height:1.55; }
.page-heading-actions { flex:none; }
.overview-heading-actions { justify-content:flex-end; }

.alert-admin-row {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    min-height:42px;
    margin:-8px 0 16px;
    padding:7px 10px 7px 12px;
    border:1px solid hsl(var(--line));
    border-radius:10px;
    color:hsl(var(--muted));
    background:hsl(var(--surface));
    font-size:.77rem;
}
.alert-admin-copy { display:flex; min-width:0; align-items:center; gap:9px; }
.alert-admin-copy > svg, .alert-admin-row button svg { width:16px; height:16px; flex:none; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.alert-admin-copy strong { color:hsl(var(--ink)); font-size:.78rem; white-space:nowrap; }
.alert-admin-copy #lastAlertSent { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.alert-admin-copy .timestamp-viewer { display:none; }
.alert-admin-row button { display:inline-flex; flex:none; align-items:center; gap:7px; white-space:nowrap; }

#locationsCheckedText, #urlsCheckedText { margin-top:1px; }
#comparisonText { font-variant-numeric:tabular-nums; }
#telegramTotal, #telegramUnique, #telegramDuplicated,
#phoneTotal, #phoneUnique, #phoneDuplicated { color:hsl(var(--ink)) !important; font-variant-numeric:tabular-nums; }

.table-scroll-region {
    width:100%;
    max-width:100%;
    min-width:0;
    margin:0;
    overflow:auto;
    overscroll-behavior-inline:contain;
    -webkit-overflow-scrolling:touch;
    scrollbar-color:hsl(var(--muted) / .5) hsl(var(--surface-raised));
    scrollbar-width:thin;
    border-radius:9px;
}
.table-scroll-region::-webkit-scrollbar { width:10px; height:10px; }
.table-scroll-region::-webkit-scrollbar-track { background:hsl(var(--surface-raised)); border-radius:10px; }
.table-scroll-region::-webkit-scrollbar-thumb { background:hsl(var(--muted) / .42); border:2px solid hsl(var(--surface-raised)); border-radius:10px; }
.table-scroll-region:focus-visible { outline:3px solid hsl(var(--accent) / .48); outline-offset:2px; }
.table-scroll-region table { min-width:760px; margin:0; border-collapse:separate; border-spacing:0; }
.data-table-scroll-region { max-height:min(72vh, 860px); }
.data-table-scroll-region table#dataTable { width:max-content; min-width:1580px; table-layout:auto; }
.recent-table-scroll table { min-width:820px; }
.users-table-scroll table { min-width:760px; }
.requests-table-scroll table { min-width:930px; }
.table-scroll-region .table thead th { position:sticky; top:0; z-index:3; }
.table-scroll-region .table thead th:first-child {
    left:0;
    z-index:5;
    box-shadow:8px 0 12px -12px hsl(var(--ink) / .65), 1px 0 0 hsl(var(--line));
}
.table-scroll-region .table tbody td:first-child {
    position:sticky;
    left:0;
    z-index:1;
    background:hsl(var(--surface));
    box-shadow:8px 0 12px -12px hsl(var(--ink) / .55), 1px 0 0 hsl(var(--line));
}
.table-scroll-region .table tbody tr:nth-child(even) td:first-child { background:hsl(var(--surface-raised)); }
.table-scroll-region .table tbody tr:hover td:first-child { background:hsl(var(--accent) / .075); }
.table-scroll-region .table tbody tr.row-selected td:first-child { background:hsl(var(--accent) / .12); }
.table-scroll-region .table > :not(caption) > * > * { min-height:44px; padding:10px 12px; }
.table-scroll-region .table tbody tr[data-action] { cursor:pointer; }
.data-table-scroll-region #dataTable th,
.data-table-scroll-region #dataTable td { max-width:250px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.data-table-scroll-region #dataTable th:nth-child(1), .data-table-scroll-region #dataTable td:nth-child(1) { min-width:235px; }
.data-table-scroll-region #dataTable th:nth-child(2), .data-table-scroll-region #dataTable td:nth-child(2) { min-width:125px; }
.data-table-scroll-region #dataTable th:nth-child(3), .data-table-scroll-region #dataTable td:nth-child(3) { min-width:120px; }
.data-table-scroll-region #dataTable th:nth-child(4), .data-table-scroll-region #dataTable td:nth-child(4) { min-width:90px; }
.data-table-scroll-region #dataTable th:nth-child(5), .data-table-scroll-region #dataTable td:nth-child(5) { min-width:220px; }
.data-table-scroll-region #dataTable th:nth-child(6), .data-table-scroll-region #dataTable td:nth-child(6) { min-width:230px; }
.data-table-scroll-region #dataTable th:nth-child(7), .data-table-scroll-region #dataTable td:nth-child(7) { min-width:125px; }
.data-table-scroll-region #dataTable th:nth-child(8), .data-table-scroll-region #dataTable td:nth-child(8) { min-width:88px; }
.data-table-scroll-region #dataTable th:nth-child(9), .data-table-scroll-region #dataTable td:nth-child(9) { min-width:145px; }
.data-table-scroll-region #dataTable th:nth-child(10), .data-table-scroll-region #dataTable td:nth-child(10) { min-width:82px; }
.data-table-scroll-region #dataTable th:nth-child(11), .data-table-scroll-region #dataTable td:nth-child(11) { min-width:145px; }
.data-table-scroll-region #dataTable th:nth-child(n+6):nth-child(-n+10),
.data-table-scroll-region #dataTable td:nth-child(n+6):nth-child(-n+10) { display:table-cell !important; }
.screenshot-action { display:inline-flex; align-items:center; gap:7px; white-space:nowrap; }
.screenshot-action svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.ui-outline-icon { width:16px; height:16px; flex:none; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; vertical-align:-.18em; }

.risk-legend-row { min-height:38px; }
.risk-shape { width:10px; height:10px; flex:none; background:currentColor; }
.risk-shape--critical { color:#dc2626; clip-path:polygon(50% 0,100% 100%,0 100%); }
.risk-shape--high { color:#ea580c; transform:rotate(45deg) scale(.78); }
.risk-shape--medium { color:#ca8a04; border-radius:50%; }
.risk-shape--low { color:#16a34a; border-radius:1px; }
.risk-shape--unknown { color:#3b82f6; border-radius:2px; }
.risk-legend-row { color:hsl(var(--ink)); }
.risk-legend-row:hover { color:hsl(var(--accent)); }

.chart-container { min-width:0; }
.chart-container.feedback-state { min-height:220px; }
.chart-actions .btn { min-width:34px; min-height:34px; }

.report-detail-dialog { width:min(760px, calc(100vw - 48px)); max-width:760px; margin:0 0 0 auto; }
.report-detail-dialog .modal-content { min-height:min(80vh, 900px); }
.report-detail-dialog .modal-header { position:sticky; top:0; z-index:2; background:hsl(var(--surface)); }
.report-detail-header-actions { display:flex; align-items:center; gap:7px; }
.report-detail-header-actions .btn { display:inline-flex; align-items:center; gap:5px; }
.report-detail-header-actions svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.report-detail-group { margin:18px 0 0; }
.report-detail-group h6, .report-extracted-section h6 { margin:0 0 10px; font-size:.84rem; font-weight:700; }
.report-detail-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); margin:0; border:1px solid hsl(var(--line)); border-radius:10px; overflow:hidden; }
.report-detail-field { min-width:0; padding:11px 13px; border-bottom:1px solid hsl(var(--line)); }
.report-detail-field:nth-child(odd) { border-right:1px solid hsl(var(--line)); }
.report-detail-field dt { margin:0 0 4px; color:hsl(var(--muted)); font-size:.69rem; font-weight:650; letter-spacing:.035em; text-transform:uppercase; }
.report-detail-field dd { margin:0; color:hsl(var(--ink)); overflow-wrap:anywhere; }
.report-field-value { white-space:pre-wrap; overflow-wrap:anywhere; }
.report-field-pre { max-height:180px; overflow:auto; margin:0; color:hsl(var(--ink)); font:inherit; white-space:pre-wrap; overflow-wrap:anywhere; }
.report-inline-link { display:inline-flex; margin:7px 8px 0 0; color:hsl(var(--accent)); font-size:.78rem; }
.report-copy-button { display:inline-flex; min-height:32px; align-items:center; gap:6px; margin-top:7px; }
.report-copy-button svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.report-copy-target { overflow-wrap:anywhere; }
.report-url-list { display:flex; flex-direction:column; gap:4px; margin:10px 0 0; overflow-wrap:anywhere; }
.report-url-list a { font-size:.78rem; }
.report-summary { padding:15px; border:1px solid hsl(var(--line)); border-radius:11px; background:hsl(var(--surface-raised)); }
.report-summary-badges { display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.report-received { margin-top:11px; color:hsl(var(--ink)); font-size:.8rem; }
.report-received > span { display:block; margin-bottom:4px; color:hsl(var(--muted)); font-size:.68rem; font-weight:650; text-transform:uppercase; }
.report-score-block { margin-top:14px; }
.report-score-heading { display:flex; justify-content:space-between; gap:10px; margin-bottom:6px; font-size:.8rem; }
.report-score-heading strong { color:hsl(var(--ink)); font-variant-numeric:tabular-nums; }
.report-score-progress { display:block; width:100%; height:8px; accent-color:#3451d1; }
.report-screenshot-section { padding:14px; border:1px solid hsl(var(--line)); border-radius:11px; background:hsl(var(--surface-raised)); }
.report-section-subtitle { margin:-4px 0 12px; color:hsl(var(--muted)); font-size:.78rem; }
.report-screenshot-preview { display:grid; width:100%; min-height:150px; place-items:center; padding:12px; border:1px solid hsl(var(--line)); border-radius:9px; background:hsl(var(--canvas)); cursor:zoom-in; }
.report-screenshot-preview img { display:block; max-width:100%; max-height:420px; object-fit:contain; }
.report-no-screenshot { padding:24px; border:1px dashed hsl(var(--line)); border-radius:9px; color:hsl(var(--muted)); text-align:center; }
.report-extracted-text { max-height:min(48vh,520px); overflow:auto; margin:0; padding:14px; border:1px solid hsl(var(--line)); border-radius:9px; color:hsl(var(--ink)); background:hsl(var(--surface-raised)); font-family:var(--font-ui); font-size:.9rem; line-height:1.75; white-space:pre-wrap; overflow-wrap:anywhere; }
.report-copy-actions { display:flex; justify-content:flex-end; }
.clipboard-fallback { position:fixed; top:0; left:-9999px; opacity:0; }

.image-modal[hidden] { display:none !important; }
.image-modal { z-index:2000; padding:16px; background:rgb(10 15 24 / .88) !important; }
.image-modal-content { display:flex; width:min(1100px, 96vw); max-width:none; max-height:94dvh; flex-direction:column; gap:10px; padding:10px; border-color:rgb(255 255 255 / .18); background:#111827; }
.image-modal-toolbar { display:flex; min-height:40px; align-items:center; justify-content:flex-end; gap:7px; }
.image-modal-original, .image-modal-control, .image-modal-close { display:inline-flex; min-width:38px; min-height:36px; align-items:center; justify-content:center; padding:6px 10px; border:1px solid rgb(255 255 255 / .2); border-radius:7px; color:#f8fafc; background:rgb(255 255 255 / .08); font:600 .76rem var(--font-ui); text-decoration:none; }
.image-modal-original { margin-right:auto; }
.image-modal-original[hidden] { display:none; }
.image-modal-control:hover, .image-modal-close:hover, .image-modal-original:hover { color:#fff; background:rgb(255 255 255 / .16); }
.image-modal-close { position:static; font-size:1rem !important; }
.image-modal-close svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; }
.image-modal-viewport { min-height:0; overflow:auto; text-align:center; }
.image-modal-img { max-width:100%; max-height:calc(94dvh - 86px); transform-origin:center center; transition:transform .12s ease; }
.image-modal-state { padding:28px; color:#f8fafc; text-align:center; }
.image-modal-state[hidden] { display:none; }
.image-modal-error { color:#fecaca; }

@media (max-width:767.98px) {
    .workspace-mobile-leading { display:flex; min-width:0; align-items:center; gap:6px; }
    .mobile-menu-button { flex:none; }
    .mobile-brand { display:flex; min-width:0; align-items:center; gap:7px; color:hsl(var(--ink)); font-size:.83rem; font-weight:700; white-space:nowrap; }
    .mobile-brand .brand-mark { width:30px; height:30px; border-radius:8px; }
    .mobile-brand .brand-mark svg { width:18px; height:18px; }
    .workspace-mobile-actions { justify-self:end; gap:2px; }
    .workspace-mobile-actions .command-control { width:36px; height:38px; }
    .command-search { display:none; }
    .command-search-trigger { display:grid; }
    .workspace-commandbar.search-open .command-search {
        position:fixed;
        z-index:1052;
        top:64px;
        right:12px;
        left:12px;
        display:flex;
        width:auto;
        min-height:44px;
        padding:7px 10px;
        border:1px solid hsl(var(--line));
        border-radius:10px;
        background:hsl(var(--surface));
        box-shadow:0 10px 28px hsl(var(--shadow) / .16);
    }
    .workspace-commandbar.search-open .command-search input { display:block; }
    .workspace-commandbar.search-open .command-search kbd { display:none; }
    .workspace-commandbar.search-open .command-search-trigger { display:none; }
    .system-status { min-width:32px; justify-content:center; padding:6px; background:transparent; }
    .system-status .status-label { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; }
    .command-palette { top:113px; right:12px; left:12px; width:auto; }
    .workspace-commandbar:not(.search-open) ~ .command-palette { top:62px; }
    .page-heading { align-items:flex-start; flex-direction:column; gap:12px; margin-bottom:18px; }
    .page-heading h2 { font-size:1.48rem; }
    .page-heading-actions, .overview-heading-actions { display:flex; width:100%; flex-direction:column; align-items:stretch; gap:8px; }
    .overview-heading-actions .segmented-control { width:100%; }
    .overview-heading-actions .segmented-control button { flex:1; }
    .overview-heading-actions > .btn { width:100%; }
    .alert-admin-row { align-items:center; flex-wrap:nowrap; gap:6px; margin:0 0 14px; padding:5px 7px; }
    .alert-admin-copy { min-width:0; flex:1; flex-wrap:nowrap; gap:6px; overflow:hidden; }
    .alert-admin-copy > svg { width:14px; height:14px; }
    .alert-admin-copy strong { max-width:90px; overflow:hidden; text-overflow:ellipsis; font-size:.7rem; }
    .alert-admin-copy #lastAlertSent { flex:1; min-width:0; max-width:170px; margin:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:.68rem; }
    .alert-admin-row .timestamp-display, .alert-admin-row .timestamp-display > span { display:inline; white-space:nowrap; }
    .alert-admin-row button { width:32px; min-width:32px; height:32px; margin:0; padding:0; justify-content:center; }
    .alert-admin-row button span { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; }
    .risk-chart-layout { grid-template-columns:minmax(150px,1fr) minmax(120px,.8fr); }
    .table-scroll-region { max-width:100%; }
    .data-table-scroll-region { max-height:68dvh; }
    .report-detail-dialog { width:100%; max-width:none; height:100dvh; margin:0; }
    .report-detail-dialog .modal-content { height:100%; min-height:100%; border:0; border-radius:0; }
    .report-detail-dialog .modal-header { padding:12px; }
    .report-detail-dialog .modal-body { overflow:auto; padding:12px; }
    .report-detail-header-actions { gap:4px; }
    .report-detail-header-actions .btn { min-width:38px; min-height:38px; padding:6px; }
    .report-detail-header-actions .btn span { display:none; }
    .report-detail-grid { grid-template-columns:1fr; }
    .report-detail-field:nth-child(odd) { border-right:0; }
    .image-modal { padding:8px; }
    .image-modal-content { width:100%; max-height:96dvh; padding:8px; }
    .image-modal-img { max-height:calc(96dvh - 82px); }
}
@media (max-width:420px) {
    .mobile-brand { font-size:.76rem; }
    .mobile-brand .brand-mark { width:28px; height:28px; }
    .workspace-mobile-actions { gap:0; }
    .workspace-mobile-actions .command-control { width:33px; }
    .risk-chart-layout { grid-template-columns:1fr; }
    .risk-legend { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); }
    .alert-admin-row { gap:8px; }
}
@media (min-width:768px) {
    .data-table-scroll-region { max-height:min(72vh, 860px); }
}
@media (prefers-reduced-motion:reduce) {
    .workspace-commandbar, .report-detail-dialog, .image-modal-img { transition:none !important; }
}

html[data-bs-theme="dark"] {
    --canvas:222 19% 10%;
    --surface:221 18% 14%;
    --surface-raised:221 17% 18%;
    --line:220 14% 27%;
    --ink:218 22% 93%;
    --muted:218 12% 70%;
    scrollbar-color:hsl(var(--muted) / .6) hsl(var(--surface-raised));
}
html[data-bs-theme="dark"] ::selection { color:#f8fafc; background:#3451d1; }
html[data-bs-theme="dark"] .table-scroll-region::-webkit-scrollbar-track { background:hsl(var(--surface-raised)); }
html[data-bs-theme="dark"] .table-scroll-region::-webkit-scrollbar-thumb { background:hsl(var(--muted) / .5); border-color:hsl(var(--surface-raised)); }
html[data-bs-theme="dark"] .risk-legend-row { border-color:hsl(var(--line)); }
html[data-bs-theme="dark"] .report-screenshot-preview { background:hsl(var(--canvas)); }
html[data-bs-theme="dark"] .report-score-progress { accent-color:#82a0ff; }
html[data-bs-theme="dark"] .image-modal-content { background:#0b1220; }
html[data-bs-theme="dark"] .image-modal-original,
html[data-bs-theme="dark"] .image-modal-control,
html[data-bs-theme="dark"] .image-modal-close { color:#f8fafc; border-color:#475569; background:#1e293b; }

/* Compact sticky shell and responsive data presentation */
html, body { max-width:100%; overflow-x:clip; }
body { padding-top:0 !important; }

.workspace-commandbar {
    display:flex;
    align-items:center;
    gap:12px;
}
.workspace-mobile-leading { display:none; }
.command-search {
    flex:0 1 420px;
    width:min(420px, 100%);
    height:36px;
    margin:0 auto 0 0;
    padding:0 10px;
    border:1px solid hsl(var(--line));
    border-radius:8px;
    background:hsl(var(--surface-raised));
    box-shadow:none;
}
.workspace-mobile-actions { display:flex; align-items:center; gap:10px; margin-left:auto; }
.command-search-trigger { display:none; }
.system-status {
    min-height:32px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    gap:7px;
    padding:0 10px;
    border:1px solid hsl(var(--line));
    border-radius:999px;
    color:hsl(var(--ink));
    background:hsl(var(--surface));
    cursor:pointer;
    font-size:.78rem;
}
.system-status:hover { background:hsl(var(--surface-raised)); }
.system-status[data-status="error"] { border-color:#fca5a5; color:#b91c1c; background:#fef2f2; }
.system-status[data-status="warning"] { border-color:#fcd34d; color:#92400e; background:#fffbeb; }
.status-dot { width:7px; height:7px; flex:0 0 7px; border-radius:50%; background:#16a34a; }
.system-status[data-status="error"] .status-dot { background:#dc2626; }
.system-status[data-status="warning"] .status-dot { background:#d97706; }
.user-menu { flex:0 0 auto; }
.user-menu-trigger {
    display:grid;
    place-items:center;
    width:34px;
    height:34px;
    padding:0;
    border:0;
    border-radius:50%;
    color:#fff;
    background:#3451d1;
}
.header-avatar { font-size:.86rem; font-weight:700; }
.status-popover, .user-menu-popover {
    z-index:1070;
    margin-top:8px !important;
    padding:10px;
    border:1px solid hsl(var(--line));
    border-radius:12px;
    color:hsl(var(--ink));
    background:hsl(var(--surface));
    box-shadow:0 12px 32px rgb(15 23 42 / .14);
}
.status-popover { width:min(340px, calc(100vw - 24px)); }
.alert-admin-row {
    display:flex;
    flex-direction:column;
    align-items:stretch;
    gap:10px;
    margin:0;
    padding:2px;
    border:0;
    border-radius:0;
    background:transparent;
}
.alert-admin-copy { display:flex; flex-direction:column; align-items:flex-start; gap:3px; }
.alert-admin-copy > svg { display:none; }
.alert-admin-copy strong { font-size:.84rem; color:hsl(var(--ink)); }
.alert-admin-copy #lastAlertSent { max-width:none; margin:0; color:hsl(var(--muted)); font-size:.76rem; white-space:normal; }
.alert-admin-row .timestamp-display { display:inline; }
.alert-admin-row .timestamp-display > span { display:inline; }
.alert-admin-row .timestamp-display .viewer-time { display:block; }
.alert-admin-row button { width:100%; justify-content:center; margin:0; }
.alert-admin-row button svg,
.user-menu-action svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.user-menu-popover { width:220px; }
.user-menu-identity { display:flex; flex-direction:column; gap:2px; padding:5px 8px 10px; border-bottom:1px solid hsl(var(--line)); margin-bottom:5px; }
.user-menu-identity strong { color:hsl(var(--ink)); font-size:.88rem; }
.user-menu-identity span { color:hsl(var(--muted)); font-size:.74rem; }
.user-menu-action { display:flex; align-items:center; gap:10px; border-radius:7px; color:hsl(var(--ink)); }
.user-menu-action:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.rail-theme-toggle { display:none; }
.sidebar .nav-link,
.sidebar .sidebar-brand,
.sidebar .rail-pin,
.sidebar .rail-theme-toggle { white-space:nowrap; }
.sidebar .nav-link span,
.sidebar .sidebar-brand-text { white-space:nowrap; }
.sidebar .nav-link.active { border-left:0; box-shadow:inset 2px 0 #3451d1; background:#eef2ff; color:#2944be; }
.sidebar .sidebar-label { margin:16px 12px 7px; color:hsl(var(--muted)); font-size:.66rem; font-weight:700; letter-spacing:.08em; text-transform:uppercase; }
.sidebar .brand-lockup { white-space:nowrap; }
.sidebar .brand-lockup > div { min-width:0; }
.sidebar .brand-name { overflow:hidden; font-size:.9rem; text-overflow:ellipsis; white-space:nowrap; }
.sidebar .brand-caption { color:hsl(var(--muted)); font-size:.7rem; }
.sidebar .sidebar-actions { display:flex; flex-direction:column; gap:5px; }
.sidebar .rail-theme-toggle {
    width:100%;
    min-height:36px;
    display:none;
    align-items:center;
    gap:12px;
    padding:7px 10px;
    border:0;
    border-radius:8px;
    color:hsl(var(--muted));
    background:transparent;
    text-align:left;
}
.sidebar .rail-theme-toggle svg { width:17px; height:17px; flex:0 0 17px; fill:none; stroke:currentColor; stroke-width:1.7; }

.page-heading { display:flex; align-items:center; justify-content:space-between; gap:16px; margin:0 0 16px; }
.page-heading h2 { margin:0; color:hsl(var(--ink)); font-size:28px; font-weight:700; letter-spacing:-.035em; line-height:1.15; }
.page-heading .page-subtitle { margin:5px 0 0; color:hsl(var(--muted)); font-size:.84rem; line-height:1.35; }
.page-heading-actions { display:flex; flex:0 0 auto; align-items:center; gap:8px; width:auto; }
.overview-heading-actions { flex-direction:row; align-items:center; }
.segmented-control { width:auto; flex:0 0 auto; padding:3px; border-radius:9px; background:hsl(var(--surface-raised)); }
.segmented-control button { min-height:29px; padding:4px 10px; border:0; border-radius:7px; color:hsl(var(--muted)); background:transparent; font-size:.76rem; white-space:nowrap; }
.segmented-control button[aria-pressed="true"],
.segmented-control button.active { color:hsl(var(--ink)); background:hsl(var(--surface)); box-shadow:0 1px 2px rgb(15 23 42 / .08); }
.refresh-button { width:36px; height:36px; display:grid; place-items:center; padding:0; border-radius:8px; }
.refresh-button svg { width:17px; height:17px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.refresh-button.is-loading svg { animation:refresh-spin .75s linear infinite; }
@keyframes refresh-spin { to { transform:rotate(360deg); } }

.card {
    border:1px solid hsl(var(--line));
    border-radius:12px;
    background:hsl(var(--surface));
    box-shadow:none;
}
.card-header { border-bottom:1px solid hsl(var(--line)); background:transparent; color:hsl(var(--ink)); }
.card-body { color:hsl(var(--ink)); }
.chart-row { margin-top:12px !important; }
.chart-card-heading { min-height:58px; display:flex; align-items:center; justify-content:space-between; gap:12px; }
.chart-card-heading h3,
.chart-card-title h3 { min-width:0; margin:0; color:hsl(var(--ink)); font-size:.94rem; font-weight:650; line-height:1.2; white-space:nowrap; }
.chart-card-heading > small,
.chart-card-title > small { color:hsl(var(--muted)); font-size:.72rem; white-space:nowrap; }
.chart-card-title { display:flex; min-width:0; flex-direction:column; gap:3px; }
.chart-card-heading.has-actions { gap:10px; }
.chart-actions { display:flex; flex:0 0 auto; align-items:center; gap:4px; }
.chart-actions .btn { width:30px; height:30px; display:grid; place-items:center; padding:0; border:1px solid hsl(var(--line)); border-radius:7px; color:hsl(var(--muted)); background:transparent; }
.chart-actions .btn svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.chart-actions .btn:hover { color:#3451d1; background:hsl(var(--surface-raised)); }
.risk-chart-layout { display:grid !important; grid-template-columns:minmax(0,1fr) !important; gap:8px !important; align-items:center; }
.risk-chart-layout .chart-container { min-width:0; max-width:100%; }
.risk-legend { display:grid !important; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; width:100%; min-width:0; }
.risk-legend-row { min-width:0; display:flex; align-items:center; gap:7px; padding:7px 8px; border:1px solid hsl(var(--line)); border-radius:8px; color:hsl(var(--ink)); background:hsl(var(--surface)); font-size:.75rem; }
.risk-legend-row:hover { border-color:#c7d2fe; background:#f8faff; }
.risk-shape { flex:0 0 10px; }
.risk-shape--critical { color:#dc2626; }
.risk-shape--high { color:#ea580c; }
.risk-shape--medium { color:#ca8a04; }
.risk-shape--low { color:#16a34a; }
.risk-shape--unknown { color:#64748b; }

.risk-summary-pills { display:flex; flex-wrap:wrap; align-items:center; gap:7px; padding:8px 0 12px; }
.risk-summary-pill {
    display:inline-flex;
    align-items:center;
    gap:5px;
    padding:4px 8px;
    border:1px solid currentColor;
    border-radius:999px;
    font-size:.72rem;
    font-weight:550;
    line-height:1.2;
}
.risk-summary-pill b { font-variant-numeric:tabular-nums; }
.risk-summary-pill.is-zero { opacity:.38; }
.risk-summary-pills.has-risk-filter .risk-summary-pill.is-zero { filter:grayscale(1); }

.table-scroll-region {
    position:relative;
    max-width:100%;
    max-height:none !important;
    height:auto !important;
    overflow-x:auto !important;
    overflow-y:visible !important;
    overscroll-behavior-x:contain;
    -webkit-overflow-scrolling:touch;
    scrollbar-width:thin;
    scrollbar-color:hsl(var(--muted) / .55) hsl(var(--surface-raised));
    box-shadow:inset -13px 0 12px -14px hsl(var(--ink) / .5);
}
.table-scroll-region:focus-visible { outline:2px solid #3451d1; outline-offset:2px; }
.table-scroll-region::-webkit-scrollbar { height:7px; }
.table-scroll-region::-webkit-scrollbar-track { background:hsl(var(--surface-raised)); }
.table-scroll-region::-webkit-scrollbar-thumb { border:1px solid hsl(var(--surface)); border-radius:99px; background:hsl(var(--muted) / .55); }
.data-table-scroll-region { max-height:none !important; }
.table-scroll-region table { margin:0; border-collapse:separate; border-spacing:0; }
.data-table-scroll-region table { min-width:1120px; }
.table-scroll-region th,
.table-scroll-region td { min-height:44px; padding:10px 12px; border-bottom:1px solid hsl(var(--line)); vertical-align:middle; }
.table-scroll-region thead th { position:sticky; top:0; z-index:2; color:hsl(var(--muted)); background:hsl(var(--surface-raised)); font-size:.69rem; font-weight:600; letter-spacing:.015em; white-space:nowrap; }
.table-scroll-region tbody tr:nth-child(even) { background:hsl(var(--surface-raised) / .38); }
.table-scroll-region tbody tr:hover { background:#eff6ff; }
.table-scroll-region tbody tr[aria-selected="true"],
.table-scroll-region tbody tr.selected { background:#eaf0ff; }
.table-scroll-region th:first-child,
.table-scroll-region td:first-child { position:static !important; left:auto !important; z-index:auto; box-shadow:none !important; }
.data-table-scroll-region #dataTable { min-width:1120px; }
.data-table-scroll-region #dataTable [data-column-index="1"] { min-width:150px; }
.data-table-scroll-region #dataTable [data-column-index="2"] { min-width:85px; }
.data-table-scroll-region #dataTable [data-column-index="3"] { min-width:105px; }
.data-table-scroll-region #dataTable [data-column-index="4"] { min-width:72px; }
.data-table-scroll-region #dataTable [data-column-index="5"] { min-width:140px; }
.data-table-scroll-region #dataTable th.column-hidden,
.data-table-scroll-region #dataTable td.column-hidden { display:none !important; }
.data-table-scroll-region #dataTable th.column-visible,
.data-table-scroll-region #dataTable td.column-visible { display:table-cell !important; }
.timestamp-compact { white-space:nowrap; font-variant-numeric:tabular-nums; }
.pagination { display:flex; flex-wrap:nowrap; align-items:center; gap:4px; }
.pagination-mobile-summary { display:none; }
.pagination .page-link { display:flex; align-items:center; gap:5px; }
.pagination .page-link svg { display:none; width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }

:where(button, a, input, select, textarea, [tabindex="0"]):focus-visible {
    outline:2px solid #3451d1;
    outline-offset:2px;
}

html[data-bs-theme="dark"] .workspace-commandbar,
html[data-bs-theme="dark"] .status-popover,
html[data-bs-theme="dark"] .user-menu-popover { background:hsl(var(--surface)); }
html[data-bs-theme="dark"] .system-status[data-status="error"] { color:#fecaca; border-color:#7f1d1d; background:#450a0a; }
html[data-bs-theme="dark"] .system-status[data-status="warning"] { color:#fde68a; border-color:#78350f; background:#451a03; }
html[data-bs-theme="dark"] .sidebar .nav-link.active { color:#bfccff; background:#1c2a50; box-shadow:inset 2px 0 #8ba2ff; }
html[data-bs-theme="dark"] .risk-legend-row:hover { border-color:#40569c; background:#1d2a49; }
html[data-bs-theme="dark"] .table-scroll-region tbody tr:hover { background:#1a2946; }
html[data-bs-theme="dark"] .table-scroll-region tbody tr[aria-selected="true"],
html[data-bs-theme="dark"] .table-scroll-region tbody tr.selected { background:#202e51; }
html[data-bs-theme="dark"] .attention-other { background:#475569; }
html[data-bs-theme="dark"] .risk-summary-pill { filter:saturate(.9); }
html[data-bs-theme="dark"] .attention-count:first-child,
html[data-bs-theme="dark"] .stat-context.text-danger { color:#fca5a5 !important; }
html[data-bs-theme="dark"] .attention-count:nth-child(2),
html[data-bs-theme="dark"] .stat-context.text-success { color:#fdba74 !important; }
html[data-bs-theme="dark"] :where(button, a, input, select, textarea, [tabindex="0"]):focus-visible { outline-color:#9db1ff; }

@media (max-width:767.98px) {
    .workspace-mobile-leading { display:flex; min-width:0; align-items:center; gap:7px; }
    .workspace-mobile-leading .mobile-menu-button { display:grid; place-items:center; width:34px; height:34px; }
    .mobile-brand { display:flex; min-width:0; align-items:center; gap:7px; overflow:hidden; color:hsl(var(--ink)); font-size:.84rem; font-weight:650; white-space:nowrap; }
    .mobile-brand .brand-mark { width:27px; height:27px; flex:0 0 27px; }
    .command-search { display:none; }
    .workspace-mobile-actions { gap:7px; }
    .command-search-trigger { display:grid; place-items:center; width:32px; height:32px; }
    .workspace-mobile-actions .command-control svg,
    .mobile-menu-button svg { width:18px; height:18px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
    .system-status { width:28px; min-width:28px; min-height:30px; padding:0; border:0; background:transparent; }
    .system-status .status-label { display:none; }
    .status-dot { width:8px; height:8px; flex-basis:8px; }
    .user-menu { display:none !important; }
    .workspace-commandbar.search-open .command-search {
        position:fixed;
        z-index:1080;
        top:62px;
        left:12px;
        right:12px;
        display:flex;
        width:auto;
        max-width:none;
        margin:0;
        background:hsl(var(--surface));
        box-shadow:0 12px 32px rgb(15 23 42 / .18);
    }
    .sidebar .rail-theme-toggle { display:flex; }
    .page-heading { align-items:flex-start; flex-wrap:wrap; gap:8px 12px; margin-bottom:12px; }
    .page-heading h2 { font-size:24px; }
    .page-heading .page-subtitle { margin-top:3px; font-size:.77rem; }
    .page-heading > div:first-child { min-width:0; flex:1 1 auto; }
    .page-heading-actions { width:auto; min-width:0; flex:0 0 auto; flex-direction:row; align-items:center; }
    .overview-page-heading { display:grid; grid-template-columns:minmax(0,1fr) auto; grid-template-areas:"title actions" "subtitle subtitle"; align-items:center; gap:5px 8px; }
    .overview-page-heading > div:first-child { display:contents; }
    .overview-page-heading h2 { grid-area:title; }
    .overview-page-heading .page-subtitle { grid-area:subtitle; min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
    .overview-page-heading .page-heading-actions { grid-area:actions; }
    .overview-heading-actions { gap:5px; }
    .overview-heading-actions .segmented-control { flex:0 0 auto; }
    .overview-heading-actions .segmented-control button { min-width:32px; padding:4px 8px; }
    .overview-heading-actions > .refresh-button { width:36px; flex:0 0 36px; }
    .overview-desktop-subtitle { display:none; }
    .chart-row { margin-top:10px !important; }
    .chart-row > [class*="col-"] { margin-bottom:10px; }
    .chart-card-heading { min-height:52px; }
    .risk-legend { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .table-scroll-region { max-height:none !important; overflow-y:visible !important; }
    .data-table-scroll-region { max-height:none !important; }
    .data-table-scroll-region #dataTable { min-width:1120px; }
    .pagination { justify-content:center; }
    .pagination .page-number { display:none; }
    .pagination-mobile-summary { display:list-item; }
    .pagination-previous .page-link,
    .pagination-next .page-link { min-width:36px; min-height:36px; justify-content:center; padding:7px; }
    .pagination-previous .page-link svg,
    .pagination-next .page-link svg { display:block; }
    .pagination-link-label { display:none; }
}
@media (max-width:420px) {
    .workspace-mobile-actions { gap:5px; }
    .mobile-brand { font-size:.8rem; }
    .risk-legend-row { padding:6px; font-size:.69rem; }
}
@media (prefers-reduced-motion:reduce) {
    *, *::before, *::after { scroll-behavior:auto !important; animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/* Report review refinements: consistent grids, resolvable popovers, and a focused detail sheet. */
.dashboard-charts-grid {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:16px;
    width:100%;
    margin:16px 0 0;
}
.dashboard-charts-grid > .card { width:100%; min-width:0; margin:0; }
.dashboard-charts-grid .chart-container { min-width:0; max-width:100%; }

.stats-summary-grid,
.stats-chart-grid,
.stats-contact-grid,
.stats-extra-grid {
    display:grid !important;
    width:100%;
    margin:0 0 20px !important;
    --bs-gutter-x:0;
    --bs-gutter-y:0;
}
.stats-summary-grid { grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; }
.stats-chart-grid,
.stats-contact-grid,
.stats-extra-grid { grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.stats-summary-grid > [class*="col-"],
.stats-chart-grid > [class*="col-"],
.stats-contact-grid > [class*="col-"],
.stats-extra-grid > [class*="col-"] {
    width:auto;
    min-width:0;
    padding:0;
    display:flex;
}
.stats-summary-grid .card,
.stats-chart-grid .card,
.stats-contact-grid .card,
.stats-extra-grid .card { width:100%; height:100%; margin:0; }
.stats-kpi-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); }
.stats-kpi-cell {
    display:flex;
    min-width:0;
    min-height:62px;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    border-right:1px solid hsl(var(--line));
}
.stats-kpi-cell:last-child { border-right:0; }
.stats-kpi-cell h3 { color:hsl(var(--ink)) !important; font-variant-numeric:tabular-nums; }
.stats-kpi-cell small { color:hsl(var(--muted)) !important; }

.risk-chart-layout {
    display:grid !important;
    grid-template-columns:minmax(0,1fr) !important;
    gap:10px !important;
    min-width:0;
}
.risk-legend {
    display:grid !important;
    grid-template-columns:repeat(5,minmax(0,1fr));
    align-items:stretch;
    gap:6px;
    width:100%;
    min-width:0;
}
.risk-legend-row {
    display:flex;
    min-width:0;
    min-height:58px;
    flex-direction:column;
    align-items:center;
    justify-content:center;
    gap:4px;
    padding:5px 2px;
    border-color:hsl(var(--line));
    border-radius:8px;
    text-align:center;
}
.risk-legend-label { display:flex; align-items:center; justify-content:center; gap:4px; min-width:0; white-space:nowrap; font-size:clamp(.55rem,.72vw,.7rem); }
.risk-legend-row b { margin:0; font-size:.78rem; font-variant-numeric:tabular-nums; }
.risk-shape--critical { color:#dc2626; }
.risk-shape--high { color:#ea580c; }
.risk-shape--medium { color:#ca8a04; }
.risk-shape--low { color:#16a34a; }
.risk-shape--unknown { color:#3b82f6; }

.risk-summary-pill {
    border:0;
    font-weight:600;
}
.risk-summary-pill.risk-critical { color:#b91c1c; background:#fee2e2; }
.risk-summary-pill.risk-high { color:#c2410c; background:#ffedd5; }
.risk-summary-pill.risk-medium { color:#854d0e; background:#fef3c7; }
.risk-summary-pill.risk-low { color:#15803d; background:#dcfce7; }
.risk-summary-pill::before { margin-right:1px; }
html[data-bs-theme="dark"] .risk-summary-pill.risk-critical { color:#fecaca; background:rgb(220 38 38 / .22); }
html[data-bs-theme="dark"] .risk-summary-pill.risk-high { color:#fed7aa; background:rgb(234 88 12 / .2); }
html[data-bs-theme="dark"] .risk-summary-pill.risk-medium { color:#fde68a; background:rgb(202 138 4 / .2); }
html[data-bs-theme="dark"] .risk-summary-pill.risk-low { color:#bbf7d0; background:rgb(22 163 74 / .2); }

.recent-report-actions { display:flex; align-items:center; gap:8px; }
.report-view-toggle { display:inline-flex; align-items:center; gap:2px; padding:3px; border:1px solid hsl(var(--line)); border-radius:8px; background:hsl(var(--surface-raised)); }
.report-view-toggle button {
    display:grid;
    width:32px;
    height:30px;
    place-items:center;
    padding:0;
    border:0;
    border-radius:6px;
    color:hsl(var(--muted));
    background:transparent;
}
.report-view-toggle button.active { color:#3451d1; background:hsl(var(--surface)); box-shadow:0 1px 2px hsl(var(--shadow) / .12); }
.report-view-toggle svg { width:16px; height:16px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
[data-report-grid][hidden],
[data-report-list][hidden] { display:none !important; }
.report-grid {
    display:grid;
    grid-template-columns:repeat(auto-fill,minmax(min(280px,100%),1fr));
    grid-auto-rows:1fr;
    gap:12px;
    width:100%;
    min-width:0;
}
.report-grid-card {
    display:flex;
    min-width:0;
    min-height:180px;
    height:100%;
    flex-direction:column;
    padding:14px;
    border:1px solid hsl(var(--line));
    border-radius:10px;
    background:hsl(var(--surface));
    cursor:pointer;
    transition:border-color .16s ease, background-color .16s ease;
}
.report-grid-card:hover,
.report-grid-card.is-selected { border-color:#a8b8f3; background:hsl(var(--accent) / .055); }
.report-grid-open {
    display:flex;
    min-width:0;
    width:100%;
    flex:1;
    flex-direction:column;
    align-items:stretch;
    padding:0;
    border:0;
    color:hsl(var(--ink));
    background:transparent;
    text-align:left;
}
.report-grid-open:focus-visible { outline:2px solid #3451d1; outline-offset:3px; border-radius:5px; }
.report-grid-card-top { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.report-grid-score { color:hsl(var(--ink)); font-variant-numeric:tabular-nums; }
.report-grid-company { display:block; margin:12px 0 5px; overflow:hidden; color:hsl(var(--ink)); font-size:.98rem; font-weight:650; text-overflow:ellipsis; white-space:nowrap; }
.report-grid-meta { display:flex; align-items:center; gap:5px; margin:0; overflow:hidden; color:hsl(var(--muted)); font-size:.73rem; white-space:nowrap; }
.report-grid-meta > * { min-width:0; overflow:hidden; text-overflow:ellipsis; }
.report-grid-badges { display:flex; flex-wrap:wrap; gap:6px; margin-top:10px; }
.report-grid-thumbnail {
    display:grid;
    min-height:64px;
    max-height:110px;
    place-items:center;
    margin-top:auto;
    padding:7px 0 0;
    border:0;
    color:hsl(var(--muted));
    background:transparent;
    text-align:center;
    font-size:.72rem;
}
.report-grid-thumbnail img { display:block; max-width:100%; max-height:98px; border-radius:7px; object-fit:contain; }
.report-grid-thumbnail.is-unavailable { width:100%; }
.report-grid-empty { grid-column:1/-1; padding:24px; color:hsl(var(--muted)); text-align:center; }

.data-popover { position:relative; }
.data-popover > summary { list-style:none; cursor:pointer; }
.data-popover > summary::-webkit-details-marker { display:none; }
.data-popover-backdrop { display:none; }
.data-popover-panel {
    position:absolute;
    z-index:1060;
    top:calc(100% + 8px);
    right:0 !important;
    left:auto !important;
    max-width:calc(100vw - 24px);
    max-height:calc(100dvh - 24px);
    overflow:auto;
    transform:none;
}
.data-popover-panel[data-flipped="true"] { top:auto; bottom:calc(100% + 8px); }
.date-filter-panel.data-popover-panel { width:245px; }
.column-chooser-panel.data-popover-panel { width:210px; }
.export-popover-panel.data-popover-panel { display:flex; width:220px; flex-direction:column; gap:3px; padding:8px; }
.data-popover-heading { display:flex; min-height:32px; align-items:center; justify-content:space-between; gap:8px; margin-bottom:8px; color:hsl(var(--ink)); font-size:.82rem; }
.data-popover-close { display:grid; width:32px; height:32px; flex:none; place-items:center; border:0; border-radius:7px; color:hsl(var(--muted)); background:transparent; font-size:1.25rem; line-height:1; }
.data-popover-close:hover { color:hsl(var(--ink)); background:hsl(var(--surface-raised)); }
.data-popover-option { display:flex; min-height:40px; align-items:center; padding:8px 10px; border:0; border-radius:7px; color:hsl(var(--ink)); background:transparent; text-align:left; }
.data-popover-option:hover { background:hsl(var(--accent) / .08); }

.report-detail-dialog.modal-dialog { width:min(720px,calc(100vw - 32px)); max-width:720px; }
.report-detail-dialog .modal-content { overflow:hidden; border:1px solid hsl(var(--line)); border-radius:16px; background:hsl(var(--surface)); }
.report-detail-toolbar {
    position:sticky;
    top:0;
    z-index:3;
    display:grid;
    grid-template-columns:40px 1fr 40px 40px;
    align-items:center;
    gap:6px;
    padding:10px 12px;
    border:0;
    background:hsl(var(--surface));
}
.report-detail-position { min-height:1px; }
.report-detail-nav,
.report-detail-close {
    display:grid;
    width:38px;
    height:38px;
    place-items:center;
    padding:0;
    border:1px solid hsl(var(--line));
    border-radius:8px;
    color:hsl(var(--muted));
    background:hsl(var(--surface));
}
.report-detail-nav:disabled { opacity:.38; }
.report-detail-nav svg,
.report-detail-close svg { width:17px; height:17px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.report-detail-close { grid-column:4; }
.report-detail-body { padding:2px 24px 22px; }
.report-detail-hero { max-width:620px; margin:0 auto 8px; padding:2px 0 12px; border-bottom:1px solid hsl(var(--line)); text-align:center; }
.report-detail-badges { display:flex; justify-content:center; align-items:center; gap:7px; }
.report-detail-hero .modal-title { margin:12px 0 5px; color:hsl(var(--ink)); font-size:1.25rem; font-weight:700; overflow-wrap:anywhere; }
.report-detail-time { color:hsl(var(--muted)); font-size:.76rem; }
.report-detail-score { display:flex; max-width:340px; flex-direction:column; align-items:center; gap:7px; margin:12px auto 0; }
.report-detail-score strong { color:hsl(var(--ink)); font-size:2.15rem; font-variant-numeric:tabular-nums; line-height:1; }
.report-detail-score progress { width:100%; height:4px; overflow:hidden; border:0; border-radius:99px; accent-color:#3451d1; background:hsl(var(--surface-raised)); }
.report-detail-score progress::-webkit-progress-bar { border-radius:99px; background:hsl(var(--surface-raised)); }
.report-detail-score progress::-webkit-progress-value { border-radius:99px; background:#3451d1; }
.report-detail-score progress::-moz-progress-bar { border-radius:99px; background:#3451d1; }
#reportDetailContent { max-width:620px; margin:0 auto; }
.report-detail-info-grid {
    display:block;
    overflow:hidden;
    border:1px solid hsl(var(--line));
    border-radius:10px;
    background:hsl(var(--surface));
}
.report-detail-info-grid[hidden] { display:none; }
.report-detail-info-grid > .report-detail-group {
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    margin:0;
    padding:0;
    border:0;
}
.report-detail-info-grid > .report-detail-group[hidden] { display:none; }
.report-detail-info-grid .report-detail-group h6 {
    grid-column:1 / -1;
    margin:0;
    padding:7px 11px;
    border-bottom:1px solid hsl(var(--line));
    color:hsl(var(--muted));
    background:hsl(var(--surface-raised));
    font-size:.7rem;
    font-weight:650;
    letter-spacing:.015em;
    text-align:left;
}
.report-detail-info-grid .report-detail-grid {
    display:grid;
    grid-column:1 / -1;
    grid-template-columns:repeat(2,minmax(0,1fr));
    margin:0;
    overflow:visible;
    border:0;
    border-radius:0;
}
.report-detail-info-grid .report-detail-field {
    display:grid;
    min-width:0;
    grid-template-columns:minmax(74px,.72fr) minmax(0,1.28fr);
    align-items:start;
    gap:8px;
    padding:8px 11px;
    border-bottom:1px solid hsl(var(--line) / .78);
}
.report-detail-info-grid .report-field-wide { grid-column:1 / -1; grid-template-columns:minmax(96px,140px) minmax(0,1fr); }
.report-detail-info-grid .report-detail-field dt { margin:0; color:hsl(var(--muted)); font-size:.72rem; font-weight:550; letter-spacing:0; text-transform:none; }
.report-detail-info-grid .report-detail-field dd { display:flex; min-width:0; align-items:flex-start; justify-content:flex-start; gap:4px; flex-wrap:wrap; margin:0; overflow-wrap:anywhere; }
.report-field-value { min-width:0; color:hsl(var(--ink)); text-align:left; white-space:pre-wrap; overflow-wrap:anywhere; }
.report-detail-info-grid .report-inline-link,
.report-detail-info-grid .report-url-list { grid-column:1 / -1; padding:7px 11px; }
.report-detail-info-grid .report-url-list { display:flex; flex-direction:column; gap:5px; margin:0; overflow-wrap:anywhere; }
.report-detail-info-grid .report-url-list a { color:hsl(var(--accent)); font-size:.76rem; overflow-wrap:anywhere; }
.report-detail-info-grid .report-inline-link { color:hsl(var(--accent)); font-size:.76rem; }
.report-detail-info-grid .report-detail-field:last-child { border-bottom:0; }
.report-detail-group[hidden] { display:none; }
.report-field-pre,
.report-extracted-text {
    width:100%;
    max-height:112px;
    overflow:auto;
    margin:0;
    padding:8px;
    border:1px solid hsl(var(--line));
    border-radius:7px;
    color:hsl(var(--ink));
    background:hsl(var(--surface-raised));
    font-family:var(--font-ui);
    font-size:.8rem;
    line-height:1.55;
    text-align:left;
    white-space:pre-wrap;
    overflow-wrap:anywhere;
}
.report-copy-button {
    display:inline-grid;
    width:30px;
    height:30px;
    flex:none;
    place-items:center;
    padding:0;
    border:0;
    border-radius:6px;
    color:hsl(var(--muted));
    background:transparent;
}
.report-copy-button:hover { color:#3451d1; background:hsl(var(--accent) / .08); }
.report-copy-button.is-copied { color:#15803d; }
.report-copy-button svg { width:15px; height:15px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.report-copy-actions { display:flex; justify-content:flex-start; margin-top:3px; }
.report-extracted-section { margin:10px 0 0; padding:10px 0 0; border-top:1px solid hsl(var(--line)); text-align:left; }
.report-extracted-section h6 { margin:0 0 6px; font-size:.8rem; text-align:left; }
.report-text-meta { margin:8px 0 12px; text-align:left; }
.report-text-meta details { display:inline-block; margin-top:4px; text-align:left; color:hsl(var(--muted-ink)); }
.report-text-meta summary { cursor:pointer; }
.report-text-meta ul { margin:8px 0 0; padding-left:20px; }
.report-url-list { display:flex; flex-direction:column; gap:6px; margin-top:8px; overflow-wrap:anywhere; }
.report-url-list a { color:#3451d1; font-size:.76rem; overflow-wrap:anywhere; }
.report-screenshot-section {
    display:grid;
    grid-template-columns:minmax(0,1fr) 112px;
    grid-template-areas:"title image" "subtitle image" "link image";
    align-items:center;
    gap:2px 12px;
    margin:0 0 10px;
    padding:2px 0 10px;
    border-bottom:1px solid hsl(var(--line));
    text-align:left;
}
.report-screenshot-section h6 { grid-area:title; margin:0; font-size:.8rem; text-align:left; }
.report-screenshot-section .report-section-subtitle { grid-area:subtitle; margin:0; color:hsl(var(--muted)); font-size:.72rem; }
.report-screenshot-section .report-inline-link { grid-area:link; justify-self:start; font-size:.74rem; }
.report-screenshot-section .report-no-screenshot { grid-column:1 / -1; color:hsl(var(--muted)); font-size:.76rem; }
.report-screenshot-preview {
    display:grid;
    grid-area:image;
    width:112px;
    height:76px;
    min-height:76px;
    max-height:76px;
    place-items:center;
    overflow:hidden;
    padding:3px;
    border:1px solid hsl(var(--line));
    border-radius:8px;
    background:hsl(var(--surface-raised));
}
.report-screenshot-preview img { display:block; max-width:100%; max-height:68px; border-radius:5px; object-fit:contain; }
.report-screenshot-preview.is-unavailable { color:hsl(var(--muted)); font-size:.8rem; }
.report-no-screenshot { color:hsl(var(--muted)); font-size:.8rem; text-align:center; }
.report-show-empty-fields { display:block; margin:16px auto 0; padding:8px 12px; border:0; color:#3451d1; background:transparent; font-size:.8rem; }
.report-show-empty-fields:hover { text-decoration:underline; text-underline-offset:3px; }
.stat-context,
#attentionPercent,
#comparisonText,
#averageDailyScans,
#locationsCheckedText,
#urlsCheckedText {
    font-size:12px !important;
    line-height:1.35;
}
.chart-card-heading small { font-size:12px; }
.chart-card-heading.has-actions { flex-wrap:wrap; }
.chart-actions { display:flex; max-width:100%; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:4px; }
.chart-actions .btn-sm { min-width:32px; min-height:34px; padding:5px 6px; font-size:12px; line-height:1.2; }
.most-reported-label { margin-bottom:9px; font-size:12px; font-weight:650; }
.stats-summary-label { margin:0 0 8px; color:hsl(var(--muted)); font-size:.88rem; font-weight:600; }
.stats-summary-value { margin:0 0 4px; color:hsl(var(--ink)); font-size:2rem; font-weight:700; font-variant-numeric:tabular-nums; line-height:1.15; }
.stats-contact-heading { margin:0; color:hsl(var(--ink)); font-size:.95rem; font-weight:650; }
.stats-contact-value { display:block; color:hsl(var(--ink)) !important; font-size:1.35rem; font-weight:650; font-variant-numeric:tabular-nums; line-height:1.25; }
html[data-bs-theme="dark"] .report-grid-card:hover,
html[data-bs-theme="dark"] .report-grid-card.is-selected { border-color:#5269a9; background:#1b2a4d; }
html[data-bs-theme="dark"] .report-copy-button.is-copied { color:#86efac; }

@media (min-width:768px) and (max-width:1199.98px) {
}
@media (max-width:767.98px) {
    .dashboard-charts-grid { grid-template-columns:minmax(0,1fr); gap:12px; }
    .stats-summary-grid { grid-template-columns:minmax(0,1fr); gap:10px; }
    .stats-chart-grid,
    .stats-contact-grid,
    .stats-extra-grid { grid-template-columns:minmax(0,1fr); gap:12px; }
    .risk-legend { grid-template-columns:repeat(5,minmax(0,1fr)); gap:4px; }
    .risk-legend-row { min-height:54px; }
    .risk-legend-label { gap:2px; font-size:.56rem; }
    .risk-legend-row b { font-size:.7rem; }
    .report-grid { grid-template-columns:minmax(0,1fr); grid-auto-rows:1fr; }
    .recent-report-actions { gap:5px; }
}
@media (max-width:575.98px) {
    .data-popover-backdrop {
        position:fixed;
        inset:0;
        z-index:1055;
        display:none;
        width:100vw;
        height:100dvh;
        padding:0;
        border:0;
        background:rgb(15 23 42 / .4);
    }
    .data-popover[open] > .data-popover-backdrop { display:block; }
    .data-popover-panel,
    .date-filter-panel.data-popover-panel,
    .column-chooser-panel.data-popover-panel,
    .export-popover-panel.data-popover-panel {
        position:fixed;
        inset:auto 0 0;
        z-index:1056;
        width:100%;
        max-width:none;
        max-height:min(78dvh,620px);
        overflow:auto;
        padding:18px 16px max(18px,env(safe-area-inset-bottom));
        border:1px solid hsl(var(--line));
        border-radius:18px 18px 0 0;
        background:hsl(var(--surface));
        box-shadow:0 -12px 36px hsl(var(--shadow) / .18);
        transform:none;
    }
    .data-popover-heading { min-height:40px; font-size:.9rem; }
    .data-popover-close { width:40px; height:40px; }
    .export-popover-panel { gap:6px !important; }
    .data-popover-option { min-height:46px; }
    .report-detail-dialog.modal-dialog { width:100vw; max-width:none; height:100dvh; max-height:100dvh; margin:0; }
    .report-detail-dialog .modal-content { width:100%; height:100dvh; max-height:100dvh; border:0; border-radius:0; }
    .report-detail-toolbar { padding:calc(8px + env(safe-area-inset-top)) 12px 8px; }
    .report-detail-body { height:calc(100dvh - 58px); overflow:auto; padding:8px 16px max(24px,env(safe-area-inset-bottom)); }
    .report-detail-hero { padding-top:4px; }
    .report-detail-score strong { font-size:1.95rem; }
    .report-detail-info-grid > .report-detail-group,
    .report-detail-info-grid .report-detail-grid { grid-template-columns:minmax(0,1fr); }
    .report-detail-info-grid .report-detail-field,
    .report-detail-info-grid .report-field-wide { grid-template-columns:minmax(88px,.42fr) minmax(0,1fr); }
    .report-screenshot-section { grid-template-columns:minmax(0,1fr) 92px; gap:2px 9px; }
    .report-screenshot-preview { width:92px; height:68px; min-height:68px; max-height:68px; }
    .report-screenshot-preview img { max-height:60px; }
}

.archive-import-card { margin:0 0 18px; }
.archive-import-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; }
.archive-import-heading h3 { margin:0 0 5px; color:hsl(var(--ink)); font-size:1.05rem; font-weight:700; }
.archive-import-heading p { max-width:680px; font-size:.84rem; }
.archive-import-message { margin-top:14px; padding:10px 12px; border-radius:8px; }
.archive-import-summary { margin-top:16px; }
.archive-import-metrics { display:grid; grid-template-columns:repeat(auto-fit,minmax(125px,1fr)); gap:8px; }
.archive-import-metric { display:flex; min-height:68px; flex-direction:column; justify-content:center; gap:4px; padding:10px 12px; border:1px solid hsl(var(--line)); border-radius:9px; background:hsl(var(--surface-raised)); }
.archive-import-metric span { color:hsl(var(--muted)); font-size:.72rem; }
.archive-import-metric strong { color:hsl(var(--ink)); font-size:1.12rem; font-variant-numeric:tabular-nums; }
.archive-import-breakdowns { display:grid; grid-template-columns:minmax(180px,.7fr) minmax(260px,1.3fr); gap:14px; margin-top:14px; }
.archive-import-breakdowns section { min-width:0; padding:12px; border:1px solid hsl(var(--line)); border-radius:9px; }
.archive-import-breakdowns h4, .archive-import-verification h4 { margin:0 0 8px; color:hsl(var(--muted)); font-size:.76rem; font-weight:700; }
.archive-import-days { max-height:260px; overflow:auto; }
.archive-import-table { margin:0; font-size:.78rem; }
.archive-import-table > :not(caption) > * > * { padding:5px 7px; }
.archive-import-confirm { display:flex; align-items:end; gap:10px; max-width:680px; margin-top:16px; }
.archive-import-confirm label { display:grid; gap:4px; color:hsl(var(--muted)); font-size:.78rem; }
.archive-import-confirm .form-control { max-width:180px; }
.archive-import-progress { display:grid; gap:10px; margin-top:16px; }
.archive-import-progress-bar { width:100%; height:10px; accent-color:#3451d1; }
.archive-import-images { font-size:.78rem; }
.archive-import-verification { margin-top:8px; padding:12px; border:1px solid hsl(var(--line)); border-radius:9px; }
.archive-import-verification summary { margin-bottom:12px; cursor:pointer; color:hsl(var(--ink)); font-weight:600; }
.archive-import-verification h4:not(:first-child) { margin-top:14px; }
html[data-bs-theme="dark"] .archive-import-metric { background:hsl(var(--surface-raised)); }
@media (max-width:767.98px) {
    .archive-import-heading { flex-direction:column; }
    .archive-import-heading > button { width:100%; }
    .archive-import-breakdowns { grid-template-columns:minmax(0,1fr); }
    .archive-import-confirm { align-items:stretch; flex-direction:column; }
    .archive-import-confirm .form-control { max-width:none; }
}
