/* ═══════════════════════════════════════════════════════════════════
   Corporate Health Unlimited — Ping Pong Tournament
   Color palette derived from CHU logo:
     Teal:   #0A6E8A  (primary)
     Green:  #8DC63F  (accent)
     Gold:   #F5B324  (highlight)
   ═══════════════════════════════════════════════════════════════════ */

:root {
    --primary:       #0A6E8A;
    --primary-light: #0D8DB0;
    --primary-dark:  #065A6E;
    --accent:        #8DC63F;
    --accent-light:  #A5D865;
    --accent-dark:   #6FA82E;
    --gold:          #F5B324;
    --gold-light:    #FBC94D;

    --bg:            #FAFBFC;
    --surface:       #FFFFFF;
    --text:          #1A1A2E;
    --text-secondary:#4A5568;
    --text-muted:    #94A3B8;
    --border:        #E2E8F0;

    --radius-sm:     0.375rem;
    --radius-md:     0.625rem;
    --radius-lg:     1rem;
    --radius-xl:     1.25rem;

    --shadow-sm:     0 1px 3px rgba(0,0,0,.06);
    --shadow-md:     0 4px 12px rgba(0,0,0,.08);
    --shadow-lg:     0 12px 40px rgba(0,0,0,.12);
    --shadow-xl:     0 20px 60px rgba(0,0,0,.15);

    --transition:    0.2s ease;
}

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

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; }
a { color: var(--primary); text-decoration: none; }
ul { list-style: none; }

.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* ── Buttons ──────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.7rem 1.75rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all var(--transition);
    text-decoration: none;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    border-color: var(--primary);
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(10,110,138,.3);
}
.btn-outline {
    background: transparent;
    color: var(--primary);
    border-color: var(--primary);
}
.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}
.btn-lg {
    padding: 0.9rem 2.25rem;
    font-size: 1.05rem;
}
.btn-full { width: 100%; justify-content: center; }

/* ── Alerts ───────────────────────────────────────────────────────── */
.alert {
    padding: 1rem 1.25rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
.alert-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #166534;
}
.alert-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    color: #991b1b;
}

/* ═══════════════════════════════════════════════════════════════════
   NAVBAR
   ═══════════════════════════════════════════════════════════════════ */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255,255,255,.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    padding: 0.75rem 0;
}
.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-logo-img {
    height: 44px;
    width: auto;
}
.nav-links {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.nav-links a {
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-weight: 500;
    color: var(--text-secondary);
    transition: color var(--transition), background var(--transition);
}
.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
    background: rgba(10,110,138,.06);
}
.nav-cta {
    margin-left: 0.5rem;
}
.nav-cta.btn { color: #fff !important; background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important; }
.nav-cta.btn:hover { background: var(--primary-dark) !important; }

/* Mobile toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}
.nav-toggle span {
    display: block;
    width: 24px;
    height: 2.5px;
    background: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

/* ═══════════════════════════════════════════════════════════════════
   HERO
   ═══════════════════════════════════════════════════════════════════ */
.hero {
    position: relative;
    padding: 10rem 0 6rem;
    overflow: hidden;
    background: linear-gradient(160deg, #f0f8fa 0%, #e8f5e9 50%, #fff8e1 100%);
}
.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
}
.hero-shape {
    position: absolute;
    border-radius: 50%;
    opacity: 0.12;
}
.shape-1 {
    width: 500px; height: 500px;
    background: var(--primary);
    top: -150px; right: -100px;
}
.shape-2 {
    width: 300px; height: 300px;
    background: var(--accent);
    bottom: -80px; left: -60px;
}
.shape-3 {
    width: 200px; height: 200px;
    background: var(--gold);
    top: 30%; left: 60%;
}

/* ── Flyer Hero ──────────────────────────────────────────────────── */
.hero.hero-flyer {
    background: #0a0a1a;
    padding: 12rem 0 7rem;
    min-height: 100vh;
}
.hero-flyer-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.hero-flyer-overlay {
    position: absolute;
    inset: 0;
    z-index: 0;
    background: linear-gradient(
        180deg,
        rgba(10, 15, 30, 0.55) 0%,
        rgba(10, 15, 30, 0.65) 40%,
        rgba(10, 15, 30, 0.85) 100%
    );
}
.hero-flyer .hero-content {
    z-index: 1;
}
.hero-flyer .hero-title {
    color: #fff;
    text-shadow: 0 2px 20px rgba(0,0,0,.3);
}
.hero-flyer .hero-title-accent {
    background: linear-gradient(135deg, var(--accent-light), var(--gold-light));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-flyer .hero-subtitle {
    color: rgba(255,255,255,.85);
}
.hero-flyer .hero-badge {
    background: rgba(245,179,36,.9);
    color: #7A4F00;
}
.hero-flyer .hero-meta-item {
    color: rgba(255,255,255,.8);
}
.hero-flyer .hero-meta-item i {
    color: var(--accent-light);
}
.hero-flyer .btn-outline {
    color: #fff;
    border-color: rgba(255,255,255,.5);
}
.hero-flyer .btn-outline:hover {
    background: rgba(255,255,255,.15);
    border-color: #fff;
    color: #fff;
}

.hero-content {
    position: relative;
    text-align: center;
    max-width: 720px;
    margin: 0 auto;
}
.hero-badge {
    display: inline-block;
    background: var(--gold);
    color: #7A4F00;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 0.4rem 1.25rem;
    border-radius: 50px;
    margin-bottom: 1.5rem;
    letter-spacing: 0.03em;
}
.hero-title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 1.25rem;
    color: var(--text);
}
.hero-title-accent {
    display: block;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-subtitle {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    line-height: 1.7;
}
.hero-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}
.hero-meta {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}
.hero-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.92rem;
    color: var(--text-secondary);
    font-weight: 500;
}
.hero-meta-item i {
    color: var(--primary);
}

