/* ========================================
   Vick's Masters Pool 2026 — Styles
   Augusta Green Theme
   ======================================== */

:root {
    --masters-green: #006747;
    --masters-dark: #004d35;
    --masters-light: #e8f5e9;
    --masters-gold: #c8a951;
    --white: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-500: #6b7280;
    --gray-700: #374151;
    --gray-900: #111827;
    --red: #dc2626;
    --red-light: #fef2f2;
    --blue: #2563eb;
    --score-under: #006747;
    --score-over: #dc2626;
    --font: 'Georgia', 'Times New Roman', serif;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

body {
    font-family: var(--font-sans);
    color: var(--gray-900);
    background: var(--gray-50);
    line-height: 1.6;
}

/* --- Navbar --- */
.navbar {
    background: var(--masters-green);
    color: var(--white);
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.nav-brand a {
    color: var(--white);
    text-decoration: none;
    font-family: var(--font);
    font-size: 1.2rem;
    font-weight: bold;
}

.nav-links {
    display: flex;
    gap: 24px;
}

.nav-links a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    font-size: 0.95rem;
    padding: 4px 0;
    border-bottom: 2px solid transparent;
    transition: border-color 0.2s;
}

.nav-links a:hover { border-bottom-color: var(--masters-gold); }

.nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
}

/* --- Container --- */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px 16px;
}

/* --- Hero --- */
.hero {
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--masters-green), var(--masters-dark));
    color: var(--white);
    border-radius: 12px;
    margin-bottom: 32px;
}

.hero-badge { font-size: 3rem; margin-bottom: 8px; }
.hero h1 { font-family: var(--font); font-size: 2.5rem; margin-bottom: 4px; }
.hero h2 { font-weight: 400; font-size: 1.3rem; margin-bottom: 4px; opacity: 0.9; }
.hero-subtitle { opacity: 0.75; margin-bottom: 24px; }

.hero-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.btn-primary {
    background: var(--masters-green);
    color: var(--white);
    border-color: var(--masters-green);
}
.btn-primary:hover { background: var(--masters-dark); }

.btn-success {
    background: var(--masters-gold);
    color: var(--gray-900);
    border-color: var(--masters-gold);
}
.btn-success:hover { opacity: 0.9; }

.btn-outline {
    background: transparent;
    color: var(--white);
    border-color: rgba(255,255,255,0.5);
}
.btn-outline:hover { border-color: var(--white); background: rgba(255,255,255,0.1); }

.btn-large { padding: 14px 32px; font-size: 1.1rem; }

.btn-expand {
    background: none;
    border: 1px solid var(--gray-300);
    border-radius: 4px;
    padding: 2px 8px;
    cursor: pointer;
    font-size: 0.8rem;
}

.btn-small {
    padding: 4px 10px;
    font-size: 0.85rem;
    background: var(--masters-green);
    color: var(--white);
    border: none;
    border-radius: 4px;
    cursor: pointer;
}
.btn-danger {
    background: #c0392b;
}
.btn-danger:hover {
    background: #e74c3c;
}

/* --- Info Cards --- */
.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.info-card {
    background: var(--white);
    padding: 24px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.info-card h3 { margin-bottom: 8px; }
.info-card a { color: var(--masters-green); text-decoration: none; font-weight: 600; }

/* --- Flash Messages --- */
.flash {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-weight: 500;
}
.flash-success { background: var(--masters-light); color: var(--masters-dark); border: 1px solid var(--masters-green); }
.flash-error { background: var(--red-light); color: var(--red); border: 1px solid var(--red); }

/* --- Rules --- */
.rules-section { margin-bottom: 32px; }
.rules-section h2 {
    font-family: var(--font);
    color: var(--masters-green);
    margin-bottom: 12px;
    padding-bottom: 4px;
    border-bottom: 2px solid var(--masters-light);
}

.rules-table {
    width: 100%;
    border-collapse: collapse;
    margin: 16px 0;
}
.rules-table th {
    background: var(--masters-green);
    color: var(--white);
    padding: 10px 12px;
    text-align: left;
}
.rules-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--gray-200);
}

.payout-example {
    background: var(--masters-light);
    padding: 16px;
    border-radius: 8px;
    margin-top: 12px;
}

/* --- Draft Board --- */
.tier-section { margin-bottom: 24px; }
.tier-header {
    font-family: var(--font);
    padding: 12px 16px;
    border-radius: 8px 8px 0 0;
    color: var(--white);
    background: var(--masters-green);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tier-badge {
    background: rgba(255,255,255,0.2);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: normal;
}

.tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 8px;
    padding: 12px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-top: none;
    border-radius: 0 0 8px 8px;
}

