/* ==========================================================================
   MOSLEY AUTO — LUXURY RACING & EXECUTIVE PERFORMANCE PORTAL (UI 3.0)
   Bespoke Dark Glassmorphism, Precision Telemetry & Executive Financial Grid
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600;700;800&display=swap');

:root {
    /* Atmospheric Dark Backgrounds */
    --bg-base: #07090e;
    --bg-subtle: #0c0f17;
    --bg-card: rgba(15, 19, 29, 0.82);
    --bg-card-elevated: rgba(20, 26, 40, 0.9);
    --bg-input: rgba(10, 13, 20, 0.85);
    --bg-input-focus: rgba(14, 18, 30, 0.95);

    /* Luxury Racing Accents */
    --accent-emerald: #10b981;
    --accent-emerald-glow: rgba(16, 185, 129, 0.28);
    --accent-teal: #14b8a6;
    --accent-gold: #fbbf24;
    --accent-gold-glow: rgba(251, 191, 36, 0.25);
    --accent-amber: #f59e0b;
    --accent-blue: #3b82f6;
    --accent-blue-glow: rgba(59, 130, 246, 0.22);
    --accent-indigo: #6366f1;
    --accent-purple: #a855f7;
    --accent-rose: #f43f5e;
    --accent-danger: #ef4444;

    /* High-contrast Typography */
    --text-white: #ffffff;
    --text-main: #f1f5f9;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --text-faint: #475569;

    /* Ultra-fine Glass Borders */
    --border-subtle: rgba(255, 255, 255, 0.07);
    --border-hover: rgba(255, 255, 255, 0.16);
    --border-focus: rgba(16, 185, 129, 0.5);

    /* Geometry & Shadows */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 22px;
    --radius-pill: 9999px;

    --shadow-card: 0 12px 36px -10px rgba(0, 0, 0, 0.7), 0 1px 0 0 rgba(255, 255, 255, 0.05) inset;
    --shadow-elevated: 0 20px 50px -15px rgba(0, 0, 0, 0.85), 0 1px 0 0 rgba(255, 255, 255, 0.08) inset;
}

/* Base Reset */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background-color: var(--bg-base);
    background-image: 
        radial-gradient(ellipse 80% 50% at 20% -10%, rgba(16, 185, 129, 0.07) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 85% 5%, rgba(99, 102, 241, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse 50% 30% at 50% 90%, rgba(251, 191, 36, 0.03) 0%, transparent 60%),
        linear-gradient(180deg, rgba(7, 9, 14, 0.96) 0%, #07090e 100%);
    background-attachment: fixed;
    color: var(--text-main);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    line-height: 1.5;
    min-height: 100vh;
    padding-bottom: 50px;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.14);
    border-radius: var(--radius-pill);
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(16, 185, 129, 0.4);
}

.app-container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 20px 24px;
}

@media (max-width: 768px) {
    .app-container {
        padding: 14px 14px;
    }
}

/* ==========================================================================
   Header Component
   ========================================================================== */
.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 14px 22px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-card);
    position: relative;
    gap: 16px;
    flex-wrap: wrap;
}

.app-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.6), rgba(99, 102, 241, 0.4), transparent);
}

.header-brand {
    display: flex;
    align-items: center;
    gap: 14px;
}

.brand-badge {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.16) 0%, rgba(99, 102, 241, 0.12) 100%);
    border: 1px solid rgba(16, 185, 129, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.15);
    color: var(--accent-emerald);
    flex-shrink: 0;
}

.brand-icon {
    width: 22px;
    height: 22px;
}

.brand-info {
    display: flex;
    flex-direction: column;
}

.brand-title-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.brand-title {
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: var(--text-white);
    line-height: 1.2;
}

.brand-tag {
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(16, 185, 129, 0.14);
    color: var(--accent-emerald);
    border: 1px solid rgba(16, 185, 129, 0.3);
    text-transform: uppercase;
}

.brand-sub {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-dim);
    letter-spacing: 0.02em;
}