/* ═══════════════════════════════════════════════════════════════════
   SECTIONS
   ═══════════════════════════════════════════════════════════════════ */
.section {
    padding: 5rem 0;
}
.section-header {
    text-align: center;
    max-width: 620px;
    margin: 0 auto 3rem;
}
.section-tag {
    display: inline-block;
    background: rgba(10,110,138,.08);
    color: var(--primary);
    font-weight: 700;
    font-size: 0.82rem;
    padding: 0.35rem 1rem;
    border-radius: 50px;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}
.section-header h2 {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--text);
}
.section-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

/* ── How It Works ─────────────────────────────────────────────────── */
.how-it-works {
    background: var(--surface);
}
.phases-grid {
    display: flex;
    align-items: stretch;
    gap: 2rem;
    justify-content: center;
}
.phase-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2.5rem 2rem;
    flex: 1;
    max-width: 380px;
    position: relative;
    transition: transform var(--transition), box-shadow var(--transition);
}
.phase-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}
.phase-card.featured {
    background: linear-gradient(160deg, rgba(10,110,138,.04), rgba(141,198,63,.04));
    border-color: var(--primary);
}
.phase-number {
    position: absolute;
    top: -16px;
    left: 24px;
    width: 36px;
    height: 36px;
    background: var(--primary);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.95rem;
}
.phase-card.featured .phase-number {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
}
.phase-icon {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}
.phase-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
    color: var(--text);
}
.phase-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.65;
}
.phase-connector {
    display: flex;
    align-items: center;
    color: var(--primary);
    font-size: 1.5rem;
    opacity: 0.4;
}

/* ── Details Grid ─────────────────────────────────────────────────── */
.details-section {
    background: var(--bg);
}
.details-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}
.detail-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    text-align: center;
    transition: transform var(--transition), box-shadow var(--transition);
}
.detail-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.detail-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 1.25rem;
    background: linear-gradient(135deg, rgba(10,110,138,.1), rgba(141,198,63,.1));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--primary);
}
.detail-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}
.detail-card p {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.6;
}

