/* DataStreak - Dark Theme CSS
   Based on Dantes Data Design System
   Pure black background with glass morphism */

/* ============================================
   CSS Variables (Design Tokens)
   ============================================ */
:root {
    /* Colors - Dark Theme */
    --background: #000000;
    --background-secondary: #0a0a0a;
    --surface: rgba(255, 255, 255, 0.03);
    --surface-hover: rgba(255, 255, 255, 0.08);
    --surface-active: rgba(255, 255, 255, 0.12);
    --glass: rgba(255, 255, 255, 0.02);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-border-hover: rgba(255, 255, 255, 0.2);

    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --text-muted: #666666;
    --text-dim: #4a4a4a;

    /* Accent Colors */
    --accent: #ffffff;
    --accent-glow: rgba(255, 255, 255, 0.3);
    --success: #10b981;
    --success-glow: rgba(16, 185, 129, 0.4);
    --error: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;

    /* Sport Colors */
    --nba-color: #C9082A;
    --nfl-color: #013369;
    --nhl-color: #000000;
    --mlb-color: #002D72;
    --wnba-color: #FF6700;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-size-xs: 0.75rem;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.25rem;
    --font-size-2xl: 1.5rem;
    --font-size-3xl: 1.875rem;
    --font-size-4xl: 2.25rem;
    --font-size-5xl: 3rem;
    --font-size-hero: clamp(3.5rem, 10vw, 6rem);

    /* Spacing */
    --nav-height: 80px;
    --subnav-height: 40px;
    --container-max: 1400px;
    --section-padding: 120px;
    --card-padding: 48px;
    --card-padding-sm: 24px;

    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-2xl: 32px;

    /* Shadows */
    --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.7);
    --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.8);
    --shadow-glow: 0 0 40px rgba(255, 255, 255, 0.1);

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============================================
   Base Styles
   ============================================ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Reset button styles globally */
button {
    background: transparent;
    border: none;
    color: inherit;
    font: inherit;
    cursor: pointer;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--background);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background);
}

::-webkit-scrollbar-thumb {
    background: var(--surface-hover);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--surface-active);
}

/* Selection */
::selection {
    background: rgba(255, 255, 255, 0.2);
    color: var(--text-primary);
}

/* Links */
a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-base);
}

/* ============================================
   Typography
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-primary);
}

.text-hero {
    font-size: var(--font-size-hero);
    font-weight: 900;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.text-gradient {
    background: linear-gradient(135deg, #ffffff, #cccccc, #999999);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-muted {
    color: var(--text-secondary);
}

.text-dim {
    color: var(--text-muted);
}

/* ============================================
   Layout
   ============================================ */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

@media (min-width: 768px) {
    .container {
        padding: 0 40px;
    }
}

@media (max-width: 375px) {
    .container {
        padding: 0 12px;
    }
}

.section {
    padding: 80px 0;
}

@media (min-width: 768px) {
    .section {
        padding: var(--section-padding) 0;
    }
}

/* ============================================
   Navigation
   ============================================ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-bottom: 1px solid var(--glass-border);
    z-index: 1000;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.9);
}

.navbar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 24px;
}

@media (min-width: 768px) {
    .navbar-inner {
        padding: 0 40px;
    }
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: var(--font-size-xl);
    font-weight: 800;
    color: var(--text-primary);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-subtitle {
    font-size: 0.55rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 0.5px;
}

.navbar-brand svg {
    width: 32px;
    height: 32px;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.3));
}

.navbar-nav {
    display: none;
    align-items: center;
    gap: 8px;
}

@media (min-width: 768px) {
    .navbar-nav {
        display: flex;
    }
}

.nav-link {
    padding: 10px 20px;
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-secondary);
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    transition: var(--transition-base);
    cursor: pointer;
}

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

.nav-link.active {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
}

.navbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-left: auto;
    flex-shrink: 0;
}

/* Dropdown Navigation */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-trigger {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    background: transparent !important;
    border: none !important;
}

.nav-dropdown-trigger svg {
    transition: transform var(--transition-base);
}

.nav-dropdown-trigger.active svg {
    transform: rotate(180deg);
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    min-width: 240px;
    padding: 12px;
    background: rgba(10, 10, 10, 0.98);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
}

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

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