/* Segmented Navigation Tabs */
.nav-segmented {
    display: inline-flex;
    align-items: center;
    background: rgba(9, 12, 19, 0.85);
    border: 1px solid var(--border-subtle);
    padding: 4px;
    border-radius: var(--radius-pill);
    gap: 4px;
}

.tab-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.86rem;
    font-weight: 700;
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
}

.tab-icon {
    width: 16px;
    height: 16px;
    stroke-width: 2;
    transition: transform 0.2s ease;
}

.tab-btn:hover {
    color: var(--text-white);
    background: rgba(255, 255, 255, 0.04);
}

.tab-btn.active {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.16), rgba(99, 102, 241, 0.12));
    color: var(--accent-emerald);
    border-color: rgba(16, 185, 129, 0.35);
    box-shadow: 0 2px 12px rgba(16, 185, 129, 0.15);
}

.tab-btn[data-tab="tab-boss"].active {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.16), rgba(245, 158, 11, 0.12));
    color: var(--accent-gold);
    border-color: rgba(251, 191, 36, 0.4);
    box-shadow: 0 2px 12px rgba(251, 191, 36, 0.15);
}

/* Header Actions & Profile */
.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-desktop-app {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
    padding: 7px 13px;
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-desktop-app:hover {
    background: rgba(16, 185, 129, 0.12);
    border-color: rgba(16, 185, 129, 0.35);
    color: var(--accent-emerald);
}

.header-icon {
    width: 14px;
    height: 14px;
}

.user-profile-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-subtle);
    padding: 5px 12px 5px 6px;
    border-radius: var(--radius-pill);
    font-size: 0.82rem;
    font-weight: 700;
    transition: all 0.2s ease;
}

.user-profile-pill:hover {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.06);
}

.user-avatar-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.15);
    border: 1.5px solid rgba(16, 185, 129, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-emerald);
}

.user-avatar-circle svg {
    width: 14px;
    height: 14px;
}

.user-display-name {
    color: var(--text-white);
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.btn-user-switch {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-dim);
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    cursor: pointer;
    padding: 2px 7px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.btn-user-switch:hover {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.35);
    color: var(--accent-amber);
}

.system-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(10, 13, 20, 0.9);
    border: 1px solid var(--border-subtle);
    padding: 7px 13px;
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
}

.status-indicator {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background-color: var(--accent-gold);
    display: inline-block;
    position: relative;
}

.status-indicator.online {
    background-color: var(--accent-emerald);
    box-shadow: 0 0 10px var(--accent-emerald);
}

.status-indicator.online::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1.5px solid var(--accent-emerald);
    animation: statusPulse 2s cubic-bezier(0.24, 0, 0.38, 1) infinite;
}

@keyframes statusPulse {
    0% { transform: scale(0.9); opacity: 0.9; }
    70% { transform: scale(2.2); opacity: 0; }
    100% { transform: scale(2.2); opacity: 0; }
}

.status-indicator.offline {
    background-color: var(--accent-danger);
    box-shadow: 0 0 8px var(--accent-danger);
}

/* Tab Content */
.tab-content {
    display: none;
    animation: fadeInTab 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

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

/* ==========================================================================
   Dashboard Grid & Cards
   ========================================================================== */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 24px;
    align-items: start;
}

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

.card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 24px 26px;
    box-shadow: var(--shadow-card);
    transition: border-color 0.22s ease, box-shadow 0.22s ease;
    position: relative;
}

.card:hover {
    border-color: var(--border-hover);
}

.card-title {
    font-size: 1.08rem;
    font-weight: 800;
    color: var(--text-white);
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: -0.01em;
}

.title-icon {
    width: 20px;
    height: 20px;
    color: var(--accent-emerald);
}

.card-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    gap: 12px;
}

.ledger-title-group {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.ledger-subtitle {
    font-size: 0.78rem;
    color: var(--text-dim);
}

/* ==========================================================================
   Mechanic Studio (Left Form Card)
   ========================================================================== */
.studio-header {
    margin-bottom: 22px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border-subtle);
}

