/* ─── Variables ──────────────────────────────────────────────────────────── */
:root {
    --bg: #0e0f1a;
    --bg-panel: #12131f;
    --border: rgba(255,255,255,.08);
    --text: #f0f0f8;
    --muted: rgba(255,255,255,.4);
    --purple: #7c3aed;
    --purple-bright: #8b5cf6;
    --purple-glow: rgba(124,58,237,.35);
}

/* ─── Base ───────────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    height: 100%;
    background: var(--bg);
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text);
}

/* ─── Layout ─────────────────────────────────────────────────────────────── */
.login-wrapper {
    display: grid;
    grid-template-columns: 420px 1fr;
    min-height: 100vh;
}

/* ─── Left panel ─────────────────────────────────────────────────────────── */
.left-panel {
    background: var(--bg-panel);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    padding: 40px 48px;
    position: relative;
    overflow: hidden;
}

.left-panel::before {
    content: '';
    position: absolute;
    bottom: -120px;
    left: -80px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(124,58,237,.18) 0%, transparent 70%);
    pointer-events: none;
}

/* ─── Brand ──────────────────────────────────────────────────────────────── */
.login-logo-img {
    height: 44px;
    width: auto;
    display: block;
    object-fit: contain;
    /* logo is white — works on dark left panel */
    filter: brightness(0) invert(1);
}

/* Watermark logo on right panel */
.wm-logo-img {
    width: 120px;
    height: auto;
    display: block;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 52px;
}

.brand-icon { width: 38px; height: 38px; }

.brand-text { display: flex; flex-direction: column; }

.brand-name {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #fff;
}

.brand-tagline {
    font-size: 9px;
    color: var(--muted);
    letter-spacing: .5px;
}

/* ─── Login heading ──────────────────────────────────────────────────────── */
.login-heading { margin-bottom: 28px; }

.login-title {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px;
    line-height: 1.2;
}

.login-subtitle {
    font-size: 13px;
    color: var(--muted);
    margin: 0;
}

/* ─── Form fields ────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 14px; }

.input-field {
    width: 100%;
    background: #fff;
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 8px;
    padding: 14px 16px;
    font-size: 14px;
    color: #1a1a2e;
    outline: none;
    transition: border-color .2s, box-shadow .2s;
}

.input-field::placeholder { color: #999; }

.input-field:focus {
    border-color: var(--purple-bright);
    box-shadow: 0 0 0 3px rgba(139,92,246,.2);
}

.input-field.is-invalid {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239,68,68,.15);
}

.input-wrapper { position: relative; }

.input-wrapper .input-field { padding-right: 44px; }

.toggle-pwd {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #aaa;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
    padding: 0;
    transition: color .2s;
}

.toggle-pwd:hover { color: #555; }

.field-error {
    font-size: 11px;
    color: #f87171;
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* ─── Remember + links ───────────────────────────────────────────────────── */
.remember-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.remember-row input[type=checkbox] {
    width: 16px;
    height: 16px;
    accent-color: var(--purple-bright);
    cursor: pointer;
}

.remember-row label {
    font-size: 13px;
    color: var(--text);
    cursor: pointer;
}

.small-link {
    display: block;
    font-size: 12px;
    color: var(--muted);
    text-decoration: none;
    margin-bottom: 6px;
    transition: color .2s;
}

.small-link:hover { color: var(--purple-bright); }

/* ─── Captcha ────────────────────────────────────────────────────────────── */
.captcha-wrap {
    margin: 20px 0 16px;
    display: flex;
    justify-content: flex-start;
}

/* ─── Buttons ────────────────────────────────────────────────────────────── */
.btn-signin {
    width: 100%;
    padding: 14px;
    background: var(--purple);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s, box-shadow .2s, transform .1s;
    letter-spacing: .3px;
}

.btn-signin:hover {
    background: var(--purple-bright);
    box-shadow: 0 4px 20px var(--purple-glow);
}

.btn-signin:active { transform: scale(.98); }

/* ─── Divider ────────────────────────────────────────────────────────────── */
.divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 18px 0;
}

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

.divider span {
    font-size: 11px;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    white-space: nowrap;
}