.nav-dropdown-item.featured {
    color: var(--success);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    margin-top: 8px;
}

.nav-dropdown-item.featured:hover {
    background: rgba(16, 185, 129, 0.2);
}

/* Mobile Menu */
.mobile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
}

@media (min-width: 768px) {
    .mobile-menu-btn {
        display: none;
    }
}

.mobile-menu {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 24px;
    transform: translateX(100%);
    transition: transform var(--transition-base), visibility 0s 0.3s;
    z-index: 999;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    visibility: hidden;
}

.mobile-menu.open {
    transform: translateX(0);
    visibility: visible;
    transition: transform var(--transition-base), visibility 0s;
}

.mobile-nav-group {
    border-bottom: 1px solid var(--glass-border);
}

.mobile-nav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 16px 0;
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: var(--text-primary);
    background: transparent;
    border: none;
    cursor: pointer;
}

.mobile-nav-header svg {
    transition: transform var(--transition-base);
}

.mobile-nav-header svg.rotate-180 {
    transform: rotate(180deg);
}

.mobile-nav-items {
    padding-bottom: 16px;
}

.mobile-nav-items a {
    display: block;
    padding: 12px 16px;
    font-size: var(--font-size-base);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
}

.mobile-nav-items a:hover {
    color: var(--text-primary);
    background: var(--surface);
}

.mobile-menu-footer {
    margin-top: auto;
    padding-top: 24px;
    border-top: 1px solid var(--glass-border);
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: 600;
    color: var(--text-primary);
    background: var(--glass);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: var(--transition-base);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.btn:hover {
    background: var(--surface-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md), var(--shadow-glow);
}

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

.btn-primary {
    background: var(--success);
    color: #ffffff;
    border: none;
    font-weight: 600;
}

.btn-primary:hover {
    background: #059669;
    transform: translateY(-1px);
}

.btn-success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(5, 150, 105, 0.1));
    border: 2px solid rgba(16, 185, 129, 0.4);
    color: var(--success);
}

.btn-success:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.3), rgba(5, 150, 105, 0.2));
    box-shadow: 0 0 30px var(--success-glow);
}

.btn-lg {
    padding: 16px 32px;
    font-size: var(--font-size-lg);
}

.btn-sm {
    padding: 8px 16px;
    font-size: var(--font-size-sm);
}

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

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

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

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

.btn-icon {
    width: 44px;
    height: 44px;
    padding: 0;
}

/* ============================================
   Cards
   ============================================ */
.card {
    background: var(--surface);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-xl);
    padding: var(--card-padding-sm);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: var(--transition-base);
}

@media (min-width: 768px) {
    .card {
        padding: var(--card-padding);
    }
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    border-color: var(--glass-border-hover);
}

.card-3d {
    transform-style: preserve-3d;
    perspective: 1000px;
}

.card-3d:hover {
    transform: translateY(-12px) rotateX(2deg);
}

.card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: linear-gradient(145deg, var(--surface), var(--surface-hover));
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
}

.card-icon svg {
    width: 28px;
    height: 28px;
    color: var(--text-primary);
}

.card-title {
    font-size: var(--font-size-xl);
    font-weight: 700;
}

.card-description {
    color: var(--text-secondary);
    margin-bottom: 20px;
    line-height: 1.7;
}

.card-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-primary);
    font-weight: 600;
    transition: var(--transition-base);
}

.card-link:hover {
    gap: 12px;
}

.card-link svg {
    width: 20px;
    height: 20px;
    transition: transform var(--transition-base);
}

.card-link:hover svg {
    transform: translateX(4px);
}

/* Featured Card */
.card-featured {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    border: 2px solid rgba(255, 255, 255, 0.15);
}

.card-featured .card-icon {
    background: linear-gradient(135deg, var(--text-primary), #cccccc);
}

.card-featured .card-icon svg {
    color: var(--background);
}

/* ============================================
   Forms
   ============================================ */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--text-secondary);
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    color: var(--text-primary);
    background: transparent !important;
    background-color: transparent !important;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    transition: var(--transition-base);
}

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

.form-input:focus {
    outline: none;
    border-color: var(--text-primary);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.1);
    background: transparent !important;
}