.studio-profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.profile-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.studio-label {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-dim);
}

.profile-name {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-white);
    letter-spacing: -0.01em;
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent-emerald);
    border: 1px solid rgba(16, 185, 129, 0.35);
}

/* Amount Input Wrapper */
.amount-group {
    margin-bottom: 14px;
}

.amount-label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 8px;
}

.label-primary {
    font-size: 0.8rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent-gold);
}

.amount-calc-hint {
    font-size: 0.72rem;
    color: var(--text-dim);
}

.amount-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: linear-gradient(180deg, rgba(251, 191, 36, 0.04) 0%, rgba(10, 13, 20, 0.95) 100%);
    border: 1px solid rgba(251, 191, 36, 0.35);
    border-radius: var(--radius-md);
    transition: all 0.22s ease;
    overflow: hidden;
}

.amount-input-wrapper:focus-within {
    border-color: var(--accent-gold);
    box-shadow: 0 0 25px rgba(251, 191, 36, 0.18), 0 0 0 2px rgba(251, 191, 36, 0.2);
}

.currency-symbol {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--accent-gold);
    padding-left: 20px;
    user-select: none;
}

#tuningAmount {
    width: 100%;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-white);
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.85rem;
    font-weight: 800;
    padding: 14px 18px 14px 10px;
    letter-spacing: 0.02em;
}

#tuningAmount::placeholder {
    color: rgba(255, 255, 255, 0.18);
}

/* Quick Amount Chips */
.quick-chips-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr) auto;
    gap: 8px;
    margin-bottom: 18px;
}

@media (max-width: 540px) {
    .quick-chips-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

.preset-chip {
    background: rgba(255, 255, 255, 0.035);
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.preset-chip:hover {
    color: var(--accent-gold);
    border-color: rgba(251, 191, 36, 0.4);
    background: rgba(251, 191, 36, 0.09);
    transform: translateY(-1px);
}

.preset-chip.clear-chip {
    color: var(--accent-danger);
    border-color: rgba(239, 68, 68, 0.25);
    font-family: inherit;
    font-size: 0.76rem;
}

.preset-chip.clear-chip:hover {
    background: rgba(239, 68, 68, 0.12);
    border-color: var(--accent-danger);
}

/* Live Telemetry HUD Card */
.telemetry-hud {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(99, 102, 241, 0.06) 100%);
    border: 1px solid rgba(16, 185, 129, 0.3);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.06);
}

.telemetry-left {
    display: flex;
    flex-direction: column;
}

.hud-label {
    font-size: 0.78rem;
    font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hud-note {
    font-size: 0.72rem;
    color: var(--text-dim);
}

.telemetry-right {
    text-align: right;
}

.hud-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.7rem;
    font-weight: 800;
    color: var(--accent-emerald);
    text-shadow: 0 0 18px rgba(16, 185, 129, 0.35);
}

/* Secondary Inputs Group */
.form-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 20px;
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-dim);
}

.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.field-icon {
    position: absolute;
    left: 14px;
    width: 16px;
    height: 16px;
    color: var(--text-dim);
    pointer-events: none;
}

.input-icon-wrapper input {
    padding-left: 40px !important;
}

input[type="text"], input[type="password"], input[type="number"] {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid var(--border-subtle);
    color: var(--text-white);
    padding: 12px 16px;
    border-radius: var(--radius-md);
    font-size: 0.92rem;
    font-family: inherit;
    outline: none;
    transition: all 0.2s ease;
}

input:focus {
    border-color: var(--border-focus);
    background: var(--bg-input-focus);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 22px;
    border-radius: var(--radius-md);
    font-family: inherit;
    font-size: 0.92rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    cursor: pointer;
    border: none;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    overflow: hidden;
    text-decoration: none;
}

.btn:active {
    transform: scale(0.98);
}

.btn-icon {
    width: 18px;
    height: 18px;
}

