:root {
    --bg-dark: #090d16;
    --bg-card: rgba(18, 24, 38, 0.7);
    --bg-card-solid: #111726;
    --bg-card-hover: rgba(26, 35, 54, 0.85);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-highlight: rgba(99, 102, 241, 0.3);
    
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --color-indigo: #6366f1;
    --color-purple: #8b5cf6;
    --color-emerald: #10b981;
    --color-rose: #f43f5e;
    --color-amber: #f59e0b;
    --color-cyan: #06b6d4;
    --color-blue: #3b82f6;

    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-heading: 'Outfit', 'Inter', sans-serif;

    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.4), 0 8px 10px -6px rgba(0, 0, 0, 0.3);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.25);
}

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

body {
    font-family: var(--font-main);
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.08) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(139, 92, 246, 0.07) 0px, transparent 50%),
        radial-gradient(at 50% 100%, rgba(6, 182, 212, 0.05) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* ==================== APP HEADER ==================== */
.app-header {
    background: rgba(13, 18, 30, 0.85);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 100;
}

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

.brand-orb {
    position: relative;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.3));
    border: 1px solid rgba(139, 92, 246, 0.4);
    border-radius: 12px;
    box-shadow: 0 0 15px rgba(99, 102, 241, 0.3);
}

.orb-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 12px;
    filter: blur(8px);
    background: var(--color-indigo);
    opacity: 0.3;
    animation: pulseGlow 3s infinite alternate;
}

@keyframes pulseGlow {
    0% { opacity: 0.2; transform: scale(0.95); }
    100% { opacity: 0.45; transform: scale(1.05); }
}

.orb-icon {
    font-size: 1.5rem;
    position: relative;
    z-index: 2;
}

.brand-title {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 60%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.badge-version {
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    padding: 0.15rem 0.45rem;
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: 20px;
    color: #a5b4fc;
    -webkit-text-fill-color: #a5b4fc;
}

.brand-tagline {
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

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

.sync-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.75rem;
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    border-radius: 20px;
    font-size: 0.78rem;
    color: #34d399;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-emerald);
    box-shadow: 0 0 8px var(--color-emerald);
}

/* ==================== BUTTONS ==================== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.55rem 1.1rem;
    font-size: 0.85rem;
    font-weight: 500;
    font-family: var(--font-main);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    border: none;
    outline: none;
}

.btn-primary {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.5);
    transform: translateY(-1px);
}

.btn-secondary {
    background: rgba(30, 41, 59, 0.75);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(51, 65, 85, 0.85);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-outline:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--text-muted);
}

.btn-sm {
    padding: 0.35rem 0.75rem;
    font-size: 0.78rem;
}

/* ==================== NAVIGATION TABS ==================== */
.app-nav {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem 2rem;
    background: rgba(11, 15, 25, 0.7);
    border-bottom: 1px solid var(--border-color);
    overflow-x: auto;
}

.nav-tab {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.65rem 1.15rem;
    background: transparent;
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-tab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.nav-tab.active {
    color: #ffffff;
    background: rgba(99, 102, 241, 0.15);
    border-color: rgba(99, 102, 241, 0.35);
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.15);
}

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

.tab-badge {
    font-size: 0.72rem;
    font-weight: 600;
    padding: 0.15rem 0.5rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.nav-tab.active .tab-badge {
    background: rgba(99, 102, 241, 0.3);
    color: #c7d2fe;
}

/* ==================== MAIN CONTENT & TABS ==================== */
.app-main {
    flex: 1;
    padding: 2rem;
    max-width: 1700px;
    margin: 0 auto;
    width: 100%;
}

.tab-content {
    display: none;
    animation: fadeIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== GLASS PANELS ==================== */
.glass-panel {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-card);
    transition: border-color 0.2s ease;
}

.glass-panel:hover {
    border-color: rgba(255, 255, 255, 0.12);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.panel-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    color: var(--text-primary);
}

.dot-accent {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-indigo);
    box-shadow: 0 0 8px var(--color-indigo);
}

.panel-tag {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ==================== KPI CARDS GRID ==================== */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.75rem;
}

.kpi-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.35rem;
    box-shadow: var(--shadow-card);
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.kpi-card:hover {
    transform: translateY(-2px);
}

.kpi-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
}