.golfer-card {
    padding: 10px 12px;
    border: 1px solid var(--gray-200);
    border-radius: 6px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--gray-50);
}

.golfer-name { font-weight: 600; font-size: 0.9rem; }
.golfer-odds { color: var(--gray-500); font-size: 0.85rem; }

/* --- Pick Form --- */
.pick-form { max-width: 600px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; }
.form-input, .form-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    font-size: 1rem;
}
.form-input:focus, .form-select:focus {
    outline: none;
    border-color: var(--masters-green);
    box-shadow: 0 0 0 3px rgba(0,103,71,0.1);
}
.form-help { color: var(--gray-500); font-size: 0.85rem; margin-bottom: 6px; }

.tier-pick { position: relative; }
.tier-pick label { color: var(--masters-green); }

.checkbox-label, .radio-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    margin-right: 16px;
}

.side-props { margin-top: 12px; padding: 16px; background: var(--gray-100); border-radius: 8px; }
.side-prop { margin-bottom: 12px; }
.side-prop p { margin-bottom: 4px; font-weight: 500; }

.submitted-section { margin-bottom: 24px; }
.submitted-list { display: flex; flex-wrap: wrap; gap: 8px; }
.participant-chip {
    background: var(--masters-light);
    color: var(--masters-dark);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* --- Dashboard --- */
.dashboard-header { margin-bottom: 24px; }
.dashboard-header h1 { margin-bottom: 4px; }

.standings-section { margin-bottom: 32px; }
.standings-section h2 { font-family: var(--font); color: var(--masters-green); margin-bottom: 16px; }

.standings-table-wrap { overflow-x: auto; }

.standings-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.standings-table th {
    background: var(--masters-green);
    color: var(--white);
    padding: 12px;
    text-align: left;
    font-size: 0.9rem;
}

.standings-table td {
    padding: 12px;
    border-bottom: 1px solid var(--gray-100);
}

.standings-table tbody tr:hover { background: var(--masters-light); }

.rank-first { background: rgba(200, 169, 81, 0.08); }
.rank-second { background: rgba(200, 169, 81, 0.04); }

.rank-cell { font-size: 1.1rem; text-align: center; }
.participant-link { color: var(--masters-green); text-decoration: none; font-weight: 600; }
.participant-link:hover { text-decoration: underline; }

.score-cell { font-weight: 700; font-size: 1.1rem; }
.score-under { color: var(--score-under); }
.score-over { color: var(--score-over); }

.movement-up { color: var(--masters-green); font-weight: 600; }
.movement-down { color: var(--red); font-weight: 600; }
.movement-cell { font-size: 0.95rem; }

.dropped-cell { font-size: 0.8rem; }

.detail-row td { padding: 0; background: var(--gray-50); }
.golfer-breakdown { padding: 12px 16px; }

.golfer-detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.golfer-detail-table th {
    background: var(--gray-200);
    color: var(--gray-700);
    padding: 8px;
    text-align: left;
}
.golfer-detail-table td {
    padding: 8px;
    border-bottom: 1px solid var(--gray-100);
}

.golfer-dropped { opacity: 0.45; }
.drop-badge {
    background: var(--red);
    color: var(--white);
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 0.7rem;
    font-weight: 600;
    margin-left: 4px;
}

.status-cut { color: var(--red); font-weight: 600; }
.status-active { color: var(--masters-green); }

/* --- Payout --- */
.payout-section { margin-bottom: 32px; }
.payout-section h2 { font-family: var(--font); color: var(--masters-green); margin-bottom: 16px; }
.payout-cards { display: flex; gap: 16px; flex-wrap: wrap; }
.payout-card {
    flex: 1;
    min-width: 200px;
    background: var(--white);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    text-align: center;
}
.payout-winner { border-color: var(--masters-gold); border-width: 2px; }
.payout-label { display: block; font-size: 0.85rem; color: var(--gray-500); margin-bottom: 4px; }
.payout-name { display: block; font-weight: 700; font-size: 1.1rem; margin-bottom: 4px; }
.payout-amount { display: block; font-size: 1.5rem; font-weight: 700; color: var(--masters-green); }

/* --- Stats --- */
.stats-section { margin-bottom: 32px; }
.stats-section h2 { font-family: var(--font); color: var(--masters-green); margin-bottom: 16px; }
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}
.stat-card {
    background: var(--white);
    padding: 16px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
}
.stat-label { display: block; font-size: 0.85rem; color: var(--gray-500); margin-bottom: 4px; }
.stat-value { display: block; font-weight: 700; font-size: 1.1rem; }
.stat-detail { display: block; font-size: 0.85rem; color: var(--gray-500); margin-top: 2px; }