.btn-icon-sm {
    width: 14px;
    height: 14px;
}

.btn-primary {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #042416;
    box-shadow: 0 4px 18px rgba(16, 185, 129, 0.35);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
    box-shadow: 0 6px 26px rgba(16, 185, 129, 0.55);
    transform: translateY(-2px);
    color: #021a0f;
}

.btn-gold {
    background: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
    color: #1f1402;
    box-shadow: 0 4px 18px rgba(251, 191, 36, 0.3);
}

.btn-gold:hover {
    background: linear-gradient(135deg, #fcd34d 0%, #f59e0b 100%);
    box-shadow: 0 6px 26px rgba(251, 191, 36, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-main);
    border: 1px solid var(--border-subtle);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--border-hover);
    color: var(--text-white);
}

.btn-submit-hero {
    width: 100%;
    padding: 15px 24px;
    font-size: 0.98rem;
    border-radius: var(--radius-md);
}

.btn-sm {
    padding: 7px 14px;
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
    width: auto;
}

.btn-lg {
    padding: 16px 28px;
    font-size: 1.02rem;
}

/* ==========================================================================
   Ledger Card & Tables (Right Column)
   ========================================================================== */
.telemetry-bar {
    display: flex;
    gap: 12px;
    background: rgba(10, 13, 20, 0.85);
    border: 1px solid var(--border-subtle);
    padding: 12px 18px;
    border-radius: var(--radius-md);
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.stat-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
}

.stat-pill-label {
    color: var(--text-dim);
    font-weight: 600;
}

.stat-pill-val {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 800;
    color: var(--text-white);
}

.stat-pill-highlight {
    margin-left: auto;
}

.table-responsive {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
    background: rgba(8, 10, 16, 0.6);
}

.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.86rem;
}

.data-table th {
    background: rgba(12, 15, 24, 0.95);
    color: var(--text-dim);
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    text-align: left;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border-subtle);
    white-space: nowrap;
}

.data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.035);
    color: var(--text-main);
    transition: background 0.15s ease;
    vertical-align: middle;
}

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

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

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-green { color: var(--accent-emerald) !important; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.text-blue { color: #60a5fa !important; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.text-gold { color: var(--accent-gold) !important; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.text-orange { color: var(--accent-amber) !important; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.text-purple { color: #c084fc !important; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.text-muted { color: var(--text-dim); }

/* ==========================================================================
   Boss Section & Executive Financial KPI Grid
   ========================================================================== */
.kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.kpi-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    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);
    border-color: var(--border-hover);
}

.kpi-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--accent-emerald);
}

.kpi-gold::before { background: var(--accent-gold); }
.kpi-blue::before { background: var(--accent-blue); }
.kpi-orange::before { background: var(--accent-amber); }
.kpi-purple::before { background: var(--accent-purple); }
.kpi-green::before { background: var(--accent-emerald); }
.kpi-amber::before { background: #fb923c; }

.kpi-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.kpi-label {
    font-size: 0.74rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-dim);
}

.kpi-badge {
    font-size: 0.62rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 2px 6px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
}

.kpi-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--text-white);
    letter-spacing: -0.02em;
}

.kpi-foot {
    font-size: 0.7rem;
    color: var(--text-dim);
}

/* Boss Discord Link Manager Box */
.discord-link-box {
    background: linear-gradient(135deg, rgba(88, 101, 242, 0.05) 0%, rgba(15, 19, 29, 0.8) 100%);
    border: 1px solid rgba(88, 101, 242, 0.25);
    border-radius: var(--radius-lg);
    padding: 22px;
    margin-top: 24px;
}

.discord-link-header {
    margin-bottom: 18px;
}

.link-head-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
}

.link-icon {
    width: 20px;
    height: 20px;
    color: #818cf8;
}

.link-head-title h3 {
    font-size: 1rem;
    font-weight: 800;
    color: var(--text-white);
}