select.form-select,
.form-select,
.form-input.form-select,
select.form-input.form-select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center !important;
    background-color: transparent !important;
    background-size: 16px !important;
    padding-right: 44px;
    cursor: pointer;
    color-scheme: dark;
}

select.form-select:hover,
.form-select:hover,
.form-input.form-select:hover,
select.form-input.form-select:hover {
    border-color: var(--glass-border-hover);
    background-color: transparent !important;
}

select.form-select:focus,
.form-select:focus,
.form-input.form-select:focus,
select.form-input.form-select:focus {
    background-color: transparent !important;
}

.form-select option {
    background: #0a0a0a;
    color: var(--text-primary);
    padding: 12px;
}

/* ============================================
   Styled Select — polished native select
   ============================================ */
.styled-select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding: 10px 40px 10px 14px;
    background: rgba(255, 255, 255, 0.04);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='rgba(255,255,255,0.5)' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    letter-spacing: 0.01em;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 160px;
    color-scheme: dark;
}

.styled-select:hover {
    border-color: rgba(255, 255, 255, 0.25);
    background-color: rgba(255, 255, 255, 0.07);
}

.styled-select:focus {
    outline: none;
    border-color: var(--accent-primary, #10b981);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15);
    background-color: rgba(255, 255, 255, 0.06);
}

.styled-select option {
    background: #111118;
    color: #fff;
    padding: 10px 14px;
    font-size: 0.85rem;
}

/* ============================================
   DS Dropdown — polished custom dropdown
   ============================================ */
.ds-dropdown {
    position: relative;
    display: inline-block;
}

.ds-dropdown-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 160px;
    justify-content: space-between;
}

.ds-dropdown-btn:hover {
    border-color: rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.07);
}

.ds-dropdown-btn svg {
    opacity: 0.5;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.ds-dropdown-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 100%;
    background: #111118;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 6px;
    z-index: 100;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.6);
}

.ds-dropdown-item {
    display: block;
    width: 100%;
    padding: 9px 14px;
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.84rem;
    font-weight: 500;
    font-family: inherit;
    text-align: left;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.15s ease;
}

.ds-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.ds-dropdown-item.active {
    background: rgba(16, 185, 129, 0.12);
    color: #10b981;
    font-weight: 600;
}

/* ============================================
   Custom Dropdown (replaces native select)
   ============================================ */
.custom-dropdown {
    position: relative;
    display: inline-block;
}

.custom-dropdown-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: transparent;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: var(--font-size-sm);
    cursor: pointer;
    min-width: 140px;
    transition: var(--transition-base);
}

.custom-dropdown-btn:hover {
    border-color: var(--glass-border-hover);
}

.custom-dropdown-btn svg {
    margin-left: auto;
    opacity: 0.6;
}

.custom-dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 100%;
    background: #0a0a0a;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    padding: 4px;
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.custom-dropdown-item {
    display: block;
    width: 100%;
    padding: 10px 12px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: var(--font-size-sm);
    text-align: left;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: var(--transition-base);
}

.custom-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.custom-dropdown-item.active {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
}

/* ============================================
   Tables
   ============================================ */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-lg);
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.table th {
    font-size: var(--font-size-sm);
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.table tbody tr {
    transition: var(--transition-base);
}

.table tbody tr:hover {
    background: var(--surface);
}

/* ============================================
   Badges & Tags
   ============================================ */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    font-size: var(--font-size-xs);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: var(--radius-sm);
    background: var(--surface);
    border: 1px solid var(--glass-border);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.3);
    color: var(--success);
}

.badge-error {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.3);
    color: var(--error);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    border-color: rgba(245, 158, 11, 0.3);
    color: var(--warning);
}

.badge-hot {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(249, 115, 22, 0.2));
    border-color: rgba(239, 68, 68, 0.4);
    color: #ff6b6b;
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 4px 12px rgba(0,0,0,0.3), 0 0 12px rgba(239, 68, 68, 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 4px 12px rgba(0,0,0,0.3), 0 0 25px rgba(239, 68, 68, 0.7), 0 0 40px rgba(255, 100, 0, 0.3);
        transform: scale(1.02);
    }
}

/* ============================================
   Sport Pills
   ============================================ */
