/**
 * Akasa Virtual EFB - Stylesheet
 * ===============================
 * Version: 3.0.0
 * 
 * Aviation-inspired dark theme with Akasa branding
 */

/* ============================================
   CSS VARIABLES
   ============================================ */

:root {
    /* Brand Colors */
    --accent-primary: #FF6300;
    --accent-secondary: #5C0FD9;
    
    /* Semantic Colors */
    --color-success: #22C55E;
    --color-warning: #F59E0B;
    --color-danger: #EF4444;
    --color-info: #3B82F6;
    
    /* Dark Theme (Default) */
    --bg-base: #0a0a0f;
    --bg-surface: #12121a;
    --bg-elevated: #1a1a24;
    --bg-input: #0f0f16;
    --bg-hover: #22222e;
    
    --text-primary: #f0f0f5;
    --text-secondary: #a0a0b0;
    --text-muted: #606070;
    
    --border-color: #2a2a38;
    --border-subtle: #1f1f28;
    
    /* Typography */
    --font-display: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;
    
    /* Spacing */
    --sidebar-width: 240px;
    --header-height: 64px;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
    
    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-normal: 250ms ease;
}

/* Light Theme */
[data-theme="light"] {
    --bg-base: #f5f5f8;
    --bg-surface: #ffffff;
    --bg-elevated: #ffffff;
    --bg-input: #f0f0f5;
    --bg-hover: #e8e8f0;
    
    --text-primary: #1a1a24;
    --text-secondary: #4a4a5a;
    --text-muted: #8a8a9a;
    
    --border-color: #d0d0e0;
    --border-subtle: #e0e0ea;
    
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* ============================================
   RESET & BASE
   ============================================ */

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

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-display);
    background: var(--bg-base);
    color: var(--text-primary);
    line-height: 1.5;
    overflow: hidden;
}

a { color: var(--accent-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

input, select, button, textarea {
    font-family: inherit;
    font-size: inherit;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.hidden { display: none !important; }
.accent { color: var(--accent-primary); }
.mono { font-family: var(--font-mono); }

.placeholder-text {
    color: var(--text-muted);
    font-size: 0.9rem;
    text-align: center;
    padding: 2rem 1rem;
}

/* ============================================
   Splash Screen - Full Page
   ============================================ */
.splash-screen {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s ease, visibility 0.5s ease;
    background: #0a0a0f;
}

.splash-screen.active {
    opacity: 1;
    visibility: visible;
}

.splash-screen.hiding {
    opacity: 0;
    visibility: hidden;
}

.splash-background {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    pointer-events: none;  /* ADD THIS LINE */
}

.splash-hint {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 2.5rem;
    animation: pulseHint 2s ease-in-out infinite;
}

.splash-hint-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    animation: bounceDown 1.5s ease-in-out infinite;
}

.splash-hint-icon svg {
    width: 24px;
    height: 24px;
    stroke: rgba(255, 255, 255, 0.9);
}

.splash-hint-text {
    font-family: var(--font-display), 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.85);
    text-transform: uppercase;
    letter-spacing: 0.2em;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.splash-screen::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, transparent 100%);
    pointer-events: none;
    z-index: 5;
}

@keyframes bounceDown {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(8px); }
}

@keyframes pulseHint {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

/* ============================================
   SCREENS
   ============================================ */

.screen {
    position: fixed;
    inset: 0;
    display: none;
}

.screen.active {
    display: flex;
}

/* ============================================
   LOGIN SCREEN
   ============================================ */

.login-screen {
    align-items: center;
    justify-content: center;
    background: var(--bg-base);
}

.login-bg-blur {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.login-bg-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.15;
    filter: blur(40px);
}

.login-card-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    padding: 1.5rem;
}

.login-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
}

.login-card-brand {
    text-align: center;
    margin-bottom: 2rem;
}

.login-logo {
    width: flex;
    height: flex;
    margin-bottom: 1rem;
}

.login-tagline {
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.15em;
    color: var(--accent-primary);
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.input-group-login input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 0.95rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.input-group-login input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(255, 99, 0, 0.15);
}

.input-group-login input::placeholder {
    color: var(--text-muted);
}

.login-status {
    text-align: center;
    font-size: 0.85rem;
    min-height: 1.5em;
    transition: color var(--transition-fast);
}

.login-status.info { color: var(--color-info); }
.login-status.success { color: var(--color-success); }
.login-status.warning { color: var(--color-warning); }
.login-status.error { color: var(--color-danger); }

.btn-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: var(--accent-primary);
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.05em;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: background var(--transition-fast), transform var(--transition-fast);
}

.btn-login:hover:not(:disabled) {
    background: #e55800;
}