.link-channel-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.link-inputs-row {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

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

.link-buttons-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-link-action {
    background: rgba(88, 101, 242, 0.16);
    border-color: rgba(88, 101, 242, 0.4);
    color: #a5b4fc;
}

.btn-link-action:hover {
    background: rgba(88, 101, 242, 0.28);
    color: #ffffff;
}

.btn-danger-soft {
    background: rgba(239, 68, 68, 0.12);
    border-color: rgba(239, 68, 68, 0.35);
    color: #f87171;
}

.btn-danger-soft:hover {
    background: rgba(239, 68, 68, 0.22);
    color: #ffffff;
}

.btn-danger-dim {
    background: rgba(239, 68, 68, 0.06);
    border-color: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
}

.linked-channels-container {
    margin-top: 14px;
    font-size: 0.84rem;
    color: var(--text-muted);
}

.discord-bubble {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(88, 101, 242, 0.16);
    color: #a5b4fc;
    border: 1px solid rgba(88, 101, 242, 0.35);
    padding: 3px 8px;
    border-radius: 6px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    font-weight: 600;
}

.password-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(16, 185, 129, 0.12);
    color: var(--accent-emerald);
    border: 1px solid rgba(16, 185, 129, 0.35);
    padding: 3px 8px;
    border-radius: 6px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.78rem;
    font-weight: 700;
}

.password-badge.no-pw {
    background: rgba(251, 191, 36, 0.1);
    color: var(--accent-gold);
    border-color: rgba(251, 191, 36, 0.35);
}

.role-pill {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.role-pill.majitel { background: rgba(251, 191, 36, 0.16); color: #fbbf24; border: 1px solid rgba(251, 191, 36, 0.4); }
.role-pill.spolumajitel { background: rgba(168, 85, 247, 0.16); color: #c084fc; border: 1px solid rgba(168, 85, 247, 0.4); }
.role-pill.manager { background: rgba(6, 182, 212, 0.16); color: #22d3ee; border: 1px solid rgba(6, 182, 212, 0.4); }
.role-pill.hlavni-mechanik { background: rgba(59, 130, 246, 0.16); color: #60a5fa; border: 1px solid rgba(59, 130, 246, 0.4); }
.role-pill.mechanik { background: rgba(16, 185, 129, 0.14); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.35); }
.role-pill.junior-mechanik { background: rgba(20, 184, 166, 0.14); color: #2dd4bf; border: 1px solid rgba(20, 184, 166, 0.35); }

/* Master Payout Action Bar */
.boss-action-bar {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.07) 0%, rgba(245, 158, 11, 0.04) 100%);
    border: 1px dashed rgba(251, 191, 36, 0.35);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
}

.boss-action-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.84rem;
    color: var(--text-muted);
    max-width: 680px;
    line-height: 1.5;
}

.info-icon {
    width: 20px;
    height: 20px;
    color: var(--accent-gold);
    flex-shrink: 0;
}

.btn-payout-master {
    width: 100%;
    max-width: 540px;
}

/* ==========================================================================
   Modern Auth Card & Discord Login Hero (Login Screen)
   ========================================================================== */
.boss-auth-screen {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 480px;
    padding: 20px 0;
}

.modern-login-card {
    max-width: 440px;
    width: 100%;
    padding: 38px 32px 28px;
    background: linear-gradient(180deg, rgba(20, 24, 38, 0.95) 0%, rgba(13, 16, 26, 0.98) 100%);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 22px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.7), 0 0 35px rgba(88, 101, 242, 0.08);
    position: relative;
    overflow: hidden;
    margin: 0 auto;
}

.modern-login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 8%;
    right: 8%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(88, 101, 242, 0.7), rgba(16, 185, 129, 0.4), transparent);
}

.auth-header {
    text-align: center;
    margin-bottom: 24px;
}

.auth-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(88, 101, 242, 0.12);
    border: 1px solid rgba(88, 101, 242, 0.3);
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: #9cb0ff;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.auth-title {
    font-size: 1.55rem;
    font-weight: 800;
    color: var(--text-white);
    margin: 0 0 8px;
    letter-spacing: -0.02em;
}