.sport-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.sport-pill {
    padding: 10px 20px;
    font-size: var(--font-size-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    background: var(--surface);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: var(--transition-base);
}

.sport-pill:hover {
    background: var(--surface-hover);
    color: var(--text-primary);
}

.sport-pill.active {
    background: var(--text-primary);
    color: var(--background);
    border-color: transparent;
}

/* ============================================
   Stats Display
   ============================================ */
.stat-card {
    text-align: center;
    padding: 28px 20px;
}

.stat-value {
    font-size: var(--font-size-lg);
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
    margin-bottom: 8px;
}

.stat-label {
    font-size: var(--font-size-sm);
    font-weight: 400;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Section Eyebrow */
.section-eyebrow {
    font-size: var(--font-size-sm);
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

/* Hit Rate Display */
.hit-rate {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 64px;
    padding: 8px 16px;
    font-size: var(--font-size-sm);
    font-weight: 700;
    border-radius: var(--radius-md);
}

.hit-rate-high {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(5, 150, 105, 0.1));
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: var(--success);
}

.hit-rate-hot {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2), rgba(249, 115, 22, 0.2));
    border: 1px solid rgba(239, 68, 68, 0.4);
    color: #ff6b6b;
}

/* ============================================
   Progress Bar
   ============================================ */
.progress {
    height: 8px;
    background: var(--surface);
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--text-secondary), var(--text-primary));
    border-radius: var(--radius-sm);
    transition: width var(--transition-slow);
}

/* ============================================
   Loading States
   ============================================ */
.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--glass-border);
    border-top-color: var(--text-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

.loading-overlay {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px;
    color: var(--text-muted);
}

/* ============================================
   Empty States
   ============================================ */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 24px;
    text-align: center;
}

.empty-state-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 24px;
    color: var(--text-dim);
}

.empty-state-title {
    font-size: var(--font-size-xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.empty-state-description {
    color: var(--text-muted);
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    padding: 160px 0 120px;
    text-align: center;
}

.hero-title {
    font-size: var(--font-size-hero);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.05;
    margin-bottom: 24px;
}

.hero-overline {
    font-size: var(--font-size-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--accent);
    margin-bottom: 16px;
}

.hero-subtitle {
    font-size: var(--font-size-xl);
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto 40px;
    line-height: 1.6;
}

/* ============================================
   Grid System
   ============================================ */
.grid {
    display: grid;
    gap: 24px;
}

@media (min-width: 768px) {
    .grid {
        gap: 32px;
    }

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

    .grid-cols-3 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1024px) {
    .grid {
        gap: 48px;
    }

    .grid-cols-4 {
        grid-template-columns: repeat(4, 1fr);
    }
}

.col-span-2 {
    grid-column: span 2;
}

/* ============================================
   Footer
   ============================================ */
.footer {
    padding: 40px 0;
    border-top: 1px solid var(--glass-border);
    text-align: center;
    color: var(--text-muted);
}

/* ============================================
   Auth Pages
   ============================================ */
.auth-container {
    max-width: 440px;
    margin: 0 auto;
    padding: 40px 24px 80px;
}

.auth-card {
    padding: 40px;
}

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

.auth-title {
    font-size: var(--font-size-2xl);
    font-weight: 700;
    margin-bottom: 8px;
}

.auth-subtitle {
    color: var(--text-secondary);
}

.auth-divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 24px 0;
    color: var(--text-muted);
    font-size: var(--font-size-sm);
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--glass-border);
}

.auth-footer {
    text-align: center;
    margin-top: 24px;
    color: var(--text-secondary);
}

.auth-footer a {
    color: var(--text-primary);
    font-weight: 600;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* OAuth Buttons */
.btn-oauth {
    width: 100%;
    margin-bottom: 12px;
    justify-content: center;
}

.btn-discord {
    background: #5865F2;
    border-color: #5865F2;
}

.btn-discord:hover {
    background: #4752C4;
    border-color: #4752C4;
}

.btn-google {
    background: var(--surface);
    border-color: var(--glass-border);
}

.btn-google:hover {
    background: var(--surface-hover);
}

/* ============================================
   Error Messages
   ============================================ */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ff6b6b;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: var(--success);
}

/* ============================================
   Live Indicator
   ============================================ */
