@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
    --bg-main: #e9e8eb;
    --bg-card: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --border-color: #f1f5f9;
    --accent-blue: #2563eb;
    --accent-purple: #7c3aed;
    --accent-teal: #0d9488;
    --accent-amber: #d97706;
    --accent-red: #ef4444;
    --accent-green: #16a34a;
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-mono: 'IBM Plex Mono', monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-main);
    font-family: var(--font-main);
    color: var(--text-primary);
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Number Typography */
.num-font, [class*="number"], .metric-val, .badge-num {
    font-family: var(--font-mono);
}

/* App Header & Brand */
.app-header {
    background-color: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.75rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-section {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.brand-logo {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-text h1 {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: #010f38;
    line-height: 1.1;
}

.brand-text span {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    list-style: none;
}

.nav-link {
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

    .nav-link:hover, .nav-link.active {
        color: var(--accent-blue);
    }

.hamburger {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-primary);
}

/* Sub-nav tabs */
.subnav-tabs {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0.5rem 1.5rem;
}

.tabs-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
}

.tab-btn {
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
    transition: all 0.2s ease;
}

    .tab-btn.active {
        background: #eff6ff;
        color: var(--accent-blue);
        font-weight: 600;
    }

/* Main Content Wrapper */
.main-wrapper {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 1.5rem;
    flex: 1;
}

/* Page Headers */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.header-titles h2 {
    font-size: 2.1rem;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.02em;
}

.header-titles p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    color: #475569;
    margin-top: 0.35rem;
}

.header-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.time-stamp {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.filter-select {
    padding: 0.4rem 0.8rem;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    background: #fff;
    font-size: 0.85rem;
    color: var(--text-primary);
}

/* Responsive Grids */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

/* Section Titles */
.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #0f172a;
    margin: 1.5rem 0 0.75rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .section-title:first-of-type {
        margin-top: 0;
    }

/* Card General Styling */
.card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.6rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-hover:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
}

.card-accent-blue {
    border-top: 4px solid var(--accent-blue);
}

.card-accent-purple {
    border-top: 4px solid var(--accent-purple);
}

.card-accent-teal {
    border-top: 4px solid var(--accent-teal);
}

.card-accent-amber {
    border-top: 4px solid var(--accent-amber);
}

.card-header-flex {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.card-header-simple {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.card-header-icon {
    color: var(--accent-blue);
}

.card-title-simple {
    font-size: 0.95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
}

.card-desc {
    margin-bottom: 1.5rem;
    flex: 1;
}

    .card-desc p {
        font-size: 1rem;
        color: #334155;
        line-height: 1.6;
        padding: 0.35rem;
    }

    .card-desc ul li {
        margin-left: 1.8rem;
    }

.icon-box {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.icon-size {
    width: 52px;
    height: 52px;
    font-size: 1.5rem;
}

.icon-blue {
    background: #dbeafe;
    color: var(--accent-blue);
}

.icon-purple {
    background: #f3e8ff;
    color: var(--accent-purple);
}

.icon-teal {
    background: #ccfbf1;
    color: var(--accent-teal);
}

.icon-amber {
    background: #fef3c7;
    color: var(--accent-amber);
}

.card-title h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
}

.card-title p {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
}

/* Radial Gauge Styling */
.gauge-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0.5rem 0 1rem 0;
    position: relative;
}

.gauge-body {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.gauge-blue {
    background: conic-gradient(var(--accent-blue) 0% 92%, #e2e8f0 92% 100%);
}

.gauge-purple {
    background: conic-gradient(var(--accent-purple) 0% 82%, #e2e8f0 82% 100%);
}

.gauge-teal {
    background: conic-gradient(var(--accent-teal) 0% 88%, #e2e8f0 88% 100%);
}

.gauge-amber {
    background: conic-gradient(var(--accent-amber) 0% 95%, #e2e8f0 95% 100%);
}

.gauge-center {
    width: 110px;
    height: 110px;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.gauge-val {
    font-size: 2.1rem;
    font-weight: 700;
    line-height: 1;
    color: #0f172a;
}

.gauge-unit {
    font-size: 1rem;
}

.gauge-subtext {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.gauge-pill {
    margin-top: 0.3rem;
    padding: 0.15rem 0.6rem;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: 600;
}

.pill-healthy {
    background: #dbeafe;
    color: #1d4ed8;
}

.pill-purple {
    background: #f3e8ff;
    color: #6b21a8;
}

.pill-good {
    background: #d1fae5;
    color: #047857;
}

.pill-excellent {
    background: #fef3c7;
    color: #b45309;
}

/* Stat Lists & Trends */
.stat-trend-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    margin-bottom: 0.75rem;
}

.trend-label {
    color: var(--text-secondary);
}

.trend-positive {
    color: var(--accent-green);
    font-weight: 600;
}

.stat-list {
    list-style: none;
    margin-top: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    padding: 0.35rem 0;
    border-bottom: 1px dashed var(--border-color);
}

    .stat-item:last-child {
        border-bottom: none;
    }

.stat-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-secondary);
}

.stat-value {
    font-weight: 600;
}

.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
}

.dot-blue {
    background: var(--accent-blue);
}

.dot-purple {
    background: var(--accent-purple);
}

.dot-amber {
    background: var(--accent-amber);
}

.dot-green {
    background: var(--accent-green);
}

.dot-red {
    background: var(--accent-red);
}

/* Progress & Threshold Bars */
.threshold-text {
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.chart-block {
    margin-top: 0.5rem;
}

.chart-title {
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.sparkline-svg {
    width: 100%;
    height: 40px;
    overflow: visible;
}

.chart-x-axis {
    display: flex;
    justify-content: space-between;
    font-size: 0.65rem;
    color: var(--text-muted);
}

.progress-group {
    margin-top: 1rem;
}

.progress-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
}

.progress-track {
    background: #e2e8f0;
    height: 6px;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.progress-fill-teal {
    background: var(--accent-teal);
    height: 100%;
}

.progress-fill-red {
    background: var(--accent-red);
    height: 100%;
}

.fill-explanations {
    width: 87.5%;
}

.fill-disclosure {
    width: 92%;
}

.status-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
}

.status-indicator {
    color: var(--accent-amber);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Card Link Footer */
.card-footer-link {
    margin-top: auto;
    padding-top: 1rem;
    text-align: center;
}

.card-footer-link-left {
    text-align: left;
    margin-top: 1rem;
}

.card-footer-link a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    transition: color 0.2s ease;
}

    .card-footer-link a:hover {
        color: var(--accent-blue);
    }

    .card-footer-link a.link-amber:hover {
        color: var(--accent-amber);
    }

/* Badges */
.badge {
    font-size: 0.725rem;
    font-weight: 600;
    padding: 0.2rem 0.5rem;
    border-radius: 9999px;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    display: inline-block;
}

.badge-pass {
    background: #d1fae5;
    color: #065f46;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-fail {
    background: #fee2e2;
    color: #991b1b;
}

.badge-neutral {
    background: #f1f5f9;
    color: #475569;
}

/* Alerts, Policy & Review Panels */
.alert-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    font-size: 0.78rem;
}

.alert-item {
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
}

.alert-time {
    color: var(--text-muted);
    white-space: nowrap;
}

.policy-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    font-size: 0.8rem;
}

.policy-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.policy-status {
    color: var(--accent-green);
    font-weight: 600;
    font-size: 0.75rem;
}

.review-details {
    margin-bottom: 1rem;
}

.review-title {
    font-size: 0.85rem;
    font-weight: 600;
}

.review-time {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.btn-primary {
    background: var(--accent-blue);
    color: #fff;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
    cursor: pointer;
    width: fit-content;
    transition: background 0.2s ease;
}

    .btn-primary:hover {
        background: #1d4ed8;
    }

/* Reasoning Box */
.reasoning-box {
    background: #f8fafc;
    border-left: 4px solid var(--accent-blue);
    padding: 0.85rem 1rem;
    border-radius: 0 8px 8px 0;
    font-size: 0.825rem;
    line-height: 1.5;
}

    .reasoning-box strong {
        color: #0f172a;
    }

/* Self-Explanation Helpers & Micro-Bars */
.tooltip-icon {
    cursor: help;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #475569;
    font-size: 10px;
    font-weight: 700;
    margin-left: 4px;
}

.mini-bar-bg {
    width: 100%;
    height: 6px;
    background: #e2e8f0;
    border-radius: 3px;
    overflow: hidden;
    margin-top: 4px;
}

.mini-bar-fill {
    height: 100%;
    border-radius: 3px;
}

.text-sm-muted {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.text-danger {
    color: var(--accent-red) !important;
}

.text-warning {
    color: var(--accent-amber) !important;
}

.text-success {
    color: var(--accent-green) !important;
}

/* Responsive Table Wrapper */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.qgi-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8rem;
    background: #fff;
    text-align: left;
}

    .qgi-table th {
        background: #f8fafc;
        color: var(--text-secondary);
        padding: 0.75rem 1rem;
        font-weight: 600;
        border-bottom: 1px solid #e2e8f0;
    }

    .qgi-table td {
        padding: 0.75rem 1rem;
        border-bottom: 1px solid #f1f5f9;
        color: var(--text-primary);
    }

    .qgi-table tr:last-child td {
        border-bottom: none;
    }

/* Footer Section */
.app-footer {
    text-align: center;
    padding: 1.5rem;
    font-size: 0.75rem;
    color: var(--text-muted);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    margin-top: 2rem;
}

/* Mobile & Tablet Responsive */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-3 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #ffffff;
        flex-direction: column;
        padding: 1rem 1.5rem;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
        border-bottom: 1px solid #e2e8f0;
    }

        .nav-menu.show {
            display: flex;
        }

    .grid-4, .grid-2 {
        grid-template-columns: 1fr;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
    }
}


/* --- SUB-NAVIGATION TOP MENU (FLUID & MOBILE-FRIENDLY) --- */
.subnav-tabs {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 0.4rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    width: 100%;
}

.tabs-container {
    display: flex;
    flex-wrap: wrap; /* Wraps items cleanly on smaller screens */
    gap: 0.4rem;
    align-items: center;
    width: 100%;
}

.tab-btn {
    padding: 0.5rem 0.85rem;
    border-radius: 8px;
    border: 1px solid transparent;
    background: transparent;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    transition: all 0.2s ease-in-out;
    flex: 1 1 auto; /* Distributes items smoothly across rows */
    text-align: center;
}

    .tab-btn:hover {
        background: #f8fafc;
        color: var(--text-primary);
    }

    .tab-btn.active {
        background: #eff6ff;
        border-color: #bfdbfe;
        color: var(--accent-blue);
        font-weight: 600;
        box-shadow: 0 1px 2px rgba(37, 99, 235, 0.08);
    }

.tab-icon {
    font-size: 0.95rem;
}

/* --- DIG-IN WORKBENCH CONTAINER STYLING --- */
.workbench-panel {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.workbench-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e2e8f0;
}

    .workbench-header h3 {
        font-size: 1.15rem;
        font-weight: 700;
        color: #0f172a;
    }

    .workbench-header p {
        font-size: 0.85rem;
        color: var(--text-secondary);
    }

/* --- 7-STAGE PROVENANCE TIMELINE --- */
.provenance-timeline {
    position: relative;
    padding-left: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

    .provenance-timeline::before {
        content: '';
        position: absolute;
        top: 10px;
        bottom: 10px;
        left: 11px;
        width: 2px;
        background: #e2e8f0;
    }

.timeline-step {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 3px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid var(--accent-blue);
    color: var(--accent-blue);
    font-size: 0.75rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.timeline-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.timeline-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    background: #f8fafc;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

/* --- WATERFALL BAR CHARTS --- */
.waterfall-bar-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.waterfall-bar-row {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.waterfall-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
}

.waterfall-track {
    width: 100%;
    height: 10px;
    background: #e2e8f0;
    border-radius: 5px;
    overflow: hidden;
}

.waterfall-fill {
    height: 100%;
    border-radius: 5px;
}

/* --- SUB-NAVIGATION TOOLBAR --- */
.sub-nav-bar {
    display: flex;
    gap: 0.5rem;
    background: #ffffff;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.sub-nav-item {
    padding: 0.45rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.15s ease-in-out;
}

    .sub-nav-item:hover {
        background: #f1f5f9;
        color: #0f172a;
    }

    .sub-nav-item.active {
        background: #e0f2fe;
        color: #0284c7;
        border: 1px solid #bae6fd;
    }

/* --- ACCENT BORDERS & EXECUTIVE GRIDS --- */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

.card-accent-blue {
    border-top: 4px solid #0284c7;
}

.card-accent-red {
    border-top: 4px solid #ef4444;
}

.card-accent-amber {
    border-top: 4px solid #f59e0b;
}

.card-accent-teal {
    border-top: 4px solid #0d9488;
}

.card-accent-purple {
    border-top: 4px solid #7c3aed;
}

/* Gauge Units */
.gauge-unit {
    font-size: 1.1rem;
    font-weight: 600;
    color: #64748b;
    margin-left: 0.2rem;
}

/* --- UNIFIED CONTEXT & DELTA CARD --- */
.context-summary-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.context-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 2rem;
}

@media (max-width: 1024px) {
    .context-summary-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
}

.context-block-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    padding-bottom: 0.4rem;
    border-bottom: 1px solid #f1f5f9;
}

.context-bullet-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

    .context-bullet-list li {
        font-size: 0.88rem;
        color: #334155;
        display: flex;
        align-items: center;
        line-height: 1.4;
    }

        .context-bullet-list li::before {
            content: "\2022";
            color: #0284c7;
            font-weight: 800;
            font-size: 1.25rem;
            line-height: 1;
            display: inline-block;
            width: 0.6rem;
            margin-right: 0.65rem;
            flex-shrink: 0;
        }

.context-label {
    color: #64748b;
    font-weight: 600;
    margin-right: 0.45rem;
    white-space: nowrap;
}

.shift-single-line {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.35rem;
    width: 100%;
}

.shift-value {
    color: #0f172a;
    font-weight: 600;
}

.delta-shift-badge {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 700;
    font-size: 0.88rem;
}

.shift-footnote {
    font-size: 0.78rem;
    color: #64748b;
    margin-left: 0.2rem;
}
/* --- END of UNIFIED CONTEXT & DELTA CARD --- */

.home-card-link {
    font-size: 1.0rem;
    font-weight: 700;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: transform 0.15s ease-in-out;
}

    .home-card-link:hover {
        transform: translateX(4px);
    }

/* --- THICK ACCENT BORDERS (8px) --- */
.card-accent-blue {
    border-top: 8px solid #0284c7 !important;
}

.card-accent-purple {
    border-top: 8px solid #7c3aed !important;
}

.card-accent-teal {
    border-top: 8px solid #0d9488 !important;
}

.card-accent-amber {
    border-top: 8px solid #f59e0b !important;
}

.card-accent-red {
    border-top: 8px solid #ef4444 !important;
}

/* --- HOME CARD ACTION BUTTONS --- */
.card-footer-btn-container {
    margin-top: auto;
    padding-top: 0.5rem;
    width: 100%;
}

.btn-card {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1.25rem;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff !important;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

    .btn-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.12), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
        color: #ffffff !important;
    }

.btn-card-blue {
    background-color: #0284c7;
}

    .btn-card-blue:hover {
        background-color: #0369a1;
    }

.btn-card-purple {
    background-color: #7c3aed;
}

    .btn-card-purple:hover {
        background-color: #6d28d9;
    }

.btn-card-teal {
    background-color: #0d9488;
}

    .btn-card-teal:hover {
        background-color: #0f766e;
    }

.btn-card-amber {
    background-color: #f59e0b;
}

    .btn-card-amber:hover {
        background-color: #d97706;
    }

/* --- SUPERVISORY INTERPRETATION & COMPLIANCE POLICY GUIDE CARD --- */
.compliance-guide-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    margin-bottom: 1.5rem;
}

.compliance-guide-header {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 0.75rem;
    margin-bottom: 1.25rem;
}

    .compliance-guide-header h3 {
        font-size: 1.15rem;
        font-weight: 700;
        color: #0f172a;
        margin-bottom: 0.25rem;
    }

    .compliance-guide-header p {
        font-size: 0.88rem;
        color: #64748b;
        margin: 0;
        line-height: 1.5;
    }

.compliance-guide-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

@media (max-width: 1024px) {
    .compliance-guide-grid {
        grid-template-columns: 1fr;
    }
}

.compliance-guide-column {
    background: #f8fafc;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.compliance-guide-title {
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.compliance-guide-title-blue {
    color: #0284c7;
}

.compliance-guide-title-amber {
    color: #d97706;
}

.compliance-guide-title-purple {
    color: #7c3aed;
}

.compliance-guide-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

    .compliance-guide-list li {
        font-size: 0.85rem;
        color: #334155;
        line-height: 1.4;
    }

    .compliance-guide-list strong {
        color: #0f172a;
    }

.executive-guide-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    margin-bottom: 1.5rem;
}

.executive-guide-header {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 0.75rem;
    margin-bottom: 1.25rem;
}

    .executive-guide-header h3 {
        font-size: 1.15rem;
        font-weight: 700;
        color: #0f172a;
        margin-bottom: 0.25rem;
    }

    .executive-guide-header p {
        font-size: 0.88rem;
        color: #64748b;
        margin: 0;
        line-height: 1.5;
    }

.executive-guide-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

@media (max-width: 1024px) {
    .executive-guide-grid {
        grid-template-columns: 1fr;
    }
}

.executive-guide-column {
    background: #f8fafc;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.executive-guide-title {
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.executive-guide-title-red {
    color: #ef4444;
}

.executive-guide-title-purple {
    color: #7c3aed;
}

.executive-guide-title-teal {
    color: #0d9488;
}

.executive-guide-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

    .executive-guide-list li {
        font-size: 0.85rem;
        color: #334155;
        line-height: 1.4;
    }

    .executive-guide-list strong {
        color: #0f172a;
    }

/** batch selection page **/
.batch-selection-card {
    background: #ffffff;
    border: 1px solid #dbe2ea;
    border-radius: 12px;
    padding: 2rem 1.75rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 280px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

    .batch-selection-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 16px -2px rgba(15, 23, 42, 0.08);
        border-color: #cbd5e1;
    }

    .batch-selection-card.active-batch {
        border-color: #2563eb;
        box-shadow: 0 0 0 1.5px #2563eb, 0 4px 12px rgba(37, 99, 235, 0.08);
    }

.batch-card-header h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 0.25rem;
}

.batch-desc {
    font-size: 0.88rem;
    color: #64748b;
    margin-bottom: 1.75rem;
}

.batch-metrics {
    margin-bottom: 2rem;
}

.batch-size {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    line-height: 1;
    margin-bottom: 0.75rem;
}

.size-prefix {
    font-weight: 600;
}

.text-blue {
    color: #1d68bd;
}

.text-teal {
    color: #0d9488;
}

.batch-range {
    font-size: 0.85rem;
    color: #64748b;
    font-weight: 500;
}

.batch-form {
    margin-top: auto;
    width: 100%;
}

.btn-load {
    width: 100%;
    padding: 0.75rem 1rem;
    background-color: #3b4b5e;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 0.925rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.15s ease, transform 0.1s ease;
}

    .btn-load:hover {
        background-color: #2c3847;
    }

.btn-loaded {
    background-color: #1e293b;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

/** Glossary **/
.glossary-hero {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}

.filter-pill {
    padding: 0.35rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.8rem;
    font-weight: 600;
    background: #f1f5f9;
    color: #475569;
    text-decoration: none;
    transition: all 0.15s ease;
    border: 1px solid #e2e8f0;
}

    .filter-pill:hover {
        background: #0284c7;
        color: #ffffff;
        border-color: #0284c7;
    }

/* Desktop View: Table */
.desktop-glossary {
    display: none;
}

/* Mobile View: Flexible Cards */
.mobile-glossary {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.glossary-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem 1.15rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
}

.glossary-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.4rem;
}

.glossary-card-acronym {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 1.15rem;
    font-weight: 700;
    color: #0284c7;
}

.glossary-card-fullname {
    font-size: 0.95rem;
    font-weight: 600;
    color: #0f172a;
    margin-bottom: 0.5rem;
}

.glossary-card-desc {
    font-size: 0.86rem;
    color: #475569;
    line-height: 1.5;
    margin-bottom: 0.65rem;
}

.glossary-card-meta {
    font-size: 0.78rem;
    font-family: 'IBM Plex Mono', monospace;
    color: #64748b;
    background: #f8fafc;
    padding: 0.35rem 0.5rem;
    border-radius: 4px;
    border-left: 3px solid #0284c7;
}

/* Breakpoint */
@media (min-width: 768px) {
    .mobile-glossary {
        display: none;
    }

    .desktop-glossary {
        display: block;
    }
}

/*** exit demo button ***/
.btn-exit-demo {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.35rem 0.75rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: #475569 !important;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.15s ease-in-out;
}

    .btn-exit-demo:hover {
        background: #0f172a;
        color: #ffffff !important;
        border-color: #0f172a;
    }