/* ─── Google button ──────────────────────────────────────────────────────── */
.btn-google {
    width: 100%;
    padding: 13px 16px;
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: background .2s, border-color .2s, transform .1s;
    text-decoration: none;
}

.btn-google:hover {
    background: rgba(255,255,255,.1);
    border-color: rgba(255,255,255,.22);
    color: #fff;
}

.btn-google:active { transform: scale(.98); }

.btn-google:disabled {
    opacity: .4;
    cursor: not-allowed;
}

.google-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* ─── Alerts ─────────────────────────────────────────────────────────────── */
.error-alert {
    background: rgba(239,68,68,.1);
    border: 1px solid rgba(239,68,68,.25);
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 13px;
    color: #fca5a5;
    margin-bottom: 16px;
}

.success-alert {
    background: rgba(34,197,94,.1);
    border: 1px solid rgba(34,197,94,.25);
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 13px;
    color: #86efac;
    margin-bottom: 16px;
}

/* ─── Right panel ────────────────────────────────────────────────────────── */
.right-panel {
    background: var(--bg);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Glow orbs */
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    pointer-events: none;
}

.orb-purple {
    width: 500px; height: 500px;
    background: radial-gradient(circle, rgba(124,58,237,.35), transparent 70%);
    bottom: -100px; right: 80px;
}

.orb-blue {
    width: 350px; height: 350px;
    background: radial-gradient(circle, rgba(59,130,246,.2), transparent 70%);
    top: 60px; right: 200px;
}

.orb-pink {
    width: 280px; height: 280px;
    background: radial-gradient(circle, rgba(236,72,153,.15), transparent 70%);
    top: 40%; left: 5%;
}

/* ─── Promo content ──────────────────────────────────────────────────────── */
.promo-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 540px;
    padding: 0 32px;
}

.promo-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(124,58,237,.18);
    border: 1px solid rgba(124,58,237,.35);
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 11px;
    font-weight: 600;
    color: var(--purple-bright);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 24px;
}

.promo-headline {
    font-size: 52px;
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -1px;
    margin-bottom: 16px;
}

.promo-headline .line1 { color: #fff; }

.promo-headline .line2 {
    background: linear-gradient(90deg, #a855f7, #ec4899, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.promo-headline .line3 {
    background: linear-gradient(90deg, #38bdf8, #818cf8);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.promo-sub {
    font-size: 14px;
    color: var(--muted);
    line-height: 1.6;
    margin-bottom: 28px;
}

/* ─── Stats row ──────────────────────────────────────────────────────────── */
.stats-row {
    display: flex;
    gap: 28px;
    justify-content: center;
    margin-bottom: 28px;
}

.stat-item { text-align: center; }

.stat-num {
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
}

.stat-lbl {
    font-size: 11px;
    color: var(--muted);
    margin-top: 3px;
}

.stat-divider {
    width: 1px;
    background: var(--border);
}

/* ─── Promo card ─────────────────────────────────────────────────────────── */
/* ─── Feature list (replaces single promo card) ──────────────────────────── */
.promo-features {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.promo-feature-item {
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 12px;
    padding: 13px 16px;
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: background .2s, border-color .2s;
}

.promo-feature-item:hover {
    background: rgba(255,255,255,.09);
    border-color: rgba(255,255,255,.15);
}

.promo-feature-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--purple), var(--purple-bright));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    color: #fff;
    flex-shrink: 0;
}

.promo-feature-title {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
}

.promo-feature-desc {
    font-size: 11.5px;
    color: var(--muted);
    margin-top: 2px;
    line-height: 1.4;
}

/* ─── Watermark ──────────────────────────────────────────────────────────── */
.wm-logo {
    position: absolute;
    top: 28px;
    right: 32px;
    opacity: .25;
    z-index: 3;
}

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .login-wrapper {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }
    .left-panel {
        padding: 32px 28px;
        border-right: none;
        border-bottom: 1px solid var(--border);
    }
    .right-panel {
        min-height: 300px;
        padding: 40px 20px;
    }
    .promo-headline { font-size: 36px; }
}

@media (max-width: 480px) {
    .left-panel { padding: 28px 20px; }
}