.live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--success);
    font-size: var(--font-size-sm);
    font-weight: 500;
}

.live-dot {
    width: 8px;
    height: 8px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }
}

/* ============================================
   Utility Classes
   ============================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.items-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

.gap-2 { gap: 8px; }
.gap-4 { gap: 16px; }
.gap-6 { gap: 24px; }

.mb-2 { margin-bottom: 8px; }
.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mb-8 { margin-bottom: 32px; }

.mt-2 { margin-top: 8px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.mt-8 { margin-top: 32px; }

.text-center { text-align: center; }
.text-sm { font-size: var(--font-size-sm); }
.text-lg { font-size: var(--font-size-lg); }
.text-xl { font-size: var(--font-size-xl); }

.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.w-full { width: 100%; }

/* Page content offset for fixed navbar + subnav (80px + 40px = 120px) */
.page-content {
    padding-top: calc(var(--nav-height) + var(--subnav-height));
    min-height: calc(100vh - var(--nav-height) - var(--subnav-height));
}

/* ============================================
   Sub-Navigation (Tools Bar)
   ============================================ */
.subnav {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    height: var(--subnav-height);
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    z-index: 999;
    display: none;
}

@media (min-width: 768px) {
    .subnav {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}

@media (max-width: 767px) {
    .page-content {
        padding-top: var(--nav-height);
        min-height: calc(100vh - var(--nav-height));
    }
}

.subnav-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    max-width: var(--container-max);
    width: 100%;
    height: 100%;
    padding: 0 24px;
}

.subnav-link {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
    padding: 0 4px;
    height: 100%;
    border-bottom: 2px solid transparent;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.subnav-link svg {
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}

.subnav-link:hover {
    color: rgba(255, 255, 255, 0.85);
}

.subnav-link.active {
    color: #fff;
    border-bottom-color: #10b981;
}

/* ============================================
   Chat Widget (DataStreak Copilot)
   ============================================ */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    font-family: var(--font-family);
}

.chat-fab {
    height: 44px;
    padding: 0 18px;
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.9), rgba(16, 185, 129, 0.7));
    border: 1px solid rgba(16, 185, 129, 0.5);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.3);
    transition: all 0.2s ease;
    white-space: nowrap;
}

.chat-fab:hover {
    transform: scale(1.04);
    box-shadow: 0 6px 28px rgba(16, 185, 129, 0.4);
}

.chat-fab-label {
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-align: center;
    line-height: 1;
}

.chat-fab--active {
    width: 44px;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.chat-fab--active:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

/* Panel */
.chat-panel {
    position: absolute;
    bottom: 64px;
    right: 0;
    width: 380px;
    height: 520px;
    background: linear-gradient(135deg, rgba(15, 15, 20, 0.97) 0%, rgba(10, 10, 15, 0.97) 100%);
    backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.chat-panel-enter { transition: all 0.2s ease-out; }
.chat-panel-enter-start { opacity: 0; transform: translateY(12px) scale(0.96); }
.chat-panel-enter-end { opacity: 1; transform: translateY(0) scale(1); }
.chat-panel-leave { transition: all 0.15s ease-in; }

/* Header */
.chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.chat-header-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.5);
}

.chat-header-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #fff;
}

.chat-header-actions {
    display: flex;
    gap: 4px;
}

.chat-header-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
}

.chat-header-btn:hover {
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.06);
}

/* Messages area */
.chat-messages {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,0.1) transparent;
}

.chat-messages::-webkit-scrollbar {
    width: 4px;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
}

/* Welcome state */
.chat-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 8px;
    gap: 12px;
}

.chat-welcome-icon {
    color: rgba(16, 185, 129, 0.7);
}

.chat-welcome-text {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
    margin: 0;
}

.chat-welcome-suggestions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    margin-top: 8px;
}

.chat-suggestion {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 8px 12px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: left;
}

.chat-suggestion:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(16, 185, 129, 0.3);
    color: #fff;
}

/* Message bubbles */
.chat-msg {
    display: flex;
    max-width: 88%;
    min-width: 0;
    overflow: hidden;
}

.chat-msg--user {
    align-self: flex-end;
}

.chat-msg--assistant {
    align-self: flex-start;
}

