
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
    --navy: #14243a;
    --navy-light: #203954;
    --accent: #4169e1;
    --text: #172033;
    --muted: #748096;
    --border: #e1e7ef;
    --surface: #ffffff;
    --page-bg: #f2f5fa;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Inter', Arial, sans-serif;
    color: var(--text);
    background: var(--page-bg);
    -webkit-font-smoothing: antialiased;
}

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px;
}

.login-shell {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    max-width: 1120px;
    min-height: 680px;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid #e8edf4;
    border-radius: 24px;
    box-shadow: 0 24px 80px rgba(24, 42, 70, 0.10);
}

.login-brand-panel {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
    padding: 42px;
    color: white;
    background:
        radial-gradient(ellipse at 15% 90%,
            rgba(65, 105, 225, .32), transparent 45%),
        linear-gradient(145deg, #14243a 0%, #1c3552 100%);
}

.login-brand-panel::after {
    content: "";
    position: absolute;
    width: 360px;
    height: 360px;
    right: -180px;
    top: 22%;
    border: 1px solid rgba(255,255,255,.09);
    border-radius: 50%;
    box-shadow:
        0 0 0 42px rgba(255,255,255,.025),
        0 0 0 84px rgba(255,255,255,.02);
    pointer-events: none;
}

.brand-logo,
.mobile-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 17px;
    font-weight: 700;
}

.brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex-shrink: 0;
    color: white;
    font-size: 21px;
    font-weight: 800;
    background: linear-gradient(135deg, #6287ff, #4169e1);
    border-radius: 12px;
    box-shadow: 0 6px 20px rgba(65,105,225,.25);
}

.brand-content {
    position: relative;
    z-index: 1;
    max-width: 430px;
    margin: 65px 0;
}

.eyebrow {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.8px;
}

.brand-content .eyebrow {
    color: #9eb7ff;
}

.brand-content h1 {
    margin: 20px 0;
    font-size: clamp(29px, 3vw, 42px);
    font-weight: 700;
    line-height: 1.22;
    letter-spacing: -1.5px;
}

.brand-content p {
    max-width: 350px;
    color: #bdc9d8;
    font-size: 14px;
    line-height: 1.9;
}

.brand-features {
    display: grid;
    gap: 18px;
    margin-top: 38px;
    color: #e5ebf5;
    font-size: 13px;
}

.feature-check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    margin-right: 10px;
    border: 1px solid rgba(255,255,255,.18);
    border-radius: 50%;
    color: #a9c0ff;
}

.brand-footer {
    color: #9cacc0;
    font-size: 12px;
}

.login-form-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 54px 48px 28px;
    background: #fff;
}

.form-container {
    width: 100%;
    max-width: 380px;
}

.step-indicator {
    display: flex;
    align-items: center;
    margin-bottom: 42px;
}

.step-dot {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: white;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}

.step-dot.active {
    border-color: var(--accent);
    background: var(--accent);
    color: white;
}

.step-dot.complete {
    border-color: #16865d;
    background: #16865d;
    color: white;
}

.step-line {
    width: 45px;
    height: 1px;
    margin: 0 10px;
    background: var(--border);
}

.form-eyebrow {
    color: var(--accent);
}

.form-container h2 {
    margin: 12px 0 10px;
    font-size: 27px;
    font-weight: 700;
    letter-spacing: -0.8px;
}

.form-description {
    margin-bottom: 28px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.8;
}

.form-label {
    margin-bottom: 9px;
    color: #344054;
    font-size: 12px;
    font-weight: 600;
}

.form-control {
    min-height: 49px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-size: 13px;
    box-shadow: none !important;
    transition: border-color .2s, box-shadow .2s;
}

.form-control::placeholder {
    color: #a0a9b8;
}

.form-control:focus {
    border-color: #7693f0;
    box-shadow: 0 0 0 3px rgba(65,105,225,.10) !important;
}

.password-wrapper {
    position: relative;
}

.password-wrapper .form-control {
    padding-right: 65px;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    padding: 4px;
    border: 0;
    background: transparent;
    color: var(--accent);
    font-size: 12px;
    font-weight: 600;
}

.btn-login {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    min-height: 50px;
    margin-top: 26px;
    padding: 12px 16px;
    border: 0;
    border-radius: 10px;
    background: var(--accent);
    color: white;
    font-size: 13px;
    font-weight: 600;
    transition: background .2s, transform .2s;
}

.btn-login:hover {
    background: #3156c6;
    transform: translateY(-1px);
}

.btn-login:disabled {
    cursor: not-allowed;
    opacity: .7;
    transform: none;
}

.button-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: white;
    border-radius: 50%;
    animation: spin .7s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.security-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    color: var(--muted);
    font-size: 11px;
}

.otp-email {
    margin: -12px 0 24px;
    color: var(--accent);
    font-size: 13px;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.otp-input {
    min-height: 60px;
    font-size: 25px;
    font-weight: 700;
    letter-spacing: 12px;
    text-align: center;
}

.resend-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 5px;
    margin-top: 24px;
    color: var(--muted);
    font-size: 11px;
}

.resend-row button,
.back-button {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--accent);
    font-size: 11px;
    font-weight: 600;
}

.resend-row button:disabled {
    color: var(--muted);
    cursor: not-allowed;
}

.back-button {
    display: block;
    margin: 22px auto 0;
}

.login-legal {
    margin-top: 38px;
    color: #9aa4b2;
    font-size: 10px;
    line-height: 1.8;
    text-align: center;
}

.mobile-brand {
    display: none;
}

@media (max-width: 850px) {
    .login-page {
        padding: 18px;
    }

    .login-shell {
        grid-template-columns: 1fr;
        max-width: 520px;
        min-height: auto;
    }

    .login-brand-panel {
        display: none;
    }

    .login-form-panel {
        padding: 28px 28px 20px;
    }

    .mobile-brand {
        display: flex;
        margin-bottom: 36px;
        font-size: 15px;
    }

    .step-indicator {
        margin-bottom: 30px;
    }

    .form-container h2 {
        font-size: 25px;
    }

    .login-legal {
        margin-top: 30px;
    }
}

@media (max-width: 380px) {
    .login-page {
        padding: 8px;
    }

    .login-shell {
        border-radius: 16px;
    }

    .login-form-panel {
        padding: 22px 18px;
    }
}

/* Password recovery link */
.forgot-password-row {
    display: flex;
    justify-content: flex-end;
    margin-top: -8px;
    margin-bottom: 24px;
    font-size: 12px;
    font-weight: 600;
}

.forgot-password-row a,
.reset-back-link {
    color: var(--accent);
    text-decoration: none;
}

.forgot-password-row a:hover,
.reset-back-link:hover {
    color: var(--navy-light);
    text-decoration: underline;
}