/* ── CTA ──────────────────────────────────────────────────────────── */
.cta-section {
    background: var(--surface);
}
.cta-card {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: var(--radius-xl);
    padding: 4rem 3rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    position: relative;
    overflow: hidden;
}
.cta-card::before {
    content: '';
    position: absolute;
    width: 300px; height: 300px;
    background: rgba(141,198,63,.15);
    border-radius: 50%;
    top: -100px; right: -50px;
}
.cta-content {
    position: relative;
}
.cta-content h2 {
    color: #fff;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 2rem;
    margin-bottom: 0.75rem;
}
.cta-content p {
    color: rgba(255,255,255,.8);
    font-size: 1.05rem;
    margin-bottom: 1.5rem;
    max-width: 480px;
}
.cta-card .btn-primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #1a1a2e;
}
.cta-card .btn-primary:hover {
    background: var(--accent-light);
    box-shadow: 0 6px 20px rgba(141,198,63,.4);
}
.cta-emoji {
    font-size: 6rem;
    position: relative;
    opacity: 0.9;
}

/* ═══════════════════════════════════════════════════════════════════
   REGISTER PAGE
   ═══════════════════════════════════════════════════════════════════ */
.register-section {
    padding-top: 8rem;
    min-height: 100vh;
    background: linear-gradient(180deg, #f0f8fa 0%, var(--bg) 100%);
}
.register-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    max-width: 520px;
    margin: 0 auto;
    box-shadow: var(--shadow-md);
}

/* League picker cards */
.league-picker {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: .75rem;
}
.league-picker-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: .4rem;
    padding: 1rem .75rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg, 10px);
    background: var(--surface, #fff);
    cursor: pointer;
    transition: border-color .2s, box-shadow .2s, transform .15s;
    font-family: inherit;
    font-size: inherit;
}
.league-picker-card:hover {
    border-color: var(--accent, #0A6E8A);
    box-shadow: 0 2px 8px rgba(10,110,138,.12);
    transform: translateY(-2px);
}
.league-picker-card.active {
    border-color: var(--accent, #0A6E8A);
    background: rgba(10,110,138,.06);
    box-shadow: 0 0 0 3px rgba(10,110,138,.18);
}
.league-picker-card img {
    border-radius: 8px;
    object-fit: contain;
}
.league-picker-name {
    font-weight: 600;
    font-size: .9rem;
    text-align: center;
    color: var(--text, #1e293b);
}
.league-picker-count {
    font-size: .78rem;
    color: #64748b;
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-group label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.form-group label i {
    color: var(--primary);
}
.form-group input {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-family: inherit;
    outline: none;
    transition: border-color var(--transition), box-shadow var(--transition);
    background: var(--bg);
}
.form-group input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(10,110,138,.1);
    background: #fff;
}
.form-group input::placeholder {
    color: var(--text-muted);
}

/* ── Avatar Picker ────────────────────────────────────────────────── */
.avatar-picker {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    background: var(--bg);
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}
.avatar-preview {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--surface);
    border: 3px solid var(--primary);
    box-shadow: var(--shadow-md);
}
.avatar-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: opacity 0.25s ease, transform 0.25s ease;
}
.avatar-controls {
    flex: 1;
    min-width: 0;
}
.avatar-hint {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}
.avatar-styles {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-bottom: 1rem;
}
.avatar-style-btn {
    padding: 0.3rem 0.65rem;
    border: 1.5px solid var(--border);
    border-radius: 50px;
    background: var(--surface);
    color: var(--text-secondary);
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
    white-space: nowrap;
}
.avatar-style-btn:hover {
    border-color: var(--primary-light);
    color: var(--primary);
    background: rgba(10,110,138,.04);
}
.avatar-style-btn.active {
    border-color: var(--primary);
    background: rgba(10,110,138,.08);
    color: var(--primary);
}
.btn-shuffle {
    padding: 0.45rem 1.25rem;
    font-size: 0.85rem;
}

@media (max-width: 520px) {
    .avatar-picker {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .avatar-controls { width: 100%; }
    .avatar-styles { justify-content: center; }
}

/* ═══════════════════════════════════════════════════════════════════
   RULES PAGE
   ═══════════════════════════════════════════════════════════════════ */
.rules-section {
    padding-top: 8rem;
    min-height: 100vh;
}
.rules-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}
.rule-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2rem;
    transition: transform var(--transition), box-shadow var(--transition);
}
.rule-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}
.rule-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(10,110,138,.1), rgba(141,198,63,.1));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}
.rule-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}
.rule-list {
    list-style: none;
}
.rule-list li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.55;
}
.rule-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55rem;
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
}
.rules-cta {
    text-align: center;
    margin-top: 3rem;
}
.rules-cta p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