.auth-subtitle {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.45;
}

/* Primární Discord Hero tlačítko */
.auth-primary-action {
    margin-bottom: 16px;
}

.btn-discord-hero {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 14px 18px;
    background: linear-gradient(135deg, #5865F2 0%, #4752c4 100%);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 14px;
    color: #ffffff !important;
    text-decoration: none;
    box-shadow: 0 6px 20px rgba(88, 101, 242, 0.35);
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-sizing: border-box;
}

.btn-discord-hero:hover {
    background: linear-gradient(135deg, #6573f5 0%, #4c58cf 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(88, 101, 242, 0.55);
    border-color: rgba(255, 255, 255, 0.4);
}

.btn-discord-hero:active {
    transform: translateY(0);
}

.discord-icon-circle {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.discord-logo {
    fill: #ffffff;
}

.btn-discord-text {
    flex: 1;
    text-align: left;
    display: flex;
    flex-direction: column;
}

.btn-label-main {
    font-size: 1.02rem;
    font-weight: 700;
    line-height: 1.25;
    color: #ffffff;
}

.btn-label-sub {
    font-size: 0.74rem;
    color: rgba(255, 255, 255, 0.82);
    font-weight: 500;
    margin-top: 2px;
}

.btn-arrow {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.65);
    transition: transform 0.2s ease, color 0.2s ease;
    padding-right: 4px;
}

.btn-discord-hero:hover .btn-arrow {
    transform: translateX(4px);
    color: #ffffff;
}

/* Záložní přihlašování */
.auth-backup-area {
    margin-top: 10px;
}

.backup-toggle-link {
    background: none;
    border: none;
    color: var(--text-dim);
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: all 0.2s ease;
    width: 100%;
}

.backup-toggle-link:hover {
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
}

.backup-toggle-link .chevron {
    font-size: 0.9rem;
    transition: transform 0.2s ease;
}

.backup-login-form {
    margin-top: 12px;
    padding: 16px;
    background: rgba(8, 10, 16, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 12px;
    text-align: left;
    animation: fadeIn 0.2s ease;
}

.backup-login-form .form-group {
    margin-bottom: 12px;
}

.backup-login-form label {
    display: block;
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 6px;
}

.backup-login-form input {
    text-align: left !important;
    font-size: 0.92rem !important;
    font-family: inherit !important;
    letter-spacing: normal !important;
    padding: 10px 14px !important;
    margin-bottom: 0 !important;
    width: 100%;
    box-sizing: border-box;
}

.btn-backup-submit {
    width: 100%;
    margin-top: 8px;
    padding: 10px 16px;
    font-size: 0.88rem;
    font-weight: 700;
}

/* Spodní patička s aplikací */
.auth-footer-bar {
    margin-top: 22px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.8rem;
    color: var(--text-dim);
    flex-wrap: wrap;
}

.auth-footer-download {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    transition: all 0.2s ease;
}

.auth-footer-download:hover {
    color: var(--accent-emerald);
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.25);
}

/* ==========================================================================
   Modal Dialog & Tuning Selector
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(4, 6, 10, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    padding: 20px;
    opacity: 1;
    transition: opacity 0.25s ease;
}

.modal-card {
    background: #0d101a;
    border: 1px solid var(--border-subtle);
    box-shadow: 0 30px 70px -15px rgba(0, 0, 0, 0.95), 0 0 35px rgba(251, 191, 36, 0.1);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 920px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: modalSlideIn 0.22s ease forwards;
}

@keyframes modalSlideIn {
    from { transform: translateY(18px) scale(0.97); opacity: 0; }
    to { transform: translateY(0) scale(1); opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-subtle);
    background: rgba(255, 255, 255, 0.02);
}

.modal-title {
    font-size: 1.22rem;
    font-weight: 800;
    color: var(--text-white);
    letter-spacing: -0.01em;
}

.modal-subtitle {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-top: 3px;
}

.modal-close-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

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

.modal-close-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border-color: rgba(239, 68, 68, 0.4);
}

.modal-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 24px;
    background: rgba(0, 0, 0, 0.35);
    border-bottom: 1px solid var(--border-subtle);
}

.modal-select-all-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: var(--text-white);
    font-weight: 700;
    font-size: 0.86rem;
    margin: 0;
}

.modal-select-all-label input {
    width: 16px;
    height: 16px;
    accent-color: var(--accent-gold);
    cursor: pointer;
}

.badge-count {
    background: rgba(251, 191, 36, 0.15);
    color: var(--accent-gold);
    border: 1px solid rgba(251, 191, 36, 0.3);
    padding: 3px 10px;
    border-radius: var(--radius-pill);
    font-size: 0.76rem;
    font-weight: 700;
}

.modal-table-container {
    flex: 1;
    overflow-y: auto;
    padding: 0;
    max-height: 380px;
}

.modal-table-container table {
    width: 100%;
    margin: 0;
}

.modal-summary-box {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    padding: 16px 24px;
    background: rgba(0, 0, 0, 0.5);
    border-top: 1px solid var(--border-subtle);
}

.summary-item {
    display: flex;
    flex-direction: column;
}

.summary-label {
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--text-dim);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.summary-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--text-white);
    margin-top: 2px;
}

.total-item {
    border-left: 2px solid var(--accent-gold);
    padding-left: 14px;
}

.highlight-total {
    font-size: 1.35rem !important;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.02);
    border-top: 1px solid var(--border-subtle);
}

.btn-del-mini {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.35);
    color: #f87171;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.2s ease;
}

.btn-del-mini:hover {
    background: rgba(239, 68, 68, 0.3);
    border-color: #ef4444;
    color: #fff;
}

/* ==========================================================================
   Toast Notification
   ========================================================================== */
.toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: rgba(14, 18, 28, 0.96);
    backdrop-filter: blur(20px);
    border: 1px solid var(--accent-emerald);
    color: var(--text-white);
    padding: 14px 22px;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 20px var(--accent-emerald-glow);
    font-size: 0.9rem;
    font-weight: 700;
    z-index: 10000;
    animation: toastSlideIn 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast.error {
    border-color: var(--accent-danger);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(239, 68, 68, 0.3);
}

@keyframes toastSlideIn {
    from { opacity: 0; transform: translateY(16px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

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

.hidden {
    display: none !important;
}

/* ==========================================================================
   Duty Toggle & Shop Live Status Pill (Feature 6)
   ========================================================================== */
.shop-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(10, 13, 20, 0.9);
    border: 1px solid var(--border-subtle);
    padding: 7px 13px;
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.shop-status-pill.open {
    border-color: rgba(16, 185, 129, 0.35);
    background: rgba(16, 185, 129, 0.08);
    color: var(--accent-emerald);
}

.shop-status-pill.closed {
    border-color: rgba(239, 68, 68, 0.25);
    background: rgba(239, 68, 68, 0.06);
    color: #fca5a5;
}

.btn-duty-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 800;
    font-family: inherit;
    cursor: pointer;
    border: 1px solid var(--border-subtle);
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-duty-toggle:hover {
    border-color: rgba(16, 185, 129, 0.4);
    background: rgba(16, 185, 129, 0.1);
    color: var(--accent-emerald);
}

.btn-duty-toggle.on-duty {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.18), rgba(5, 150, 105, 0.25));
    border-color: var(--accent-emerald);
    color: #ffffff;
    box-shadow: 0 0 16px rgba(16, 185, 129, 0.25);
}

.duty-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--text-dim);
    display: inline-block;
    transition: background 0.2s ease;
}

.btn-duty-toggle.on-duty .duty-pulse {
    background: var(--accent-emerald);
    box-shadow: 0 0 10px var(--accent-emerald);
    animation: statusPulse 1.8s infinite;
}

/* ==========================================================================
   Leaderboard & Podium Grid (Feature 1)
   ========================================================================== */
.leaderboard-screen {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.leaderboard-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
}

.section-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--text-white);
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: -0.01em;
}