/* --- Score Summary (participant detail) --- */
.score-summary { display: flex; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.score-card-big, .score-card-small {
    background: var(--white);
    padding: 20px 24px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
    text-align: center;
}
.score-card-big { border-color: var(--masters-green); border-width: 2px; }
.score-label { display: block; font-size: 0.85rem; color: var(--gray-500); margin-bottom: 4px; }
.score-card-big .score-value { font-size: 2rem; font-weight: 700; }
.score-card-small .score-value { font-size: 1.3rem; font-weight: 600; color: var(--gray-500); }

.golfer-breakdown-full { margin-bottom: 24px; }
.golfer-breakdown-full h2 { font-family: var(--font); color: var(--masters-green); margin-bottom: 12px; }

.back-link { color: var(--masters-green); text-decoration: none; display: inline-block; margin-bottom: 16px; }
.back-link:hover { text-decoration: underline; }

/* --- Reports --- */
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 16px;
}
.report-card {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}
.report-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.report-card a { text-decoration: none; color: var(--gray-900); }
.report-thumb { width: 100%; height: auto; }
.report-icon { text-align: center; font-size: 3rem; padding: 20px; }
.report-name { display: block; padding: 12px; font-weight: 500; text-align: center; }

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: 48px;
    color: var(--gray-500);
}

/* --- CTA Box --- */
.cta-box {
    text-align: center;
    padding: 32px;
    background: var(--masters-light);
    border-radius: 8px;
    margin-top: 32px;
}
.cta-box h3 { margin-bottom: 12px; }
.cta-box .btn-outline { color: var(--masters-green); border-color: var(--masters-green); }
.cta-box .btn-outline:hover { background: var(--masters-green); color: var(--white); }
.cta-box .btn { margin: 0 6px; }

/* --- Admin --- */
.admin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 16px;
}
.admin-card {
    background: var(--white);
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--gray-200);
}
.admin-card h3 { margin-bottom: 12px; color: var(--masters-green); }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.85rem; }
.admin-table th { background: var(--gray-100); padding: 8px; text-align: left; }
.admin-table td { padding: 8px; border-bottom: 1px solid var(--gray-100); }

.form-input-small { width: 60px; padding: 4px 8px; border: 1px solid var(--gray-300); border-radius: 4px; }
.form-select-small { padding: 4px 8px; border: 1px solid var(--gray-300); border-radius: 4px; }
.form-textarea { width: 100%; padding: 8px; border: 1px solid var(--gray-300); border-radius: 6px; font-family: monospace; font-size: 0.85rem; }

.side-result-form { margin-bottom: 8px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.side-result-form p { flex: 1; min-width: 200px; }

/* --- Footer --- */
.footer {
    text-align: center;
    padding: 24px;
    color: var(--gray-500);
    font-size: 0.85rem;
    border-top: 1px solid var(--gray-200);
    margin-top: 48px;
}

/* --- 2025 Results Page --- */
.results-hero {
    text-align: center;
    margin: 2rem 0;
}

.champion-card {
    background: linear-gradient(135deg, var(--masters-green), var(--masters-dark));
    color: white;
    padding: 2.5rem;
    border-radius: var(--radius);
    display: inline-block;
    min-width: 320px;
    box-shadow: 0 8px 32px rgba(0, 103, 71, 0.3);
}

.champion-label {
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--masters-gold);
    margin-bottom: 0.5rem;
}

.champion-name {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
}

.champion-score {
    font-size: 3rem;
    font-weight: 900;
    color: var(--masters-gold);
    margin-bottom: 0.5rem;
}

.champion-detail {
    font-size: 0.95rem;
    opacity: 0.9;
}

.picks-grid-2025 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.25rem;
    margin-top: 1rem;
}

