/* ================= PREDICTIONS PAGE ONLY ================= */

.predictions-page .header-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 20px;
}

.predictions-page .prediction-sponsor-strip {
    display: block;
    text-decoration: none;
    margin: 0 0 18px 0;
    border-radius: 12px;
    border: 1px solid #343a40;
    background: linear-gradient(135deg, #1e1e1e, #2a2a2a);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
    transition: all 0.2s ease-in-out;
    overflow: hidden;
}

.predictions-page .prediction-sponsor-strip:hover {
    transform: translateY(-1px);
    border-color: #00d4ff;
    box-shadow: 0 6px 18px rgba(0, 212, 255, 0.18);
    text-decoration: none;
}

.predictions-page .prediction-sponsor-strip.no-link {
    cursor: default;
}

.predictions-page .prediction-sponsor-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 12px 16px;
}

.predictions-page .prediction-sponsor-text-wrap {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.predictions-page .prediction-sponsor-label {
    font-size: 12px;
    color: #b0b7c3;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    margin-bottom: 3px;
}

.predictions-page .prediction-sponsor-name {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.2;
}

.predictions-page .prediction-sponsor-logo {
    width: 52px;
    height: 52px;
    object-fit: contain;
    flex-shrink: 0;
    background: #ffffff;
    border-radius: 10px;
    padding: 4px;
}

@media (max-width: 600px) {
    .predictions-page .prediction-sponsor-content {
        padding: 10px 12px;
        gap: 10px;
    }

    .predictions-page .prediction-sponsor-label {
        font-size: 11px;
    }

    .predictions-page .prediction-sponsor-name {
        font-size: 15px;
    }

    .predictions-page .prediction-sponsor-logo {
        width: 44px;
        height: 44px;
    }
}

.predictions-page .back-btn {
    display: inline-block;
    padding: 8px 15px;
    background: #444;
    color: white;
    text-decoration: none;
    border-radius: 5px;
}

.predictions-page .reset-btn {
    padding: 8px 15px;
    background: #d32f2f;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

/* ================= TABS ================= */

.predictions-page .tabs {
    display: flex;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    border-bottom: 2px solid #ddd;
    margin-bottom: 20px;
    gap: 0;
}

.predictions-page .tabs::-webkit-scrollbar {
    display: none;
}

.predictions-page .tabs {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.predictions-page .tab-btn {
    padding: 12px 20px;
    cursor: pointer;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    flex-shrink: 0;
    font-size: 15px;
    color: #555;
    transition: all 0.2s ease;
}

.predictions-page .tab-btn:hover {
    color: #1e88e5;
    background: #f9f9f9;
}

.predictions-page .tab-btn.active {
    color: #1e88e5;
    font-weight: bold;
    border-bottom: 3px solid #1e88e5;
}

/* ================= CARDS & MATCH HEADER ================= */

.predictions-page .prediction-card {
    border: 1px solid #ddd;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 6px;
    background: #fff;
}

.predictions-page .match-header {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 10px;
    margin-bottom: 10px;
    width: 100%;
}

.predictions-page .team {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
    white-space: nowrap;
    min-width: 0;
}

.predictions-page .team-name {
    font-size: clamp(10px, 3.5vw, 18px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.predictions-page .pred-team-logo {
    width: clamp(20px, 6vw, 40px);
    height: clamp(20px, 6vw, 40px);
    object-fit: contain;
    flex-shrink: 0;
}

.predictions-page .vs {
    font-weight: bold;
    color: #666;
    font-size: clamp(12px, 3vw, 16px);
}

.predictions-page .kickoff-countdown {
    text-align: center;
    font-weight: bold;
    margin-bottom: 10px;
    color: #1e88e5;
}

/* ================= FORMS ================= */

.predictions-page .prediction-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-top: 15px;
}

.predictions-page .radio-group {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.predictions-page .goals-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.predictions-page .goals-group input {
    width: 60px;
    padding: 8px;
    text-align: center;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.predictions-page .submit-btn {
    padding: 10px 20px;
    background: #1e88e5;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

.predictions-page .locked-box {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    text-align: center;
}

/* ================= TABLES ================= */

.predictions-page .pred-table-wrap {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.predictions-page .pred-standings-table {
    width: 100%;
    min-width: 0;
    table-layout: fixed;
    border-collapse: collapse;
    margin-top: 15px;
}

.predictions-page .pred-history-table {
    width: 100%;
    min-width: 500px;
    border-collapse: collapse;
    margin-top: 15px;
}

.predictions-page .pred-standings-table th,
.predictions-page .pred-standings-table td,
.predictions-page .pred-history-table th,
.predictions-page .pred-history-table td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
    vertical-align: middle;
}

.predictions-page .pred-standings-table th,
.predictions-page .pred-history-table th {
    background: #1e88e5;
    color: white;
}

.predictions-page .col-rank {
    width: 12%;
    text-align: center;
}

.predictions-page .col-user {
    width: 38%;
    text-align: left;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.predictions-page .col-perfect {
    width: 20%;
    text-align: center;
}

.predictions-page .col-points {
    width: 30%;
    text-align: center;
}

.predictions-page .hist-date {
    width: 25%;
    text-align: center;
}

.predictions-page .hist-match {
    width: 40%;
    text-align: left;
}

.predictions-page .hist-pred {
    width: 20%;
    text-align: center;
}

.predictions-page .hist-points {
    width: 15%;
    text-align: center;
}

/* ================= HIGHLIGHTS & COLORS ================= */

.predictions-page .highlight {
    background: #ffe082 !important;
    font-weight: bold;
    border-left: 5px solid #ff9800;
}

.predictions-page .first-place {
    background: #fff8e1;
    font-weight: bold;
    border-left: 6px solid #FFD700;
}

.predictions-page .second-place {
    background: #f5f5f5;
    font-weight: bold;
    border-left: 6px solid #C0C0C0;
}

.predictions-page .third-place {
    background: #fff3e0;
    font-weight: bold;
    border-left: 6px solid #CD7F32;
}

.predictions-page .perfect {
    background: #e8f5e9;
    border-left: 6px solid #2e7d32;
}

.predictions-page .partial {
    background: #fff8e1;
    border-left: 6px solid #f9a825;
}

.predictions-page .wrong {
    background: #ffebee;
    border-left: 6px solid #c62828;
}

.predictions-page .correct {
    color: #2e7d32;
    font-weight: bold;
}

.predictions-page .incorrect {
    color: #c62828;
}

.predictions-page .correct::after {
    content: " ✔";
    color: #2e7d32;
}

.predictions-page .incorrect::after {
    content: " ✖";
    color: #c62828;
}

.predictions-page .pending {
    color: orange;
}

.predictions-page .actual-score {
    margin-top: 5px;
    font-size: 14px;
    color: #555;
}

.predictions-page .points {
    font-weight: bold;
    margin-top: 5px;
}

.predictions-page .medal {
    font-size: 20px;
}

/* ================= MOBILE ================= */

@media (max-width: 600px) {
    .predictions-page .submit-btn {
        width: 100%;
    }

    .predictions-page .tab-btn {
        padding: 10px 15px;
        font-size: 14px;
    }
}
@media (max-width: 600px) {
    .predictions-page .col-user {
        max-width: 90px;
        font-size: 13px;
    }

    .predictions-page .pred-standings-table th,
    .predictions-page .pred-standings-table td {
        padding: 8px;
        font-size: 13px;
    }
}
@media (max-width: 600px) {
    .predictions-page .pred-standings-table th,
    .predictions-page .pred-standings-table td {
        padding: 8px 6px;
        font-size: 12px;
    }

    .predictions-page .col-user {
        max-width: 100px;
    }
}
/* ===== STANDINGS TABLE VISIBILITY FIX ===== */

/* Default/light mode table text */
.predictions-page .pred-standings-table td {
    color: #111;
    font-weight: 500;
}

/* Table header should always stay readable */
.predictions-page .pred-standings-table th {
    background: #1e88e5;
    color: #ffffff !important;
}

/* Normal standings rows in dark mode */
body.dark-theme .predictions-page .pred-standings-table tbody tr:not(.first-place):not(.second-place):not(.third-place):not(.highlight) {
    background-color: #1e1e1e !important;
}

/* Text for normal rows in dark mode */
body.dark-theme .predictions-page .pred-standings-table tbody tr:not(.first-place):not(.second-place):not(.third-place):not(.highlight) td {
    color: #f1f1f1 !important;
}

/* Keep top 3 rows light, so their text should stay dark */
.predictions-page .first-place td,
.predictions-page .second-place td,
.predictions-page .third-place td,
.predictions-page .highlight td {
    color: #111 !important;
}

/* Keep the special top 3 backgrounds */
.predictions-page .first-place {
    background: #fff8e1 !important;
    font-weight: bold;
    border-left: 6px solid #FFD700;
}

.predictions-page .second-place {
    background: #f5f5f5 !important;
    font-weight: bold;
    border-left: 6px solid #C0C0C0;
}

.predictions-page .third-place {
    background: #fff3e0 !important;
    font-weight: bold;
    border-left: 6px solid #CD7F32;
}

/* Current user row */
.predictions-page .highlight {
    background: #ffe082 !important;
    font-weight: bold;
    border-left: 5px solid #ff9800;
}

/* Make points/perfect numbers sharper */
.predictions-page .col-perfect,
.predictions-page .col-points {
    font-weight: 600;
}

.predictions-page .bulk-submit-btn {
    width: 100%;
    margin-top: 10px;
    margin-bottom: 25px;
    padding: 14px 20px;
    font-size: 16px;
}

.predictions-page .bulk-predictions-form {
    margin: 0;
}