.period-toggle-group {
    display: inline-flex;
    background: rgba(10, 13, 20, 0.9);
    border: 1px solid var(--border-subtle);
    padding: 3px;
    border-radius: var(--radius-pill);
    gap: 4px;
}

.btn-period {
    background: transparent;
    border: none;
    color: var(--text-dim);
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-period:hover {
    color: var(--text-white);
}

.btn-period.active {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-white);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* Podium Cards */
.podium-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    align-items: stretch;
}

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

.podium-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 24px 22px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.podium-card:hover {
    transform: translateY(-3px);
}

.podium-rank-badge {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 14px;
    position: relative;
}

/* 1st Place Gold */
.podium-gold {
    border-color: rgba(251, 191, 36, 0.45);
    background: linear-gradient(180deg, rgba(251, 191, 36, 0.07) 0%, rgba(15, 19, 29, 0.95) 100%);
    box-shadow: 0 16px 40px -10px rgba(0, 0, 0, 0.8), 0 0 35px rgba(251, 191, 36, 0.15);
}

.podium-gold .podium-rank-badge {
    background: linear-gradient(135deg, #fbbf24 0%, #d97706 100%);
    color: #1a1100;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.4);
}

/* 2nd Place Silver */
.podium-silver {
    border-color: rgba(148, 163, 184, 0.35);
    background: linear-gradient(180deg, rgba(148, 163, 184, 0.05) 0%, rgba(15, 19, 29, 0.95) 100%);
}

.podium-silver .podium-rank-badge {
    background: linear-gradient(135deg, #cbd5e1 0%, #64748b 100%);
    color: #0f172a;
    box-shadow: 0 0 16px rgba(148, 163, 184, 0.3);
}

/* 3rd Place Bronze */
.podium-bronze {
    border-color: rgba(249, 115, 22, 0.35);
    background: linear-gradient(180deg, rgba(249, 115, 22, 0.05) 0%, rgba(15, 19, 29, 0.95) 100%);
}

.podium-bronze .podium-rank-badge {
    background: linear-gradient(135deg, #fb923c 0%, #c2410c 100%);
    color: #ffffff;
    box-shadow: 0 0 16px rgba(249, 115, 22, 0.3);
}

.podium-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--text-white);
    margin-bottom: 4px;
}

.podium-role {
    margin-bottom: 16px;
}

.podium-stats-row {
    display: flex;
    justify-content: space-around;
    width: 100%;
    padding-top: 14px;
    border-top: 1px solid var(--border-subtle);
    gap: 8px;
}

.podium-stat {
    display: flex;
    flex-direction: column;
}

.podium-stat-val {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.12rem;
    font-weight: 800;
    color: var(--text-white);
}

.podium-stat-lbl {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 2px;
}

/* ==========================================================================
   Boss Sub-Navigation & Payout History Archive (Feature 4)
   ========================================================================== */
.boss-subnav {
    display: inline-flex;
    background: rgba(10, 13, 20, 0.9);
    border: 1px solid var(--border-subtle);
    padding: 4px;
    border-radius: var(--radius-pill);
    gap: 4px;
    margin-bottom: 20px;
}

.boss-subtab-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-muted);
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 700;
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
}

.subtab-icon {
    width: 15px;
    height: 15px;
}

.boss-subtab-btn:hover {
    color: var(--text-white);
}

.boss-subtab-btn.active {
    background: rgba(255, 255, 255, 0.08);
    color: var(--accent-gold);
    border-color: rgba(251, 191, 36, 0.35);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

.boss-subtab-content {
    display: none;
    animation: fadeInTab 0.22s ease forwards;
}

.boss-subtab-content.active {
    display: block;
}

.btn-csv-download {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: var(--accent-emerald);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.74rem;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-csv-download:hover {
    background: rgba(16, 185, 129, 0.22);
    color: #ffffff;
}

