html {
    background: var(--bg-html);
}

body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background: var(--bg-body);
    color: var(--text-primary);
}

:root {
    --sentinel-primary: #60a5fa;
    --sentinel-primary-light: rgba(96, 165, 250, 0.15);
    --sentinel-surface: var(--bg-surface);
    --sentinel-surface-border: var(--border-default);
    --sentinel-input-bg: var(--input-bg);
    --sentinel-input-border: var(--input-border);
    --sentinel-text: var(--text-primary);
    --sentinel-text-muted: var(--text-muted);
    --sentinel-heading: var(--text-heading);
}

.login-page {
    min-height: 100vh;
    background: var(--login-bg);
    display: flex;
    flex-direction: column;
}

.login-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 32px 20px 48px;
    gap: 20px;
}

.login-brand {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.login-brand-logo {
    width: 140px;
    height: auto;
    object-fit: contain;
}

.login-brand-logo-main {
    width: 250px;
}

.login-brand-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-heading);
}

.login-brand-subtitle {
    font-size: 14px;
    color: var(--text-muted);
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: var(--login-card-bg);
    border-radius: 18px;
    padding: 24px;
    box-shadow: 0 12px 30px var(--login-card-shadow);
    border: 1px solid var(--login-card-border);
}

.login-input {
    background: var(--input-bg) !important;
    border: 1px solid var(--input-border);
    border-radius: 12px;
    padding: 10px 12px;
    color: var(--text-input) !important;
}

.login-input:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.2);
    background: var(--input-bg) !important;
    color: var(--text-input) !important;
}

.login-input option {
    background: var(--input-bg);
    color: var(--text-input);
}

/* Override browser autofill white background */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
select:-webkit-autofill,
select:-webkit-autofill:hover,
select:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--input-autofill-text);
    -webkit-box-shadow: 0 0 0px 1000px var(--input-autofill-bg) inset;
    box-shadow: 0 0 0px 1000px var(--input-autofill-bg) inset;
    border-color: var(--input-border);
    transition: background-color 5000s ease-in-out 0s;
}

.login-button {
    width: 100%;
    height: 48px;
    border-radius: 12px;
    background: #2563eb;
    color: #fff;
    font-weight: 600;
    border: none;
}

.login-button:hover {
    background: #1d4ed8;
}

.login-button:disabled {
    opacity: 0.75;
}

.login-error {
    max-width: 420px;
    width: 100%;
    background: var(--login-error-bg);
    color: var(--login-error-text);
    border-radius: 12px;
    padding: 12px 16px;
    border: 1px solid var(--login-error-border);
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: var(--accent-link);
}

