/* ========== RESET Y ESTILOS GLOBALES ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', 'Helvetica', sans-serif;
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: #f5f5f5; /* Color de respaldo */
    position: relative;
}

/* Pseudo-elemento para la imagen de fondo (marca de agua) */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/img/marcaDorada.png');
    background-repeat: no-repeat;
    background-size: 50% auto;        /* Tamaño reducido al 50% */
    background-position: center center;
    background-attachment: fixed;
    filter: grayscale(100%);           /* Escala de grises */
    opacity: 0.15;                     /* Opacidad suave */
    pointer-events: none;              /* No interfiere con clicks */
    z-index: -1;                       /* Detrás de todo el contenido */
}

/* ========== BARRA DECORATIVA ========== */
.page-header {
    margin: 40px 0 20px 0;
    text-align: center;
    position: relative;
    z-index: 1;
}

.header-bar {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.bar {
    height: 10px;
    width: 80px;
    margin: 0 6px;
    border-radius: 20px;
}

.bar-vino { background-color: #601633; }
.bar-dorado { background-color: #a57f2c; }
.bar-beige { background-color: #DDC9A3; }

.page-title {
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 2.5rem;
    color: #601633;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0;
}

.page-subtitle {
    font-size: 1.1rem;
    color: #a57f2c;
    margin-top: 10px;
}

/* ========== CONTENEDOR DEL LOGIN ========== */
.login-container {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    position: relative;
    z-index: 1;
}

.login-card {
    background: white;
    border-radius: 30px;
    padding: 40px;
    width: 100%;
    max-width: 450px;
    box-shadow: 0 15px 35px rgba(96, 22, 51, 0.15);
    border: 2px solid #DDC9A3;
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #601633, #a57f2c, #DDC9A3);
}

.login-icono {
    text-align: center;
    font-size: 4rem;
    color: #601633;
    margin-bottom: 20px;
}

.login-icono i {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.login-card h2 {
    color: #601633;
    margin-bottom: 30px;
    text-align: center;
    font-size: 2rem;
    font-weight: 600;
}

.alerta {
    padding: 15px 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alerta.error {
    background: #fee;
    color: #c00;
    border-left: 4px solid #c00;
}

.alerta.exito {
    background: #e8f5e9;
    color: #2e7d32;
    border-left: 4px solid #2e7d32;
}

.alerta.info {
    background: #e3f2fd;
    color: #0d47a1;
    border-left: 4px solid #0d47a1;
}

.input-group {
    margin-bottom: 25px;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #601633;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.input-group label i {
    color: #a57f2c;
    font-size: 1rem;
}

.input-group input {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid #DDC9A3;
    border-radius: 15px;
    font-size: 1rem;
    transition: all 0.3s;
    background: white;
}

.input-group input:focus {
    outline: none;
    border-color: #a57f2c;
    box-shadow: 0 0 0 4px rgba(165, 127, 44, 0.1);
}

.input-group input::placeholder {
    color: #999;
    font-style: italic;
}

.password-container {
    position: relative;
    display: flex;
    align-items: center;
}

.password-container input {
    padding-right: 50px;
}

.toggle-password {
    position: absolute;
    right: 5px;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    cursor: pointer;
    color: #a57f2c;
    font-size: 1.1rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toggle-password:hover {
    background: #f0f0f0;
    color: #601633;
}

.login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px 0;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
    font-size: 0.9rem;
}

.remember-me input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #601633;
}

.forgot-password {
    color: #a57f2c;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.forgot-password:hover {
    color: #601633;
    text-decoration: underline;
}

.btn-login {
    background: #601633;
    color: white;
    border: none;
    padding: 15px 25px;
    border-radius: 15px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(96, 22, 51, 0.3);
}

.btn-login:hover:not(:disabled) {
    background: #7a1e40;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(96, 22, 51, 0.4);
}

.btn-login:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.login-footer {
    margin-top: 30px;
    text-align: center;
    padding-top: 20px;
    border-top: 2px solid #DDC9A3;
}

.login-footer p {
    color: #666;
    margin: 5px 0;
}

.login-footer a {
    color: #601633;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.login-footer a:hover {
    color: #a57f2c;
    text-decoration: underline;
}

.verification-badge {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 10px 15px;
    border-radius: 8px;
    margin-top: 15px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.verification-badge i {
    color: #856404;
    font-size: 1.2rem;
}

.verification-badge a {
    color: #601633;
    font-weight: 600;
    text-decoration: none;
}

.verification-badge a:hover {
    text-decoration: underline;
}

/* ========== PERSONALIZACIÓN DEL SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #611232;
    border-radius: 10px;
    border: 2px solid #f1f1f1;
}

::-webkit-scrollbar-thumb:hover {
    background: #7a1845;
}

* {
    scrollbar-width: thin;
    scrollbar-color: #611232 #f1f1f1;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 576px) {
    .page-title {
        font-size: 2rem;
    }
    
    .bar {
        width: 50px;
        height: 8px;
    }
    
    .login-card {
        padding: 30px 20px;
    }
    
    .login-icono {
        font-size: 3rem;
    }
    
    .login-options {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

/* Debug info (opcional, solo para desarrollo) */
.debug-info {
    background: #f5f5f5;
    border-radius: 8px;
    padding: 10px;
    margin-top: 20px;
    font-size: 0.8rem;
    color: #666;
    border-left: 3px solid #601633;
}