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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    background: rgba(0, 0, 0, 0.3);
    padding: 20px 0;
    color: white;
    backdrop-filter: blur(10px);
}

.header h1 {
    text-align: center;
    margin-bottom: 15px;
    font-size: 2.5em;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.nav {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
}

.nav a {
    color: white;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 25px;
    background: rgba(255,255,255,0.1);
    transition: all 0.3s;
}

.nav a:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-2px);
}

/* Main */
.main {
    padding: 40px 0;
}

.hero {
    text-align: center;
    color: white;
    padding: 60px 20px;
    background: rgba(255,255,255,0.1);
    border-radius: 20px;
    margin-bottom: 40px;
}

.hero h2 {
    font-size: 3em;
    margin-bottom: 20px;
}

.cta-buttons {
    margin-top: 30px;
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 30px;
    font-size: 1.1em;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.btn-primary {
    background: #ffd700;
    color: #1e3c72;
    font-weight: bold;
}

.btn-primary:hover {
    background: #ffed4e;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
}

.btn-secondary {
    background: white;
    color: #1e3c72;
}

.bandera-icon { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; margin-right: 6px; vertical-align: middle; border: 1px solid #cbd5e1; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }

.reglas {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    min-height: 100vh;
    color: #1e93c9;
}
.reglas-grid {
    background: white;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.regla-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(194, 17, 17, 0.2);
}
/* Partidos */
.partidos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.partido-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.partido-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 0.9em;
    color: #666;
}

.equipos {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin: 20px 0;
}

.equipo {
    text-align: center;
}

.vs {
    font-weight: bold;
    color: #1e3c72;
    font-size: 1.2em;
}

/* Pronósticos */
.pronostico-card {
    background: white;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.pronostico-form {
    margin-top: 20px;
}

.equipos-pronostico {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
}

.equipo-input {
    text-align: center;
}

.equipo-input label {
    display: block;
    margin-bottom: 10px;
    font-weight: bold;
}

.equipo-input input {
    width: 80px;
    padding: 10px;
    font-size: 1.5em;
    text-align: center;
    border: 2px solid #ddd;
    border-radius: 10px;
}

/* Tabla */
.tabla-container {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    overflow-x: auto;
}

.tabla-posiciones {
    width: 100%;
    border-collapse: collapse;
}

.tabla-posiciones th,
.tabla-posiciones td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.tabla-posiciones th {
    background: #1e3c72;
    color: white;
}

.tabla-posiciones tr:hover {
    background: #f5f5f5;
}

.primer-lugar { background: #ffd700 !important; }
.segundo-lugar { background: #c0c0c0 !important; }
.tercer-lugar { background: #cd7f32 !important; }
.usuario-actual { background: #e3f2fd !important; font-weight: bold; }

/* Auth */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-box {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    max-width: 450px;
    width: 100%;
}

.auth-box h1 {
    text-align: center;
    color: #1e3c72;
    margin-bottom: 30px;
}

.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.auth-form input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
}

.auth-link {
    text-align: center;
    margin-top: 20px;
}

.auth-link a {
    color: #1e3c72;
}

.error {
    background: #ffebee;
    color: #c62828;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.mensaje {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* Footer */
.footer {
    background: rgba(0,0,0,0.3);
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}

/* Responsive */
@media (max-width: 768px) {
    .header h1 {
        font-size: 1.8em;
    }
    
    .hero h2 {
        font-size: 2em;
    }
    
    .partidos-grid {
        grid-template-columns: 1fr;
    }
/* --- NUEVO MENU DE NAVEGACION --- */
.navbar {
    background-color: #1e3c72; /* Azul oscuro corporativo */
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0 15px;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 65px;
}

.nav-logo {
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 800;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    letter-spacing: 0.5px;
}

.nav-logo:hover { opacity: 0.9; }

.nav-links {
    display: flex;
    gap: 5px;
    align-items: center;
}

.nav-link {
    color: #cbd5e1;
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.nav-link:hover {
    color: #ffffff;
    background-color: rgba(255,255,255,0.1);
}

/* Clase para la página actual */
.nav-link.active {
    color: #ffffff;
    background-color: #2ecc71; /* Verde para indicar activo */
    font-weight: 700;
}

/* Botones especiales */
.btn-login {
    background-color: #2ecc71;
    color: #1e3c72;
    font-weight: 700;
}
.btn-login:hover { background-color: #27ae60; color: white; }

.btn-logout {
    background-color: #e74c3c;
    color: white;
}
.btn-logout:hover { background-color: #c0392b; }

/* Responsive para móviles */
@media (max-width: 768px) {
    .nav-container { flex-direction: column; height: auto; padding: 10px 0; }
    .nav-links { flex-wrap: wrap; justify-content: center; padding: 10px 0; width: 100%; }
    .nav-link { width: 100%; text-align: center; }
    .nav-logo { margin-bottom: 10px; }
}


}