* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f7fa;
}

.login-wrapper {
    min-height: 100vh;
    display: flex;
    background: #ffffff;
    overflow: hidden;
}

.login-left,
.login-right {
    min-height: 100vh;
}

.login-left {
    width: 40%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 2rem;
    background: #ffffff;
    position: relative;
    z-index: 2;
}

.login-right {
    width: 60%;
    position: relative;
    z-index: 1;
    background: url("../images/image-login.webp") center center / cover no-repeat;
}

/* Blanco opaco junto al formulario → transparente hacia la derecha (no se nota la unión). */
.login-right::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
        to right,
        #ffffff 0%,
        rgba(255, 255, 255, 0.97) 6%,
        rgba(255, 255, 255, 0.88) 14%,
        rgba(255, 255, 255, 0.7) 24%,
        rgba(255, 255, 255, 0.45) 36%,
        rgba(255, 255, 255, 0.22) 48%,
        rgba(255, 255, 255, 0.08) 58%,
        rgba(255, 255, 255, 0) 70%
    );
}

.login-brand {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 2rem;
}

.login-card {
    width: 100%;
    max-width: 540px;
    padding: 3.25rem 2.85rem;
    border-radius: 10px;
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.1);
    background: #ffffff;
}

.login-title {
    text-align: center;
    font-size: 1.75rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 2rem;
}

.form-label {
    font-size: 0.95rem;
    color: #374151;
    font-weight: 500;
}

.form-control {
    border-radius: 4px;
    border-color: #d1d5db;
    padding: 0.7rem 0.85rem;
}

.form-control:focus {
    border-color: #1e3a8a;
    box-shadow: 0 0 0 0.2rem rgba(30, 58, 138, 0.15);
}

.btn-primary {
    background-color: #1e3a8a;
    border-color: #1e3a8a;
    padding: 0.75rem 1rem;
    font-weight: 600;
    border-radius: 4px;
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: #1e40af;
    border-color: #1e40af;
}

.btn-primary:disabled {
    background-color: #64748b;
    border-color: #64748b;
}

.login-footer {
    margin-top: 2rem;
    margin-bottom: 0;
    text-align: center;
    font-size: 0.8rem;
    color: #2563eb;
}

.login-footer a {
    color: #2563eb;
    text-decoration: none;
}

.brand-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.dot {
    border-radius: 50%;
    display: inline-block;
}

.dot-blue {
    width: 14px;
    height: 14px;
    background: #3b82f6;
}

.dot-red {
    width: 18px;
    height: 18px;
    background: #dc2626;
}

.dot-navy {
    width: 24px;
    height: 24px;
    background: #1e3a8a;
}

.login-brand h2 {
    color: #1d4ed8;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.login-brand p {
    color: #b45309;
    font-size: 1rem;
    margin: 0;
}

@media (max-width: 991.98px) {
    .login-wrapper {
        flex-direction: column;
    }
    .login-left,
    .login-right {
        width: 100%;
        min-height: auto;
    }
    .login-left {
        background: #ffffff;
        padding: 2rem 1.25rem 1.5rem;
    }
    .login-card {
        max-width: 520px;
        padding: 2.5rem 1.75rem;
    }
    .login-right {
        min-height: 280px;
        background: url("../images/image-login.webp") center center / cover no-repeat;
        -webkit-mask-image: none;
        mask-image: none;
    }
    .login-right::before {
        background: linear-gradient(
            to bottom,
            #ffffff 0%,
            rgba(255, 255, 255, 0.85) 18%,
            rgba(255, 255, 255, 0.35) 40%,
            rgba(255, 255, 255, 0) 65%
        );
    }
    .login-brand h2 {
        font-size: 1.8rem;
    }
}

.login-link {
    font-size: 0.9rem;
    color: #2563eb;
    text-decoration: none;
}

.login-link:hover {
    text-decoration: underline;
}

.login-security-note {
    margin-top: 0.75rem;
    font-size: 0.75rem;
    color: #94a3b8;
    text-align: center;
    line-height: 1.35;
}

.politica-content {
    max-height: 50vh;
    overflow: auto;
    padding: 0.75rem 1rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8fafc;
    font-size: 0.92rem;
}

.politica-content h4 {
    font-size: 1rem;
    margin-top: 0.85rem;
    color: #0f172a;
}

.font-monospace {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}