.btn-primary {
    color: #fff;
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.btn-primary:hover {
    background-color: var(--accent-primary-hover);
    border-color: var(--accent-primary-hover);
}

.btn-outline-primary {
    color: var(--btn-outline-primary-text);
    border-color: var(--btn-outline-primary-border);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
    color: #fff;
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-select:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem var(--focus-ring-outer), 0 0 0 0.25rem var(--accent-primary-light);
  border-color: var(--accent-link);
}

.form-control,
.form-select,
.form-check-input {
    background-color: var(--input-bg);
    border-color: var(--input-border);
    border-radius: 12px;
    color: var(--text-input);
}

.form-control:focus,
.form-select:focus {
    background-color: var(--input-bg);
    color: var(--text-input);
}

.form-control:disabled,
.form-select:disabled,
.form-control[readonly] {
    background-color: var(--input-disabled-bg);
    color: var(--input-disabled-text);
}

.form-control::placeholder {
    color: var(--text-muted);
}

.form-floating > label {
    color: var(--text-muted);
}

.form-label, label {
    color: var(--text-label);
}

.form-text {
    color: var(--text-muted);
}

.card {
    background: var(--card-bg);
    border-radius: 18px;
    border: 1px solid var(--card-border);
    box-shadow: 0 4px 14px var(--bg-card-shadow);
    color: var(--text-primary);
}

.card-title { color: var(--text-heading); }
.card-text { color: var(--text-label); }

.card-header,
.card-footer {
    background: transparent;
    border-color: var(--sentinel-surface-border);
}

.table-responsive {
    background: var(--bg-surface);
    border-radius: 16px;
    border: 1px solid var(--border-default);
    box-shadow: 0 4px 14px var(--bg-card-shadow);
    padding: 8px 12px;
}

.table thead th {
    color: var(--table-th-text);
    font-weight: 600;
    border-bottom-color: var(--table-th-border);
}

.table tbody tr {
    border-color: var(--border-default);
}

.table tbody td {
    color: var(--text-primary);
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
    background-color: var(--table-stripe-odd);
}

.table-striped > tbody > tr:nth-of-type(even) > * {
    background-color: var(--table-stripe-even);
}

.table > :not(caption) > * > * {
    background-color: transparent;
}

.table-hover > tbody > tr:hover > * {
    background-color: var(--table-hover);
}

.modal-header,
.modal-footer {
    border-color: var(--border-default);
}

.modal-title {
    color: var(--text-heading);
    font-weight: 700;
}

.table {
    background: var(--bg-surface);
    border-radius: 12px;
    color: var(--text-primary);
}

.modal-content {
    background-color: var(--card-bg) !important;
    border-radius: 18px;
    border: 1px solid var(--card-border);
    box-shadow: 0 12px 30px var(--bg-modal-shadow);
    color: var(--text-primary);
}

.modal-header {
    background-color: var(--bg-surface-alt);
    color: var(--text-heading);
}

.modal-body {
    background-color: var(--card-bg);
    color: var(--text-primary);
}

.modal-footer {
    background-color: var(--card-bg);
}

.modal-body .col-form-label,
.modal-body label {
    color: var(--text-label);
}

.modal-body .form-control,
.modal-body .form-select {
    background-color: var(--input-bg);
    border-color: var(--input-border);
    color: var(--text-input);
}

.modal-body .form-check-input {
    background-color: var(--input-bg);
    border-color: var(--input-border);
}

.modal-body .form-check-input:checked {
    background-color: var(--accent-primary);
    border-color: var(--accent-primary);
}

.modal-body .form-check-label {
    color: var(--text-primary);
}

.modal-body .input-group .form-select {
    background-color: var(--input-bg);
    color: var(--text-input);
}

.modal-backdrop.show {
    background-color: rgba(0, 0, 0, 0.6);
}

h1, h2, h3, h4, h5, h6 { color: var(--text-heading); }
.text-muted { color: var(--text-muted) !important; }

.alert-info { background: var(--alert-info-bg); border-color: var(--alert-info-border); color: var(--alert-info-text); }
.alert-warning { background: var(--alert-warning-bg); border-color: var(--alert-warning-border); color: var(--alert-warning-text); }
.alert-danger { background: var(--alert-danger-bg); border-color: var(--alert-danger-border); color: var(--alert-danger-text); }
.alert-success { background: var(--alert-success-bg); border-color: var(--alert-success-border); color: var(--alert-success-text); }

.badge.text-bg-light { background: var(--badge-light-bg) !important; color: var(--badge-light-text) !important; }
.badge.text-bg-secondary { background: var(--badge-secondary-bg) !important; color: var(--badge-secondary-text) !important; }
.badge.text-bg-primary { background: rgba(37, 99, 235, 0.2) !important; color: #60a5fa !important; }
.badge.text-bg-success { background: rgba(16, 185, 129, 0.2) !important; color: #34d399 !important; }
.badge.text-bg-warning { background: rgba(245, 158, 11, 0.2) !important; color: #fbbf24 !important; }
.badge.text-bg-danger { background: rgba(239, 68, 68, 0.2) !important; color: #f87171 !important; }
.badge.text-bg-info { background: rgba(6, 182, 212, 0.2) !important; color: #22d3ee !important; }

.list-group-item {
    background: var(--list-group-bg);
    border-color: var(--list-group-border);
    color: var(--text-primary);
}

.list-group-item:hover {
    background: var(--list-group-hover);
}

.page-link {
    background: var(--pagination-bg);
    border-color: var(--pagination-border);
    color: var(--pagination-text);
}

.page-link:hover {
    background: var(--pagination-hover-bg);
    color: var(--pagination-hover-text);
}

.page-item.active .page-link {
    background: #2563eb;
    border-color: #2563eb;
}

.content {
    padding-top: 1.1rem;
}

/* Dark file input */
input[type="file"]::file-selector-button {
    background: var(--file-btn-bg);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 6px 16px;
    font-weight: 600;
    cursor: pointer;
    margin-right: 12px;
}

input[type="file"]::file-selector-button:hover {
    background: var(--file-btn-hover);
}

/* Validation summary dark */
.validation-summary-errors,
.validation-errors {
    color: #f87171;
}

.validation-summary-errors ul {
    padding-left: 1rem;
}

/* Dark select dropdown options */
.form-select option {
    background: var(--input-bg);
    color: var(--text-input);
}

/* Dark card-header text */
.card-header {
    color: var(--text-heading);
}

/* Close button — adapts to theme */
.btn-close {
    filter: var(--btn-close-filter);
}

.modal-header .btn-close {
    filter: var(--btn-close-filter);
}

/* ── Unified page title bar ── */
.page-title-bar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    margin-bottom: 0.75rem;
    flex-wrap: nowrap;
    min-height: 44px;
}
.page-title-bar-left {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 0 0 auto;
}
.page-title-bar-icon {
    font-size: 1.2rem;
}
.page-title-bar-title {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: nowrap;
}
.page-title-bar-subtitle {
    margin: 0;
    font-size: 0.75rem;
    color: var(--text-muted, #6c757d);
    line-height: 1.2;
}
.page-title-bar-center {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
    max-width: 500px;
    margin: 0 auto;
}
.page-title-bar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 0 0 auto;
    margin-left: auto;
}
.page-title-bar-brand {
    height: 40px !important;
    max-height: 40px !important;
    width: auto !important;
    max-width: 220px;
    object-fit: contain;
    flex-shrink: 0;
}

/* ── Org context (picker or label) ── */
.org-context {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}
.org-context-lbl {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-muted, #6c757d);
    white-space: nowrap;
}
.org-context-select {
    width: 200px;
    font-size: 0.78rem;
    border-radius: 6px;
    border: 1px solid var(--input-border, #ced4da);
    background: var(--input-bg, #fff);
    color: var(--text-input, #212529);
    padding: 2px 8px;
    height: 30px;
}
.org-context-label {
    font-size: 0.8rem;
    color: var(--text-heading);
    font-weight: 500;
}
.org-context-logo {
    height: 30px;
    width: auto;
    object-fit: contain;
    border-radius: 3px;
}
.org-context-name {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
}

/* ── Role context (picker) ── */
.role-context {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-right: 0.75rem;
}
.role-context-lbl {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-muted, #6c757d);
    white-space: nowrap;
}
.role-context-select {
    width: 180px;
    font-size: 0.78rem;
    border-radius: 6px;
    border: 1px solid var(--input-border, #ced4da);
    background: var(--input-bg, #fff);
    color: var(--text-input, #212529);
    padding: 2px 8px;
    height: 30px;
}

.theme-toggle-btn {
    background: var(--bg-surface-alt);
    border: 1px solid var(--border-default);
    color: var(--text-label);
    border-radius: 8px;
    padding: 4px 10px;
    font-size: 0.82rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.theme-toggle-btn:hover {
    background: var(--bg-surface-hover);
    color: var(--text-heading);
}

/* Hide page-title-bar on dashboard pages — they have their own headers */
main:has(.dark-dash) .page-title-bar,
main:has(.noc-dash) .page-title-bar {
    display: none;
}

main:has(.dark-dash),
main:has(.noc-dash) {
    height: 100vh;
    overflow: hidden;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}

#blazor-error-ui {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: absolute;
    display: block;
    width: 8rem;
    height: 8rem;
    inset: 20vh 0 auto 0;
    margin: 0 auto 0 auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* Bootstrap's .form-control-plaintext keeps its own dark color in dark mode (illegible
   on dark surfaces e.g. the Review VIP card). Force it to follow the themed text color.
   !important is needed because Bootstrap's --bs-body-color isn't overridden by our theme. */
.form-control-plaintext {
    color: var(--text-primary) !important;
}

:focus-visible {
    outline: 2px solid #0d6efd;
    outline-offset: 2px;
}

.btn:focus-visible,
.btn-link:focus-visible,
.form-control:focus-visible,
.form-select:focus-visible {
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.35);
}

.btn-link:focus-visible {
    text-decoration: underline;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

:focus-visible {
    outline: 2px solid #1b6ec2;
    outline-offset: 2px;
}

.btn:focus-visible,
.btn-link:focus-visible,
.form-control:focus-visible,
.form-select:focus-visible {
    box-shadow: 0 0 0 0.25rem rgba(27, 110, 194, 0.35);
}

.btn-link:focus-visible {
    text-decoration: underline;
}

/* ═══════════════════════════════════════════════════════════
   BPC Beat — Dashboard Design System (moved from Home.razor.css)
   ═══════════════════════════════════════════════════════════ */

.dark-dash {
    background: var(--dash-bg);
    margin: -1.1rem -1.5rem 0;
    padding: 0.6rem 1.5rem 1rem;
    height: 100vh;
    display: flex;
    flex-direction: column;
    color: var(--text-primary);
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.dark-dash h3, .dark-dash h4, .dark-dash h5, .dark-dash h6 { color: var(--text-heading); }
.dark-dash a { color: var(--text-primary); text-decoration: none; }
.dark-dash a:hover { color: var(--text-heading); }

.dash-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
    margin-bottom: 0.5rem;
    gap: 1rem;
}
.dash-header-org {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    max-width: 500px;
}
.dash-header-org .org-context-select {
    background: var(--dash-picker-bg) !important;
    border: 1px solid var(--dash-picker-border) !important;
    color: var(--dash-picker-text) !important;
}
.dash-header-org .org-context-select option {
    background: var(--dash-picker-option-bg);
    color: var(--dash-picker-option-text);
}
.dash-header-org .org-context-name,
.dash-header-org .org-context-lbl {
    color: var(--dash-picker-label) !important;
}
.dash-header-org .role-context-select {
    background: var(--dash-picker-bg) !important;
    border: 1px solid var(--dash-picker-border) !important;
    color: var(--dash-picker-text) !important;
}
.dash-header-org .role-context-select option {
    background: var(--dash-picker-option-bg);
    color: var(--dash-picker-option-text);
}
.dash-header-org .role-context-lbl {
    color: var(--dash-picker-label) !important;
}

.dash-title { font-weight: 700; font-size: 1.35rem; margin-bottom: 0; }
.dash-subtitle { color: var(--dash-subtitle-text); font-size: 0.8rem; margin-bottom: 0; }

.dash-logo {
    height: 40px !important;
    max-height: 40px !important;
    width: auto !important;
    max-width: 220px;
    object-fit: contain;
    flex-shrink: 0;
}

.dash-stat {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.85rem;
    border-radius: 12px;
    background: var(--dash-stat-bg);
    border: 1px solid var(--dash-stat-border);
    color: var(--dash-board-text);
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
    min-height: 0;
}

.dash-stat:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px var(--bg-card-shadow);
    border-color: var(--border-input);
}

.dash-stat-icon-wrap {
    width: 36px; height: 36px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem; flex-shrink: 0; color: #fff;
}

.dash-stat-teal  .dash-stat-icon-wrap { background: #0d9488; }
.dash-stat-amber .dash-stat-icon-wrap { background: #d97706; }
.dash-stat-red   .dash-stat-icon-wrap { background: #dc2626; }
.dash-stat-blue  .dash-stat-icon-wrap { background: #2563eb; }

.dash-stat-info { flex: 1; min-width: 0; }
.dash-stat-label { font-weight: 600; font-size: 0.78rem; line-height: 1.15; color: var(--dash-board-text); }
.dash-stat-sub { font-size: 0.65rem; color: var(--text-muted); }
.dash-stat-num { font-size: 1.35rem; font-weight: 700; flex-shrink: 0; margin-left: auto; color: var(--text-heading); }

.dash-card {
    background: var(--dash-card-bg);
    border: 1px solid var(--dash-card-border);
    border-radius: 12px;
    padding: 0.65rem 0.75rem;
}

.dash-card-header {
    display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.4rem;
}

.dash-card-header h6 { margin: 0; font-weight: 600; font-size: 0.82rem; color: var(--dash-board-text); }

.dash-btn {
    padding: 0.2rem 0.6rem; border-radius: 7px;
    border: 1px solid var(--border-input);
    background: var(--dash-btn-bg); color: var(--dash-btn-text);
    font-size: 0.72rem; font-weight: 500; cursor: pointer;
    transition: all 0.12s ease; white-space: nowrap;
}
.dash-btn:hover { background: var(--dash-btn-hover-bg); color: var(--text-heading); }

.dash-main-panel { flex: 1; min-height: 0; display: flex; flex-direction: column; margin-bottom: 0.5rem; }
.dash-main-panel > .dash-card { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.dash-main-panel .dash-board-wrap { flex: 1; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(255,255,255,0.08) transparent; }

.dash-bottom-row { flex-shrink: 0; }

.dash-board-wrap { border-radius: 8px; border: 1px solid var(--dash-card-border); }
.dash-board { width: 100%; border-collapse: collapse; font-size: 0.78rem; }
.dash-board thead th { background: var(--dash-btn-bg); color: var(--text-label); font-weight: 600; font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.04em; padding: 0.45rem 0.6rem; border-bottom: 1px solid var(--border-input); white-space: nowrap; }
.dash-board tbody tr { border-bottom: 1px solid var(--dash-board-border); cursor: pointer; transition: background 0.1s ease; }
.dash-board tbody tr:hover { background: var(--dash-board-hover); }
.dash-board tbody td { padding: 0.4rem 0.6rem; color: var(--text-primary); vertical-align: middle; }
.dash-board-org-logo { width: 24px; height: 24px; border-radius: 4px; object-fit: contain; background: rgba(255,255,255,0.06); vertical-align: middle; }

/* NOC board cell styles — readable in both light and dark */
.noc-cell-bold { font-weight: 600; color: var(--text-heading, #111827); }
.noc-cell-text { color: var(--text-primary, #111827); }
.noc-cell-mono { font-family: monospace; font-size: 0.76rem; color: var(--text-primary, #111827); }
.noc-cell-muted { color: var(--text-muted, #4b5563); }
.dark-dash .noc-cell-bold { color: #f1f5f9; }
.dark-dash .noc-cell-text { color: #e2e8f0; }
.dark-dash .noc-cell-mono { color: #e2e8f0; }
.dark-dash .noc-cell-muted { color: #64748b; }

/* Date filter inputs — uses theme variables for both light and dark */
.noc-date-label { font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; color: var(--noc-heading, #111827); white-space: nowrap; }
.noc-date-input { background: var(--noc-control-bg, #ffffff); border: 1px solid var(--noc-border, #d1d5db); border-radius: 6px; color: var(--noc-text, #111827); font-size: 0.78rem; padding: 0.25rem 0.5rem; }

/* Dark-dash (Home.razor embedded board) — always dark */
.dark-dash .noc-date-label { color: #94a3b8; }
.dark-dash .noc-date-input { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.15); color: #e2e8f0; }
.dark-dash .noc-date-input::-webkit-calendar-picker-indicator { filter: invert(0.8); }

.dash-board .status-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 0.3rem; vertical-align: middle; }
.dash-board .status-dot-green { background: #10b981; }
.dash-board .status-dot-amber { background: #f59e0b; }
.dash-board .status-dot-red   { background: #ef4444; }
.dash-board .status-dot-blue  { background: #3b82f6; }
.dash-board .status-dot-gray  { background: #64748b; }
.dash-board-empty { color: var(--dash-board-empty); text-align: center; padding: 1.5rem; font-size: 0.8rem; }

.dash-feed-empty { color: var(--dash-feed-empty); font-size: 0.78rem; text-align: center; padding: 1rem 0; }

.dash-alert-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.35rem 0.4rem; border-bottom: 1px solid rgba(255,255,255,0.04); cursor: pointer; border-radius: 5px; transition: background 0.12s ease; }
.dash-alert-item:last-child { border-bottom: none; }
.dash-alert-item:hover { background: rgba(255,255,255,0.03); }
.dash-alert-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.dash-alert-title { font-size: 0.78rem; font-weight: 600; color: var(--dash-board-text); }
.dash-alert-sub { font-size: 0.68rem; color: var(--text-muted); }
.dash-alert-arrow { color: var(--text-muted); font-size: 0.7rem; margin-left: auto; flex-shrink: 0; }

.dash-section-label { font-size: 0.72rem; font-weight: 600; color: var(--text-label); margin-bottom: 0.35rem; padding-bottom: 0.25rem; border-bottom: 1px solid var(--dash-card-border); }

.dash-bar-row { display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.25rem; }
.dash-bar-label { width: 70px; font-size: 0.72rem; color: var(--text-label); flex-shrink: 0; }
.dash-bar-track { flex: 1; height: 16px; background: var(--dash-btn-bg); border-radius: 4px; overflow: hidden; }
.dash-bar-fill { height: 100%; border-radius: 4px; transition: width 0.6s cubic-bezier(0.4,0,0.2,1); min-width: 3px; }
.dash-bar-val { width: 24px; font-size: 0.72rem; font-weight: 600; color: var(--dash-board-text); text-align: right; flex-shrink: 0; }

.dash-qa-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.4rem; }
.dash-qa-tile { background: var(--dash-bg); border: 1px solid var(--dash-card-border); border-radius: 10px; padding: 0.5rem 0.4rem; text-align: center; cursor: pointer; transition: all 0.12s ease; }
.dash-qa-tile:hover { background: var(--dash-btn-bg); border-color: var(--border-input); transform: translateY(-1px); }
.dash-qa-icon { width: 34px; height: 34px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; font-size: 1rem; margin: 0 auto 0.25rem; }
.dash-qa-blue   { background: rgba(59,130,246,0.15);  color: #60a5fa; }
.dash-qa-green  { background: rgba(16,185,129,0.15);  color: #34d399; }
.dash-qa-slate  { background: rgba(100,116,139,0.2);  color: #94a3b8; }
.dash-qa-cyan   { background: rgba(6,182,212,0.15);   color: #22d3ee; }
.dash-qa-amber  { background: rgba(245,158,11,0.15);  color: #fbbf24; }
.dash-qa-purple { background: rgba(139,92,246,0.15);  color: #a78bfa; }
.dash-qa-red    { background: rgba(239,68,68,0.15);   color: #f87171; }
.dash-qa-title { font-size: 0.72rem; font-weight: 600; color: var(--dash-board-text); line-height: 1.15; }
.dash-qa-sub { font-size: 0.62rem; color: var(--text-muted); margin-top: 0.05rem; }

.dash-role-list { display: flex; flex-direction: column; gap: 0.2rem; }
.dash-role-item { display: flex; align-items: center; gap: 0.35rem; }
.dash-role-count-num { width: 16px; font-size: 0.72rem; font-weight: 600; color: var(--text-label); text-align: right; flex-shrink: 0; }
.dash-role-name { width: 110px; font-size: 0.74rem; color: var(--text-primary); flex-shrink: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dash-role-bar-track { flex: 1; height: 14px; background: var(--dash-btn-bg); border-radius: 4px; overflow: hidden; }
.dash-role-bar-fill { height: 100%; border-radius: 4px; background: linear-gradient(90deg, #06b6d4, #22d3ee); transition: width 0.6s cubic-bezier(0.4,0,0.2,1); min-width: 3px; }
.dash-role-count { width: 22px; font-size: 0.72rem; font-weight: 600; color: var(--text-label); text-align: right; flex-shrink: 0; }
.dark-dash .bg-success { background-color: #10b981 !important; }
.dark-dash .bg-danger  { background-color: #ef4444 !important; }
.dark-dash .bg-warning { background-color: #f59e0b !important; }
.dark-dash .bg-info    { background-color: #06b6d4 !important; }
.dark-dash .bg-primary { background-color: #3b82f6 !important; }

@media (min-width: 641px) {
    .dark-dash { margin: -1.1rem -1.5rem 0 -2rem; padding: 0.6rem 1.5rem 1rem; }
}

@media (max-width: 768px) {
    .dark-dash { padding: 0.5rem; overflow-y: auto; }
    .dash-stat { flex-wrap: wrap; gap: 0.4rem; padding: 0.5rem 0.7rem; }
    .dash-stat-num { font-size: 1.2rem; }
    .dash-qa-grid { gap: 0.35rem; }
    .dash-role-name { width: 70px; }
    .dash-bar-label { width: 60px; }
}

/* ── ActiveJourneys.razor.css (moved from scoped CSS) ── */
.active-journeys-page {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 80px);
}

.active-journeys-header {
    display: flex;
    align-items: center;
    padding: 8px 0;
    flex-shrink: 0;
}

.active-journeys-filters {
    flex-shrink: 0;
    display: none;
}

.active-journeys-body {
    display: flex;
    flex: 1;
    min-height: 0;
    gap: 0;
    border: 1px solid var(--border-default);
    border-radius: 8px;
    overflow: hidden;
}

.active-journeys-sidebar {
    width: 360px;
    min-width: 320px;
    max-width: 400px;
    overflow-y: auto;
    border-right: 1px solid var(--border-default);
    background: var(--bg-surface);
    padding: 0.5rem 0;
}

.active-journeys-list {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.active-journey-card {
    padding: 0.75rem 0.75rem;
    border-bottom: 1px solid var(--border-default);
    cursor: pointer;
    transition: background-color 0.15s;
}

    .active-journey-card:hover {
        background-color: var(--bg-surface-alt);
    }

    .active-journey-card.selected {
        background-color: rgba(37, 99, 235, 0.15);
        border-left: 3px solid #2563eb;
    }

    .active-journey-card.chat-active {
        background-color: rgba(245, 158, 11, 0.1);
        border-left: 3px solid #f59e0b;
    }

    .active-journey-card.completed {
        background-color: rgba(16, 185, 129, 0.05);
        opacity: 0.85;
    }

    .active-journey-card.completed.chat-active {
        background-color: rgba(16, 185, 129, 0.08);
        border-left: 3px solid #16a34a;
        opacity: 1;
    }

.active-journeys-map-container {
    flex: 1;
    position: relative;
    min-width: 0;
}

.active-journeys-map {
    width: 100%;
    height: 100%;
    min-height: 400px;
}

/* ── NOC Chat Panel ── */

.noc-chat-panel {
    width: 340px;
    min-width: 300px;
    max-width: 380px;
    display: flex;
    flex-direction: column;
    border-left: 1px solid var(--border-default);
    background: var(--bg-surface);
}

.noc-chat-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    border-bottom: 1px solid var(--border-default);
}

.noc-chat-section:last-child {
    border-bottom: none;
}

.noc-chat-section-header {
    padding: 6px 12px;
    font-size: 0.78rem;
    font-weight: 600;
    flex-shrink: 0;
}

    .noc-chat-section-header.vip {
        background: rgba(245, 158, 11, 0.1);
        color: #fbbf24;
        border-bottom: 1px solid rgba(245, 158, 11, 0.2);
    }

    .noc-chat-section-header.driver {
        background: rgba(37, 99, 235, 0.1);
        color: #60a5fa;
        border-bottom: 1px solid rgba(37, 99, 235, 0.2);
    }

.noc-chat-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-default);
    background: var(--bg-body);
    flex-shrink: 0;
}

.noc-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.noc-chat-bubble {
    max-width: 85%;
    padding: 6px 10px;
    border-radius: 10px;
    font-size: 0.82rem;
    line-height: 1.35;
    word-break: break-word;
}

    .noc-chat-bubble.own {
        align-self: flex-end;
        background: #1d4ed8;
        color: #fff;
        border-bottom-right-radius: 2px;
    }

    .noc-chat-bubble.other {
        align-self: flex-start;
        background: var(--bg-surface-alt);
        color: var(--text-primary);
        border-bottom-left-radius: 2px;
    }

.noc-chat-sender {
    font-weight: 600;
    font-size: 0.72rem;
    color: var(--text-label);
    margin-bottom: 1px;
}

.noc-chat-text {
    white-space: pre-wrap;
}

.noc-chat-time {
    font-size: 0.65rem;
    opacity: 0.7;
    text-align: right;
    margin-top: 2px;
}

.noc-chat-input {
    display: flex;
    gap: 6px;
    padding: 8px 10px;
    border-top: 1px solid var(--border-default);
    background: var(--bg-body);
    flex-shrink: 0;
}

.noc-chat-empty {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Journey Detail Panel ── */

.noc-detail-panel {
    border-top: 2px solid var(--border-default);
    padding: 12px;
    background: var(--bg-surface);
}

.noc-detail-header {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.85rem;
    flex-wrap: wrap;
}

.noc-detail-status-badge {
    font-size: 0.9rem !important;
    font-weight: 800 !important;
    padding: 0.4rem 0.8rem !important;
    border-radius: 999px !important;
    letter-spacing: 0.2px;
    box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.12);
}

.noc-detail-spid {
    font-size: 0.7rem;
    color: #6b7280;
    margin-left: auto;
}

.noc-detail-rating {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-top: 6px;
    padding: 4px 0;
}

.noc-rating-star {
    font-size: 1rem;
}

    .noc-rating-star.filled {
        color: #f59e0b;
    }

    .noc-rating-star.empty {
        color: #d1d5db;
    }

.noc-rating-comment {
    font-size: 0.7rem;
    color: #6b7280;
    font-style: italic;
    margin-left: 6px;
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.noc-detail-route {
    font-size: 0.78rem;
    color: var(--text-label);
    margin-top: 6px;
    padding: 4px 0;
    border-bottom: 1px dashed var(--border-default);
}

.noc-detail-times {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 4px;
}

.noc-detail-time {
    font-size: 0.72rem;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.noc-time-label {
    font-size: 0.64rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: #475569;
    min-width: 48px;
}

.noc-detail-time-actual {
    color: #334155;
    font-weight: 600;
}

.noc-detail-metrics {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.noc-detail-metric {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px;
    border-radius: 6px;
    background: var(--bg-surface-alt);
    border: 1px solid var(--border-default);
}

.noc-metric-value {
    font-weight: 700;
    font-size: 0.82rem;
    color: var(--accent-link);
}

.noc-metric-label {
    font-size: 0.65rem;
    color: var(--text-muted);
}

.noc-detail-photo {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.noc-detail-card-plate {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent-link);
    background: var(--bg-surface-alt);
    padding: 1px 6px;
    border-radius: 3px;
    display: inline-block;
    margin-top: 1px;
}

.noc-detail-addresses {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-top: 8px;
    border-top: 1px dashed var(--border-default);
}

.noc-detail-addr {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.72rem;
    color: var(--text-label);
}

.noc-addr-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

    .noc-addr-dot.pickup {
        background: #16a34a;
    }

    .noc-addr-dot.dest {
        background: #dc2626;
    }

.noc-detail-cards {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.noc-detail-card {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 6px;
    background: var(--bg-surface-alt);
    border: 1px solid var(--border-default);
}

.noc-detail-card-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

    .noc-detail-card-icon.driver {
        background: #3e7bdc;
        color: white;
    }

    .noc-detail-card-icon.vip {
        background: #c08b2f;
        color: white;
    }

    .noc-detail-card-icon.org {
        background: #1f2937;
        color: white;
    }

.noc-detail-card-body {
    min-width: 0;
}

.noc-detail-card-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-heading);
}

.noc-detail-card-sub {
    font-size: 0.7rem;
    color: var(--text-muted);
}

/* Status Timeline */
.noc-timeline-panel {
    border-top: 1px solid var(--border-default);
    padding: 10px 12px;
    background: var(--bg-surface);
}

.noc-timeline-header {
    font-weight: 700;
    font-size: 0.78rem;
    color: var(--text-label);
    margin-bottom: 8px;
}

.noc-timeline-step {
    display: flex;
    gap: 10px;
}

.noc-timeline-track {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 16px;
    flex-shrink: 0;
}

.noc-timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 2px solid;
}

    .noc-timeline-dot.dot-done {
        background: #16a34a;
        border-color: #16a34a;
    }

    .noc-timeline-dot.dot-current {
        background: var(--bg-surface);
        border-color: #2563eb;
        box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
    }

    .noc-timeline-dot.dot-pending {
        background: var(--bg-surface-alt);
        border-color: var(--border-input);
    }

    .noc-timeline-dot.dot-late {
        background: #dc2626;
        border-color: #dc2626;
    }

.noc-timeline-line {
    width: 2px;
    flex: 1;
    min-height: 16px;
}

    .noc-timeline-line.line-done {
        background: #16a34a;
    }

    .noc-timeline-line.line-pending {
        background: var(--border-input);
    }

.noc-timeline-content {
    padding-bottom: 10px;
    min-width: 0;
}

    .noc-timeline-content.text-done {
        color: #34d399;
    }

    .noc-timeline-content.text-current {
        color: #60a5fa;
        font-weight: 600;
    }

    .noc-timeline-content.text-pending {
        color: #64748b;
    }

    .noc-timeline-content.text-late {
        color: #dc2626;
    }

.noc-timeline-label {
    font-size: 0.78rem;
    display: flex;
    align-items: center;
    gap: 6px;
}

.noc-timeline-late-badge {
    font-size: 0.6rem;
    font-weight: 700;
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
    padding: 1px 5px;
    border-radius: 4px;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.noc-timeline-time {
    font-size: 0.7rem;
    margin-top: 1px;
}

.noc-timeline-planned {
    color: #9ca3af;
    margin-left: 4px;
}

.noc-timeline-eta {
    color: #6b7280;
    font-style: italic;
}

/* ── JourneyMonitor.razor.css (moved from scoped CSS) ── */
.journey-monitor-page {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 80px);
}

.journey-monitor-header {
    flex-shrink: 0;
}

.journey-monitor-body {
    display: flex;
    flex: 1;
    min-height: 0;
    gap: 0;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
}

.journey-monitor-map-section {
    flex: 1;
    position: relative;
    min-width: 0;
}

.journey-monitor-map {
    width: 100%;
    height: 100%;
    min-height: 400px;
}

.journey-monitor-info-overlay {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 290px;
    max-height: calc(100% - 24px);
    overflow-y: auto;
    z-index: 10;
}

/* Metrics row matching mobile TripInProgress 3-column layout */
.journey-monitor-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
}

.journey-monitor-chat-section {
    width: 380px;
    min-width: 340px;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    border-left: 1px solid #dee2e6;
    background: #fafafa;
}

.journey-monitor-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem;
    min-height: 0;
}

.journey-monitor-chat-quickreplies {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    padding-top: 4px;
    border-top: 1px solid #e9ecef;
}

/* ── NocDashboard.razor.css (moved from scoped CSS) ── */
/* ── NOC Dashboard — Airline Departures Board ── */

.noc-dash {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 80px);
    padding: 0 1rem;
    gap: 0;
    background: var(--noc-bg);
    margin: -1.1rem -1.5rem 0;
    padding: 0.6rem 1.5rem 1rem;
    color: var(--noc-text);
}

/* ── Header row ── */
.noc-dash-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    flex-shrink: 0;
    gap: 1rem;
}
.noc-dash-header-org {
    flex: 1 1 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    max-width: 500px;
}
.noc-dash-header-org .org-context-select {
    background: var(--dash-picker-bg) !important;
    border: 1px solid var(--dash-picker-border) !important;
    color: var(--dash-picker-text) !important;
}
.noc-dash-header-org .org-context-select option {
    background: var(--dash-picker-option-bg);
    color: var(--dash-picker-option-text);
}
.noc-dash-header-org .org-context-name,
.noc-dash-header-org .org-context-lbl {
    color: var(--dash-picker-label) !important;
}
.noc-dash-header-org .role-context-select {
    background: var(--dash-picker-bg) !important;
    border: 1px solid var(--dash-picker-border) !important;
    color: var(--dash-picker-text) !important;
}
.noc-dash-header-org .role-context-select option {
    background: var(--dash-picker-option-bg);
    color: var(--dash-picker-option-text);
}
.noc-dash-header-org .role-context-lbl {
    color: var(--dash-picker-label) !important;
}

.noc-dash-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--noc-heading);
    margin: 0;
}

.noc-dash-subtitle {
    font-size: 0.78rem;
    color: var(--noc-muted);
    margin: 0;
}

.noc-logo {
    height: 40px !important;
    max-height: 40px !important;
    width: auto !important;
    max-width: 220px;
    object-fit: contain;
    flex-shrink: 0;
    opacity: 1;
}

.noc-filter-select {
    width: 150px;
    background: var(--noc-control-bg) !important;
    border-color: var(--noc-border);
    color: var(--noc-text) !important;
    font-size: 0.82rem;
}

.noc-refresh-btn {
    background: var(--noc-control-bg);
    border: 1px solid var(--noc-border);
    color: var(--accent-link);
    font-size: 0.8rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
}

.noc-refresh-btn:hover { background: var(--noc-hover); }
.noc-refresh-btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* ── Stat cards ── */
.noc-stat-row {
    flex-shrink: 0;
    margin-bottom: 0.5rem;
}

.noc-stat {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 10px;
    background: var(--noc-card-bg);
    border: 1px solid var(--noc-border);
}

.noc-stat-icon {
    font-size: 1.1rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    flex-shrink: 0;
}

.noc-stat-teal .noc-stat-icon { background: rgba(16, 185, 129, 0.15); color: #10b981; }
.noc-stat-amber .noc-stat-icon { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.noc-stat-blue .noc-stat-icon { background: rgba(96, 165, 250, 0.15); color: #60a5fa; }
.noc-stat-red .noc-stat-icon { background: rgba(239, 68, 68, 0.15); color: #ef4444; }

.noc-stat-info { flex: 1; min-width: 0; }
.noc-stat-label { font-weight: 600; font-size: 0.78rem; color: var(--noc-cell-text); }
.noc-stat-sub { font-size: 0.68rem; color: var(--noc-muted); }
.noc-stat-num { font-size: 1.3rem; font-weight: 800; color: var(--noc-heading); font-family: 'Consolas', monospace; }

/* ── Notification bar ── */

/* ── SOS Alert ── */

.noc-sos-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #7f1d1d 0%, #991b1b 50%, #b91c1c 100%);
    color: #fff;
    border-radius: 8px;
    margin-bottom: 8px;
    flex-shrink: 0;
    border: 2px solid #ef4444;
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.5);
    animation: sosFlash 1s ease-in-out infinite;
}

.noc-sos-icon {
    font-size: 2rem;
    animation: sosPulse 0.6s ease-in-out infinite;
}

.noc-sos-body {
    flex: 1;
    min-width: 0;
}

.noc-sos-title {
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.noc-sos-detail {
    font-size: 0.82rem;
    opacity: 0.9;
    margin-top: 2px;
}

.noc-sos-time {
    margin-left: 8px;
    font-family: 'Consolas', monospace;
    opacity: 0.7;
}

@keyframes sosFlash {
    0%, 100% { box-shadow: 0 0 20px rgba(239, 68, 68, 0.5); }
    50% { box-shadow: 0 0 40px rgba(239, 68, 68, 0.8), 0 0 60px rgba(239, 68, 68, 0.3); }
}

@keyframes sosPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

/* ── Chat Notification bar ── */

.noc-notify {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    background: var(--noc-notify-bg);
    color: #fff;
    border-radius: 8px;
    margin-bottom: 8px;
    flex-shrink: 0;
    animation: slideDown 0.3s ease-out;
}

    .noc-notify.flash {
        animation: slideDown 0.3s ease-out, notifyPulse 1.5s ease-in-out 2;
    }

.noc-notify-icon {
    font-size: 1.5rem;
}

.noc-notify-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.noc-notify-preview {
    font-size: 0.85rem;
    opacity: 0.9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.noc-notify-journey {
    font-size: 0.72rem;
    opacity: 0.6;
}

/* ── Board table ── */

.noc-board-wrap {
    flex: 1;
    overflow-y: auto;
    border: 1px solid var(--noc-border);
    border-radius: 8px;
    background: var(--noc-board-bg);
}

.noc-board {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    font-family: 'Segoe UI', 'Roboto', sans-serif;
}

    .noc-board thead {
        position: sticky;
        top: 0;
        z-index: 10;
    }

    .noc-board th {
        background: var(--noc-th-bg);
        color: var(--noc-th-text);
        font-weight: 600;
        font-size: 0.72rem;
        text-transform: uppercase;
        letter-spacing: 0.8px;
        padding: 10px 12px;
        border-bottom: 2px solid var(--noc-th-border);
        white-space: nowrap;
    }

    .noc-board td {
        padding: 10px 12px;
        border-bottom: 1px solid var(--noc-row-border);
        color: var(--noc-cell-text);
        vertical-align: middle;
    }

    .noc-board tbody tr {
        cursor: pointer;
        transition: background-color 0.15s;
    }

        .noc-board tbody tr:hover {
            background-color: var(--noc-hover);
        }

    /* PA read-only rows — no pointer, no hover highlight */
    .noc-board tbody tr.noc-board-row-readonly {
        cursor: default;
    }

        .noc-board tbody tr.noc-board-row-readonly:hover {
            background-color: inherit;
        }

/* ── Health row backgrounds — vivid airline style ── */

.noc-board-row.health-green {
    background: transparent;
    border-left: 4px solid var(--noc-dot-green);
}

.noc-board-row.health-amber {
    background: transparent;
    border-left: 4px solid var(--noc-dot-amber);
}

.noc-board-row.health-red {
    background: transparent;
    border-left: 5px solid var(--noc-dot-red);
}

.noc-board-row.health-grey {
    background: transparent;
    border-left: 3px solid transparent;
}

.noc-board-row.health-done {
    background: transparent;
    border-left: 3px solid transparent;
}

/* ── Live (actively in-progress) row — overrides health background ── */
/* Distinct teal stripe so active trips never blend with scheduled amber/grey rows */

.noc-board-row.is-live {
    background: transparent !important;
    border-left: 5px solid #06b6d4 !important;
    border-right: 2px solid rgba(14, 165, 233, 0.65);
    box-shadow: none;
}

.noc-board-row.is-live.health-amber {
    background: transparent !important;
    border-left: 5px solid var(--noc-dot-amber) !important;
    border-right: 2px solid rgba(245, 158, 11, 0.55);
    box-shadow: none;
}

.noc-board-row.is-live.health-red {
    background: transparent !important;
    border-left: 5px solid var(--noc-dot-red) !important;
    border-right: 2px solid rgba(239, 68, 68, 0.65);
    box-shadow: none;
}

/* ── Org logo / initials ── */

.col-org {
    width: 44px;
    text-align: center;
}

.org-logo {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    object-fit: contain;
    background: #fff;
    padding: 1px;
}

.org-initials {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 4px;
    background: var(--noc-initials-bg);
    color: var(--noc-th-text);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* ── Status text — vivid per-health like airport boards ── */

.col-status-text {
    font-weight: 700;
    font-size: 0.82rem;
    white-space: nowrap;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.2px;
    border: 1px solid transparent;
    line-height: 1.15;
}

.status-pill-live {
    box-shadow: 0 0 0 2px rgba(14, 165, 233, 0.2);
}

.status-pill-green {
    background: rgba(16, 185, 129, 0.18);
    color: var(--noc-status-green);
    border-color: rgba(16, 185, 129, 0.28);
}

.status-pill-amber {
    background: rgba(245, 158, 11, 0.18);
    color: var(--noc-status-amber);
    border-color: rgba(245, 158, 11, 0.3);
}

.status-pill-red {
    background: rgba(239, 68, 68, 0.2);
    color: var(--noc-status-red);
    border-color: rgba(239, 68, 68, 0.34);
}

.status-pill-grey {
    background: rgba(148, 163, 184, 0.18);
    color: var(--noc-status-grey);
    border-color: rgba(148, 163, 184, 0.26);
}

.status-pill-done {
    background: rgba(100, 116, 139, 0.16);
    color: var(--noc-status-done);
    border-color: rgba(100, 116, 139, 0.24);
}

    .col-status-text.status-green {
        color: var(--noc-status-green);
    }

    .col-status-text.status-amber {
        color: var(--noc-status-amber);
    }

    .col-status-text.status-red {
        color: var(--noc-status-red);
        animation: blink 1.2s step-end infinite;
    }

    .col-status-text.status-grey {
        color: var(--noc-status-grey);
    }

    .col-status-text.status-done {
        color: var(--noc-status-done);
    }

/* ── ETA column colour ── */

.col-eta-green {
    color: var(--noc-status-green);
}

.col-eta-amber {
    color: var(--noc-status-amber);
}

.col-eta-red {
    color: var(--noc-status-red);
    font-weight: 700;
}

.col-eta-done {
    color: var(--noc-cell-text);
}

.col-eta-grey {
    color: var(--noc-cell-text);
}

/* ── Remarks (health label) — vivid colour ── */

.col-remarks {
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    color: var(--noc-cell-text);
}

    .col-remarks.health-green {
        color: var(--noc-status-green);
    }

    .col-remarks.health-amber {
        color: var(--noc-status-amber);
    }

    .col-remarks.health-red {
        color: var(--noc-status-red);
    }

    .col-remarks.health-grey {
        color: var(--noc-status-grey);
    }

    .col-remarks.health-done {
        color: var(--noc-status-done);
    }

/* ── Health dot ── */

.health-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

    .health-dot.health-green {
        background: var(--noc-dot-green);
        box-shadow: var(--noc-dot-green-glow);
    }

    .health-dot.health-amber {
        background: var(--noc-dot-amber);
        box-shadow: var(--noc-dot-amber-glow);
        animation: pulse 2s ease-in-out infinite;
    }

    .health-dot.health-red {
        background: var(--noc-dot-red);
        box-shadow: var(--noc-dot-red-glow);
        animation: pulse 1s ease-in-out infinite;
    }

    .health-dot.health-grey {
        background: var(--noc-dot-grey);
    }

    .health-dot.health-done {
        background: var(--noc-dot-grey);
    }

.col-health {
    width: 30px;
    text-align: center;
}

.col-vip {
    font-weight: 600;
    white-space: nowrap;
    max-width: 150px;
    color: var(--noc-heading);
}

.col-route {
    max-width: 200px;
    font-size: 0.78rem;
    color: var(--noc-text);
}

.col-time {
    white-space: nowrap;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 0.82rem;
    letter-spacing: 0.3px;
    color: var(--noc-cell-text);
}

.col-driver {
    max-width: 130px;
    color: var(--noc-text);
}

.col-action {
    width: 60px;
    text-align: right;
}

/* ── Rating stars ── */

.col-rating {
    white-space: nowrap;
    font-size: 0.82rem;
    letter-spacing: 1px;
}

.star {
    font-size: 0.85rem;
}

.star-filled {
    color: var(--noc-star-filled);
    text-shadow: var(--noc-star-filled-glow);
}

.star-empty {
    color: var(--noc-star-empty);
}

.btn-action {
    font-size: 0.72rem;
    padding: 2px 10px;
    border-color: var(--noc-border);
    color: var(--noc-muted);
}

    .btn-action:hover {
        background: var(--noc-hover);
        border-color: var(--noc-muted);
        color: var(--noc-heading);
    }

/* ── New message flash ── */

.noc-board-row.new-message {
    animation: rowFlash 0.6s ease-in-out 3;
}

/* ── Animations ── */

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

@keyframes rowFlash {
    0% { background-color: rgba(59, 130, 246, 0.3); }
    50% { background-color: rgba(59, 130, 246, 0.05); }
    100% { background-color: rgba(59, 130, 246, 0.3); }
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes notifyPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4); }
    50% { box-shadow: 0 0 0 8px rgba(59, 130, 246, 0); }
}

@keyframes blink {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0.3; }
}

/* ── ThreatIntelPage.razor.css (moved from scoped CSS) ── */
/* ── Threat Intelligence Page ── */

.threat-map-card {
    position: sticky;
    top: 1rem;
}

.threat-map-container {
    width: 100%;
    height: 280px;
    border-radius: 8px;
    border: 1px solid var(--border-default);
    z-index: 1;
}

/* Ensure Leaflet renders inside the card properly */
.threat-map-container .leaflet-container {
    border-radius: 8px;
}

@media (max-width: 991.98px) {
    .threat-map-container {
        height: 220px;
    }
}

/* ── TravelRequestDetail.razor.css (moved from scoped CSS) ── */
.travel-request-detail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.travel-request-detail-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.trip-timeline-row {
    display: grid;
    grid-template-columns: 16px 1fr;
    gap: 1rem;
    position: relative;
}

.trip-timeline-row::before {
    content: "";
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: rgba(148, 163, 184, 0.2);
}

.trip-timeline-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #1d4ed8;
    margin-top: 1rem;
    z-index: 1;
}

.trip-timeline-dot-warn {
    background: #dc3545;
}

/* Red border on date/time inputs involved in a leg timing conflict */
.input-conflict {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25);
}

.trip-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.trip-coordinates .form-control-sm {
    max-width: 140px;
}

.itinerary-map {
    height: 280px;
}

@media (max-width: 768px) {
    .travel-request-detail-header {
        flex-direction: column;
        align-items: stretch;
    }

    .travel-request-detail-actions {
        justify-content: flex-start;
    }
}

/* ── PA edit mode sticky bottom bar ── */
.pa-edit-sticky-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1050;
    background: #d97706;
    color: #fff;
    padding: 0.6rem 1.5rem;
    box-shadow: 0 -2px 8px rgba(0,0,0,0.15);
}

.pa-edit-sticky-bar .btn-light {
    color: #92400e;
    border-color: #fff;
}

.pa-edit-sticky-bar .btn-light:hover {
    background: #fef3c7;
}

/* ── TravelRequestReview.razor.css (moved from scoped CSS) ── */
.travel-request-review-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.travel-request-details-grid {
    align-items: stretch;
}

.travel-request-summary-card {
    gap: 0.5rem;
}

.travel-request-review-page .col-form-label {
    padding-top: 0;
    padding-bottom: 0;
}

.travel-request-details-card,
.travel-request-itinerary-card,
.travel-request-map-card {
    height: 100%;
}

.travel-request-itinerary-card {
    display: flex;
    flex-direction: column;
}

.travel-request-itinerary-items {
    overflow-y: auto;
}

.leg-assignment-card {
    background: var(--bg-surface-alt);
    transition: box-shadow 0.15s ease;
    border-color: var(--border-default);
}

.leg-assignment-card:hover {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.travel-request-map-card {
    display: flex;
    flex-direction: column;
}

.travel-request-map-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 280px;
}

.travel-request-map,
.travel-request-map-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 768px) {
    .travel-request-review-header {
        flex-direction: column;
        align-items: stretch;
    }
}

/* ── TravelRequests.razor.css (moved from scoped CSS) ── */
.travel-requests-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.travel-requests-search {
    min-width: 240px;
    max-width: 320px;
    width: 100%;
}

.travel-request-modal-dialog {
    max-width: 1200px;
}

.travel-request-details-grid {
    align-items: stretch;
}

.travel-request-summary-card {
    gap: 0.5rem;
}

.travel-request-modal .col-form-label {
    padding-top: 0;
    padding-bottom: 0;
}

.travel-request-details-card,
.travel-request-itinerary-card,
.travel-request-map-card {
    height: 100%;
}

.travel-request-itinerary-card {
    display: flex;
    flex-direction: column;
}

.travel-request-itinerary-items {
    overflow-y: auto;
    max-height: 320px;
}

.travel-request-map-card {
    display: flex;
    flex-direction: column;
}

.travel-request-map-body {
    flex: 1;
    display: flex;
}

.travel-request-map,
.travel-request-map-placeholder {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

@media (max-width: 768px) {
    .travel-requests-header {
        flex-direction: column;
        align-items: stretch;
    }

    .travel-requests-search {
        max-width: 100%;
    }

    .travel-request-modal-dialog {
        max-width: 100%;
    }
}

/* ── VipProfile.razor.css (moved from scoped CSS) ── */
.vip-profile-header {
    border: none;
    background: linear-gradient(135deg, #0f1b3d 0%, #1e2d5f 100%);
    color: #fff;
}

.vip-profile-header .card-body {
    background: transparent;
}

.vip-avatar-frame {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.vip-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.vip-avatar-placeholder {
    font-size: 2rem;
    font-weight: 600;
    color: #fff;
}

.vip-profile-actions .btn {
    min-width: 140px;
}

/* ── VipWizard.razor.css (moved from scoped CSS) ── */
.wizard-tabs {
    display: grid;
    gap: 12px;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.wizard-tab {
    border: 1px solid var(--sentinel-surface-border);
    background: var(--sentinel-surface);
    border-radius: 14px;
    padding: 12px 16px;
    text-align: left;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: var(--sentinel-primary);
    font-weight: 600;
    box-shadow: 0 8px 16px rgba(12, 27, 70, 0.08);
}

.wizard-tab.active {
    border-color: var(--sentinel-primary);
    box-shadow: 0 10px 20px rgba(12, 27, 70, 0.18);
}

.wizard-tab:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    box-shadow: none;
}

.wizard-tab-status {
    color: var(--sentinel-primary);
    font-weight: 700;
}

