:root {
    --merco-red: #CE311E;
    --merco-deep: #A01421;
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Montserrat', sans-serif;
    background: #fff;
    overflow: hidden;
}

.login-wrapper {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    height: 100vh;
    width: 100vw;
}

/* Lado Visual - Izquierda */
.visual-pane {
    background: linear-gradient(135deg, var(--merco-deep) 0%, var(--merco-red) 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 10% 12%;
    position: relative;
    overflow: hidden;
    color: #fff;
}

.visual-background-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-10deg);
    width: 150%;
    height: auto;
    opacity: 0.08;
    pointer-events: none;
    z-index: 0;
}

.visual-logo {
    font-size: 1.2rem;
    font-weight: 800;
    letter-spacing: 0.2em;
    margin-bottom: 6rem;
    opacity: 0.9;
    z-index: 1;
}

.visual-content {
    z-index: 1;
}

.visual-content h1 {
    font-size: 4.5rem;
    font-weight: 300;
    line-height: 1;
    margin: 0;
    letter-spacing: -0.04em;
}

.visual-content h1 strong {
    display: block;
    font-weight: 800;
}

.visual-content p {
    font-size: 1.25rem;
    margin-top: 2rem;
    opacity: 0.7;
    max-width: 400px;
    line-height: 1.6;
}

/* Lado Formulario - Derecha */
.form-pane {
    position: relative;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem;
}

.form-container {
    width: 100%;
    max-width: 400px;
    animation: fadeInRight 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}

.form-header {
    margin-bottom: 4rem;
}

.form-header h2 {
    font-size: 2rem;
    font-weight: 700;
    color: #1E293B;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.02em;
}

.form-header p {
    color: #64748B;
    margin: 0;
}

.input-group {
    margin-bottom: 2.5rem;
    position: relative;
}

.input-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #94A3B8;
    margin-bottom: 0.75rem;
    transition: color 0.3s ease;
}

.input-group input {
    width: 100%;
    border: none;
    border-bottom: 2px solid #E2E8F0;
    padding: 0.75rem 0;
    font-size: 1.1rem;
    font-family: inherit;
    color: #1E293B;
    outline: none;
    transition: all 0.3s ease;
    background: transparent;
}

.input-group input:focus {
    border-bottom-color: var(--merco-red);
}

.input-group input:focus + label {
    color: var(--merco-red);
}

.error-summary {
    background: #FEF2F2;
    border-left: 4px solid #EF4444;
    padding: 1rem;
    margin-bottom: 2rem;
    list-style: none;
    color: #B91C1C;
    font-size: 0.9rem;
}

.error-summary ul { margin: 0; padding: 0; list-style: none; }

.btn-login {
    background: #1E293B;
    color: #fff;
    width: 100%;
    padding: 1.25rem;
    border: none;
    font-size: 1rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.btn-login:hover {
    background: var(--merco-red);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(206, 49, 30, 0.2);
}

.footer-links {
    margin-top: 4rem;
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #94A3B8;
}

@media (max-width: 1024px) {
    .login-wrapper {
        grid-template-columns: 1fr;
    }
    .visual-pane {
        display: none;
    }
}

/* Recuperación de contraseña */
.form-header .form-intro {
    line-height: 1.6;
}

.success-summary {
    background: #F0FDF4;
    border-left: 4px solid #22C55E;
    padding: 1rem;
    margin-bottom: 2rem;
    color: #166534;
    font-size: 0.9rem;
    line-height: 1.6;
}

.field-error {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.8rem;
    color: #B91C1C;
}

.footer-links a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--merco-red);
}