.chat-msg-content {
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 0.82rem;
    line-height: 1.55;
    word-break: break-word;
    overflow-wrap: anywhere;
    min-width: 0;
    max-width: 100%;
    overflow: hidden;
}

.chat-msg--user .chat-msg-content {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.15);
    color: #fff;
    border-bottom-right-radius: 4px;
}

.chat-msg--assistant .chat-msg-content {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.9);
    border-bottom-left-radius: 4px;
}

.chat-msg-content strong {
    font-weight: 600;
    color: #fff;
}

.chat-msg-content code {
    background: rgba(255, 255, 255, 0.08);
    padding: 1px 5px;
    border-radius: 4px;
    font-size: 0.78rem;
}

.chat-link {
    color: #10b981;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.chat-link:hover {
    color: #34d399;
}

/* Typing indicator */
.chat-typing {
    display: inline-flex;
    gap: 4px;
    align-items: center;
    padding: 4px 0;
}

.chat-typing span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    animation: chatTyping 1.2s infinite;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes chatTyping {
    0%, 60%, 100% { opacity: 0.3; transform: scale(0.8); }
    30% { opacity: 1; transform: scale(1); }
}

/* Error toast */
.chat-error {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    margin: 0 12px 4px;
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 8px;
    color: #fca5a5;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.chat-error-close {
    background: none;
    border: none;
    color: #fca5a5;
    cursor: pointer;
    font-size: 1rem;
    padding: 0 4px;
}

/* Input area */
.chat-input-area {
    padding: 12px 14px 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    flex-shrink: 0;
}

.chat-disclaimer {
    font-size: 0.62rem;
    color: rgba(255, 255, 255, 0.25);
    text-align: center;
    margin-bottom: 8px;
}

.chat-input-form {
    display: flex;
    gap: 8px;
    align-items: center;
}

.chat-input {
    flex: 1;
    min-width: 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 10px 14px;
    color: #fff;
    font-size: 0.82rem;
    font-family: var(--font-family);
    outline: none;
    transition: border-color 0.15s ease;
}

.chat-input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.chat-input:focus {
    border-color: rgba(16, 185, 129, 0.4);
}

.chat-input:disabled {
    opacity: 0.5;
}

.chat-send-btn {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: #10b981;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.15s ease;
}

.chat-send-btn:hover:not(:disabled) {
    background: rgba(16, 185, 129, 0.3);
    color: #34d399;
}

.chat-send-btn:disabled {
    opacity: 0.3;
    cursor: default;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .chat-widget {
        bottom: 12px;
        right: 12px;
    }

    .chat-panel {
        position: fixed;
        bottom: 0;
        right: 0;
        left: 0;
        top: auto;
        width: 100%;
        max-width: 100vw;
        height: 75vh;
        border-radius: 16px 16px 0 0;
        border-bottom: none;
    }

    .chat-fab {
        width: 48px;
        height: 48px;
        padding: 0;
        border-radius: 50%;
        overflow: hidden;
    }

    .chat-fab-label {
        display: none !important;
    }
}

/* ============================================
   PWA Mobile — Desktop-hidden elements
   ============================================ */
.mobile-tab-bar { display: none; }
.sport-pills { display: none; }
.mobile-cards { display: none; }

/* ============================================
   PWA Mobile Utilities (@media max-width: 767px)
   ============================================ */