/* ═══════════════════════════════════════════════════════════════════
   SCHEDULE PAGE
   ═══════════════════════════════════════════════════════════════════ */
.schedule-section {
    padding-top: 8rem;
    min-height: 100vh;
}
.schedule-empty {
    text-align: center;
    padding: 4rem 2rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    max-width: 480px;
    margin: 0 auto;
}
.schedule-empty h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}
.schedule-empty p {
    color: var(--text-secondary);
}
.schedule-week-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    margin-bottom: 1.5rem;
}
.schedule-week-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}
.schedule-week-header h3 {
    font-size: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
}
.schedule-week-progress {
    font-size: 0.82rem;
    color: var(--text-muted);
    font-weight: 600;
}
.schedule-matches {
    display: flex;
    flex-direction: column;
}
.schedule-match {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.85rem 1.5rem;
    border-bottom: 1px solid var(--border);
}
.schedule-match:last-child { border-bottom: none; }
.schedule-match.is-complete { background: rgba(16,185,129,.03); }
.schedule-player {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex: 1;
    min-width: 0;
    font-size: 0.92rem;
    color: var(--text-secondary);
}
.schedule-player.is-winner {
    font-weight: 700;
    color: var(--text);
}
.schedule-avatar {
    border-radius: 50%;
    border: 2px solid var(--border);
    flex-shrink: 0;
}
.schedule-vs {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    flex-shrink: 0;
    width: 40px;
    text-align: center;
}
.schedule-report-cta {
    background: linear-gradient(135deg, rgba(10,110,138,.06), rgba(141,198,63,.06));
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 1.25rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-top: 1rem;
    font-size: 0.95rem;
    color: var(--text-secondary);
}
.schedule-report-cta i {
    color: var(--primary);
    font-size: 1.25rem;
}
.schedule-report-cta a {
    font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════════════
   STANDINGS PAGE
   ═══════════════════════════════════════════════════════════════════ */
.standings-section {
    padding-top: 8rem;
    min-height: 100vh;
}
.standings-table-wrap {
    max-width: 680px;
    margin: 0 auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}
.standings-table {
    width: 100%;
    border-collapse: collapse;
}
.standings-table th {
    text-align: left;
    padding: 0.85rem 1.25rem;
    background: var(--bg);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    border-bottom: 1px solid var(--border);
}
.standings-table td {
    padding: 0.85rem 1.25rem;
    font-size: 0.95rem;
    border-bottom: 1px solid var(--border);
    color: var(--text-secondary);
}
.standings-table tr:last-child td { border-bottom: none; }
.standings-table tr:hover td { background: rgba(10,110,138,.02); }
.standings-table .col-rank { width: 50px; text-align: center; }
.standings-table .col-stat { width: 65px; text-align: center; font-weight: 700; }
.standings-table .col-wins { color: #16a34a; }
.standings-table .col-losses { color: #ef4444; }
.rank-medal { font-size: 1.3rem; }
.rank-gold td { background: rgba(245,179,36,.06); }
.rank-silver td { background: rgba(148,163,184,.06); }
.rank-bronze td { background: rgba(180,130,80,.04); }
.standings-player {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
}
.standings-avatar {
    border-radius: 50%;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

@media (max-width: 520px) {
    .schedule-match {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    .schedule-player { justify-content: center; }
}

/* ═══════════════════════════════════════════════════════════════════
   BRACKET / PLAYOFFS PAGE
   ═══════════════════════════════════════════════════════════════════ */
.bracket-section {
    padding-top: 8rem;
    min-height: 100vh;
}
.bracket-container {
    display: flex;
    gap: 0;
    overflow-x: auto;
    padding: 1.5rem 0;
    max-width: 100%;
}
.bracket-round {
    flex-shrink: 0;
    min-width: 220px;
    display: flex;
    flex-direction: column;
}
.bracket-round-header {
    text-align: center;
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--primary);
    padding: 0.5rem 0;
    margin-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary);
}
.bracket-matches {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    flex: 1;
    gap: 0.75rem;
    padding: 0.5rem 0.5rem;
}
.bracket-match {
    background: var(--surface);
    border: 1.5px solid var(--border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition);
}
.bracket-match:hover {
    box-shadow: var(--shadow-md);
}
.bracket-match.is-complete {
    border-color: #86efac;
}
.bracket-match.is-bye {
    border-color: #e2e8f0;
    opacity: 0.6;
}
.bracket-slot {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border);
    min-height: 38px;
}
.bracket-slot:last-of-type {
    border-bottom: none;
}
.bracket-slot.is-winner {
    background: rgba(16,185,129,.08);
    font-weight: 700;
    color: var(--text);
}
.bracket-avatar {
    border-radius: 50%;
    border: 1.5px solid var(--border);
    flex-shrink: 0;
}
.bracket-player-name {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.bracket-crown {
    color: #F5B324;
    font-size: 0.72rem;
    flex-shrink: 0;
}
.bracket-tbd {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.8rem;
}
.bracket-bye-label {
    display: block;
    text-align: center;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.2rem;
    background: var(--bg);
}

/* Champion banner */
.champion-banner {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 2px solid #fbbf24;
    border-radius: var(--radius-xl);
    padding: 1.5rem 2rem;
    margin-bottom: 2rem;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
    box-shadow: 0 4px 20px rgba(245,179,36,.2);
}
.champion-avatar {
    border-radius: 50%;
    border: 3px solid #f59e0b;
    flex-shrink: 0;
}
.champion-label {
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #92400e;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.25rem;
}
.champion-label i {
    color: #f59e0b;
}
.champion-name {
    font-size: 1.5rem;
    font-weight: 800;
    color: #78350f;
    font-family: 'Space Grotesk', 'Inter', sans-serif;
}

@media (max-width: 768px) {
    .bracket-container {
        flex-direction: column;
    }
    .bracket-round {
        min-width: 100%;
    }
    .champion-banner {
        flex-direction: column;
        text-align: center;
    }
}

/* ═══════════════════════════════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════════════════════════════ */
.site-footer {
    background: var(--text);
    color: rgba(255,255,255,.7);
    padding: 3.5rem 0 0;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 3rem;
    padding-bottom: 2.5rem;
    border-bottom: 1px solid rgba(255,255,255,.1);
}
.footer-logo {
    height: 48px;
    width: auto;
    margin-bottom: 1rem;
    filter: brightness(0) invert(1);
    opacity: 0.85;
}
.footer-brand p {
    font-size: 0.9rem;
    line-height: 1.6;
    color: rgba(255,255,255,.55);
}
.footer-links h4,
.footer-contact h4 {
    color: #fff;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 1rem;
}
.footer-links ul { list-style: none; }
.footer-links li { margin-bottom: 0.5rem; }
.footer-links a {
    color: rgba(255,255,255,.6);
    font-size: 0.9rem;
    transition: color var(--transition);
}
.footer-links a:hover { color: var(--accent-light); }
.footer-contact p {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
    color: rgba(255,255,255,.55);
}
.footer-bottom {
    padding: 1.5rem 0;
    text-align: center;
}
.footer-bottom p {
    font-size: 0.82rem;
    color: rgba(255,255,255,.35);
}

/* ═══════════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .nav-toggle { display: flex; }
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border);
        box-shadow: var(--shadow-md);
    }
    .nav-links.open { display: flex; }

    .hero { padding: 8rem 0 4rem; }
    .hero-title { font-size: 2.25rem; }

    .phases-grid { flex-direction: column; align-items: center; }
    .phase-connector { transform: rotate(90deg); }

    .details-grid { grid-template-columns: 1fr; }

    .rules-grid { grid-template-columns: 1fr; }

    .cta-card {
        flex-direction: column;
        text-align: center;
        padding: 3rem 2rem;
    }
    .cta-emoji { font-size: 4rem; }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}