.participant-picks-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.participant-picks-card h3 {
    margin-bottom: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.score-badge {
    font-size: 1rem;
    padding: 0.25rem 0.75rem;
    border-radius: 999px;
    font-weight: 700;
}

.score-badge.under-par {
    background: #dcfce7;
    color: #166534;
}

.score-badge.over-par {
    background: #fef2f2;
    color: #991b1b;
}

.mini-table {
    width: 100%;
    font-size: 0.85rem;
}

.mini-table th {
    text-align: left;
    padding: 0.3rem 0.5rem;
    border-bottom: 1px solid var(--gray-200);
    color: var(--gray-500);
    font-weight: 600;
}

.mini-table td {
    padding: 0.3rem 0.5rem;
    border-bottom: 1px solid #f3f4f6;
}

.mini-table tr.dropped td {
    opacity: 0.4;
    text-decoration: line-through;
}

.cut-badge {
    background: #fef2f2;
    color: #dc2626;
    font-size: 0.7rem;
    padding: 0.1rem 0.4rem;
    border-radius: 3px;
    font-weight: 700;
}

.rank-1 td { background: #fefce8; }
.rank-2 td { background: #f0fdf4; }

/* --- Utilities --- */
.text-muted { color: var(--gray-500); }
.subtitle { color: var(--gray-500); margin-bottom: 24px; }

/* --- Responsive --- */
@media (max-width: 768px) {
    .nav-links { display: none; position: absolute; top: 60px; left: 0; right: 0; background: var(--masters-green); flex-direction: column; padding: 16px 24px; gap: 12px; }
    .nav-links.open { display: flex; }
    .nav-toggle { display: block; }

    .hero h1 { font-size: 1.8rem; }
    .hero h2 { font-size: 1.1rem; }
    .hero-actions { flex-direction: column; align-items: center; }

    .standings-table { font-size: 0.85rem; }
    .standings-table th, .standings-table td { padding: 8px 6px; }
    .dropped-cell { display: none; }

    .admin-grid { grid-template-columns: 1fr; }
    .tier-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}

/* ==========================================
   MASTERS POOL DASHBOARD — Card Layout
   Inspired by the 2025 Excel Report
   ========================================== */

/* --- Pool Header --- */
.masters-pool-header {
    background: linear-gradient(135deg, #006747 0%, #004d35 60%, #003926 100%);
    color: #fff;
    text-align: center;
    padding: 40px 20px 32px;
    border-radius: 12px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 103, 71, 0.35);
}
.masters-pool-header::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}
.pool-header-inner { position: relative; z-index: 1; }

.pool-header-decoration {
    margin-bottom: 8px;
    display: flex;
    justify-content: center;
    gap: 12px;
}
.azalea {
    font-size: 1.5rem;
    animation: azalea-sway 3s ease-in-out infinite;
    color: #e8a0bf;
}
.azalea-1 { animation-delay: 0s; }
.azalea-2 { animation-delay: 0.5s; color: #f0c4d8; }
.azalea-3 { animation-delay: 1s; }

@keyframes azalea-sway {
    0%, 100% { transform: rotate(-5deg) scale(1); }
    50% { transform: rotate(5deg) scale(1.1); }
}

.pool-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 2.8rem;
    font-weight: 900;
    letter-spacing: 3px;
    margin-bottom: 2px;
    text-shadow: 0 2px 8px rgba(0,0,0,0.2);
    color: #fff;
}
.pool-subtitle {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.15rem;
    font-weight: 400;
    color: #c8a951;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 16px;
}
.privacy-note {
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
    margin-top: 8px;
}

/* --- Live Indicator --- */
.live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.85);
    background: rgba(0,0,0,0.2);
    padding: 6px 16px;
    border-radius: 20px;
}
.live-dot {
    width: 8px;
    height: 8px;
    background: #4ade80;
    border-radius: 50%;
    animation: pulse-live 2s ease-in-out infinite;
}
@keyframes pulse-live {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); }
    50% { opacity: 0.6; box-shadow: 0 0 0 6px rgba(74, 222, 128, 0); }
}

