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

body {
    font-family: 'Inter', Arial, sans-serif;
    min-height: 100vh;
    background: color-mix(in srgb, var(--gv-primary, #2563EB) 5%, #f4f6f9);
    color: #111827;
}

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
}

.login-container {
    width: 100%;
    max-width: 980px;
    min-height: 600px;

    display: grid;
    grid-template-columns: 42% 58%;

    /* A whisper of brand tint rather than stark white, so the form panel
       still feels part of the same page as the gradient brand panel next
       to it -- far too subtle to affect input/label contrast. */
    background: linear-gradient(180deg, color-mix(in srgb, var(--gp-primary, #2563EB) 3%, white) 0%, #ffffff 200px);
    border-radius: 24px;
    overflow: hidden;

    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
}

/* ---------- LEFT BRAND PANEL ---------- */

.login-brand-panel {
    position: relative;
    padding: 48px 42px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: #fff;

    /* The official Deep Navy -> Electric Blue -> Premium Violet identity,
       not a one-off two-stop navy variant. */
    background:
        radial-gradient(circle at top right, color-mix(in srgb, var(--gp-accent, #7C3AED) 25%, transparent), transparent 45%),
        var(--gv-gradient-brand, linear-gradient(150deg, #0B1220, #2563EB, #7C3AED));
}

.login-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    font-size: 16px;
}

.login-logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    background: linear-gradient(135deg, var(--gp-primary, #2563EB), var(--gp-accent, #7C3AED));
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 18px;
    flex-shrink: 0;
}

.login-logo-img {
    width: 40px;
    height: 40px;
    border-radius: 11px;
    /* contain, not cover -- a logo must never be cropped. */
    object-fit: contain;
}

.login-brand-copy h2 {
    font-size: 26px;
    font-weight: 800;
    margin: 30px 0 14px;
    line-height: 1.3;
}

.login-brand-copy p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    line-height: 1.7;
}

.login-benefits {
    margin-top: 28px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.login-benefit {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.85);
}

.login-benefit i {
    /* A light tint, not the full-saturation accent -- these icons sit
       directly on the multi-hue brand gradient, where a violet-on-violet
       stretch of it would read as low-contrast. */
    color: #E9D5FF;
    font-size: 16px;
}

.login-brand-footer {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
}

/* ---------- RIGHT FORM PANEL ---------- */

.login-form-panel {
    padding: 56px 56px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-header h1 {
    font-size: 26px;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.3px;
}

.login-header p {
    margin-top: 8px;
    color: #6b7280;
    font-size: 14px;
}

.login-error {
    margin-top: 20px;
    background: #fff1f2;
    color: #b42318;
    border: 1px solid #fecdd3;
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 14px;
}

.login-success {
    margin-top: 20px;
    background: color-mix(in srgb, var(--gv-success, #16A34A) 10%, white);
    color: color-mix(in srgb, var(--gv-success, #16A34A) 75%, black);
    border: 1px solid color-mix(in srgb, var(--gv-success, #16A34A) 35%, white);
    padding: 12px 14px;
    border-radius: 10px;
    font-size: 14px;
}

.login-form {
    margin-top: 26px;
}

.login-field { margin-bottom: 18px; }

.login-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 700;
    color: #1f2937;
}

.login-input-wrapper { position: relative; }

.login-field input {
    width: 100%;
    height: 50px;
    padding: 0 15px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #ffffff;
    color: #111827;
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.login-field input:focus {
    border-color: var(--gp-primary, #2563EB);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--gp-primary, #2563EB) 15%, transparent);
}

.login-password-toggle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
}

.login-submit {
    width: 100%;
    height: 52px;
    margin-top: 6px;
    border: none;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--gv-navy, #0B1220), var(--gp-primary, #2563EB) 55%, var(--gp-accent, #7C3AED));
    color: white;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.login-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 25px color-mix(in srgb, var(--gp-primary, #2563EB) 35%, transparent);
}

.login-google-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 50px;
    border: 1px solid #dce2ea;
    border-radius: 10px;
    background: #fff;
    color: #172033;
    font-size: 14.5px;
    font-weight: 650;
    text-decoration: none;
    cursor: pointer;
    transition: background-color 0.15s ease, box-shadow 0.15s ease;
}
.login-google-btn:hover { background: #f8f9fb; color: #172033; }
.login-google-btn:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--gp-primary, #2563EB) 25%, transparent);
}
.login-google-btn.is-loading { opacity: 0.65; pointer-events: none; }
.login-google-btn.is-loading span::after { content: '…'; }

.login-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: #9aa4b2;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
}
.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e4e8f0;
}

.login-register-link {
    text-align: center;
    margin-top: 24px;
    font-size: 13px;
    color: #6b7280;
}

.login-register-link a {
    color: var(--gp-primary, #2563EB);
    font-weight: 700;
    text-decoration: none;
}

@media (max-width: 800px) {
    .login-container {
        grid-template-columns: 1fr;
    }
    .login-brand-panel { display: none; }
    .login-form-panel { padding: 40px 28px; }
}