@media (max-width: 767px) {
    /* Hero section — reduce massive padding on mobile */
    .hero { padding: 60px 0 40px; }
    .hero-title { font-size: 1.75rem; }
    .hero-subtitle { font-size: 0.88rem; }
    .hero-overline { font-size: 0.72rem; }

    /* Table scroll wrapper — wrap any <table> parent with this class */
    .table-scroll-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .table-scroll-wrapper::-webkit-scrollbar { display: none; }

    /* Vertical stacking helper */
    .mobile-stack {
        flex-direction: column !important;
        align-items: stretch !important;
    }

    /* Touch target minimum */
    .mobile-touch {
        min-width: 44px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* Navbar safe-area for iOS notch */
    .navbar {
        padding-top: env(safe-area-inset-top, 0px);
    }

    /* Container tighter padding on phones */
    .container {
        padding-left: 12px;
        padding-right: 12px;
    }

    /* Page content — prevent any horizontal overflow */
    .page-content {
        overflow-x: hidden;
        max-width: 100vw;
    }

    /* Global filter controls — pages override individually */
    .filters-row {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    /* Filter buttons touch-friendly */
    .filter-btn,
    .filter-pill {
        min-height: 40px;
        padding: 8px 12px;
    }

    /* Subnav — hide on mobile (replaced by tab bar) */
    .subnav {
        display: none !important;
    }

    /* ── Bottom Tab Bar ── */
    .mobile-tab-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: calc(56px + env(safe-area-inset-bottom, 0px));
        padding-bottom: env(safe-area-inset-bottom, 0px);
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        z-index: 1000;
        align-items: flex-start;
        justify-content: space-around;
    }

    .tab-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        flex: 1;
        padding: 8px 0 4px;
        min-height: 56px;
        color: rgba(255, 255, 255, 0.4);
        text-decoration: none;
        font-size: 0.62rem;
        font-weight: 500;
        letter-spacing: 0.02em;
        background: none;
        border: none;
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
        transition: color 0.15s ease;
    }

    .tab-item svg {
        width: 22px;
        height: 22px;
        margin-bottom: 3px;
        stroke-width: 1.8;
    }

    .tab-item.active {
        color: #10b981;
    }

    .tab-item:active {
        color: rgba(255, 255, 255, 0.7);
    }

    /* Page content — clear tab bar */
    .page-content {
        padding-bottom: calc(56px + env(safe-area-inset-bottom, 0px) + 16px);
    }

    /* Mobile menu sits above tab bar */
    .mobile-menu {
        bottom: calc(56px + env(safe-area-inset-bottom, 0px));
    }

    /* Chat widget above tab bar */
    .chat-widget {
        bottom: calc(64px + env(safe-area-inset-bottom, 0px)) !important;
    }

    /* ── Sport Pill Switcher ── */
    .sport-pills {
        display: block;
        position: sticky;
        top: var(--nav-height);
        z-index: 998;
        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-bottom: 1px solid rgba(255, 255, 255, 0.06);
        padding: 8px 0;
    }

    .sport-pills-inner {
        display: flex;
        gap: 8px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding: 0 12px;
    }
    .sport-pills-inner::-webkit-scrollbar { display: none; }

    .sport-pill {
        flex-shrink: 0;
        padding: 6px 14px;
        border-radius: 100px;
        font-size: 0.75rem;
        font-weight: 600;
        color: rgba(255, 255, 255, 0.5);
        background: rgba(255, 255, 255, 0.06);
        border: 1px solid rgba(255, 255, 255, 0.08);
        text-decoration: none;
        min-height: 32px;
        display: flex;
        align-items: center;
        transition: all 0.15s ease;
        -webkit-tap-highlight-color: transparent;
    }

    .sport-pill.active {
        background: rgba(16, 185, 129, 0.15);
        color: #10b981;
        border-color: rgba(16, 185, 129, 0.3);
    }

    /* ── Mobile Card Pattern ── */
    .mobile-cards {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .desktop-table {
        display: none !important;
    }

    .mobile-card {
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.06);
        border-radius: 16px;
        overflow: hidden;
    }

    .mobile-card-header {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 14px 16px 10px;
    }

    .mobile-card-avatar {
        position: relative;
        width: 44px;
        height: 44px;
        flex-shrink: 0;
    }

    .mobile-card-avatar img {
        width: 100%;
        height: 100%;
        border-radius: 50%;
        object-fit: cover;
    }

    .mobile-card-avatar .team-badge {
        position: absolute;
        bottom: -2px;
        right: -2px;
        width: 20px;
        height: 20px;
        background: rgba(20, 20, 25, 0.85);
        border-radius: 50%;
        padding: 1px;
        border: 1px solid rgba(255, 255, 255, 0.15);
    }

    .mobile-card-avatar .team-badge img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border-radius: 0;
    }

    .mobile-card-player {
        flex: 1;
        min-width: 0;
    }

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

    .mobile-card-meta {
        font-size: 0.72rem;
        color: rgba(255, 255, 255, 0.5);
        margin-top: 2px;
    }

    .mobile-card-badge {
        padding: 3px 8px;
        border-radius: 6px;
        font-size: 0.7rem;
        font-weight: 700;
        flex-shrink: 0;
    }

    .mobile-card-stats {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
        padding: 0 16px 12px;
    }

    .mobile-card-stat {
        text-align: center;
    }

    .mobile-card-stat-label {
        font-size: 0.6rem;
        font-weight: 600;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        color: rgba(255, 255, 255, 0.35);
        margin-bottom: 3px;
    }

    .mobile-card-stat-value {
        font-weight: 700;
        font-size: 0.95rem;
        color: #fff;
    }

    .mobile-card-footer {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 10px 16px;
        border-top: 1px solid rgba(255, 255, 255, 0.06);
        font-size: 0.75rem;
    }

    /* Streaks — force card view, hide toggle */
    .data-mode-toggle .mode-btn[aria-label="Card view"],
    .data-mode-toggle .mode-btn[aria-label="List view"] {
        display: none;
    }

    /* ── Sheet Threshold Grid ── */
    .sheet-threshold-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 1px;
        margin: 0 12px 12px;
        background: rgba(255, 255, 255, 0.06);
        border-radius: 10px;
        overflow: hidden;
    }

    .sheet-threshold-cell {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 8px 4px;
        background: rgba(0, 0, 0, 0.3);
    }

    .sheet-threshold-label {
        font-size: 0.6rem;
        font-weight: 600;
        color: rgba(255, 255, 255, 0.35);
        letter-spacing: 0.03em;
        margin-bottom: 3px;
    }

    .sheet-threshold-value {
        font-size: 0.8rem;
        font-weight: 700;
        padding: 2px 6px;
        border-radius: 4px;
    }
}

