:root {
  color-scheme: dark;
  --canvas: #060e1c;
  --sidebar: #071323;
  --panel: #0b1728;
  --panel-raised: #0e1c30;
  --panel-hover: #11233a;
  --ink: #e8f0fa;
  --muted: #91a2b9;
  --line: #1c304a;
  --line-bright: #29415e;
  --cyan: #20c8f4;
  --blue: #168cf0;
  --green: #16d49a;
  --amber: #ffbd2e;
  --red: #ff526a;
  font-family: "Segoe UI", Arial, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; scroll-padding-top: 1.25rem; }
body { margin: 0; min-height: 100vh; background: radial-gradient(ellipse at 78% -15%, #102342 0, transparent 37rem), var(--canvas); color: var(--ink); }
[hidden] { display: none !important; }
button, input, select { font: inherit; }
button, a, input, select { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }

.app-shell { min-height: 100vh; }
.sidebar { position: fixed; z-index: 5; inset: 0 auto 0 0; display: flex; flex-direction: column; width: 250px; padding: 1.25rem 1rem 1rem; border-right: 1px solid var(--line); background: linear-gradient(180deg, #091729 0%, var(--sidebar) 100%); }
.brand { display: flex; align-items: center; gap: .8rem; min-height: 3.3rem; padding: 0 .35rem 1.4rem; border-bottom: 1px solid var(--line); }
.brand-mark { display: grid; width: 2.65rem; height: 2.65rem; place-items: center; border: 1px solid #1c638c; border-radius: 11px; background: linear-gradient(145deg, #0c3150, #10243d); color: var(--cyan); font-size: 1.5rem; font-weight: 800; box-shadow: inset 0 0 18px #0a9aca22; }
.brand-copy { display: grid; gap: .2rem; }
.brand-copy strong { font-size: .85rem; letter-spacing: .035em; }
.brand-copy strong span { color: var(--cyan); }
.brand-copy small { color: #8295ad; font-size: .58rem; font-weight: 700; letter-spacing: .14em; }
.nav-caption { margin: 1.65rem .65rem .55rem; color: #637892; font-size: .64rem; font-weight: 800; letter-spacing: .16em; }
.sidebar-nav { display: grid; gap: .35rem; }
.nav-link { position: relative; display: flex; align-items: center; gap: .75rem; min-height: 2.85rem; padding: .55rem .75rem; border: 1px solid transparent; border-radius: 9px; color: #b8c6d8; font-size: .88rem; font-weight: 600; transition: .18s ease; }
.nav-link:hover { border-color: var(--line); background: #0c1e32; color: var(--ink); }
.nav-link[aria-current="page"] { border-color: #145577; background: linear-gradient(90deg, #0a405e, #0b2942); color: var(--cyan); box-shadow: inset 0 0 22px #087aa51c; }
.nav-link[aria-current="page"]::before { position: absolute; inset: .5rem auto .5rem -1px; width: 3px; border-radius: 0 4px 4px 0; background: var(--cyan); content: ""; }
.nav-icon { display: grid; width: 1.25rem; place-items: center; color: #9fb1c8; font-size: 1.12rem; line-height: 1; }
.nav-link[aria-current="page"] .nav-icon { color: var(--cyan); }
.detail-nav { min-height: 0; flex: 1 1 auto; overflow-y: auto; }
.detail-nav .nav-caption { margin-top: 1.4rem; }
.standalone-nav { flex: 0 0 auto; }
.standalone-nav .nav-caption { margin-top: 1.15rem; }
.detail-sidebar-nav { gap: .22rem; }
.detail-report-link { min-height: 2.5rem; padding: .42rem .5rem; gap: .45rem; font-size: .73rem; line-height: 1.3; }
.detail-report-link .nav-icon { width: 1rem; font-size: .95rem; }
.sidebar-bottom { margin-top: auto; }
.system-state { display: flex; align-items: center; gap: .55rem; padding: .7rem .75rem; border: 1px solid #17463f; border-radius: 9px; background: #092520; color: #a9dece; font-size: .75rem; }
.system-state strong { margin-left: auto; color: var(--green); font-size: .63rem; letter-spacing: .1em; }
.state-light, .dot { width: .48rem; height: .48rem; flex: 0 0 auto; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px #16d49a99; }
.sidebar-bottom p { margin: .9rem .55rem 0; color: #647892; font-size: .7rem; }

.main-shell { min-height: 100vh; margin-left: 250px; }
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 82px; padding: .8rem clamp(1.25rem, 3vw, 3rem); border-bottom: 1px solid #1b2d44; background: #071222b8; backdrop-filter: blur(12px); }
.topbar-context .eyebrow { margin-bottom: .25rem; }
.topbar h1 { margin: 0; color: #cbd8e8; font-size: .92rem; font-weight: 600; letter-spacing: .015em; }
.eyebrow { margin: 0 0 .42rem; color: var(--cyan); font-size: .66rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.eyebrow-divider { padding: 0 .2rem; color: #51657f; }
.topbar-right { display: flex; align-items: center; gap: .75rem; }
.local-badge { display: inline-flex; align-items: center; gap: .5rem; padding: .52rem .75rem; border: 1px solid #263b55; border-radius: 999px; background: #0b192b; color: #bbcadb; font-size: .72rem; font-weight: 700; white-space: nowrap; }
.local-badge .dot { width: .42rem; height: .42rem; }
.page { width: min(1680px, calc(100% - clamp(2rem, 5vw, 5rem))); margin: 0 auto; padding: 2rem 0 3rem; }
.overview-section { scroll-margin-top: 1rem; }
h2 { margin: 0; color: var(--ink); font-size: clamp(1.35rem, 2vw, 1.7rem); letter-spacing: -.025em; }
h3 { color: var(--ink); }
.welcome-row, .section-heading { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.welcome-row { align-items: flex-end; margin-bottom: 1.15rem; }
.welcome-description { margin: .48rem 0 0; color: var(--muted); font-size: .87rem; }
.muted, .scope-note { color: var(--muted); line-height: 1.55; }
.scope-note { padding: .78rem 1rem; margin: 0 0 1.1rem; border: 1px solid #1c3951; border-left: 3px solid #168bb1; border-radius: 8px; background: #0a1a2a; font-size: .8rem; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: .45rem; min-height: 2.45rem; padding: .58rem .9rem; border: 1px solid transparent; border-radius: 8px; font-size: .8rem; font-weight: 750; cursor: pointer; transition: .18s ease; }
.button:disabled { cursor: default; opacity: .45; }
.button-primary { border-color: #168af0; background: linear-gradient(110deg, #078ec8, #1477e9); color: white; box-shadow: 0 5px 16px #087be52b; }
.button-primary:hover:not(:disabled) { filter: brightness(1.12); transform: translateY(-1px); }
.button-secondary { border-color: #275071; background: #0c263c; color: #72d8f2; }
.button-secondary:hover:not(:disabled) { border-color: #2185ab; background: #0d314a; }
.button-quiet { border-color: #334962; background: #112139; color: #c5d2e1; }
.button-quiet:hover { background: #1a2d47; }
.button-danger { border-color: #682c3c; background: #321923; color: #ff9ba9; }
.button-quiet-light { border: 1px solid var(--line-bright); background: #0d1a2c; color: #c4d3e6; }
.button-quiet-light:hover:not(:disabled) { border-color: #3d668a; background: #12243a; }

.summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .85rem; }
.summary-card { position: relative; min-height: 111px; overflow: hidden; padding: 1rem 1.05rem; border: 1px solid var(--line); border-radius: 12px; background: linear-gradient(145deg, #0d1b2d, #0a1626); box-shadow: 0 9px 25px #02091424; }
.summary-card::after { position: absolute; right: -1.2rem; bottom: -2rem; width: 6rem; height: 6rem; border-radius: 50%; background: var(--card-glow, #168cf0); content: ""; filter: blur(42px); opacity: .15; }
.summary-label { position: relative; z-index: 1; display: flex; justify-content: space-between; align-items: center; gap: .5rem; color: #a2b3c8; font-size: .7rem; font-weight: 750; letter-spacing: .075em; text-transform: uppercase; }
.summary-icon { color: var(--card-color, var(--cyan)); font-size: 1rem; }
.summary-value { position: relative; z-index: 1; margin-top: .65rem; color: var(--card-color, var(--cyan)); font-size: 1.9rem; font-weight: 800; letter-spacing: -.045em; line-height: 1; font-variant-numeric: tabular-nums; }
.summary-detail { position: relative; z-index: 1; margin-top: .45rem; color: #8295ad; font-size: .71rem; }
.tone-good { --card-color: var(--green); --card-glow: var(--green); }
.tone-warn { --card-color: var(--amber); --card-glow: var(--amber); }
.tone-danger { --card-color: var(--red); --card-glow: var(--red); }
.tone-info { --card-color: #25bafa; --card-glow: #168cf0; }

.health-panel { display: grid; grid-template-columns: minmax(0, 1fr) 132px minmax(140px, .4fr); align-items: center; gap: 1.5rem; min-height: 174px; padding: 1.2rem clamp(1rem, 2vw, 1.8rem); margin: 1rem 0 2rem; border: 1px solid #203b57; border-radius: 14px; background: radial-gradient(ellipse at 79% 50%, #10304477 0, transparent 33rem), linear-gradient(115deg, #0a1b2d, #0b1728); box-shadow: 0 12px 32px #0209142b; }
.health-copy h2 { font-size: 1.2rem; }
.health-copy .muted { max-width: 650px; margin: .45rem 0 0; font-size: .82rem; }
.health-breakdown { margin-top: .75rem; color: #92a5bc; font-size: .76rem; }
.health-ring { --ring-progress: 0%; --ring-color: var(--green); position: relative; display: grid; width: 122px; aspect-ratio: 1; place-items: center; border-radius: 50%; background: conic-gradient(var(--ring-color) 0 var(--ring-progress), #172940 var(--ring-progress) 100%); filter: drop-shadow(0 0 13px color-mix(in srgb, var(--ring-color) 17%, transparent)); }
.health-ring::before { position: absolute; inset: 9px; border: 1px solid #233952; border-radius: 50%; background: #091526; content: ""; }
.ring-center { position: relative; display: grid; justify-items: center; gap: .2rem; }
.ring-center strong { color: var(--ink); font-size: 1.42rem; font-variant-numeric: tabular-nums; }
.ring-center span { color: #91a3ba; font-size: .57rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.health-legend { display: grid; justify-content: end; gap: .62rem; color: #a5b4c7; font-size: .74rem; }
.health-legend span { display: flex; align-items: center; gap: .5rem; }
.legend-dot { width: .48rem; height: .48rem; border-radius: 50%; }
.legend-good { background: var(--green); box-shadow: 0 0 9px #16d49a77; }
.legend-attention { background: var(--amber); box-shadow: 0 0 9px #ffbd2e66; }

.content-section { margin-top: 2rem; scroll-margin-top: 1rem; }
.section-heading { margin-bottom: .9rem; }
.section-heading h2 { font-size: 1.18rem; }
.section-count { padding: .36rem .6rem; border: 1px solid var(--line); border-radius: 999px; background: #0b182a; color: #91a5bd; font-size: .7rem; white-space: nowrap; }
.source-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(245px, 1fr)); gap: .7rem; }
.source-card { min-width: 0; padding: .85rem .95rem; border: 1px solid var(--line); border-radius: 10px; background: linear-gradient(135deg, #0c192b, #0a1525); transition: border-color .18s ease, transform .18s ease; }
.source-card:hover { border-color: #345272; transform: translateY(-1px); }
.source-top { display: flex; justify-content: space-between; align-items: center; gap: .7rem; }
.source-name { overflow: hidden; color: #dce7f4; font-size: .82rem; font-weight: 700; text-overflow: ellipsis; }
.source-time { margin-top: .5rem; color: #8093aa; font-size: .71rem; }
.status-pill { display: inline-flex; align-items: center; gap: .36rem; padding: .27rem .48rem; border: 1px solid transparent; border-radius: 999px; font-size: .63rem; font-weight: 800; letter-spacing: .035em; white-space: nowrap; }
.status-pill::before { width: .35rem; height: .35rem; border-radius: 50%; background: currentColor; content: ""; }
.status-fresh { border-color: #17614e; background: #0d332d; color: #33dfaa; }
.status-stale { border-color: #654d20; background: #352a17; color: #ffca59; }
.status-missing, .status-unavailable { border-color: #334358; background: #172234; color: #a3b0c1; }
.status-error { border-color: #683141; background: #351b27; color: #ff7285; }
.status-held { border-color: #654d20; background: #352a17; color: #ffca59; }

.metric-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: .85rem; }
.metric-card { overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: linear-gradient(145deg, #0c1a2c, #0a1524); }
.metric-card h3 { display: flex; align-items: center; gap: .55rem; min-height: 47px; margin: 0; padding: .8rem .95rem; border-bottom: 1px solid var(--line); font-size: .81rem; }
.metric-card h3::before { width: .42rem; height: .42rem; border-radius: 2px; background: var(--cyan); box-shadow: 0 0 8px #20c8f477; content: ""; }
.metric-table { width: 100%; border-collapse: collapse; }
.metric-table td { padding: .63rem .95rem; border-bottom: 1px solid #17273b; color: #aebdd0; font-size: .79rem; }
.metric-table tr:last-child td { border-bottom: 0; }
.metric-value { color: #e1edf9 !important; text-align: right; font-variant-numeric: tabular-nums; font-weight: 750; white-space: nowrap; }
.metric-stale { color: #ffc651 !important; }
.empty-state { padding: 1rem; color: var(--muted); font-size: .86rem; }

.details-card, .admin-card, .gemini-chat-card { padding: clamp(1rem, 2vw, 1.35rem); border: 1px solid var(--line); border-radius: 13px; background: linear-gradient(145deg, #0c1a2c, #091525); }
.details-card h2, .admin-card h2 { margin: 0; }
.detail-intro { margin: .55rem 0 1rem; font-size: .8rem; }
.gemini-chat-card { display: flex; flex-direction: column; min-height: min(72vh, 820px); margin-top: 0; }
.gemini-chat-heading { align-items: flex-start; }
.gemini-chat-heading h2 { margin: 0; }
.gemini-chat-heading .detail-intro { margin-bottom: 0; }
.gemini-chat-actions, .gemini-chat-compose-actions { display: flex; align-items: center; gap: .65rem; }
.gemini-connection { padding: .38rem .65rem; border: 1px solid #17614e; border-radius: 999px; background: #0d332d; color: #33dfaa; font-size: .7rem; font-weight: 700; }
.gemini-connection.is-error { border-color: #683141; background: #351b27; color: #ff9ba9; }
.gemini-chat-notice { padding: .7rem .85rem; margin: .4rem 0 .9rem; border: 1px solid #28445e; border-left: 3px solid var(--cyan); border-radius: 8px; background: #091a2a; color: #a9bbd0; font-size: .76rem; line-height: 1.5; }
.gemini-chat-messages { display: flex; flex: 1 1 400px; flex-direction: column; gap: .8rem; min-height: 280px; max-height: 58vh; overflow-y: auto; padding: .85rem; border: 1px solid var(--line); border-radius: 10px; background: #071321; scroll-behavior: smooth; }
.gemini-message { width: fit-content; max-width: min(88%, 850px); padding: .7rem .85rem; border: 1px solid #243c56; border-radius: 11px; background: #0d1c2e; }
.gemini-message-user { align-self: flex-end; border-color: #15516b; background: linear-gradient(145deg, #0d3247, #10253c); }
.gemini-message-system { align-self: center; border-color: #694531; background: #302318; color: #ffd69a; }
.gemini-message-author { display: block; margin-bottom: .3rem; color: #4bd7f3; font-size: .68rem; font-weight: 800; letter-spacing: .04em; }
.gemini-message-user .gemini-message-author { color: #8ec9ff; text-align: right; }
.gemini-message-system .gemini-message-author { color: #ffc56b; }
.gemini-message-content { min-width: 0; color: #dce7f4; font-size: .85rem; line-height: 1.65; overflow-wrap: anywhere; }
.gemini-message-content > :first-child { margin-top: 0; }
.gemini-message-content > :last-child { margin-bottom: 0; }
.gemini-message-content p { margin: .45rem 0; white-space: pre-wrap; }
.gemini-message-content h4 { margin: .7rem 0 .35rem; color: #f1f7ff; font-size: .9rem; line-height: 1.4; }
.gemini-message-content ul, .gemini-message-content ol { display: grid; gap: .28rem; padding-left: 1.3rem; margin: .45rem 0; }
.gemini-message-content li { padding-left: .12rem; }
.gemini-message-content strong { color: #f2f8ff; font-weight: 750; }
.gemini-message-content code { padding: .08rem .32rem; border: 1px solid #2a405a; border-radius: 4px; background: #091626; color: #a8e7f6; font-size: .82em; }
.gemini-response-table-wrap { max-width: 100%; margin: .65rem 0; overflow-x: auto; border: 1px solid #263e59; border-radius: 8px; }
.gemini-response-table { width: 100%; min-width: 680px; border-collapse: collapse; font-size: .78rem; }
.gemini-response-table th, .gemini-response-table td { padding: .55rem .65rem; border-bottom: 1px solid #20344b; text-align: left; vertical-align: top; }
.gemini-response-table th { position: sticky; top: 0; background: #13263d; color: #9fe9f7; font-size: .73rem; font-weight: 750; white-space: nowrap; }
.gemini-response-table td { color: #d0deed; }
.gemini-response-table tbody tr:nth-child(even) { background: #102036; }
.gemini-response-table tbody tr:last-child td { border-bottom: 0; }
.gemini-response-table td:nth-child(n+4) { font-variant-numeric: tabular-nums; }
.gemini-message-user .gemini-message-content { white-space: pre-wrap; }
.gemini-message-system .gemini-message-content { color: #ffd69a; }
.gemini-message-meta { display: block; margin-top: .45rem; color: #8197b0; font-size: .65rem; }
.gemini-message.is-pending .gemini-message-content { color: #8ea3bb; animation: gemini-pulse 1.2s ease-in-out infinite alternate; }
.gemini-chat-form { display: grid; gap: .55rem; margin-top: .85rem; }
.gemini-chat-form textarea { width: 100%; min-height: 5rem; resize: vertical; padding: .8rem .9rem; border: 1px solid #2b405a; border-radius: 9px; background: #081526; color: var(--ink); font: inherit; font-size: .85rem; line-height: 1.5; }
.gemini-chat-form textarea:focus { border-color: var(--cyan); outline: 3px solid #20c8f422; }
.gemini-chat-form textarea:disabled { opacity: .7; }
.gemini-chat-compose-footer { display: flex; justify-content: space-between; align-items: center; gap: .8rem; }
.gemini-chat-compose-footer .muted { font-size: .7rem; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@keyframes gemini-pulse { from { opacity: .55; } to { opacity: 1; } }
label { display: grid; gap: .42rem; color: #b8c7d9; font-size: .8rem; font-weight: 650; }
input, select { width: 100%; min-height: 2.65rem; padding: .62rem .75rem; border: 1px solid #2b405a; border-radius: 8px; background: #081526; color: var(--ink); }
input:focus, select:focus { border-color: var(--cyan); outline: 3px solid #20c8f422; }
.detail-filters { display: grid; grid-template-columns: minmax(230px, 1.7fr) minmax(150px, 1fr) minmax(175px, 1fr) auto; align-items: end; gap: .75rem; margin: .35rem 0 1rem; }
.detail-filters[hidden] { display: none; }
.detail-filters label, .detail-filters input, .detail-filters select { min-width: 0; }
.filter-summary { grid-column: 1 / -1; min-height: 1rem; color: #91a4bc; font-size: .72rem; }
.detail-meta { display: flex; justify-content: flex-end; align-items: center; gap: .3rem; min-height: 2.1rem; margin: .65rem 0 .85rem; color: #91a4bc; font-size: .75rem; }
.table-scroll { overflow: auto; max-height: 62vh; border: 1px solid var(--line); border-radius: 9px; background: #081424; }
.detail-table { width: 100%; min-width: 760px; border-collapse: collapse; }
.detail-table th { position: sticky; z-index: 1; top: 0; padding: .74rem .78rem; border-bottom: 1px solid #2a405a; background: #102138; color: #b8c9dd; font-size: .7rem; text-align: left; white-space: nowrap; }
.detail-table td { padding: .65rem .78rem; border-bottom: 1px solid #17283d; color: #b9c9db; font-size: .75rem; }
.detail-table tbody tr:hover { background: #10213880; }
.detail-table tbody tr.loss-ticket-action-needed td { background: rgba(150, 34, 48, .22); color: #ffe0e3; }
.detail-table tbody tr.loss-ticket-action-needed td:first-child { box-shadow: inset 3px 0 #ff5264; }
.detail-table td.loss-ticket-age-warning { white-space: normal; }
.loss-ticket-age-value { display: inline-block; margin-right: .4rem; color: #ff7b88; font-weight: 800; white-space: nowrap; }
.loss-ticket-warning-badge { display: inline-block; padding: .2rem .45rem; border: 1px solid #a93b49; border-radius: 999px; background: #4b1821; color: #ffb8bf; font-size: .65rem; font-weight: 800; white-space: nowrap; }
.detail-table tr:last-child td { border-bottom: 0; }
.bsc-group-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: start; gap: 1rem; }
.bsc-group-grid.bsc-area-view { grid-template-columns: minmax(0, 1fr); }
.bsc-group-grid[hidden], .table-scroll[hidden], .detail-pager[hidden] { display: none; }
.bsc-group-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 10px; background: #081424; }
.bsc-group-card[data-area="quang-lap"] { border-top: 3px solid #38c6ed; }
.bsc-group-card[data-area="dran"] { border-top: 3px solid #43d19b; }
.bsc-group-card[data-area="thanh-my"] { border-top: 3px solid #b78cff; }
.bsc-group-card[data-area="unknown"] { border-top: 3px solid #f4b942; }
.bsc-group-heading { display: flex; justify-content: space-between; align-items: center; gap: .6rem; padding: .8rem .9rem; border-bottom: 1px solid var(--line); background: #102138; }
.bsc-group-heading h3 { margin: 0; color: #e2edf9; font-size: .95rem; }
.bsc-group-count { flex: 0 0 auto; color: #9eb1c8; font-size: .72rem; }
.bsc-group-table-scroll { max-height: 62vh; overflow: auto; }
.bsc-group-table { min-width: 620px; table-layout: fixed; }
.bsc-group-table th:nth-child(1) { width: 19%; }
.bsc-group-table th:nth-child(2) { width: 23%; }
.bsc-group-table th:nth-child(3) { width: 16%; }
.bsc-group-table th:nth-child(4) { width: 20%; }
.bsc-group-table th:nth-child(5) { width: 22%; }
.bsc-group-table td { vertical-align: middle; }
.bsc-group-table .bsc-employee-cell,
.bsc-group-table .bsc-secondary-cell,
.bsc-group-table .bsc-score-cell { overflow: hidden; text-overflow: ellipsis; }
.bsc-group-table .bsc-employee-cell strong,
.bsc-group-table .bsc-employee-cell small,
.bsc-group-table .bsc-secondary-cell span,
.bsc-group-table .bsc-secondary-cell small,
.bsc-group-table .bsc-score-cell strong,
.bsc-group-table .bsc-score-cell small { display: block; }
.bsc-group-table .bsc-employee-cell small,
.bsc-group-table .bsc-secondary-cell small,
.bsc-group-table .bsc-score-cell small { margin-top: .2rem; color: #879bb2; font-size: .65rem; }
.bsc-group-table .bsc-score-cell { color: #e4f0ff; font-weight: 700; font-variant-numeric: tabular-nums; }
.bsc-group-table .bsc-kpi-details { min-width: 0; }
.bsc-group-table .bsc-kpi-table { position: relative; z-index: 2; }
.aomc-heading-actions { display: flex; align-items: center; gap: .6rem; }
.bsc-view-controls { display: inline-flex; gap: .25rem; padding: .2rem; border: 1px solid var(--line); border-radius: 9px; background: #081424; }
.bsc-view-controls .button { min-height: 2rem; padding: .35rem .62rem; border-color: transparent; font-size: .72rem; }
.bsc-view-controls .button[aria-pressed="true"] { border-color: #176183; background: #0e344b; color: #8beaff; }
.aomc-history-controls { display: inline-flex; align-items: center; gap: .45rem; }
.aomc-data-mode-controls { display: inline-flex; align-items: center; gap: .45rem; flex-wrap: wrap; }
.aomc-data-mode-controls .button[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); background: rgba(0, 201, 245, .12); }
.aomc-data-mode-controls .muted { max-width: 23rem; font-size: .68rem; }
.aomc-history-controls label { display: grid; gap: .15rem; color: var(--muted); font-size: .62rem; line-height: 1.1; }
.aomc-history-controls input, .aomc-history-controls select { min-height: 2rem; max-width: 8.5rem; padding: .25rem .4rem; border: 1px solid var(--line); border-radius: 7px; background: #081424; color: var(--ink); font: inherit; font-size: .72rem; }
.aomc-history-controls select { max-width: 9rem; }
.bsc-poster-mode { display: block; }
.bsc-poster-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); align-items: start; gap: 1rem; }
.bsc-poster-card { min-width: 0; padding: .65rem; overflow: hidden; border: 1px solid #d9e4ed; border-top: 4px solid #21b6c8; border-radius: 14px; background: #f7fbfc; color: #142536; box-shadow: 0 12px 28px #02091424; }
.bsc-poster-preview { display: block; width: 100%; height: auto; border-radius: 9px; background: #eff7f5; cursor: zoom-in; }
.bsc-poster-preview:focus-visible { outline: 3px solid #20c4df; outline-offset: 3px; }
.bsc-poster-dialog { max-width: 96vw; max-height: 96vh; padding: 0; overflow: hidden; border: 1px solid #31516c; border-radius: 14px; background: #081424; color: #e5f0fc; box-shadow: 0 24px 80px #000b; }
.bsc-poster-dialog::backdrop { background: #020914d9; backdrop-filter: blur(4px); }
.bsc-poster-dialog-content { display: grid; max-height: 96vh; grid-template-rows: auto minmax(0, 1fr); padding: .75rem; }
.bsc-poster-dialog-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 0 .65rem; }
.bsc-poster-dialog-toolbar h2 { margin: 0; color: #dceafb; font-size: .95rem; }
.bsc-poster-dialog-close { min-height: 2rem; }
.bsc-poster-dialog-image { display: block; width: auto; height: auto; max-width: 92vw; max-height: 88vh; border-radius: 8px; background: #eff7f5; }
.bsc-poster-download { width: 100%; margin-top: .55rem; }
.ghtt-infographic-view { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1rem; }
.ghtt-infographic-view[hidden] { display: none; }
.ghtt-poster-card { width: min(100%, 1100px); margin-inline: auto; }
.ghtt-poster-preview { width: 100%; height: auto; }
.ghtt-preview-status { min-height: 8rem; display: grid; place-items: center; margin: 0; padding: 1.25rem; color: #91a2b9; text-align: center; font-size: .85rem; }
.ghtt-preview-status.error { color: #ffadb8; }
.ghtt-empty-state { padding: 1.5rem; border: 1px solid var(--line); border-radius: 10px; background: #081424; }
.detail-table .detail-value { color: #e0eafa; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wireless-report-table { min-width: 1120px; }
.wireless-report-table th, .wireless-report-table td { height: 3.1rem; box-sizing: border-box; vertical-align: middle; }
.wireless-report-table th:first-child, .wireless-report-table td:first-child { min-width: 15rem; text-align: left; }
.wireless-report-table .wireless-bts-row td { background: rgba(41, 84, 122, .12); }
.wireless-report-table .wireless-bts-row td:first-child { padding-left: 2rem; }
.wireless-area-status { display: inline-flex; margin-left: .55rem; padding: .18rem .42rem; border: 1px solid #23644f; border-radius: 999px; background: #0a2d28; color: #72e0b5; font-size: .64rem; font-weight: 700; white-space: nowrap; }
.wireless-area-status.is-outstanding { border-color: #8a5731; background: #392311; color: #ffc17e; }
.wireless-area-status.is-station { border-color: #31557a; background: #102844; color: #9bc8f1; }
.wireless-outstanding-row td { background: rgba(150, 76, 24, .12); }
.wireless-outstanding-row td:first-child { box-shadow: inset 3px 0 #f0a04b; }
.wireless-backlog-value { color: #ffc17e !important; font-weight: 800; }
.bsc-report-table { min-width: 1120px; table-layout: fixed; }
.bsc-report-table th, .bsc-report-table td { box-sizing: border-box; vertical-align: middle; }
.bsc-report-table th:nth-child(1), .bsc-report-table td:nth-child(1) { width: 14%; text-align: left; }
.bsc-report-table th:nth-child(2), .bsc-report-table td:nth-child(2) { width: 9%; text-align: left; }
.bsc-report-table th:nth-child(3), .bsc-report-table td:nth-child(3) { width: 16%; text-align: left; }
.bsc-report-table th:nth-child(4), .bsc-report-table td:nth-child(4) { width: 9%; text-align: right; }
.bsc-report-table th:nth-child(5), .bsc-report-table td:nth-child(5) { width: 8%; text-align: center; }
.bsc-report-table th:nth-child(6), .bsc-report-table td:nth-child(6) { width: 9%; text-align: center; }
.bsc-report-table th:nth-child(7), .bsc-report-table td:nth-child(7) { width: 12%; text-align: right; }
.bsc-report-table th:nth-child(8), .bsc-report-table td:nth-child(8) { width: 8%; text-align: right; }
.bsc-report-table th:nth-child(9), .bsc-report-table td:nth-child(9) { width: 15%; text-align: left; }
.bsc-report-table td:nth-child(-n+3) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fiber-break-report-table { min-width: 1280px; table-layout: fixed; }
.fiber-break-report-table th, .fiber-break-report-table td { box-sizing: border-box; vertical-align: middle; }
.fiber-break-report-table th:nth-child(1), .fiber-break-report-table td:nth-child(1) { width: 6%; text-align: left; }
.fiber-break-report-table th:nth-child(2), .fiber-break-report-table td:nth-child(2) { width: 12%; text-align: left; }
.fiber-break-report-table th:nth-child(3), .fiber-break-report-table td:nth-child(3) { width: 18%; text-align: left; }
.fiber-break-report-table th:nth-child(4), .fiber-break-report-table td:nth-child(4) { width: 20%; text-align: left; }
.fiber-break-report-table th:nth-child(5), .fiber-break-report-table td:nth-child(5) { width: 7%; text-align: left; }
.fiber-break-report-table th:nth-child(6), .fiber-break-report-table td:nth-child(6) { width: 9%; text-align: center; }
.fiber-break-report-table th:nth-child(7), .fiber-break-report-table td:nth-child(7) { width: 9%; text-align: right; }
.fiber-break-report-table th:nth-child(8), .fiber-break-report-table td:nth-child(8) { width: 8%; text-align: center; }
.fiber-break-report-table th:nth-child(9), .fiber-break-report-table td:nth-child(9) { width: 7%; text-align: center; }
.fiber-break-report-table th:nth-child(10), .fiber-break-report-table td:nth-child(10) { width: 4%; text-align: center; }
.fiber-break-report-table td:nth-child(-n+5) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.fiber-business-report-table { min-width: 900px; table-layout: fixed; }
.fiber-business-report-table th, .fiber-business-report-table td { box-sizing: border-box; vertical-align: middle; }
.fiber-business-report-table th:nth-child(1), .fiber-business-report-table td:nth-child(1) { width: 14%; text-align: left; }
.fiber-business-report-table th:nth-child(2), .fiber-business-report-table td:nth-child(2) { width: 9%; text-align: right; }
.fiber-business-report-table th:nth-child(3), .fiber-business-report-table td:nth-child(3) { width: 9%; text-align: right; }
.fiber-business-report-table th:nth-child(4), .fiber-business-report-table td:nth-child(4) { width: 11%; text-align: right; }
.fiber-business-report-table th:nth-child(5), .fiber-business-report-table td:nth-child(5) { width: 15%; text-align: right; }
.fiber-business-report-table th:nth-child(6), .fiber-business-report-table td:nth-child(6) { width: 14%; text-align: right; }
.fiber-business-report-table th:nth-child(7), .fiber-business-report-table td:nth-child(7) { width: 14%; text-align: right; }
.fiber-business-report-table th:nth-child(8), .fiber-business-report-table td:nth-child(8) { width: 14%; text-align: right; }
.ghtt-report-table { min-width: 1100px; table-layout: fixed; }
.ghtt-report-table th, .ghtt-report-table td { box-sizing: border-box; vertical-align: middle; }
.ghtt-report-table th:nth-child(1), .ghtt-report-table td:nth-child(1) { width: 14%; text-align: left; }
.ghtt-report-table th:nth-child(2), .ghtt-report-table td:nth-child(2) { width: 8%; text-align: right; }
.ghtt-report-table th:nth-child(3), .ghtt-report-table td:nth-child(3) { width: 10%; text-align: right; }
.ghtt-report-table th:nth-child(4), .ghtt-report-table td:nth-child(4) { width: 13%; text-align: right; }
.ghtt-report-table th:nth-child(5), .ghtt-report-table td:nth-child(5) { width: 13%; text-align: right; }
.ghtt-report-table th:nth-child(6), .ghtt-report-table td:nth-child(6) { width: 13%; text-align: right; }
.ghtt-report-table th:nth-child(7), .ghtt-report-table td:nth-child(7) { width: 10%; text-align: right; }
.ghtt-report-table th:nth-child(8), .ghtt-report-table td:nth-child(8) { width: 10%; text-align: right; }
.ghtt-report-table th:nth-child(9), .ghtt-report-table td:nth-child(9) { width: 9%; text-align: right; }
.bsc-kpi-details { min-width: 8rem; text-align: left; }
.bsc-kpi-details summary { color: var(--cyan); cursor: pointer; font-weight: 700; }
.bsc-kpi-table { margin-top: .65rem; border-collapse: collapse; min-width: 46rem; }
.bsc-kpi-table th, .bsc-kpi-table td { padding: .42rem .55rem; border-bottom: 1px solid #20344b; text-align: right; white-space: nowrap; }
.bsc-kpi-table th:nth-child(2), .bsc-kpi-table td:nth-child(2) { min-width: 15rem; max-width: 22rem; text-align: left; white-space: normal; }
.bsc-kpi-table th { color: #a9c4df; font-size: .68rem; }
.bsc-kpi-table td { color: #dbe7f5; font-size: .7rem; }
.detail-pager { display: flex; justify-content: center; align-items: center; gap: 1rem; padding-top: .9rem; }
.detail-pager .muted { font-size: .77rem; }
.user-form { display: grid; grid-template-columns: repeat(3, minmax(150px, 1fr)); align-items: end; gap: 1rem; margin-top: 1.1rem; }
.region-fieldset { grid-column: 1 / -1; margin: 0; padding: .85rem; border: 1px solid var(--line-bright); border-radius: 8px; }
.region-fieldset legend { padding: 0 .35rem; color: #a9bad0; font-size: .76rem; }
.region-options { display: flex; flex-wrap: wrap; gap: .55rem 1rem; }
.region-options label { display: inline-flex; align-items: center; gap: .4rem; font-size: .76rem; font-weight: 500; }
.region-options input { width: 1rem; min-height: 1rem; accent-color: var(--cyan); }
.user-role-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; gap: .85rem; margin-top: 1.1rem; }
.user-role-column { display: flex; flex-direction: column; min-width: 0; min-height: 12rem; padding: .85rem; border: 1px solid var(--line-bright); border-top: 3px solid var(--role-accent, var(--cyan)); border-radius: 10px; background: linear-gradient(145deg, #0d1d31, #091627); }
.user-role-column[data-role="admin"] { --role-accent: #b78cff; }
.user-role-column[data-role="operator"] { --role-accent: #39c6ee; }
.user-role-column[data-role="viewer"] { --role-accent: #56d4a8; }
.user-role-heading { display: flex; justify-content: space-between; align-items: center; gap: .6rem; min-height: 2.3rem; padding-bottom: .65rem; border-bottom: 1px solid var(--line); }
.user-role-heading h3 { min-width: 0; margin: 0; color: #e7f1fc; font-size: .9rem; }
.user-role-count { flex: 0 0 auto; padding: .25rem .48rem; border: 1px solid color-mix(in srgb, var(--role-accent) 42%, transparent); border-radius: 999px; background: color-mix(in srgb, var(--role-accent) 10%, transparent); color: var(--role-accent); font-size: .66rem; font-weight: 750; white-space: nowrap; }
.user-role-accounts { display: grid; align-content: start; gap: .5rem; padding-top: .65rem; }
.user-role-empty { margin: .3rem 0; color: #8295ad; font-size: .76rem; }
.user-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: .7rem; min-width: 0; padding: .7rem; border: 1px solid var(--line); border-radius: 8px; background: #091627; }
.user-row > div { min-width: 0; }
.user-row strong { overflow-wrap: anywhere; }
.user-meta { margin-top: .28rem; color: var(--muted); font-size: .7rem; line-height: 1.45; overflow-wrap: anywhere; }
.page-footer { padding: 1.6rem 0 .2rem; color: #70839b; font-size: .71rem; }
.notice { padding: .8rem 1rem; margin-bottom: 1rem; border: 1px solid #294763; border-radius: 9px; background: #0c2134; color: #b9d5e8; font-size: .83rem; }
.notice.error { border-color: #713542; background: #2b1822; color: #ffadb8; }
.auth-card { width: min(520px, 100%); padding: 1.6rem; margin: clamp(2rem, 8vh, 5rem) auto; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(145deg, #0e1c30, #0a1525); box-shadow: 0 18px 55px #02091466; }
.auth-card h2 { margin-bottom: .65rem; }
.auth-card > .muted { font-size: .84rem; }
.form-grid { display: grid; gap: 1rem; margin-top: 1.2rem; }

@media (max-width: 1120px) {
  .bsc-group-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bsc-poster-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .health-panel { grid-template-columns: minmax(0, 1fr) 112px minmax(120px, .45fr); gap: 1rem; }
  .health-ring { width: 108px; }
  .detail-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .user-role-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 780px) {
  .bsc-group-grid { grid-template-columns: 1fr; }
  .bsc-poster-grid { grid-template-columns: 1fr; }
  .sidebar { position: relative; inset: auto; width: 100%; padding: .8rem 1rem .7rem; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand { min-height: auto; padding: 0 0 .75rem; border-bottom: 0; }
  .brand-mark { width: 2.3rem; height: 2.3rem; }
  .nav-caption, .sidebar-bottom { display: none; }
  .sidebar-nav { display: flex; gap: .35rem; overflow-x: auto; padding-top: .35rem; }
  .detail-nav { overflow: visible; }
  .detail-nav .nav-caption { display: none; }
  .detail-sidebar-nav { align-items: center; overflow-x: auto; padding-bottom: .15rem; }
  .nav-link { flex: 0 0 auto; min-height: 2.5rem; padding: .45rem .62rem; font-size: .75rem; }
  .nav-link[aria-current="page"]::before { inset: auto .55rem -1px; width: auto; height: 2px; }
  .nav-icon { width: auto; font-size: 1rem; }
  .main-shell { margin-left: 0; }
  .gemini-chat-card { min-height: 68vh; padding: .9rem; }
  .gemini-chat-heading { flex-direction: column; }
  .gemini-chat-actions { width: 100%; flex-wrap: wrap; }
  .gemini-chat-messages { max-height: 52vh; }
  .topbar { min-height: 67px; padding: .65rem 1rem; }
  .topbar h1 { font-size: .8rem; }
  .page { width: calc(100% - 2rem); padding-top: 1.35rem; }
  .health-panel { grid-template-columns: minmax(0, 1fr) 100px; min-height: 145px; }
  .health-ring { width: 96px; }
  .health-legend { grid-column: 1 / -1; display: flex; justify-content: flex-start; }
  .user-form { grid-template-columns: 1fr; }
  .region-fieldset { grid-column: auto; }
}
@media (max-width: 520px) {
  .user-role-grid { grid-template-columns: 1fr; }
  .topbar { align-items: flex-start; }
  .topbar-right { align-items: flex-end; flex-direction: column; gap: .4rem; }
  .local-badge { padding: .35rem .55rem; font-size: .65rem; }
  .button { min-height: 2.25rem; padding: .48rem .65rem; font-size: .72rem; }
  .welcome-row { align-items: flex-start; flex-direction: column; }
  .refresh-button { align-self: flex-start; }
  .summary-grid { gap: .55rem; }
  .summary-card { min-height: 99px; padding: .75rem; }
  .summary-label { font-size: .61rem; }
  .summary-value { font-size: 1.55rem; }
  .summary-detail { font-size: .64rem; }
  .health-panel { grid-template-columns: minmax(0, 1fr) 82px; gap: .6rem; padding: .95rem; }
  .health-ring { width: 78px; }
  .ring-center strong { font-size: 1.05rem; }
  .ring-center span { font-size: .47rem; }
  .health-copy h2 { font-size: 1.05rem; }
  .health-copy .muted, .health-breakdown { font-size: .72rem; }
  .section-heading { align-items: flex-start; }
  .section-heading h2 { font-size: 1.02rem; }
  .section-count { font-size: .61rem; }
  .source-list { grid-template-columns: 1fr; }
  .details-card, .admin-card { padding: .85rem; }
  .section-heading .button { white-space: nowrap; }
  .detail-filters { grid-template-columns: 1fr; }
  .detail-filters .button { justify-self: start; }
  .filter-summary { grid-column: auto; }
}

/* NOC presentation layer: preserve the existing data and navigation behavior. */
body {
  background:
    radial-gradient(ellipse at 76% 0, #0b42634d 0, transparent 38rem),
    radial-gradient(ellipse at 100% 42%, #0a2d4830 0, transparent 34rem),
    var(--canvas);
}

.brand-mark {
  font-size: .88rem;
  letter-spacing: -.07em;
}

.assessment-card {
  display: grid;
  gap: 1.3rem;
  padding: clamp(1rem, 2.2vw, 1.6rem);
  border: 1px solid #203d59;
  border-radius: 13px;
  background: linear-gradient(145deg, #0b1a2c, #081425);
  box-shadow: 0 10px 24px #02091424, inset 0 1px #d5f5ff05;
}

.assessment-controls {
  display: flex;
  align-items: flex-end;
  gap: .6rem;
}

.assessment-controls label {
  display: grid;
  gap: .3rem;
  color: #9eb4ca;
  font-size: .72rem;
  font-weight: 700;
}

.assessment-controls input {
  min-height: 2.55rem;
  padding: .45rem .65rem;
  border: 1px solid #294763;
  border-radius: 8px;
  background: #071426;
  color: #edf5ff;
  font: inherit;
  color-scheme: dark;
}

.assessment-note {
  min-height: 1.2rem;
  margin: -.45rem 0 0;
  font-size: .79rem;
}

.assessment-ai {
  display: grid;
  gap: .65rem;
  padding: 1rem;
  border: 1px solid #1e5269;
  border-radius: 10px;
  background: linear-gradient(145deg, #0b2536, #091a2b);
}
.assessment-ai-heading { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.assessment-ai-heading .eyebrow { margin: 0 0 .25rem; color: #51d4ed; }
.assessment-ai-heading h3 { margin: 0; color: #eaf6ff; font-size: 1rem; }
.assessment-ai-status { color: #ffd36c; font-size: .7rem; font-weight: 700; text-align: right; }
.assessment-ai-status.is-ready { color: #65e2b7; }
.assessment-ai-status.is-error { color: #ff9daa; }
.assessment-ai-overall { margin: 0; color: #d0e2f2; font-size: .8rem; line-height: 1.6; }
.assessment-ai-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .55rem; }
.assessment-ai-area { padding: .75rem; border: 1px solid #1c3e57; border-radius: 8px; background: #091a2b; }
.assessment-ai-area strong { color: #6bdcf3; font-size: .75rem; }
.assessment-ai-area p { margin: .4rem 0 0; color: #c2d4e6; font-size: .72rem; line-height: 1.55; }
.assessment-ai-area .assessment-ai-focus { color: #ffd36c; }

.assessment-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: .65rem;
}

.assessment-stat,
.assessment-coverage-card,
.assessment-area-card {
  min-width: 0;
  border: 1px solid #203d59;
  border-radius: 10px;
  background: linear-gradient(145deg, #0d2034, #091729);
}

.assessment-stat {
  display: grid;
  gap: .45rem;
  padding: .85rem;
}

.assessment-stat-label {
  color: #a8bdd2;
  font-size: .69rem;
  line-height: 1.4;
}

.assessment-stat-value {
  color: #42cdf2;
  font-size: 1.55rem;
  letter-spacing: -.03em;
}

.assessment-coverage,
.assessment-areas { display: grid; gap: .7rem; }
.compact-heading { margin: 0; }
.compact-heading h3 { margin: .1rem 0 0; font-size: 1rem; }

.assessment-coverage-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .65rem;
}

.assessment-coverage-card { padding: .8rem; }
.assessment-coverage-card strong { display: block; padding-right: 6.5rem; color: #e7f1fc; font-size: .76rem; line-height: 1.4; }
.assessment-coverage-count { display: inline-block; margin-top: .5rem; color: #49d7f5; font-size: .7rem; font-weight: 800; }
.assessment-coverage-card p { margin: .35rem 0 0; color: #8fa8c0; font-size: .68rem; line-height: 1.5; }
.assessment-coverage-card .assessment-warning { color: #ffd16c; }

.assessment-area-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem;
}

.assessment-area-card { padding: .95rem; }
.assessment-area-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem; }
.assessment-area-heading h4 { margin: 0; color: #f0f6fd; font-size: 1rem; }
.assessment-area-state { flex: 0 0 auto; padding: .28rem .5rem; border: 1px solid #24516a; border-radius: 999px; background: #0b293b; color: #63d9f3; font-size: .62rem; font-weight: 800; }
.assessment-area-state.is-critical { border-color: #783344; background: #321923; color: #ff9daa; }
.assessment-area-state.is-attention { border-color: #745a28; background: #302714; color: #ffd36c; }
.assessment-area-state.is-clear { border-color: #1d5a49; background: #0c2b25; color: #65e2b7; }

.assessment-metrics {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: .34rem .7rem;
  padding: .75rem 0;
  margin: .55rem 0;
  border-top: 1px solid #1c344d;
  border-bottom: 1px solid #1c344d;
  font-size: .71rem;
}

.assessment-metrics dt { color: #9fb4ca; }
.assessment-metrics dd { margin: 0; color: #e6f2ff; font-weight: 800; text-align: right; }
.assessment-recommendation-title { color: #4bd6f2; font-size: .72rem; }
.assessment-recommendations { display: grid; gap: .38rem; padding-left: 1rem; margin: .4rem 0 0; color: #b8cadc; font-size: .7rem; line-height: 1.55; }

@media (max-width: 1000px) {
  .assessment-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .assessment-coverage-grid { grid-template-columns: 1fr; }
}

@media (max-width: 780px) {
  .assessment-card { padding: .9rem; }
  .assessment-controls { align-items: stretch; flex-direction: column; }
  .assessment-controls input { width: 100%; }
  .assessment-area-grid { grid-template-columns: 1fr; }
  .assessment-ai-grid { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  .assessment-summary { gap: .45rem; }
  .assessment-stat { padding: .65rem; }
  .assessment-stat-label { font-size: .62rem; }
  .assessment-stat-value { font-size: 1.25rem; }
  .assessment-area-card { padding: .75rem; }
}

.topbar {
  position: sticky;
  z-index: 4;
  top: 0;
  min-height: 88px;
  border-bottom-color: #1a3b58;
  background:
    radial-gradient(ellipse at 82% 50%, #07577735 0, transparent 34rem),
    #071323ed;
  box-shadow: 0 8px 24px #02091438;
}

.topbar h1 {
  color: #edf6ff;
  font-size: 1rem;
  font-weight: 750;
  letter-spacing: .015em;
}

.topbar .eyebrow { color: #51d9fb; }

.local-badge {
  border-color: #1c5362;
  background: #09202c;
  color: #c1d9e6;
}

.page { padding-top: 1.45rem; }

.overview-section {
  position: relative;
  overflow: hidden;
  padding: clamp(1rem, 1.8vw, 1.55rem);
  border: 1px solid #1b5271;
  border-radius: 16px;
  background:
    radial-gradient(ellipse at 82% 0, #0876a53d 0, transparent 34rem),
    linear-gradient(120deg, #0a263c 0%, #0a1a2e 48%, #091629 100%);
  box-shadow: 0 16px 38px #0209143d, inset 0 1px #9ceaff0b;
}

.overview-section::after {
  position: absolute;
  top: -6rem;
  right: 14%;
  width: 16rem;
  height: 16rem;
  border: 1px solid #2aa7d00b;
  border-radius: 50%;
  box-shadow: 0 0 0 2.5rem #2aa7d006, 0 0 0 5rem #2aa7d004;
  content: "";
  pointer-events: none;
}

.welcome-row,
.scope-note,
.summary-grid { position: relative; z-index: 1; }

.welcome-row { margin-bottom: 1.2rem; }

.welcome-row h2 {
  color: #eff7ff;
  font-size: clamp(1.55rem, 2.1vw, 2rem);
  font-weight: 800;
  letter-spacing: -.035em;
}

.welcome-description { color: #b5c9dc; }

.scope-note {
  border-color: #1d4863;
  border-left-color: var(--cyan);
  background: #071827a8;
  color: #b4c9dc;
}

.summary-grid { gap: .8rem; }

.summary-card {
  min-height: 116px;
  border-color: #24435e;
  border-radius: 11px;
  background: linear-gradient(145deg, #0e2034f2, #091729f5);
  box-shadow: inset 0 1px #d5f5ff08, 0 10px 24px #02091424;
  transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}

.summary-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 2px;
  background: var(--card-color, var(--cyan));
  content: "";
  opacity: .72;
}

.summary-card:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--card-color, var(--cyan)) 45%, #24435e);
  box-shadow: inset 0 1px #d5f5ff0d, 0 14px 28px #02091445;
}

.health-panel {
  min-height: 184px;
  border-color: #204b68;
  background:
    radial-gradient(ellipse at 76% 50%, #0c719439 0, transparent 30rem),
    linear-gradient(115deg, #0a1d31, #0a1729 72%);
  box-shadow: 0 12px 32px #02091435, inset 0 1px #d5f5ff08;
}

.health-copy .eyebrow,
.section-heading .eyebrow { color: #48d8f6; }

.source-card {
  border-color: #203c58;
  border-radius: 9px;
  background: linear-gradient(135deg, #0d1d31, #091728);
  box-shadow: inset 0 1px #d5f5ff05;
}

.source-card:hover {
  border-color: #2c7593;
  background: linear-gradient(135deg, #10253a, #0b1b2e);
  box-shadow: 0 8px 20px #02091440;
}

.metric-card,
.details-card,
.admin-card {
  border-color: #203d59;
  box-shadow: 0 10px 24px #02091424, inset 0 1px #d5f5ff05;
}

.metric-card h3 {
  background: linear-gradient(90deg, #10263c, #0c1c30);
  color: #edf5ff;
}

.section-count {
  border-color: #254662;
  background: #0b1c2f;
  color: #afc1d5;
}

.button:focus-visible,
.nav-link:focus-visible {
  outline-offset: 3px;
  box-shadow: 0 0 0 4px #20c8f41c;
}

@media (max-width: 780px) {
  .topbar { position: relative; min-height: 70px; }
  .overview-section { padding: 1rem; }
}

@media (max-width: 520px) {
  .topbar h1 { font-size: .86rem; }
  .overview-section { padding: .8rem; border-radius: 12px; }
  .welcome-row h2 { font-size: 1.35rem; }
}