.card-glow-indigo::before { background: linear-gradient(90deg, #6366f1, #8b5cf6); }
.card-glow-rose::before { background: linear-gradient(90deg, #f43f5e, #fb7185); }
.card-glow-emerald::before { background: linear-gradient(90deg, #10b981, #34d399); }
.card-glow-amber::before { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.card-glow-cyan::before { background: linear-gradient(90deg, #06b6d4, #38bdf8); }
.card-glow-purple::before { background: linear-gradient(90deg, #8b5cf6, #c084fc); }

.kpi-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.kpi-title {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.kpi-icon {
    font-size: 1.25rem;
}

.kpi-value {
    font-family: var(--font-heading);
    font-size: 1.85rem;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}

.kpi-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ==================== CHARTS GRID ==================== */
.dashboard-grid-2 {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.75rem;
}

@media (max-width: 1100px) {
    .dashboard-grid-2 {
        grid-template-columns: 1fr;
    }
}

.chart-wrapper {
    position: relative;
    height: 320px;
    width: 100%;
}

.chart-wrapper-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* ==================== TABLES ==================== */
.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    text-align: left;
}

.data-table th {
    background: rgba(15, 23, 42, 0.6);
    color: var(--text-secondary);
    font-weight: 600;
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--border-color);
    white-space: nowrap;
}

.data-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    color: var(--text-primary);
    vertical-align: middle;
}

.data-table tbody tr {
    transition: background-color 0.15s ease;
}

.data-table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.03);
}

.table-sm th, .table-sm td {
    padding: 0.55rem 0.75rem;
    font-size: 0.8rem;
}

/* ==================== BADGES & PILLS ==================== */
.badge-type {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.badge-fixed { background: rgba(99, 102, 241, 0.18); color: #a5b4fc; border: 1px solid rgba(99, 102, 241, 0.35); }
.badge-tm { background: rgba(16, 185, 129, 0.18); color: #6ee7b7; border: 1px solid rgba(16, 185, 129, 0.35); }
.badge-retainer { background: rgba(6, 182, 212, 0.18); color: #67e8f9; border: 1px solid rgba(6, 182, 212, 0.35); }
.badge-internal { background: rgba(148, 163, 184, 0.15); color: #cbd5e1; border: 1px solid rgba(148, 163, 184, 0.25); }

.pill-green {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-weight: 600;
}

.pill-cyan {
    background: rgba(6, 182, 212, 0.2);
    color: #22d3ee;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-weight: 600;
}

.pill-amber {
    background: rgba(245, 158, 11, 0.2);
    color: #fbbf24;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-weight: 600;
}

.pill-rose {
    background: rgba(244, 63, 94, 0.2);
    color: #fb7185;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-weight: 600;
}

.health-dot {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.78rem;
    font-weight: 500;
}

.dot-healthy { color: #34d399; }
.dot-warning { color: #fbbf24; }
.dot-critical { color: #fb7185; }
.dot-internal { color: #94a3b8; }

/* Progress bar for budget used */
.progress-bar-container {
    width: 90px;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 4px;
}

.progress-bar-fill {
    height: 100%;
    border-radius: 3px;
    background: var(--color-indigo);
}

.fill-warning { background: var(--color-amber); }
.fill-critical { background: var(--color-rose); }

/* ==================== FORMS & CONTROLS ==================== */
.filter-bar {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
}

.form-input, .form-select {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.55rem 0.85rem;
    color: var(--text-primary);
    font-family: var(--font-main);
    font-size: 0.85rem;
    outline: none;
    transition: all 0.2s ease;
}

.form-input:focus, .form-select:focus {
    border-color: var(--color-indigo);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}

.search-input {
    min-width: 240px;
}

.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.35rem;
}

.field-hint {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 2px;
    display: block;
}

.form-row {
    display: flex;
    gap: 1rem;
}

.col-4 { flex: 1; }
.col-6 { flex: 1; }

/* ==================== INFO CALLOUT ==================== */
.info-callout {
    display: flex;
    gap: 1rem;
    background: rgba(99, 102, 241, 0.08);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    align-items: center;
}

.callout-icon {
    font-size: 1.4rem;
}

.callout-text {
    font-size: 0.85rem;
    color: #cbd5e1;
    line-height: 1.45;
}

/* ==================== RUN-RATE & BREAK-EVEN GRID ==================== */
.runrate-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
}

.runrate-card {
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.25rem;
}

.runrate-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.runrate-value {
    font-family: var(--font-heading);
    font-size: 1.7rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.runrate-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* ==================== DRILLDOWN BOX ==================== */
.drilldown-box {
    background: rgba(11, 15, 25, 0.9);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    animation: fadeIn 0.2s ease;
}

.drilldown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.6rem;
}

.drilldown-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

@media (max-width: 900px) {
    .drilldown-grid {
        grid-template-columns: 1fr;
    }
}

.sub-header {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
}

/* ==================== OVERHEAD SUMMARY ==================== */
.overhead-summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.mini-kpi {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.mini-label {
    display: block;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 0.3rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.mini-value {
    font-family: var(--font-heading);
    font-size: 1.45rem;
    font-weight: 700;
}

/* ==================== WHAT-IF SANDBOX SLIDERS ==================== */
.sandbox-intro {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.sliders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.slider-box {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.25rem;
}

.slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.85rem;
}

.slider-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
}

.slider-badge {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--color-indigo);
    background: rgba(99, 102, 241, 0.15);
    padding: 0.15rem 0.5rem;
    border-radius: 6px;
}

.custom-slider {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.12);
    outline: none;
    cursor: pointer;
}

.custom-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--color-indigo);
    cursor: pointer;
    box-shadow: 0 0 10px var(--color-indigo);
    transition: transform 0.1s ease;
}

.custom-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.slider-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
}

.hire-tags-list {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
    margin-top: 0.6rem;
}

.hire-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(99, 102, 241, 0.2);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: 20px;
    padding: 0.35rem 0.75rem;
    font-size: 0.78rem;
    color: #c7d2fe;
}

.hire-remove {
    cursor: pointer;
    font-weight: bold;
    color: #f87171;
}

.comparison-heading {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.comparison-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
}

.comp-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.15rem;
}

.comp-label {
    font-size: 0.78rem;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
}

.comp-baseline {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-decoration: line-through;
}

.comp-scenario {
    font-family: var(--font-heading);
    font-size: 1.55rem;
    font-weight: 700;
    margin: 0.2rem 0;
}

.comp-diff {
    font-size: 0.78rem;
    font-weight: 600;
    color: #34d399;
}

/* ==================== BURDEN CALCULATOR PREVIEW ==================== */
.burden-calc-card {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: var(--radius-md);
    padding: 1.15rem;
    margin-top: 1rem;
}

.calc-formula {
    font-size: 0.78rem;
    color: var(--text-secondary);
    font-family: monospace;
    margin-bottom: 0.85rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 0.5rem;
}

.calc-results-row {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

.calc-stat-label {
    display: block;
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-bottom: 0.2rem;
}

.calc-stat-val {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: 700;
}

/* ==================== MODALS ==================== */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 1.5rem;
}

.modal-backdrop.active {
    display: flex;
}

.modal-dialog {
    background: #111726;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 620px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.7);
    animation: modalPop 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

@keyframes modalPop {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

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

.modal-title {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 600;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 1.5rem;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
}

/* ==================== TOAST NOTIFICATIONS ==================== */
.toast-container {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toast {
    background: #1e293b;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 0.85rem 1.25rem;
    color: var(--text-primary);
    font-size: 0.85rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: slideUp 0.25s ease;
}

.toast-success { border-left: 4px solid var(--color-emerald); }
.toast-error { border-left: 4px solid var(--color-rose); }

@keyframes slideUp {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Utility classes */
.mt-3 { margin-top: 1rem; }
.mt-4 { margin-top: 1.5rem; }
.text-sm { font-size: 0.8rem; }
.text-muted { color: var(--text-muted); }
.text-amber { color: var(--color-amber); }
.text-emerald { color: var(--color-emerald); }
.text-indigo { color: var(--color-indigo); }
.text-rose { color: var(--color-rose); }
.text-cyan { color: var(--color-cyan); }

/* ==================== UNANET & INTEGRATION STYLES ==================== */
.btn-unanet {
    background: linear-gradient(135deg, #059669 0%, #0d9488 100%);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.35);
}
.btn-unanet:hover {
    background: linear-gradient(135deg, #047857 0%, #0f766e 100%);
    box-shadow: 0 6px 16px rgba(13, 148, 136, 0.5);
    transform: translateY(-1px);
}

.badge-source {
    display: inline-block;
    padding: 0.15rem 0.45rem;
    border-radius: 4px;
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.badge-source-unanet {
    background: rgba(16, 185, 129, 0.15);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
}
.badge-source-willcall {
    background: rgba(99, 102, 241, 0.15);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.3);
}
.badge-source-both {
    background: rgba(139, 92, 246, 0.15);
    color: #c4b5fd;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

.sync-card {
    background: rgba(30, 41, 59, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    padding: 1rem 1.25rem;
    margin-bottom: 1rem;
}
.sync-card-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.sync-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
    margin-top: 0.5rem;
}
.sync-stat-box {
    background: rgba(15, 23, 42, 0.6);
    border-radius: var(--radius-sm);
    padding: 0.65rem 0.85rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}
.sync-stat-label {
    font-size: 0.72rem;
    color: var(--text-muted);
    text-transform: uppercase;
}
.sync-stat-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-top: 0.2rem;
}
.spinner-inline {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 6px;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==================== SPRINT SELECTION & SCOPE STYLES ==================== */
.sprint-scope-bar {
    background: rgba(20, 27, 45, 0.7);
    border: 1px solid rgba(99, 102, 241, 0.25);
    border-radius: var(--radius-md);
    backdrop-filter: blur(12px);
    padding: 1rem 1.35rem;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    box-shadow: 0 8px 20px -6px rgba(0, 0, 0, 0.35);
}

.scope-info {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.scope-icon {
    font-size: 1.6rem;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
}

.scope-title {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    font-size: 0.95rem;
    flex-wrap: wrap;
}

.scope-title strong {
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
}

.badge-scope {
    background: rgba(99, 102, 241, 0.2);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.4);
    padding: 0.15rem 0.65rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.scope-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 0.2rem;
}

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

.scope-presets {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background: rgba(15, 23, 42, 0.6);
    padding: 0.25rem;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.btn-preset {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-secondary);
    padding: 0.35rem 0.65rem;
    border-radius: 6px;
    font-size: 0.78rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: var(--font-main);
    white-space: nowrap;
}

.btn-preset:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.btn-preset.active {
    background: rgba(99, 102, 241, 0.3);
    color: #e0e7ff;
    border-color: rgba(99, 102, 241, 0.5);
    font-weight: 600;
}

/* Modal Sprint Picker */
.sprint-picker-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.sprint-picker-search {
    flex: 1;
    min-width: 220px;
}

.sprint-picker-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0.75rem;
    max-height: 400px;
    overflow-y: auto;
    padding: 0.35rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-sm);
    background: rgba(15, 23, 42, 0.4);
}

.sprint-picker-card {
    background: rgba(20, 27, 45, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 0.75rem 0.9rem;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    user-select: none;
}

.sprint-picker-card:hover {
    background: rgba(30, 41, 65, 0.85);
    border-color: rgba(99, 102, 241, 0.4);
    transform: translateY(-1px);
}

.sprint-picker-card.selected {
    background: rgba(99, 102, 241, 0.16);
    border-color: rgba(99, 102, 241, 0.55);
    box-shadow: 0 0 10px rgba(99, 102, 241, 0.2);
}

.sprint-card-checkbox {
    margin-top: 0.25rem;
    width: 17px;
    height: 17px;
    cursor: pointer;
    accent-color: var(--color-indigo);
}

.sprint-card-content {
    flex: 1;
    min-width: 0;
}

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

.sprint-card-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sprint-card-dates {
    font-size: 0.76rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.sprint-card-footer {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.4rem;
    flex-wrap: wrap;
}

.sprint-tag-status {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 0.1rem 0.45rem;
    border-radius: 4px;
    letter-spacing: 0.02em;
}

.status-active {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.4);
}

.status-upcoming {
    background: rgba(99, 102, 241, 0.2);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.4);
}

.status-completed {
    background: rgba(148, 163, 184, 0.15);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.25);
}

.sprint-tag-board {
    font-size: 0.65rem;
    padding: 0.1rem 0.45rem;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