/* ============================================
   Landscape Mode — show full tables on mobile
   ============================================ */
@media (max-width: 932px) and (orientation: landscape) {
    /* Show tables, hide cards */
    .desktop-table {
        display: block !important;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .mobile-cards {
        display: none !important;
    }
    .sheet-threshold-grid {
        display: none !important;
    }

    /* Sticky player name column */
    .sheet-table td.player-cell,
    .sheet-table th:nth-child(2) {
        position: sticky;
        left: 0;
        z-index: 5;
        background: #0a0a0a;
    }
    .sheet-table thead th:nth-child(2) {
        background: #111;
    }

    /* Hide rank column to save space */
    .sheet-table .rank-col,
    .sheet-table .rank-cell {
        display: none;
    }

    /* Compact table for landscape */
    .sheet-table th,
    .sheet-table td {
        padding: 8px 6px;
        font-size: 0.72rem;
    }
    .sheet-table {
        font-size: 0.75rem;
    }

    /* Rotate hint — hidden in landscape */
    .rotate-hint {
        display: none !important;
    }

    /* Landscape toast */
    .landscape-toast {
        display: flex !important;
    }
}

/* Rotate hint — visible only in portrait on sheets pages */
.rotate-hint { display: none; }

@media (max-width: 767px) and (orientation: portrait) {
    .rotate-hint {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        padding: 10px 16px;
        margin: 0 12px 12px;
        background: rgba(59, 130, 246, 0.08);
        border: 1px solid rgba(59, 130, 246, 0.2);
        border-radius: 10px;
        color: rgba(255, 255, 255, 0.5);
        font-size: 0.75rem;
        font-weight: 500;
    }
    .rotate-hint svg {
        flex-shrink: 0;
        color: #60a5fa;
    }
}

/* Landscape toast notification */
.landscape-toast {
    display: none;
    position: fixed;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 20px;
    background: rgba(16, 185, 129, 0.9);
    color: #fff;
    font-size: 0.78rem;
    font-weight: 600;
    border-radius: 100px;
    z-index: 99999;
    pointer-events: none;
    animation: toastFade 2.5s ease forwards;
}

@keyframes toastFade {
    0% { opacity: 0; transform: translateX(-50%) translateY(-8px); }
    15% { opacity: 1; transform: translateX(-50%) translateY(0); }
    70% { opacity: 1; }
    100% { opacity: 0; }
}

@media (max-width: 375px) {
    .container {
        padding-left: 8px;
        padding-right: 8px;
    }
}
