/* =============================================================
   Pronósticos Copa Mundial 2026 — Estilos frontend
   Intencionalmente minimalista para facilitar la personalización.
   ============================================================= */

/* --- Formularios de autenticación --- */
.wc2026-auth-wrap { max-width: 480px; margin: 0 auto; }

.wc2026-tabs { display: flex; gap: 4px; margin-bottom: 16px; flex-wrap: wrap; }
.wc2026-tab-btn {
    padding: 8px 16px; border: 1px solid #ccc; background: #f5f5f5;
    cursor: pointer; border-radius: 4px; font-size: 14px;
}
.wc2026-tab-btn.active { background: #0073aa; color: #fff; border-color: #0073aa; }

.wc2026-tab-content { display: none; }
.wc2026-tab-content.active { display: block; }
.wc2026-tab-content label { display: block; margin-bottom: 10px; font-weight: 600; }
.wc2026-tab-content input[type="text"],
.wc2026-tab-content input[type="email"],
.wc2026-tab-content input[type="password"] {
    display: block; width: 100%; margin-top: 4px; padding: 8px;
    border: 1px solid #ccc; border-radius: 4px; box-sizing: border-box; font-weight: 400;
}

.wc2026-btn {
    margin-top: 12px; padding: 10px 24px; background: #0073aa;
    color: #fff; border: none; border-radius: 4px; cursor: pointer; font-size: 15px;
}
.wc2026-btn:hover { background: #005d8f; }

.wc2026-msg { margin-bottom: 10px; padding: 8px 12px; border-radius: 4px; display: none; }
.wc2026-msg.wc2026-success { display: block; background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.wc2026-msg.wc2026-error   { display: block; background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }

/* --- Contenedor del juego --- */
.wc2026-game-wrap { max-width: 820px; margin: 0 auto; }
.wc2026-header { margin-bottom: 12px; font-size: 15px; }

.wc2026-tz-note {
    background: #fff8e1; border-left: 4px solid #ffc107;
    padding: 8px 14px; margin-bottom: 16px; font-size: 14px;
    border-radius: 0 4px 4px 0;
}

/* --- Barra de ordenación principal --- */
.wc2026-sort-bar { margin-bottom: 16px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.wc2026-sort-btn {
    padding: 6px 16px; border: 1px solid #ccc; background: #f5f5f5;
    border-radius: 4px; cursor: pointer; font-size: 13px;
}
.wc2026-sort-btn.active { background: #0073aa; color: #fff; border-color: #0073aa; }

/* --- Subtabs de grupo --- */
.wc2026-subtabs {
    display: flex; flex-wrap: wrap; gap: 4px;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #e0e0e0;
}
.wc2026-subtab-btn {
    padding: 5px 13px;
    border: 1px solid #ccc;
    background: #f5f5f5;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    min-width: 36px;
    text-align: center;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.wc2026-subtab-btn:hover { background: #e8e8e8; }
.wc2026-subtab-btn.active { background: #005d8f; color: #fff; border-color: #005d8f; }
.wc2026-subtabs-divider {
    display: flex; align-items: center;
    color: #ccc; font-size: 16px; padding: 0 4px; user-select: none;
}
.wc2026-subtab-ko {
    background: #f0f4ff; border-color: #b0bfdf;
}
.wc2026-subtab-ko.active {
    background: #3a5a9b; border-color: #3a5a9b; color: #fff;
}

/* --- Bloque de grupo --- */
.wc2026-group-block { margin-bottom: 32px; }
.wc2026-group-title { font-size: 18px; margin-bottom: 12px; padding-bottom: 6px; border-bottom: 2px solid #e0e0e0; }

/* --- Tarjeta de partido --- */
.wc2026-match-card {
    border: 1px solid #e0e0e0; border-radius: 6px;
    padding: 14px 16px; margin-bottom: 10px; background: #fff;
}
.wc2026-match-card.wc2026-exact   { border-left: 4px solid #28a745; background: #f0fff4; }
.wc2026-match-card.wc2026-correct { border-left: 4px solid #17a2b8; background: #f0faff; }
.wc2026-match-card.wc2026-wrong   { border-left: 4px solid #dc3545; background: #fff5f5; }

/* --- Meta del partido --- */
.wc2026-match-meta {
    font-size: 12px; color: #666; margin-bottom: 10px;
    display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
}
.wc2026-stage-badge {
    background: #6c757d; color: #fff; padding: 2px 8px;
    border-radius: 10px; font-size: 11px;
}

/* --- Fila principal: equipo / inputs o resultado / equipo --- */
.wc2026-match-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    flex-wrap: nowrap;
}
.wc2026-team {
    font-size: 15px; font-weight: 600;
    display: flex; align-items: center; gap: 6px;
    flex: 1; min-width: 0;
}
.wc2026-team-home { justify-content: flex-start; }
.wc2026-team-away { justify-content: flex-end; text-align: right; }
.wc2026-flag { font-size: 22px; line-height: 1; flex-shrink: 0; }

/* Centre: inputs or score */
.wc2026-centre {
    display: flex; align-items: center; gap: 6px;
    flex-shrink: 0;
}
.wc2026-centre input[type="number"] {
    width: 52px; padding: 6px 4px; text-align: center;
    border: 1px solid #ccc; border-radius: 4px; font-size: 16px; font-weight: 700;
    -moz-appearance: textfield;
}
.wc2026-centre input[type="number"]::-webkit-inner-spin-button,
.wc2026-centre input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none; }
.wc2026-sep { font-size: 18px; font-weight: 700; color: #555; }
.wc2026-result { font-size: 22px; font-weight: 700; white-space: nowrap; }
.wc2026-vs { font-size: 15px; color: #999; }

/* --- Save button row --- */
.wc2026-save-row {
    display: flex; align-items: center; gap: 8px;
    margin-top: 6px;
}

/* Save button — default state */
.wc2026-save-btn {
    padding: 6px 14px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: background 0.2s, color 0.2s;
    min-width: 90px;
}
.wc2026-save-btn:hover:not(:disabled) { background: #005d8f; }

/* Save button — saved state (green, disabled) */
.wc2026-save-btn.wc2026-saved,
.wc2026-save-btn.wc2026-saved:disabled {
    background: #28a745;
    color: #fff;
    cursor: default;
    opacity: 1; /* override browser's disabled dimming */
}

/* Generic disabled (saving in progress) */
.wc2026-save-btn:disabled:not(.wc2026-saved) { background: #aaa; cursor: default; }

.wc2026-save-status { font-size: 13px; }
.wc2026-save-status.wc2026-success { color: #28a745; }
.wc2026-save-status.wc2026-error   { color: #dc3545; }

.wc2026-pred-locked { color: #888; font-style: italic; }

/* Badges de puntos */
.wc2026-pts-badge { padding: 2px 8px; border-radius: 10px; font-size: 13px; font-weight: 600; }
.wc2026-pts-3 { background: #d4edda; color: #155724; }
.wc2026-pts-1 { background: #d1ecf1; color: #0c5460; }
.wc2026-pts-0 { background: #f8d7da; color: #721c24; }

/* --- Nota de reglas --- */
.wc2026-rules-note {
    margin-top: 24px; font-size: 13px; color: #555;
    background: #f8f9fa; padding: 12px 16px; border-radius: 4px;
    border: 1px solid #e0e0e0; line-height: 1.8;
}

/* --- Tabla de posiciones --- */
.wc2026-leaderboard-wrap { max-width: 700px; margin: 0 auto; }
.wc2026-leaderboard { width: 100%; border-collapse: collapse; font-size: 14px; }
.wc2026-leaderboard th,
.wc2026-leaderboard td { padding: 10px 12px; border-bottom: 1px solid #e0e0e0; text-align: left; }
.wc2026-leaderboard thead { background: #f5f5f5; font-weight: 700; }
.wc2026-leaderboard tr.wc2026-me { background: #fff8e1; font-weight: 700; }
.wc2026-leaderboard tr:hover { background: #f9f9f9; }

/* --- Responsive --- */
@media (max-width: 480px) {
    .wc2026-match-row { gap: 6px; }
    .wc2026-team { font-size: 13px; }
    .wc2026-flag { font-size: 18px; }
    .wc2026-centre input[type="number"] { width: 42px; font-size: 14px; padding: 5px 2px; }
    .wc2026-result { font-size: 18px; }
    .wc2026-subtab-btn { padding: 5px 10px; font-size: 12px; }
}
