/* ═══════════════════════════════════════════════════════════
   PRINT GRID — Global UI Overrides
   Dark-first design system corrections
   ═══════════════════════════════════════════════════════════ */

/* ── MudTabs: flex-scroll fix ──────────────────────────────
   Ensures tab panel areas fill available height and scroll
   instead of overflowing the viewport.                       */
.mud-tabs {
    display: flex;
    flex-direction: column;
}
.mud-tabs-panels {
    flex: 1 1 0;
    min-height: 0;
    overflow-y: auto;
}
.mud-tab-panel {
    height: 100%;
}

/* ── Active Tab — contrast + indicator ─────────────────────
   MudBlazor active tab uses .mud-tab-active on the button   */
.mud-tab.mud-tab-active .mud-tab-text-icon,
.mud-tab.mud-tab-active {
    color: var(--mud-palette-primary) !important;
    font-weight: 700 !important;
}
/* Visible bottom border on active tab */
.mud-tab.mud-tab-active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--mud-palette-primary);
    border-radius: 2px 2px 0 0;
}
.mud-tab {
    position: relative;
}

/* ── Inactive Tab text — readable on dark backgrounds ──────*/
.mud-tab:not(.mud-tab-active) .mud-tab-text-icon {
    color: var(--mud-palette-text-secondary) !important;
    opacity: 0.85;
}

/* ── MudTextField text contrast on dark ────────────────────
   Ensures typed text and placeholder text are legible       */
.mud-input-root input,
.mud-input-root textarea {
    color: var(--mud-palette-text-primary) !important;
}
.mud-input-root input::placeholder,
.mud-input-root textarea::placeholder {
    color: var(--mud-palette-text-secondary) !important;
    opacity: 0.75;
}
/* Outlined variant border visibility */
.mud-input-outlined .mud-input-outlined-border {
    border-color: var(--mud-palette-lines-default) !important;
}
.mud-input-outlined:hover .mud-input-outlined-border {
    border-color: var(--mud-palette-text-secondary) !important;
}
.mud-input-outlined.mud-input-root-adorned-start .mud-input-adornment {
    color: var(--mud-palette-text-secondary);
}

/* ── MudText on dark surface — ensure #E0E0E0 minimum ──────*/
.mud-typography {
    color: var(--mud-palette-text-primary);
}

/* ── Custom scrollbar — dark theme ─────────────────────────*/
::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: #1e293b;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #334155;
}
