/* Login, register and password reset pages. Soft UI palette, matches landing.css. */
:root {
    --ink: #2b2f38;
    --ink-2: #67748e;
    --ink-3: #a1a7b4;
    --line: #e9ecef;
    --bg-soft: #f3f6f9;
    --accent: #2a4466;
    --danger: #ea0606;
    --gradient-primary: linear-gradient(310deg, #2a4466 0%, #0073e6 100%);
    --gradient-dark: linear-gradient(310deg, #141727 0%, #3a416f 100%);
}

.auth-body {
    position: relative;
    margin: 0;
    min-height: 100vh;
    background: #f4f5f9;
    color: var(--ink);
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Dark corporate band behind the card */
.auth-band {
    position: absolute; top: 0; left: 0; right: 0; height: 52vh; min-height: 380px;
    background-image: var(--gradient-dark); overflow: hidden;
    border-radius: 0 0 40px 40px;
}
.auth-grid {
    position: absolute; inset: 0;
    background-image: linear-gradient(to right, rgba(255, 255, 255, .05) 1px, transparent 1px), linear-gradient(to bottom, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 48px 48px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 30%, #000 20%, transparent 75%);
    mask-image: radial-gradient(ellipse at 50% 30%, #000 20%, transparent 75%);
}
.auth-glow { position: absolute; width: 520px; height: 520px; border-radius: 50%; filter: blur(120px); pointer-events: none; }
.auth-glow-1 { background: #0073e6; opacity: .28; top: -260px; right: 8%; }
.auth-glow-2 { background: #2a4466; opacity: .4; bottom: -320px; left: 6%; }

/* Top bar */
.auth-top {
    position: relative; z-index: 2; max-width: 1200px; margin: 0 auto; padding: 28px 32px;
    display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.auth-brand img { display: block; height: 40px; width: auto; }
.auth-top-actions { display: flex; align-items: center; gap: 10px; }

.auth-locale {
    display: inline-flex; align-items: center; gap: 2px; padding: 4px 4px 4px 12px; border-radius: 999px;
    background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .14);
    color: rgba(255, 255, 255, .7); font-size: 13px;
}
.auth-locale i { margin-right: 6px; font-size: 13px; }
.auth-locale a {
    padding: 5px 11px; border-radius: 999px; font-weight: 700; letter-spacing: .03em;
    color: rgba(255, 255, 255, .7); transition: background-color .2s, color .2s;
}
.auth-locale a:hover { color: #fff; }
.auth-locale a.active { background: #fff; color: var(--ink); }

.auth-back {
    display: inline-flex; align-items: center; gap: 8px; padding: 9px 16px; border-radius: 999px;
    font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, .85);
    border: 1px solid rgba(255, 255, 255, .14); transition: background-color .2s, color .2s;
}
.auth-back:hover { background: rgba(255, 255, 255, .1); color: #fff; }
.auth-back i { font-size: 11px; }

/* Card */
.auth-main { position: relative; z-index: 1; padding: 24px 16px 40px; display: flex; flex-direction: column; align-items: center; }
.auth-card {
    width: 100%; max-width: 460px; padding: 44px 44px 40px; border-radius: 28px; background: #fff;
    box-shadow: 0 40px 80px -24px rgba(20, 23, 39, .35), 0 2px 6px rgba(20, 23, 39, .05);
}
.auth-badge {
    display: flex; width: fit-content; align-items: center; gap: 8px; margin: 0 auto 24px; padding: 6px 14px; border-radius: 999px;
    background: rgba(42, 68, 102, .08); color: var(--accent);
    font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}

.auth-head { margin-bottom: 32px; text-align: center; }
.auth-head h1 { margin: 0; font-size: clamp(26px, 3vw, 32px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.15; color: var(--ink); }
.auth-head p { margin: 10px 0 0; font-size: 15px; color: var(--ink-2); }
.auth-icon {
    display: grid; place-items: center; width: 52px; height: 52px; margin: 0 auto 20px; border-radius: 14px;
    background-image: var(--gradient-primary); color: #fff; font-size: 19px; box-shadow: 0 10px 20px -8px rgba(0, 115, 230, .5);
}
.auth-icon + h1 { margin-top: 0; }
.auth-card:has(.auth-icon) .auth-badge { display: none; }

.auth-alert {
    display: flex; gap: 10px; align-items: flex-start; margin-bottom: 24px; padding: 14px 16px; border-radius: 14px;
    background: rgba(130, 214, 22, .12); color: #3f7a06; font-size: 14px; font-weight: 500;
}
.auth-alert i { margin-top: 3px; }

/* Fields */
.auth-form { display: grid; gap: 20px; }
.auth-field .form-label { margin: 0 0 8px; padding: 0; font-size: 14px; font-weight: 600; color: var(--ink); }
.auth-input { position: relative; }
.auth-input-icon {
    position: absolute; left: 16px; top: 50%; transform: translateY(-50%);
    font-size: 14px; color: var(--ink-3); pointer-events: none; transition: color .2s;
}
.auth-input .form-control {
    height: 52px; padding: 0 16px 0 46px; border-radius: 14px; border: 1px solid #d2d6da;
    font-size: 15px; color: var(--ink); background: #fff; transition: border-color .2s, box-shadow .2s;
}
.auth-input .form-control::placeholder { color: #adb5bd; }
.auth-input .form-control:focus { border-color: #76baff; box-shadow: 0 0 0 4px rgba(42, 68, 102, .12); }
.auth-input:focus-within .auth-input-icon { color: var(--accent); }
.auth-input .form-control.is-invalid { border-color: var(--danger); background-image: none; padding-right: 48px; }
.auth-input .form-control.is-invalid:focus { box-shadow: 0 0 0 4px rgba(234, 6, 6, .12); }
.auth-input .form-control[type="password"], .auth-input .form-control[data-revealed] { padding-right: 52px; }

.auth-toggle {
    position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
    width: 40px; height: 40px; border: 0; border-radius: 10px; background: transparent;
    color: var(--ink-3); cursor: pointer; transition: background-color .2s, color .2s;
}
.auth-toggle:hover { background: var(--bg-soft); color: var(--ink); }
.auth-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.auth-error { display: flex; gap: 6px; align-items: center; margin: 8px 0 0; font-size: 13px; font-weight: 500; color: var(--danger); }
.auth-hint { margin: 8px 0 0; font-size: 13px; color: var(--ink-3); }

.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.auth-row .form-check-label { font-size: 14px; color: var(--ink-2); }
.auth-row .form-check-input:checked { background-color: var(--accent); border-color: var(--accent); }

.auth-link { font-size: 14px; font-weight: 700; color: var(--accent); }
.auth-link:hover { color: #213651; }

.auth-submit {
    display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: 100%; height: 52px; margin-top: 4px;
    border: 0; border-radius: 14px; background-image: var(--gradient-primary); color: #fff;
    font-family: inherit; font-size: 15px; font-weight: 700; cursor: pointer;
    box-shadow: 0 10px 30px -10px rgba(0, 115, 230, .6); transition: transform .2s, box-shadow .2s, opacity .2s;
}
.auth-submit:hover { transform: translateY(-1px); box-shadow: 0 16px 36px -10px rgba(0, 115, 230, .7); }
.auth-submit:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.auth-submit i { font-size: 13px; transition: transform .2s; }
.auth-submit:hover i.fa-arrow-right { transform: translateX(3px); }
.auth-submit[disabled] { opacity: .75; cursor: progress; transform: none; }

.auth-alt { margin: 28px 0 0; text-align: center; font-size: 14px; color: var(--ink-2); }

/* Corporate footer */
.auth-footer { width: 100%; max-width: 460px; margin-top: 28px; text-align: center; display: grid; gap: 10px; }
.auth-footer p { margin: 0; font-size: 13px; color: var(--ink-3); }
.auth-notice { text-wrap: balance; }
.auth-notice i { margin-right: 6px; font-size: 11px; }
.auth-company { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 10px; }
.auth-company strong { color: var(--ink-2); font-weight: 700; }
.auth-company span::before { content: '·'; margin-right: 10px; }

@media (max-width: 575px) {
    .auth-band { height: 300px; min-height: 0; border-radius: 0 0 28px 28px; }
    .auth-top { padding: 20px 16px; }
    .auth-brand img { height: 32px; }
    .auth-back span { display: none; }
    .auth-back { padding: 9px 12px; }
    .auth-main { padding-top: 8px; }
    .auth-card { padding: 32px 22px 28px; border-radius: 22px; }
    .auth-company span::before { content: none; }
}