/* --- Quick Standings Bar --- */
.standings-bar {
    display: flex;
    gap: 8px;
    padding: 12px 0;
    margin-bottom: 24px;
    overflow-x: auto;
    scrollbar-width: thin;
}
.standings-bar-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    padding: 10px 16px;
    text-decoration: none;
    color: #111827;
    white-space: nowrap;
    transition: all 0.25s ease;
    cursor: pointer;
    min-width: 0;
    flex-shrink: 0;
}
.standings-bar-item:hover {
    border-color: #006747;
    box-shadow: 0 4px 12px rgba(0, 103, 71, 0.15);
    transform: translateY(-2px);
}
.standings-bar-item.bar-leader {
    border-color: #c8a951;
    background: linear-gradient(135deg, #fffef5, #fff9e0);
}
.bar-rank {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #006747;
    color: #fff;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.8rem;
    flex-shrink: 0;
}
.bar-leader .bar-rank { background: #c8a951; color: #1a1a1a; }
.bar-name { font-weight: 600; font-size: 0.9rem; }
.bar-score { font-weight: 700; font-size: 0.95rem; }
.bar-under { color: #006747; }
.bar-over { color: #dc2626; }
.bar-even { color: #374151; }
.bar-movement { font-size: 0.8rem; font-weight: 600; }

/* --- Participant Cards Grid --- */
.participant-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(480px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

/* --- Individual Card --- */
.masters-card {
    background: #fff;
    border-radius: 12px;
    border: 2px solid #e5e7eb;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s ease;
    animation: card-enter 0.5s ease-out both;
}
.masters-card > *:first-child {
    border-radius: 10px 10px 0 0;
}
.masters-card > *:last-child {
    border-radius: 0 0 10px 10px;
}
.masters-card:nth-child(1) { animation-delay: 0s; }
.masters-card:nth-child(2) { animation-delay: 0.08s; }
.masters-card:nth-child(3) { animation-delay: 0.16s; }
.masters-card:nth-child(4) { animation-delay: 0.24s; }
.masters-card:nth-child(5) { animation-delay: 0.32s; }
.masters-card:nth-child(6) { animation-delay: 0.40s; }
.masters-card:nth-child(7) { animation-delay: 0.48s; }

@keyframes card-enter {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.masters-card:hover {
    box-shadow: 0 8px 24px rgba(0, 103, 71, 0.12);
    transform: translateY(-2px);
}

.masters-card.card-leader {
    border-color: #c8a951;
    box-shadow: 0 4px 16px rgba(200, 169, 81, 0.25);
}
.masters-card.card-runner-up {
    border-color: #a0aab4;
}

.masters-card.card-highlight {
    animation: highlight-glow 1.5s ease;
}
@keyframes highlight-glow {
    0% { box-shadow: 0 0 0 0 rgba(200, 169, 81, 0.6); }
    50% { box-shadow: 0 0 0 8px rgba(200, 169, 81, 0.2); }
    100% { box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
}

/* --- Card Header --- */
.card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #006747, #004d35);
    color: #fff;
}
.card-head-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1 1 auto;
}
.card-flag-icon { flex-shrink: 0; opacity: 0.85; }
.card-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.25rem;
    font-weight: 700;
}
.card-name a {
    color: #fff;
    text-decoration: none;
}
.card-name a:hover { text-decoration: underline; color: #c8a951; }
.card-rank-label {
    font-size: 0.8rem;
    color: rgba(255,255,255,0.7);
    font-weight: 400;
}
.card-leader .card-rank-label { color: #c8a951; }
.card-head-right { text-align: right; flex-shrink: 0; }

.card-movement {
    font-size: 1.1rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 6px;
    background: rgba(255,255,255,0.1);
    white-space: nowrap;
}
.card-movement.movement-up { color: #4ade80; }
.card-movement.movement-down { color: #f87171; }

/* --- Card Score Bar --- */
.card-score-bar {
    display: flex;
    align-items: baseline;
    gap: 8px;
    padding: 12px 20px;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    overflow: visible;
    min-height: 48px;
}
.card-score-main {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.8rem;
    font-weight: 900;
    white-space: nowrap;
    flex-shrink: 0;
}
.card-score-main.score-under { color: #006747; }
.card-score-main.score-over { color: #dc2626; }
.card-score-label {
    font-size: 0.85rem;
    color: #6b7280;
    font-weight: 500;
}

/* --- Golfer Table --- */
.card-table-wrap { overflow-x: auto; }

.masters-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}
.masters-table thead th {
    background: #f0ebe0;
    color: #5c4e2a;
    font-weight: 700;
    padding: 8px 10px;
    text-align: center;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #d9cda7;
}
.masters-table thead th.col-golfer,
.masters-table thead th.col-tier {
    text-align: left;
}

.masters-table tbody td {
    padding: 8px 10px;
    border-bottom: 1px solid #f0ebe0;
    text-align: center;
    vertical-align: middle;
}
.masters-table tbody td.col-tier {
    text-align: left;
    font-weight: 600;
    color: #006747;
    white-space: nowrap;
}
.masters-table tbody td.col-golfer {
    text-align: left;
    font-weight: 600;
    color: #1a1a1a;
    white-space: nowrap;
}

/* --- Thru Column --- */
.col-thru {
    text-align: center;
    white-space: nowrap;
    font-size: 0.8rem;
    color: #6b7280;
}
.masters-table thead th.col-thru {
    text-align: center;
}

/* --- Round Score Cells --- */
.round-score {
    display: inline-block;
    min-width: 32px;
    padding: 3px 6px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.85rem;
    text-align: center;
}
.rs-under {
    background: #dcfce7;
    color: #166534;
}
.rs-over {
    background: #fef2f2;
    color: #991b1b;
}
.rs-even {
    background: #f3f4f6;
    color: #374151;
}
.rs-live {
    animation: pulse-score 2s ease-in-out infinite;
}
@keyframes pulse-score {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.65; }
}
.rs-pending { }

/* Penalty rounds (very high scores) get red highlight */
.round-score.rs-over {
    /* Intensity increases with score — handled via threshold in template or override */
}
.round-score.rs-penalty {
    color: #dc2626;
    font-style: italic;
    opacity: 0.7;
}

/* --- Total Column --- */
.col-total {
    font-weight: 800;
    font-size: 0.95rem;
    text-align: center !important;
}
.total-under { color: #006747; }
.total-over { color: #dc2626; }
.total-even { color: #374151; }

/* --- Dropped Row --- */
.row-dropped {
    opacity: 0.35;
}
.row-dropped td {
    text-decoration: line-through;
    text-decoration-color: rgba(0,0,0,0.3);
}
.row-dropped td.col-golfer { text-decoration: none; }
.row-dropped .col-golfer { font-style: italic; }

/* --- CUT / WD / Thru Badges --- */
.badge-cut {
    display: inline-block;
    background: #dc2626;
    color: #fff;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 700;
    margin-left: 4px;
    vertical-align: middle;
}
.badge-thru {
    display: inline-block;
    background: #006747;
    color: #fff;
    padding: 1px 6px;
    border-radius: 3px;
    font-size: 0.65rem;
    font-weight: 600;
    margin-left: 4px;
    vertical-align: middle;
}

/* --- Footer Rows --- */
.masters-table tfoot td {
    padding: 8px 10px;
    font-weight: 700;
    text-align: center;
    border-top: 2px solid #d9cda7;
}
.row-total td {
    background: #f9fafb;
    color: #6b7280;
    font-size: 0.85rem;
}
.row-drops-total td {
    background: #f0ebe0;
    font-size: 0.95rem;
}
.total-label {
    text-align: right !important;
    font-style: italic;
    padding-right: 12px !important;
}

/* --- Card Private State --- */
.card-private {
    padding: 32px 20px;
    text-align: center;
    color: #9ca3af;
    font-style: italic;
}

/* --- Payout Banner --- */
.payout-banner {
    margin-bottom: 32px;
    text-align: center;
}
.payout-banner h2 {
    font-family: 'Playfair Display', Georgia, serif;
    color: #006747;
    margin-bottom: 16px;
    font-size: 1.4rem;
}
.payout-banner .payout-cards {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}
.payout-banner .payout-card {
    flex: 0 1 220px;
    background: #fff;
    padding: 24px 20px;
    border-radius: 12px;
    border: 2px solid #e5e7eb;
    text-align: center;
    transition: transform 0.2s ease;
}
.payout-banner .payout-card:hover { transform: translateY(-3px); }
.payout-banner .payout-winner { border-color: #c8a951; background: linear-gradient(135deg, #fffef5, #fff9e0); }
.payout-trophy { font-size: 2rem; margin-bottom: 4px; }
.payout-banner .payout-name { display: block; font-weight: 700; font-size: 1.05rem; margin-bottom: 2px; }
.payout-banner .payout-amount { display: block; font-family: 'Playfair Display', Georgia, serif; font-size: 1.6rem; font-weight: 900; color: #006747; }

/* --- Masters Stats Section --- */
.masters-stats h2 {
    font-family: 'Playfair Display', Georgia, serif;
    color: #006747;
    margin-bottom: 16px;
    font-size: 1.4rem;
}
.masters-stats .stat-card {
    position: relative;
    padding-left: 52px;
    min-height: 60px;
}
.stat-icon {
    position: absolute;
    left: 16px;
    top: 16px;
    font-size: 1.5rem;
}

/* --- Dashboard Responsive --- */
@media (max-width: 1024px) {
    .participant-cards {
        grid-template-columns: 1fr;
    }
}
/* Header full/short label toggle — default: show full, hide short */
.hdr-short { display: none; }
.hdr-full  { display: inline; }

@media (max-width: 600px) {
    .pool-title { font-size: 1.8rem; letter-spacing: 1px; }
    .pool-subtitle { font-size: 0.9rem; letter-spacing: 2px; }
    .standings-bar { gap: 6px; padding: 8px 0; }
    .standings-bar-item { padding: 8px 12px; font-size: 0.85rem; }
    .card-head { padding: 10px 12px; }
    .card-name { font-size: 1.05rem; }
    .card-flag-icon { display: none; }
    .card-score-bar { padding: 10px 12px; }
    .card-score-main { font-size: 1.4rem; }
    .payout-banner .payout-card { flex: 0 1 160px; padding: 16px 12px; }

    /* Swap to short headers */
    .hdr-full  { display: none; }
    .hdr-short { display: inline; }

    /* Force table to fit viewport — allow scroll if needed */
    .card-table-wrap { overflow-x: auto; }
    .masters-table { font-size: 0.75rem; table-layout: fixed; width: 100%; }
    .masters-table thead th { padding: 5px 2px; font-size: 0.65rem; letter-spacing: 0; }
    .masters-table tbody td { padding: 5px 2px; }

    /* Column widths: let golfer take remaining space */
    .masters-table .col-tier   { width: 22px; }
    .masters-table .col-golfer { width: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 0; }
    .masters-table .col-thru   { width: 30px; font-size: 0.65rem; }
    .masters-table .col-round  { width: 26px; }
    .masters-table .col-total  { width: 40px; }

    .round-score { min-width: 0; padding: 2px 3px; font-size: 0.72rem; }
    .badge-cut, .badge-thru { font-size: 0.55rem; padding: 0px 3px; margin-left: 2px; }

    /* Footer rows */
    .total-label { font-size: 0.7rem; }
    .masters-table tfoot td { padding: 5px 4px; }
    .row-total td { font-size: 0.75rem; }
    .row-drops-total td { font-size: 0.82rem; }
    .masters-table tfoot .col-total { font-size: 0.85rem; }
}

/* ================================================
   RANKING CHART
   ================================================ */
.ranking-chart-section {
    max-width: 900px;
    margin: 0 auto 32px;
    padding: 0 16px;
}

.chart-title {
    font-family: 'Playfair Display', Georgia, serif;
    color: #006747;
    text-align: center;
    font-size: 1.4rem;
    margin-bottom: 8px;
}

.chart-day-filter {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.day-filter-btn {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 5px 14px;
    border: 1.5px solid #006747;
    border-radius: 20px;
    background: #fff;
    color: #006747;
    cursor: pointer;
    transition: all 0.15s;
}

.day-filter-btn:hover {
    background: #e8f5e9;
}

.day-filter-btn.active {
    background: #006747;
    color: #fff;
}

.chart-container {
    position: relative;
    background: #fff;
    border-radius: 12px;
    border: 2px solid #d9cda7;
    padding: 20px 16px;
    height: 320px;
    box-shadow: 0 2px 8px rgba(0, 103, 71, 0.08);
}

@media (max-width: 600px) {
    .chart-container {
        height: 260px;
        padding: 12px 8px;
    }
    .chart-title {
        font-size: 1.1rem;
    }
}

/* ================================================
   FULL TOURNAMENT LEADERBOARD
   ================================================ */
.tournament-leaderboard-section {
    max-width: 900px;
    margin: 0 auto 40px;
    padding: 0 16px;
}

.leaderboard-title {
    font-family: 'Playfair Display', Georgia, serif;
    color: #006747;
    text-align: center;
    font-size: 1.4rem;
    margin-bottom: 4px;
}

.leaderboard-subtitle {
    text-align: center;
    color: #6b7280;
    font-size: 0.85rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.lb-pool-swatch {
    display: inline-block;
    width: 14px;
    height: 14px;
    background: #e6f5ee;
    border: 2px solid #006747;
    border-radius: 3px;
    vertical-align: middle;
}

/* ================================================
   TIER MOVERS — ODDS vs REALITY
   ================================================ */
.tier-movers-section {
    max-width: 900px;
    margin: 0 auto 32px;
    padding: 0 16px;
}
.movers-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}
.movers-column {
    background: #fff;
    border-radius: 12px;
    border: 2px solid #e5e7eb;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.movers-col-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1rem;
    font-weight: 700;
    padding: 12px 16px;
    margin: 0;
    border-bottom: 2px solid #e5e7eb;
}
.movers-col-title.movers-hot {
    background: linear-gradient(135deg, #006747, #004d35);
    color: #fff;
    border-bottom: 2px solid #c8a951;
}
.movers-col-title.movers-cold {
    background: #f9fafb;
    color: #6b7280;
    border-bottom: 2px solid #e5e7eb;
}
.mover-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-bottom: 1px solid #f0ebe0;
    transition: background 0.15s;
}
.mover-row:last-child { border-bottom: none; }
.mover-row:hover { background: #faf8f2; }
.mover-row.mover-pool {
    background: #e6f5ee;
}
.mover-row.mover-pool:hover {
    background: #d4eddf;
}
.mover-delta {
    flex-shrink: 0;
    width: 42px;
    text-align: center;
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 900;
    font-size: 1.1rem;
    border-radius: 6px;
    padding: 4px 0;
}
.mover-delta.delta-up {
    color: #006747;
    background: #dcfce7;
}
.mover-delta.delta-down {
    color: #dc2626;
    background: #fef2f2;
}
.mover-info {
    flex: 1;
    min-width: 0;
}
.mover-name {
    display: block;
    font-weight: 700;
    font-size: 0.9rem;
    color: #1a1a1a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.mover-score {
    font-weight: 700;
    font-size: 0.82rem;
}
.mover-score.ms-under { color: #006747; }
.mover-score.ms-over { color: #dc2626; }
.mover-score.ms-even { color: #6b7280; }
.mover-detail {
    display: block;
    font-size: 0.75rem;
    color: #9ca3af;
}
.mover-picked {
    flex-shrink: 0;
    font-size: 0.72rem;
    color: #006747;
    font-weight: 600;
    max-width: 80px;
    text-align: right;
    word-break: break-word;
    line-height: 1.3;
}

@media (max-width: 700px) {
    .movers-grid { grid-template-columns: 1fr; }
    .mover-picked { display: none; }
    .mover-row { padding: 8px 12px; }
    .mover-delta { width: 36px; font-size: 0.95rem; }
    .mover-name { font-size: 0.85rem; }
}

.leaderboard-table-wrap {
    background: #fff;
    border-radius: 12px;
    border: 2px solid #d9cda7;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 103, 71, 0.08);
    max-height: 600px;
    overflow-y: auto;
}

.leaderboard-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.leaderboard-table thead {
    position: sticky;
    top: 0;
    z-index: 2;
}

.leaderboard-table thead th {
    background: #006747;
    color: #fff;
    padding: 10px 8px;
    text-align: left;
    font-weight: 700;
    font-size: 0.78rem;
    letter-spacing: 0;
    white-space: nowrap;
    border-bottom: 2px solid #c8a951;
}

.leaderboard-table tbody tr {
    border-bottom: 1px solid #f0ebe0;
    transition: background 0.15s;
}

.leaderboard-table tbody tr:hover {
    background: #faf8f2;
}

/* Pool golfer row highlight */
.lb-row-pool {
    background: #e6f5ee !important;
    border-left: 3px solid #006747;
}
.lb-row-pool:hover {
    background: #d4eddf !important;
}

/* Cut / WD rows */
.lb-row-cut,
.lb-row-wd {
    opacity: 0.55;
}
.lb-row-cut td,
.lb-row-wd td {
    color: #9ca3af;
}

.leaderboard-table td {
    padding: 8px 12px;
    vertical-align: middle;
}

.lb-pos {
    width: 50px;
    font-weight: 700;
    color: #4a6741;
    text-align: center;
}

.lb-name {
    font-weight: 600;
    color: #1a3c34;
}

.lb-score {
    text-align: center;
    font-weight: 700;
    width: 65px;
}

.lb-thru {
    text-align: center;
    width: 55px;
    font-size: 0.82rem;
    color: #6b7280;
}

.lb-today {
    text-align: center;
    width: 55px;
    font-weight: 600;
}

.lb-picked {
    font-size: 0.8rem;
    color: #006747;
    font-weight: 600;
}

.lb-tier {
    text-align: center;
    width: 65px;
    font-weight: 700;
    font-size: 0.82rem;
    color: #006747;
    white-space: nowrap;
}
.lb-odds {
    display: block;
    font-size: 0.68rem;
    font-weight: 400;
    color: #9ca3af;
}

.lb-under { color: #b91c1c; }
.lb-over  { color: #4a6741; }
.lb-even  { color: #6b7280; }

/* --- Leaderboard responsive --- */
@media (max-width: 600px) {
    .leaderboard-table { font-size: 0.78rem; table-layout: fixed; width: 100%; }
    .leaderboard-table thead th { padding: 8px 4px; font-size: 0.7rem; }
    .leaderboard-table td { padding: 5px 4px; }
    .lb-pos { width: 28px; }
    .lb-name { width: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .lb-score { width: 36px; }
    .lb-thru { width: 32px; }
    .lb-today { display: none; }
    .leaderboard-table thead th.lb-today { display: none; }
    .lb-tier { width: 36px; font-size: 0.7rem; }
    .lb-odds { font-size: 0.58rem; }
    .lb-picked { font-size: 0.65rem; width: 70px; white-space: normal; word-break: break-word; line-height: 1.3; }
    .leaderboard-table-wrap { max-height: 500px; }
}

/* --- Cut bubble stat highlight --- */
.stat-cut-line .stat-value {
    color: #b91c1c;
    font-size: 1.6rem;
}
.stat-bubble .stat-detail {
    font-size: 0.78rem;
    line-height: 1.4;
}

/* ================================================
   CHART TOGGLE BUTTONS
   ================================================ */
.chart-toggle {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.toggle-btn {
    padding: 6px 16px;
    border: 2px solid #006747;
    border-radius: 20px;
    background: #fff;
    color: #006747;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.toggle-btn:hover {
    background: #e6f5ee;
}

.toggle-btn.toggle-active {
    background: #006747;
    color: #fff;
}
