/* AutoGlass Pro — Login v2 (split layout) */
:root {
    --login-navy: #0c2d5e;
    --login-navy-dark: #071e42;
    --login-blue: #1a4a8a;
    --login-text: #1e293b;
    --login-muted: #64748b;
    --login-border: #e2e8f0;
    --login-bg: #f1f5f9;
    --login-white: #ffffff;
    --login-radius: 12px;
}

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

html:has(body.login-v2) {
    height: auto;
    overflow: auto;
}

body.login-v2 {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--login-text);
    background: var(--login-bg);
    min-height: 100vh;
    height: auto;
    overflow: auto;
}

.login-split {
    display: flex;
    min-height: 100vh;
}

/* ── Left panel ── */
.login-left {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
    background: var(--login-bg);
}

.login-left-inner {
    width: 100%;
    max-width: 440px;
}

.login-header {
    text-align: center;
    margin-bottom: 1.75rem;
}

.login-logo {
    max-width: 280px;
    width: 100%;
    height: auto;
    margin-bottom: 1.5rem;
}

.login-header h1 {
    font-size: 1.625rem;
    font-weight: 700;
    color: var(--login-navy);
    margin-bottom: 0.5rem;
}

.login-desc {
    font-size: 0.875rem;
    color: var(--login-muted);
    line-height: 1.5;
    max-width: 360px;
    margin: 0 auto;
}

/* ── Card ── */
.login-card {
    background: var(--login-white);
    border: 1px solid var(--login-border);
    border-radius: var(--login-radius);
    padding: 1.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.login-alert {
    padding: 0.625rem 0.875rem;
    border-radius: 8px;
    font-size: 0.8125rem;
    margin-bottom: 1rem;
}

.login-alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.login-alert-warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

.field-group {
    margin-bottom: 1.25rem;
}

.field-group label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--login-muted);
    margin-bottom: 0.5rem;
}

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.label-row label {
    margin-bottom: 0;
}

.forgot-link {
    font-size: 0.75rem;
    color: var(--login-blue);
    text-decoration: none;
}

.forgot-link:hover {
    text-decoration: underline;
}

.input-icon-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 0.875rem;
    width: 18px;
    height: 18px;
    color: var(--login-muted);
    pointer-events: none;
}

.input-icon-wrap input {
    width: 100%;
    padding: 0.75rem 2.75rem 0.75rem 2.75rem;
    border: 1px solid var(--login-border);
    border-radius: 8px;
    font-size: 0.9375rem;
    color: var(--login-text);
    background: var(--login-white);
    transition: border-color 0.15s, box-shadow 0.15s;
}

.input-icon-wrap input:focus {
    outline: none;
    border-color: var(--login-blue);
    box-shadow: 0 0 0 3px rgba(26, 74, 138, 0.12);
}

.input-icon-wrap input::placeholder {
    color: #94a3b8;
}

.toggle-password {
    position: absolute;
    right: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    color: var(--login-muted);
    display: flex;
    align-items: center;
}

.toggle-password:hover {
    color: var(--login-text);
}

.toggle-password svg {
    width: 18px;
    height: 18px;
}

.remember-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--login-muted);
    margin-bottom: 1.25rem;
    cursor: pointer;
}

.remember-row input {
    width: 16px;
    height: 16px;
    accent-color: var(--login-navy);
}

.btn-login {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.25rem;
    background: var(--login-navy);
    color: var(--login-white);
    border: none;
    border-radius: 8px;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s;
}

.btn-login:hover {
    background: var(--login-navy-dark);
}

.btn-login svg {
    width: 18px;
    height: 18px;
}

/* ── Support ── */
.login-support {
    margin-top: 1.75rem;
}

.support-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.support-divider::before,
.support-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--login-border);
}

.support-divider span {
    font-size: 0.6875rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--login-muted);
}

.support-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
}

.support-links a {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    color: var(--login-muted);
    text-decoration: none;
}

.support-links a:hover {
    color: var(--login-navy);
}

.support-links svg {
    width: 16px;
    height: 16px;
}

.login-copyright {
    text-align: center;
    font-size: 0.6875rem;
    color: #94a3b8;
    margin-top: 1.5rem;
    line-height: 1.4;
}

/* ── Right panel ── */
.login-right {
    width: 42%;
    min-width: 320px;
    background:
        linear-gradient(160deg, rgba(7, 30, 66, 0.92) 0%, rgba(12, 45, 94, 0.88) 50%, rgba(26, 74, 138, 0.85) 100%),
        url('../img/login-workshop.jpg') center / cover no-repeat;
    display: flex;
    align-items: flex-end;
    padding: 3rem;
    border-radius: 0;
}

.login-right-content {
    color: var(--login-white);
    max-width: 400px;
}

.login-right-content h2 {
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.login-right-content p {
    font-size: 0.9375rem;
    line-height: 1.6;
    opacity: 0.9;
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .login-split {
        flex-direction: column;
    }

    .login-right {
        width: 100%;
        min-width: unset;
        min-height: 220px;
        padding: 2rem;
        border-radius: 0;
    }

    .login-right-content h2 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .login-left {
        padding: 1.5rem 1rem;
    }

    .login-card {
        padding: 1.25rem;
    }

    .support-links {
        gap: 1rem;
        flex-wrap: wrap;
    }
}