.btn-login:active:not(:disabled) {
    transform: scale(0.98);
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.login-card-hint {
    margin-top: 1.5rem;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ============================================
   EFB MAIN LAYOUT
   ============================================ */

.efb-screen {
    display: none;
}

.efb-screen.active {
    display: flex;
}

/* Sidebar */
.efb-sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    background: var(--bg-surface);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
}

.sidebar-brand-image {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.5rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-brand-image .brand-logo {
    width: 64px;
    height: 64px;
    object-fit: contain;
}

.sidebar-brand-image .brand-text {
    font-family: 'Outfit', var(--font-display), sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
    letter-spacing: 0.02em;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.75rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
    width: 36px;
    height: 36px;
}

.sidebar-brand span {
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: 0.05em;
    color: var(--accent-primary);
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.nav-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.nav-item:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-item.active {
    background: rgba(255, 99, 0, 0.1);
    color: var(--accent-primary);
}

.sidebar-footer {
    padding: 1rem;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.pilot-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.pilot-avatar {
    width: 36px;
    height: 36px;
    background: var(--accent-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    color: white;
    flex-shrink: 0;
}

.pilot-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.pilot-name {
    font-weight: 600;
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pilot-status {
    font-size: 0.75rem;
    color: var(--color-success);
}

.btn-logout {
    width: 36px;
    height: 36px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.btn-logout svg {
    width: 18px;
    height: 18px;
}

.btn-logout:hover {
    background: var(--color-danger);
    border-color: var(--color-danger);
    color: white;
}

/* Main Content */
.efb-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    min-width: 0;
}

.efb-header {
    height: var(--header-height);
    padding: 0 1.5rem;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.header-title {
    display: flex;
    align-items: baseline;
    gap: 1rem;
}

.header-title h1 {
    font-size: 1.25rem;
    font-weight: 600;
}

.header-time {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--accent-primary);
    color: white;
    font-weight: 500;
    font-size: 0.85rem;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.btn-primary svg {
    width: 16px;
    height: 16px;
}

.btn-primary:hover {
    background: #e55800;
}

.btn-icon {
    width: 40px;
    height: 40px;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.btn-icon svg {
    width: 20px;
    height: 20px;
}

.btn-icon:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

/* Theme Toggle */
#btn-theme-toggle .icon-moon { display: none; }
[data-theme="light"] #btn-theme-toggle .icon-sun { display: none; }
[data-theme="light"] #btn-theme-toggle .icon-moon { display: block; }

/* Content Area */
.efb-content {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
}

/* Pages */
.page {
    display: none;
}

.page.active {
    display: block;
}

/* ============================================
   CARDS
   ============================================ */

.card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-subtle);
}

.card-header h2 {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ============================================
   DASHBOARD
   ============================================ */

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

/* Flight Card */
.card-flight {
    grid-column: span 1;
}

.flight-route {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    padding: 2rem;
}

.route-airport {
    text-align: center;
}

.airport-code {
    display: block;
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.airport-name {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    max-width: 150px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.route-line {
    flex: 1;
    max-width: 150px;
}

.route-line svg {
    width: 100%;
    height: 20px;
}

.flight-details {
    display: flex;
    justify-content: center;
    gap: 3rem;
    padding: 0 1.25rem 1.25rem;
}

.detail-item {
    text-align: center;
}

.detail-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-bottom: 0.25rem;
}

.detail-value {
    font-family: var(--font-mono);
    font-weight: 500;
}

/* Status Badge */
.status-badge {
    padding: 0.25rem 0.75rem;
    background: var(--bg-input);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
}

.status-badge.active {
    background: rgba(34, 197, 94, 0.15);
    color: var(--color-success);
}

/* Stats Card */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1px;
    background: var(--border-subtle);
}

.stat-item {
    background: var(--bg-surface);
    padding: 1.25rem;
    text-align: center;
}

.stat-value {
    display: block;
    font-family: var(--font-mono);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

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

/* Weather Card */
.weather-icao {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent-primary);
}

.weather-content {
    padding: 1rem 1.25rem;
}

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

.weather-item {
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 1.25rem 1rem;
    text-align: center;
    transition: transform var(--transition-fast);
}

.weather-item:hover {
    transform: translateY(-1px);
}

.weather-label {
    display: block;
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.4rem;
}

.weather-value {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 600;
}

.weather-raw {
    margin-top: 1rem;
}

.weather-raw-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.4rem;
}

.weather-raw-text {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    line-height: 1.5;
    color: var(--accent-primary);
    background: var(--bg-input);
    padding: 0.875rem 1rem;
    border-radius: var(--radius-sm);
    word-break: break-word;
    border-left: 3px solid var(--accent-primary);
}

/* ============================================
   FLIGHT PLAN (OFP) - ENLARGED LAYOUT
   ============================================ */

.ofp-container {
    max-width: 100%;
    margin: 0 auto;
}

.ofp-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    color: var(--text-muted);
}

.ofp-placeholder svg {
    width: 72px;
    height: 72px;
    margin-bottom: 1.25rem;
    opacity: 0.5;
}

.ofp-placeholder p {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.ofp-placeholder span {
    font-size: 0.9rem;
}

/* OFP Header */
.ofp-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem 2rem;
    margin-bottom: 1.5rem;
}

.ofp-header-left {
    text-align: left;
}

.ofp-header-left .ofp-callsign {
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
    font-family: var(--font-mono);
}

.ofp-header-left .ofp-aircraft {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-top: 0.35rem;
}

.ofp-header-center {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.ofp-header-center .ofp-icao {
    font-family: var(--font-mono);
    font-size: 2.25rem;
    font-weight: 700;
}

.ofp-header-center .ofp-icao.origin,
.ofp-header-center .ofp-icao.dest {
    color: var(--accent-primary);
}

.ofp-header-center .ofp-airport-name {
    font-size: 0.85rem;
    color: var(--text-muted);
    max-width: 150px;
    text-align: center;
}

.ofp-header-center .ofp-arrow {
    color: var(--text-muted);
    font-family: var(--font-mono);
    letter-spacing: 3px;
    font-size: 1.1rem;
}

.ofp-header-right {
    text-align: right;
}

.ofp-header-right .ofp-fl {
    font-family: var(--font-mono);
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.ofp-header-right .ofp-distance {
    font-size: 1rem;
    color: var(--text-secondary);
    margin-top: 0.25rem;
}

/* OFP Cards Grid */
.ofp-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.ofp-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
}

.ofp-card-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

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

.ofp-card-grid.times-grid {
    grid-template-columns: repeat(2, 1fr);
}

.ofp-card-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.ofp-card-item.centered {
    text-align: center;
}

.ofp-card-item .item-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.ofp-card-item .item-value {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 500;
}

.ofp-card-item .item-value.large {
    font-size: 1.75rem;
    font-weight: 600;
}

.ofp-card-item .item-value.accent {
    color: var(--accent-primary);
}

.ofp-card-rows {
    display: flex;
    flex-direction: column;
    gap: 0.625rem;
}

.ofp-row {
    display: flex;
    justify-content: space-between;
    font-size: 1rem;
}

.ofp-row span:first-child {
    color: var(--text-secondary);
}

.ofp-row span:last-child {
    font-family: var(--font-mono);
    font-weight: 500;
}

.ofp-row.total {
    border-top: 1px solid var(--border-subtle);
    padding-top: 0.625rem;
    margin-top: 0.35rem;
    font-weight: 600;
}

.ofp-row.total span:last-child {
    color: var(--accent-primary);
}

/* Route Section */
.ofp-route-section {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    margin-bottom: 1.5rem;
}

.ofp-section-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.ofp-route-text {
    font-family: var(--font-mono);
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.7;
    word-break: break-word;
}

/* EFOB Tracking Table */
.efob-section {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.efob-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid var(--border-subtle);
}

.efob-title {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.efob-title svg {
    width: 22px;
    height: 22px;
    color: var(--accent-primary);
}

.efob-status {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-right: 1rem;
}

.efob-status.active {
    color: var(--color-success);
}

.efob-badge {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.35rem 1rem;
    background: var(--accent-primary);
    color: white;
    border-radius: 20px;
}

.efob-table {
    width: 100%;
}

.efob-table-header {
    display: grid;
    grid-template-columns: 60px 1fr 100px 80px 100px 110px 160px;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: var(--bg-input);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
}

.efob-table-body {
    max-height: 500px;
    overflow-y: auto;
}

.efob-row {
    display: grid;
    grid-template-columns: 60px 1fr 100px 80px 100px 110px 160px;
    gap: 0.75rem;
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    transition: background var(--transition-fast);
    align-items: center;
}

.efob-row:hover {
    background: var(--bg-hover);
}

.efob-row .col-num {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.efob-row .col-wpt {
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 1rem;
}

.efob-row .col-via {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.efob-row .col-fl {
    font-family: var(--font-mono);
    color: var(--accent-primary);
    font-weight: 500;
}

.efob-row .col-planned,
.efob-row .col-actual {
    font-family: var(--font-mono);
    text-align: right;
}

.efob-row .col-dev {
    text-align: right;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.efob-row .col-actual {
    display: flex;
    justify-content: flex-end;
}

.efob-input {
    width: 70px;
    padding: 0.5rem 0.625rem;
    font-size: 0.95rem;
    text-align: center;
}

.efob-input.predicted {
    background: rgba(255, 99, 0, 0.1);
    border-color: rgba(255, 99, 0, 0.3);
    color: var(--accent-primary);
}

.efob-input.manual-entry {
    background: var(--bg-input);
    border-color: var(--color-success);
}

.col-dev.dev-positive {
    color: var(--color-success) !important;
}

.col-dev.dev-negative {
    color: var(--color-danger) !important;
}

.col-dev.dev-neutral {
    color: var(--text-secondary) !important;
}

.col-dev.predicted {
    font-style: italic;
}

/* ============================================
   WEATHER PAGE - ENLARGED
   ============================================ */

.weather-layout {
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.weather-panel-duo {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.weather-panel {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.weather-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    background: var(--bg-input);
    border-bottom: 1px solid var(--border-subtle);
}

.weather-panel-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
}

.weather-panel-header span {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.weather-panel-body {
    padding: 1.5rem;
}

/* Weather Data Grid */
.weather-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.weather-item {
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 1.25rem 1rem;
    text-align: center;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.weather-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.weather-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.weather-value {
    font-family: var(--font-mono);
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* METAR/TAF Raw Display */
.weather-raw {
    margin-top: 1rem;
}

.weather-raw-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.weather-raw-text {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    line-height: 1.6;
    color: var(--accent-primary);
    background: var(--bg-input);
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    word-break: break-word;
    border-left: 3px solid var(--accent-primary);
}

/* Manual Weather Search */
.weather-search {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.weather-search h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
}

.search-row {
    display: flex;
    gap: 1rem;
    align-items: flex-end;
}

.search-row input {
    flex: 1;
    max-width: 150px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    font-family: var(--font-mono);
    text-transform: uppercase;
}

.search-row .btn-primary {
    padding: 0.75rem 1.5rem;
}

#weather-search-result {
    margin-top: 1.5rem;
}

#weather-search-result .weather-panel {
    margin-top: 0;
}

/* Responsive */
@media (max-width: 1000px) {
    .weather-panel-duo {
        grid-template-columns: 1fr;
    }
    
    .weather-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .weather-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .weather-value {
        font-size: 1rem;
    }
}

/* ============================================
   PERFORMANCE PAGE - REDESIGNED
   ============================================ */

.perf-page {
    display: flex;
    flex-direction: column;
    height: 100%;
    gap: 1.25rem;
}

/* Header Bar */
.perf-header-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.125rem 1.75rem;
}

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

.perf-header-title svg {
    width: 36px;
    height: 36px;
    color: var(--accent-primary);
}

.perf-header-title h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.perf-subtitle {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.perf-header-actions {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.btn-perf-action {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1.125rem;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 0.95rem;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-perf-action svg {
    width: 18px;
    height: 18px;
}

.btn-perf-action:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.btn-calculate {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
}

.btn-calculate svg {
    width: 20px;
    height: 20px;
}

/* Content Grid */
.perf-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    flex: 1;
    min-height: 0;
}

/* Input Column */
.perf-inputs-column {
    display: flex;
    flex-direction: column;
    gap: 1.125rem;
    overflow-y: auto;
}

/* Results Column */
.perf-results-column {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

/* Performance Cards */
.perf-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.perf-results-card {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.perf-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    background: var(--bg-input);
    border-bottom: 1px solid var(--border-subtle);
}

.perf-card-header h3 {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
}

.perf-card-header h3 svg {
    width: 20px;
    height: 20px;
    color: var(--accent-primary);
}

.perf-card-body {
    padding: 1.25rem 1.5rem;
    flex: 1;
    overflow-y: auto;
}

.perf-results-card .perf-card-body {
    padding: 1.5rem;
}

/* Data Source Badge */
.data-source {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    background: var(--bg-elevated);
    border-radius: 10px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.data-source.live {
    background: rgba(34, 197, 94, 0.15);
    color: var(--color-success);
}

.data-source.manual {
    background: rgba(245, 158, 11, 0.15);
    color: var(--color-warning);
}

/* Input Grids */
.input-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

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

.input-grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1rem;
}

/* Input Fields */
.input-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-field label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.input-field input,
.input-field select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 1rem;
    transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.input-field input:focus,
.input-field select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(255, 99, 0, 0.1);
}

.input-field input:read-only {
    background: var(--bg-elevated);
    color: var(--text-secondary);
}

.input-field input.input-mono {
    font-family: var(--font-mono);
    font-size: 1.05rem;
}

/* Input with Unit */
.input-with-unit {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-unit input {
    padding-right: 3rem;
}

.input-with-unit .unit {
    position: absolute;
    right: 0.875rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    pointer-events: none;
}

/* Input with Button */
.input-with-btn {
    display: flex;
    gap: 0.625rem;
}

.input-with-btn input {
    flex: 1;
}

.btn-input-action {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--accent-primary);
    border: none;
    border-radius: var(--radius-sm);
    color: white;
    cursor: pointer;
    transition: background var(--transition-fast);
}

.btn-input-action svg {
    width: 18px;
    height: 18px;
}

.btn-input-action:hover {
    background: #e55800;
}

/* Compact Runway Visualization */
.runway-viz-compact {
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    padding: 1rem;
    margin-top: 0.75rem;
}

.runway-viz-placeholder {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
    padding: 0.75rem;
}

.runway-viz-inner {
    width: 100%;
}

.runway-track {
    position: relative;
    height: 36px;
    background: #1a1a24;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.625rem;
}

.runway-markings {
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
}

.runway-id {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 3px rgba(0,0,0,0.5);
}

/* TO SHIFT area (unusable portion) */
.runway-shift {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: repeating-linear-gradient(
        45deg,
        rgba(255, 255, 255, 0.05),
        rgba(255, 255, 255, 0.05) 4px,
        transparent 4px,
        transparent 8px
    );
    border-right: 2px dashed rgba(255, 99, 0, 0.6);
    z-index: 1;
}

.runway-tora {
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--accent-primary), rgba(255, 99, 0, 0.6));
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 0.875rem;
    z-index: 2;
}

.runway-tora.full-length {
    left: 0;
    right: auto;
    width: 100% !important;
}

.tora-label {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
}

.runway-stats {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    color: var(--text-secondary);
    flex-wrap: wrap;
    gap: 0.625rem;
}

.runway-stats .to-shift {
    color: var(--accent-primary);
    font-weight: 600;
}

/* Weather METAR Display */
.weather-metar-line {
    display: flex;
    align-items: flex-start;
    gap: 0.625rem;
    padding: 0.75rem 1rem;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    margin-top: 0.75rem;
}

.metar-label {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-muted);
    flex-shrink: 0;
}

.metar-text {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--accent-primary);
    word-break: break-all;
    line-height: 1.5;
}

/* Results Placeholder */
.perf-results-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 320px;
    color: var(--text-muted);
    text-align: center;
}

.perf-results-placeholder svg {
    width: 56px;
    height: 56px;
    margin-bottom: 1.125rem;
    opacity: 0.4;
}

.perf-results-placeholder p {
    font-size: 1.1rem;
    margin-bottom: 0.375rem;
}

.perf-results-placeholder span {
    font-size: 0.9rem;
    opacity: 0.7;
}

/* Performance Results Display */
.perf-result-section {
    margin-bottom: 1.75rem;
}

.perf-result-section:last-child {
    margin-bottom: 0;
}

.perf-result-section h3 {
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.875rem;
    padding-bottom: 0.625rem;
    border-bottom: 1px solid var(--border-subtle);
}

/* V-Speeds Display */
.perf-speeds {
    display: flex;
    justify-content: center;
    gap: 3rem;
    padding: 0.625rem 0;
}

.perf-speed {
    text-align: center;
}

.speed-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.375rem;
    text-transform: uppercase;
}

.speed-value {
    font-family: var(--font-mono);
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--accent-primary);
}

/* Distance Bar */
.perf-distance {
    margin-bottom: 0.625rem;
}

.distance-bar {
    height: 32px;
    background: var(--color-success);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.625rem;
}

.distance-required {
    height: 100%;
    background: var(--accent-primary);
    transition: width 0.3s ease;
}

.distance-values {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.distance-values .good { color: var(--color-success); }
.distance-values .caution { color: var(--color-warning); }
.distance-values .warning { color: var(--color-danger); }

/* Config Grid */
.perf-config,
.perf-corrections {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.625rem;
}

.config-item,
.corr-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.625rem 0.875rem;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
}

.config-item span:first-child,
.corr-item span:first-child {
    color: var(--text-secondary);
}

.config-item span:last-child,
.corr-item span:last-child {
    font-family: var(--font-mono);
    font-weight: 600;
    color: var(--text-primary);
}

/* Warnings */
.perf-warnings {
    margin-top: 1.125rem;
}

.warning-item {
    padding: 0.75rem 1rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-left: 3px solid var(--color-danger);
    border-radius: var(--radius-sm);
    color: var(--color-danger);
    font-size: 0.9rem;
    margin-bottom: 0.625rem;
}

.warning-item:last-child {
    margin-bottom: 0;
}

/* Responsive */
@media (max-width: 1200px) {
    .perf-content-grid {
        grid-template-columns: 1fr;
    }
    
    .perf-inputs-column {
        max-height: none;
    }
    
    .perf-results-card {
        min-height: 400px;
    }
}

@media (max-width: 768px) {
    .perf-header-bar {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1rem 1.25rem;
    }
    
    .perf-header-title h1 {
        font-size: 1.35rem;
    }
    
    .perf-header-actions {
        width: 100%;
        justify-content: center;
    }
    
    .input-grid-3,
    .input-grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .perf-speeds {
        gap: 2rem;
    }
    
    .speed-value {
        font-size: 1.75rem;
    }
}

.input-group label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 1rem;
    transition: border-color var(--transition-fast);
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.input-mono {
    font-family: var(--font-mono);
}

.input-unit {
    font-size: 0.9rem;
    color: var(--text-muted);
    padding-bottom: 0.8rem;
}

.btn-search {
    width: 44px;
    height: 44px;
    flex-shrink: 0;
}

.btn-full {
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
}

/* Runway Visualization */
.runway-viz {
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 1.75rem;
    margin-bottom: 1.75rem;
    min-height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.runway-viz-inner {
    width: 100%;
}

.runway-track {
    position: relative;
    height: 44px;
    background: #2a2a38;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.875rem;
}

.runway-markings {
    position: absolute;
    left: 0.625rem;
    top: 50%;
    transform: translateY(-50%);
}

.runway-id {
    font-family: var(--font-mono);
    font-size: 1rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

.runway-tora {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    background: rgba(255, 99, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 0.875rem;
}

.tora-label {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 600;
    color: white;
}

.runway-stats {
    display: flex;
    justify-content: center;
    gap: 2.25rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Performance Results */
.perf-results-data {
    min-height: 220px;
}

.perf-result-section {
    margin-bottom: 1.75rem;
}

.perf-result-section h3 {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.875rem;
}

.perf-speeds {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
}

.perf-speed {
    text-align: center;
}

.speed-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.375rem;
}

.speed-value {
    font-family: var(--font-mono);
    font-size: 2rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.perf-distance .distance-bar {
    height: 28px;
    background: var(--color-success);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.875rem;
}

.distance-required {
    height: 100%;
    background: var(--accent-primary);
}

.distance-values {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.distance-values .good { color: var(--color-success); }
.distance-values .caution { color: var(--color-warning); }
.distance-values .warning { color: var(--color-danger); }

.perf-config,
.perf-corrections {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.625rem;
}

.config-item,
.corr-item {
    display: flex;
    justify-content: space-between;
    padding: 0.625rem 0.875rem;
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
}

.config-item span:last-child,
.corr-item span:last-child {
    font-family: var(--font-mono);
    font-weight: 500;
}

.perf-warnings {
    margin-top: 1.125rem;
}

.warning-item {
    padding: 0.875rem 1rem;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-sm);
    color: var(--color-danger);
    font-size: 0.95rem;
    margin-bottom: 0.625rem;
}

/* ============================================
   ACARS - Authentic 737 CDU/FMC Style Display
   ============================================ */
.acars-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    max-width: 1600px;
}

/* FMC Container - Full 737 CDU Style */
.fmc-container {
    display: flex;
    justify-content: center;
}

.fmc-frame {
    background: linear-gradient(145deg, #1a1a1a, #0a0a0a);
    border-radius: 24px;
    padding: 28px;
    box-shadow: 
        0 25px 70px rgba(0,0,0,0.7),
        inset 0 1px 0 rgba(255,255,255,0.05),
        inset 0 -2px 0 rgba(0,0,0,0.3);
    border: 4px solid #2a2a2a;
    width: 100%;
    max-width: 580px;
}

.fmc-bezel {
    background: linear-gradient(180deg, #0a0a0a, #151515);
    border: 6px solid #1a1a1a;
    border-radius: 14px;
    padding: 20px;
    box-shadow: 
        inset 0 5px 25px rgba(0,0,0,0.8),
        0 3px 6px rgba(0,0,0,0.5);
}

.fmc-screen {
    background: #1a1a1a;
    border: 5px solid #2a2a2a;
    border-radius: 10px;
    padding: 24px 28px;
    min-height: 520px;
    font-family: 'JetBrains Mono', 'Consolas', 'Courier New', monospace;
    position: relative;
    box-shadow: 
        inset 0 0 60px rgba(0, 0, 0, 0.5),
        inset 0 0 15px rgba(0, 0, 0, 0.3);
    /* CRT screen effect */
    background-image: 
        repeating-linear-gradient(
            0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.1) 2px,
            rgba(0, 0, 0, 0.1) 4px
        );
}

.fmc-header {
    display: flex;
    justify-content: space-between;
    padding-bottom: 16px;
    border-bottom: 1px solid #3a3a3a;
    margin-bottom: 20px;
}

.fmc-title {
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.1em;
}

.fmc-page {
    color: #ffffff;
    font-size: 1.35rem;
    font-weight: 600;
}

.fmc-content {
    min-height: 400px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.fmc-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.3rem;
    color: #ffffff;
    min-height: 34px;
    padding: 5px 0;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.fmc-line.fmc-center {
    justify-content: center;
    text-align: center;
}

.fmc-line.fmc-small {
    font-size: 1.1rem;
    color: #aaaaaa;
}

/* FMC Separator line - like real 737 CDU */
.fmc-line.fmc-separator {
    min-height: 14px;
    border-bottom: 1px dashed #3a3a3a;
    margin: 6px 0;
}

.fmc-line .fmc-label {
    color: #888888;
    font-size: 1.05rem;
    letter-spacing: 0.08em;
}

.fmc-line .fmc-value {
    color: #ffffff;
    font-weight: 600;
}

.fmc-line .fmc-cyan,
.fmc-line.fmc-accent {
    color: #00ffff;
}

.fmc-line .fmc-white {
    color: #ffffff;
}

.fmc-line .fmc-magenta {
    color: #ff66ff;
}

.fmc-line .fmc-amber,
.fmc-line.fmc-yellow {
    color: #ffaa00;
}

.fmc-line .fmc-green {
    color: #00ff00;
}

.fmc-line .fmc-orange {
    color: var(--accent-primary);
}

.fmc-center-arrow {
    color: #ffffff;
    margin: 0 0.5rem;
}

/* FMC Blinking text for loading states */
.fmc-blink {
    animation: fmcBlink 0.8s infinite;
}

@keyframes fmcBlink {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0.2; }
}

.fmc-scratchpad {
    position: absolute;
    bottom: 24px;
    left: 28px;
    right: 28px;
    border-top: 1px solid #3a3a3a;
    padding-top: 14px;
    color: #ffffff;
    font-size: 1.3rem;
    min-height: 32px;
    letter-spacing: 0.05em;
}

/* FMC Function Keys - 737 CDU Style */
.fmc-function-keys {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-top: 28px;
}

.fmc-key {
    padding: 18px 14px;
    background: linear-gradient(180deg, #2a2a2a 0%, #1a1a1a 100%);
    border: 2px solid #3a3a3a;
    border-radius: 10px;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    cursor: pointer;
    transition: all 0.15s;
}

.fmc-key:hover {
    background: linear-gradient(180deg, #3a3a3a 0%, #2a2a2a 100%);
    box-shadow: 0 0 20px rgba(255, 99, 0, 0.3);
    border-color: #4a4a4a;
}

.fmc-key:active {
    transform: scale(0.97);
}

.fmc-key.active,
.fmc-key.fmc-key-active {
    background: linear-gradient(180deg, #3a2a1a 0%, #2a1a0a 100%);
    border-color: #FF6300;
    box-shadow: 0 0 20px rgba(255, 99, 0, 0.4), inset 0 0 25px rgba(255, 99, 0, 0.1);
    color: #FF6300;
}

.fmc-key.disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* FMC Nav Keys */
.fmc-nav-keys {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
}

.fmc-nav {
    flex: 1;
    padding: 16px 32px;
    background: linear-gradient(180deg, #2a2a2a 0%, #1a1a1a 100%);
    border: 2px solid #3a3a3a;
    border-radius: 8px;
    color: #ffffff;
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.fmc-nav:hover {
    background: linear-gradient(180deg, #3a3a3a 0%, #2a2a2a 100%);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.1);
}

/* ACARS Status Panel */
.acars-status-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.acars-card {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.acars-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: var(--bg-input);
    border-bottom: 1px solid var(--border-subtle);
}

.acars-card-header h3 {
    font-size: 1rem;
    font-weight: 600;
}

.acars-indicator {
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.3rem 0.75rem;
    background: var(--bg-elevated);
    border-radius: 12px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.acars-indicator.active {
    background: rgba(34, 197, 94, 0.15);
    color: var(--color-success);
}

.acars-card-body {
    padding: 1.25rem;
}

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

.acars-status-item {
    background: var(--bg-input);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.status-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    margin-bottom: 0.35rem;
}

.status-value {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 600;
}

.acars-trigger-badge {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.2rem 0.6rem;
    background: var(--bg-input);
    border-radius: 10px;
    color: var(--text-muted);
}

.acars-trigger-badge.armed {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-info);
}

.acars-trigger-badge.triggered {
    background: rgba(34, 197, 94, 0.15);
    color: var(--color-success);
}

.arrival-info .arr-data {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
}

.arrival-info .arr-item {
    background: var(--bg-input);
    border-radius: var(--radius-sm);
    padding: 0.625rem 0.75rem;
}

.arrival-info .arr-label {
    display: block;
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: uppercase;
    margin-bottom: 0.15rem;
}

.arrival-info .arr-value {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--accent-primary);
}


/* FMC Frame - Light bezel */
[data-theme="light"] .fmc-frame {
    background: linear-gradient(145deg, #e8e8ec, #d8d8dc);
    border-color: #c8c8cc;
    box-shadow: 
        0 10px 40px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.8),
        inset 0 -2px 0 rgba(0, 0, 0, 0.1);
}

/* FMC Bezel - Light inner frame */
[data-theme="light"] .fmc-bezel {
    background: linear-gradient(180deg, #f0f0f4, #e0e0e4);
    border-color: #d0d0d4;
    box-shadow: 
        inset 0 2px 10px rgba(0, 0, 0, 0.1),
        0 1px 2px rgba(0, 0, 0, 0.1);
}

/* FMC Screen - Light background */
[data-theme="light"] .fmc-screen {
    background: #f8f8fa;
    border-color: #d0d0d4;
    box-shadow: 
        inset 0 0 30px rgba(0, 0, 0, 0.05),
        inset 0 0 5px rgba(0, 0, 0, 0.03);
    /* Remove CRT scanline effect for light mode */
    background-image: none;
}

/* FMC Header */
[data-theme="light"] .fmc-header {
    border-bottom-color: #d0d0d4;
}

[data-theme="light"] .fmc-title,
[data-theme="light"] .fmc-page {
    color: #1a1a2e;
}

/* FMC Lines - Dark text on light background */
[data-theme="light"] .fmc-line {
    color: #1a1a2e;
}

[data-theme="light"] .fmc-line.fmc-small {
    color: #5a5a70;
}

[data-theme="light"] .fmc-line.fmc-separator {
    border-bottom-color: #d0d0d4;
}

[data-theme="light"] .fmc-line .fmc-label {
    color: #6a6a7a;
}

[data-theme="light"] .fmc-line .fmc-value {
    color: #1a1a2e;
}

[data-theme="light"] .fmc-line .fmc-white {
    color: #1a1a2e;
}

/* Accent colors - Darker versions for light mode */
[data-theme="light"] .fmc-line .fmc-cyan {
    color: #0088aa;
}

[data-theme="light"] .fmc-line .fmc-magenta {
    color: #cc44cc;
}

[data-theme="light"] .fmc-line .fmc-amber {
    color: #cc7700;
}

[data-theme="light"] .fmc-line .fmc-green {
    color: #00aa44;
}

/* FMC Scratchpad */
[data-theme="light"] .fmc-scratchpad {
    border-top-color: #d0d0d4;
    color: #1a1a2e;
}

/* FMC Function Keys - Light style */
[data-theme="light"] .fmc-key {
    background: linear-gradient(180deg, #f0f0f4 0%, #e0e0e4 100%);
    border-color: #c0c0c4;
    color: #1a1a2e;
}

[data-theme="light"] .fmc-key:hover {
    background: linear-gradient(180deg, #f8f8fc 0%, #e8e8ec 100%);
    box-shadow: 0 0 15px rgba(255, 99, 0, 0.2);
    border-color: #b0b0b4;
}

[data-theme="light"] .fmc-key.fmc-key-active {
    background: linear-gradient(180deg, #fff5ee 0%, #ffe8d8 100%);
    border-color: #FF6300;
    box-shadow: 0 0 15px rgba(255, 99, 0, 0.3), inset 0 0 20px rgba(255, 99, 0, 0.05);
    color: #FF6300;
}

/* FMC Nav Keys - Light style */
[data-theme="light"] .fmc-nav {
    background: linear-gradient(180deg, #f0f0f4 0%, #e0e0e4 100%);
    border-color: #c0c0c4;
    color: #1a1a2e;
}

[data-theme="light"] .fmc-nav:hover {
    background: linear-gradient(180deg, #f8f8fc 0%, #e8e8ec 100%);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

/* ACARS Status Panel Cards */
[data-theme="light"] .acars-card {
    background: #ffffff;
    border-color: #e0e0e4;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .acars-card-header {
    background: #f8f8fa;
    border-bottom-color: #e0e0e4;
}

[data-theme="light"] .acars-card-header h3 {
    color: #1a1a2e;
}

/* ACARS Status Grid Items */
[data-theme="light"] .acars-status-item {
    background: #f5f5f7;
}

[data-theme="light"] .acars-status-item .label {
    color: #6a6a7a;
}

[data-theme="light"] .acars-status-item .value {
    color: #1a1a2e;
}

/* ACARS Indicator badges */
[data-theme="light"] .acars-indicator {
    background: rgba(255, 170, 0, 0.12);
    color: #cc7700;
}

[data-theme="light"] .acars-indicator.active {
    background: rgba(0, 180, 80, 0.12);
    color: #00884a;
}

[data-theme="light"] .acars-trigger-badge {
    background: rgba(100, 100, 100, 0.1);
    color: #666;
}

[data-theme="light"] .acars-trigger-badge.triggered {
    background: rgba(0, 180, 80, 0.12);
    color: #00884a;
}

/* Arrival ACARS card */
[data-theme="light"] .arrival-info-placeholder {
    color: #cc7700;
}






/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */

#toast-container {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toast {
    padding: 0.875rem 1.25rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.9rem;
    box-shadow: var(--shadow-md);
    animation: slideIn 0.3s ease;
    transition: opacity 0.3s ease;
}

.toast-info { border-left: 3px solid var(--color-info); }
.toast-success { border-left: 3px solid var(--color-success); }
.toast-warning { border-left: 3px solid var(--color-warning); }
.toast-error { border-left: 3px solid var(--color-danger); }

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1200px) {
    .performance-layout {
        grid-template-columns: 1fr;
    }
    
    .acars-layout {
        grid-template-columns: 1fr;
    }
    
    .ofp-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .card-flight {
        grid-column: 1;
    }
    
    .weather-panel-duo {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    :root {
        --sidebar-width: 70px;
    }
    
    .sidebar-brand span,
    .nav-item span,
    .pilot-details {
        display: none;
    }
    
    .nav-item {
        justify-content: center;
        padding: 1rem;
    }
    
    .efb-content {
        padding: 1rem;
    }
    
    .fmc-screen {
        width: 280px;
    }
    
    .ofp-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .ofp-header-left,
    .ofp-header-right {
        text-align: center;
    }
    
    .ofp-cards {
        grid-template-columns: 1fr;
    }
    
    .efob-table-header,
    .efob-row {
        grid-template-columns: 40px 1fr 60px 60px;
    }
    
    .efob-table-header .col-actual,
    .efob-table-header .col-dev,
    .efob-table-header .col-via,
    .efob-row .col-actual,
    .efob-row .col-dev,
    .efob-row .col-via {
        display: none;
    }
}

/* ============================================
   EFOB INPUT AND PREDICTION STYLES
   ============================================ */

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

.efob-status {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-style: italic;
}

.efob-status.active {
    color: var(--color-success);
    font-style: normal;
    font-weight: 500;
}

.efob-input {
    width: 70px;
    padding: 0.35rem 0.5rem;
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    text-align: right;
    transition: all var(--transition-fast);
}

.efob-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(255, 99, 0, 0.15);
}

.efob-input::placeholder {
    color: var(--text-muted);
}

.efob-input.predicted {
    background: rgba(59, 130, 246, 0.1);
    border-color: var(--color-info);
    color: var(--color-info);
    font-style: italic;
}

.efob-input::-webkit-outer-spin-button,
.efob-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.efob-input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

/* Deviation colors */
.col-dev.dev-positive {
    color: var(--color-success);
    font-weight: 500;
}

.col-dev.dev-negative {
    color: var(--color-danger);
    font-weight: 500;
}

.col-dev.dev-neutral {
    color: var(--text-secondary);
}

.col-dev.predicted {
    font-style: italic;
    opacity: 0.8;
}

/* Demo Mode Indicator */
.demo-indicator {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--color-warning);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ============================================
   CHARTS PAGE - UPDATED STYLES V2
   ============================================
   
   Changes:
   - Increased max-width from 800px to 1000px
   - Larger buttons and icons
   - Footer in a styled box
   - Removed "Opens in new tab" badge styles
   ============================================ */

/* Charts Container - LARGER */
.charts-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
}

/* Charts Header */
.charts-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.charts-header-info {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.charts-icon {
    width: 56px;
    height: 56px;
    min-width: 56px;
    min-height: 56px;
    padding: 12px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
}

.charts-icon svg {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    max-width: 32px;
    max-height: 32px;
    stroke: white;
}

.charts-header h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    line-height: 1.2;
}

.charts-subtitle {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin: 0.25rem 0 0 0;
}

/* Section Variants - LARGER */
.charts-section-departure,
.charts-section-arrival {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: border-color var(--transition-fast);
}

.charts-section-departure:hover,
.charts-section-arrival:hover {
    border-color: var(--border-subtle);
}

/* Section Header */
.charts-section-departure .charts-section-header,
.charts-section-arrival .charts-section-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
    border-bottom: none;
    padding-bottom: 0;
}

/* Section Icon - LARGER */
.charts-section-icon {
    width: 52px;
    height: 52px;
    min-width: 52px;
    min-height: 52px;
    max-width: 52px;
    max-height: 52px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.charts-section-icon svg {
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
    min-height: 26px !important;
    max-width: 26px !important;
    max-height: 26px !important;
    flex-shrink: 0;
}

.charts-section-icon.departure {
    background: rgba(34, 197, 94, 0.15);
    color: #22C55E;
}

.charts-section-icon.departure svg {
    stroke: #22C55E;
}

.charts-section-icon.arrival {
    background: rgba(59, 130, 246, 0.15);
    color: #3B82F6;
}

.charts-section-icon.arrival svg {
    stroke: #3B82F6;
}

.charts-section-info {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.charts-section-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-muted);
}

.charts-section-airport {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Chart Buttons Row */
.charts-buttons-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
}

/* Individual Chart Button - LARGER */
.chart-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 1.5rem 1.25rem;
    background: var(--bg-elevated);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    text-align: center;
    min-height: 130px;
}

.chart-btn:hover:not(:disabled) {
    transform: translateY(-2px);
}

.chart-btn:active:not(:disabled) {
    transform: translateY(0);
}

.chart-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.chart-btn-icao {
    font-family: var(--font-mono);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: 0.05em;
}

.chart-btn:disabled .chart-btn-icao {
    color: var(--text-muted);
}

.chart-btn-type {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.3rem 0.75rem;
    background: var(--bg-surface);
    border-radius: var(--radius-sm);
}

.chart-btn-desc {
    font-size: 0.75rem;
    color: var(--text-muted);
    line-height: 1.3;
}

/* Departure Section Button Styles */
.charts-section-departure .chart-btn-icao {
    color: #22C55E;
}

.charts-section-departure .chart-btn:hover:not(:disabled) {
    border-color: #22C55E;
    background: rgba(34, 197, 94, 0.08);
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.15);
}

.charts-section-departure .chart-btn:hover:not(:disabled) .chart-btn-type {
    background: rgba(34, 197, 94, 0.15);
    color: #22C55E;
}

/* Arrival Section Button Styles */
.charts-section-arrival .chart-btn-icao {
    color: #3B82F6;
}

.charts-section-arrival .chart-btn:hover:not(:disabled) {
    border-color: #3B82F6;
    background: rgba(59, 130, 246, 0.08);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.charts-section-arrival .chart-btn:hover:not(:disabled) .chart-btn-type {
    background: rgba(59, 130, 246, 0.15);
    color: #3B82F6;
}

/* Charts Footer - STYLED BOX */
.charts-footer-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.charts-footer-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.charts-footer-icon {
    width: 22px;
    height: 22px;
    min-width: 22px;
    min-height: 22px;
    max-width: 22px;
    max-height: 22px;
    stroke: var(--accent-primary);
    opacity: 0.8;
}

.charts-footer-content strong {
    color: var(--text-primary);
    font-weight: 600;
}

.charts-footer-link {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--accent-primary);
    text-decoration: none;
    transition: opacity var(--transition-fast);
}

.charts-footer-link:hover {
    opacity: 0.8;
    text-decoration: none;
}

.charts-footer-link svg {
    width: 16px;
    height: 16px;
    min-width: 16px;
    min-height: 16px;
    max-width: 16px;
    max-height: 16px;
}

/* ============================================
   LIGHT THEME OVERRIDES
   ============================================ */

[data-theme="light"] .charts-section-departure,
[data-theme="light"] .charts-section-arrival,
[data-theme="light"] .charts-footer-box {
    background: var(--bg-surface);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .chart-btn {
    background: var(--bg-elevated);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

[data-theme="light"] .charts-section-departure .chart-btn:hover:not(:disabled) {
    box-shadow: 0 4px 12px rgba(34, 197, 94, 0.2);
}

[data-theme="light"] .charts-section-arrival .chart-btn:hover:not(:disabled) {
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .charts-container {
        gap: 1.25rem;
    }
    
    .charts-header h1 {
        font-size: 1.5rem;
    }
    
    .charts-icon {
        width: 48px;
        height: 48px;
        min-width: 48px;
        min-height: 48px;
    }
    
    .charts-section-icon {
        width: 44px;
        height: 44px;
        min-width: 44px;
        min-height: 44px;
        max-width: 44px;
        max-height: 44px;
    }
    
    .charts-buttons-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .chart-btn {
        padding: 1.25rem 1rem;
        min-height: 120px;
    }
    
    .chart-btn-icao {
        font-size: 1.15rem;
    }
    
    .charts-footer-box {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .charts-buttons-row {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   SIDEBAR COLLAPSIBLE - COMPLETE FIX
   ============================================
   
   ADD THIS TO THE END OF YOUR efb.css FILE
   
   This fixes:
   1. Larger icons (24px instead of 20px)
   2. Larger text (1rem instead of 0.9rem)
   3. Working tooltips on collapsed state
   4. Proper toggle button positioning
   ============================================ */

/* ============================================
   CSS VARIABLES
   ============================================ */

:root {
    --sidebar-width: 260px;
    --sidebar-collapsed-width: 72px;
}

/* ============================================
   SIDEBAR BASE - LARGER STYLING
   ============================================ */

.efb-sidebar {
    width: var(--sidebar-width);
    transition: width 0.3s ease;
    position: relative;
    overflow: visible;
}

/* Larger brand area */
.sidebar-brand-image {
    padding: 1.5rem 1.25rem;
    gap: 0.75rem;
}

.sidebar-brand-image .brand-logo {
    width: 48px;
    height: 48px;
    min-width: 48px;
}

.sidebar-brand-image .brand-text {
    font-size: 1.75rem;
    transition: opacity 0.2s ease, width 0.3s ease;
}

/* Larger nav items */
.sidebar-nav {
    padding: 1.25rem 0.875rem;
    gap: 0.375rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.875rem 1.125rem;
    font-size: 1rem;
    font-weight: 500;
    position: relative;
    white-space: nowrap;
    overflow: visible;
}

/* Larger icons */
.nav-item svg {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    flex-shrink: 0;
}

.nav-item span {
    opacity: 1;
    transition: opacity 0.2s ease 0.1s, width 0.3s ease;
}

/* ============================================
   TOOLTIP STYLES - IMPORTANT!
   ============================================ */

/* Tooltip (hidden by default) */
.nav-item::after {
    content: attr(data-tooltip);
    position: absolute;
    left: calc(100% + 16px);
    top: 50%;
    transform: translateY(-50%);
    padding: 8px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 500;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, visibility 0.15s ease;
    pointer-events: none;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    z-index: 9999;
}

/* Tooltip arrow */
.nav-item::before {
    content: '';
    position: absolute;
    left: calc(100% + 8px);
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-right-color: var(--border-color);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease, visibility 0.15s ease;
    z-index: 9999;
}

/* ============================================
   SIDEBAR TOGGLE BUTTON
   ============================================ */

.sidebar-toggle {
    position: absolute;
    right: -14px;
    top: 28px;
    z-index: 1001;
    width: 28px;
    height: 28px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all var(--transition-fast);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.sidebar-toggle:hover {
    background: var(--bg-hover);
    border-color: var(--accent-primary);
    transform: scale(1.1);
}

/* Arrow icon */
.sidebar-toggle span {
    display: block;
    width: 7px;
    height: 7px;
    border-left: 2px solid var(--text-secondary);
    border-bottom: 2px solid var(--text-secondary);
    transform: rotate(45deg);
    margin-left: 3px;
    transition: transform 0.3s ease, margin 0.3s ease;
}

.sidebar-toggle:hover span {
    border-color: var(--accent-primary);
}

/* Arrow points right when collapsed */
.efb-screen.sidebar-collapsed .sidebar-toggle span {
    transform: rotate(-135deg);
    margin-left: -3px;
}

/* ============================================
   COLLAPSED STATE
   ============================================ */

.efb-screen.sidebar-collapsed .efb-sidebar {
    width: var(--sidebar-collapsed-width);
}

/* Hide text when collapsed */
.efb-screen.sidebar-collapsed .brand-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.efb-screen.sidebar-collapsed .nav-item span {
    opacity: 0;
    width: 0;
    overflow: hidden;
    transition: opacity 0.1s ease;
}

.efb-screen.sidebar-collapsed .pilot-details {
    opacity: 0;
    width: 0;
    overflow: hidden;
}

.efb-screen.sidebar-collapsed .btn-logout {
    opacity: 0;
    width: 0;
    min-width: 0;
    padding: 0;
    overflow: hidden;
}

/* Center items when collapsed */
.efb-screen.sidebar-collapsed .sidebar-brand-image {
    justify-content: center;
    padding-left: 0;
    padding-right: 0;
}

.efb-screen.sidebar-collapsed .nav-item {
    justify-content: center;
    padding-left: 0;
    padding-right: 0;
}

.efb-screen.sidebar-collapsed .sidebar-footer {
    justify-content: center;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
}

.efb-screen.sidebar-collapsed .pilot-info {
    justify-content: center;
}

/* ============================================
   SHOW TOOLTIPS WHEN COLLAPSED - CRITICAL!
   ============================================ */

.efb-screen.sidebar-collapsed .nav-item:hover::after {
    opacity: 1;
    visibility: visible;
}

.efb-screen.sidebar-collapsed .nav-item:hover::before {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   SIDEBAR FOOTER - LARGER
   ============================================ */

.sidebar-footer {
    padding: 1.125rem;
    gap: 0.875rem;
}

.pilot-avatar {
    width: 40px;
    height: 40px;
    min-width: 40px;
    font-size: 0.9rem;
}

.pilot-name {
    font-size: 0.9rem;
}

.pilot-status {
    font-size: 0.8rem;
}

.btn-logout {
    width: 40px;
    height: 40px;
    min-width: 40px;
}

.btn-logout svg {
    width: 20px;
    height: 20px;
}

/* ============================================
   MAIN CONTENT TRANSITION
   ============================================ */

.efb-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100vh;
    min-width: 0;
    transition: margin-left 0.3s ease;
}

/* ============================================
   MOBILE RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    :root {
        --sidebar-collapsed-width: 0px;
    }
    
    .efb-sidebar {
        position: fixed;
        left: 0;
        top: 0;
        height: 100vh;
        z-index: 1000;
    }
    
    .efb-screen.sidebar-collapsed .efb-sidebar {
        width: 0;
        overflow: hidden;
    }
    
    .sidebar-toggle {
        right: -44px;
        width: 36px;
        height: 36px;
        background: var(--bg-elevated);
    }
    
    .efb-screen.sidebar-collapsed .sidebar-toggle {
        position: fixed;
        left: 12px;
        top: 12px;
        right: auto;
    }
}

/* ============================================
   LIGHT THEME ADJUSTMENTS
   ============================================ */

[data-theme="light"] .sidebar-toggle {
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

[data-theme="light"] .nav-item::after {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}