/* ===== Login / Register — Meridian dizayni ===== */

.auth-body {
    /* Meridian palitrasi */
    --mrd-navy:      #0B2447;
    --mrd-navy-2:    #0E2E5C;
    --mrd-navy-3:    #12376E;
    --mrd-blue:      #2563EB;
    --mrd-blue-2:    #1D4ED8;
    --mrd-blue-lt:   #5B9BFF;
    --mrd-blue-soft: #EAF1FE;
    --mrd-ink:       #0B2447;
    --mrd-slate:     #334E68;
    --mrd-slate-2:   #5A7292;
    --mrd-slate-3:   #8299B5;
    --mrd-line:      #E5EAF2;
    --mrd-line-2:    #D3DCEA;
    --mrd-surface:   #F4F7FB;
    --mrd-amber:     #F59E0B;

    font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--mrd-surface);
    color: var(--mrd-ink);
    min-height: 100vh;
    overflow-x: hidden;
}

.auth-wrap {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 480px 1fr;
}

/* ---------- LEFT SIDE ---------- */
.auth-side {
    background: linear-gradient(160deg, var(--mrd-navy) 0%, var(--mrd-navy-2) 60%, var(--mrd-navy-3) 100%);
    color: #fff;
    padding: 40px 44px;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.auth-side::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 50% at 75% 25%, rgba(37,99,235,.28), transparent 70%);
    pointer-events: none;
}
.auth-side .logo-light {
    display: flex;
    align-items: center;
    gap: 11px;
    font-weight: 800;
    font-size: 21px;
    letter-spacing: -.01em;
    color: #fff;
    position: relative;
    z-index: 2;
}
.auth-side .logo-light .logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: var(--mrd-blue);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
}
.auth-side .logo-light .logo-text { color: #fff; }

.auth-side-content {
    position: relative;
    z-index: 2;
}
.auth-side-content h1 {
    color: #fff;
    font-weight: 800;
    font-size: 36px;
    line-height: 1.12;
    letter-spacing: -.02em;
    margin-bottom: 16px;
}
.auth-side-content p {
    color: #B7C6DE;
    font-size: 15px;
    line-height: 1.65;
    margin-bottom: 28px;
    max-width: 380px;
}
.auth-side-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.auth-side-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #DCE7FF;
    font-weight: 600;
    font-size: 15px;
}
.auth-side-list i {
    color: var(--mrd-blue-lt);
    font-size: 18px;
}

/* trust chip at bottom of side panel */
.auth-side-decor {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    align-self: flex-start;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.16);
    padding: 10px 16px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 700;
    color: #DCE7FF;
}
.auth-side-decor i { color: var(--mrd-blue-lt); }
/* eski dekorativ doiralar endi ishlatilmaydi */
.decor-circle { display: none; }

/* ---------- RIGHT SIDE — Form ---------- */
.auth-main {
    padding: 40px 28px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    background: var(--mrd-surface);
}
.back-home {
    position: absolute;
    top: 28px; left: 28px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--mrd-slate-2);
    font-weight: 600;
    transition: color .2s;
}
.back-home:hover { color: var(--mrd-blue); }

.auth-card {
    width: 100%;
    max-width: 440px;
    background: #fff;
    border: 1px solid var(--mrd-line);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 40px 90px -40px rgba(11,36,71,.4);
}

/* ---------- ROLE TABS ---------- */
.role-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    background: var(--mrd-surface);
    border: 1px solid var(--mrd-line);
    padding: 6px;
    border-radius: 12px;
    margin-bottom: 26px;
}
.role-tabs.role-tabs-3 {
    grid-template-columns: 1fr 1fr 1fr;
    gap: 6px;
}
.role-tabs.role-tabs-3 .role-tab {
    padding: 8px 10px;
    gap: 8px;
}
.role-tabs.role-tabs-3 .role-tab i {
    width: 28px; height: 28px;
    font-size: 14px;
}
.role-tabs.role-tabs-3 .role-tab strong { font-size: 12px; }
.role-tabs.role-tabs-3 .role-tab span { font-size: 10.5px; }
@media (max-width: 500px) {
    .role-tabs.role-tabs-3 .role-tab div { display: none; }
    .role-tabs.role-tabs-3 .role-tab { justify-content: center; padding: 10px; }
}
.role-tab {
    background: transparent;
    border: none;
    padding: 10px 14px;
    border-radius: 9px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
    transition: background .2s, box-shadow .2s;
    color: var(--mrd-slate);
    font-family: inherit;
}
.role-tab i {
    font-size: 16px;
    width: 34px; height: 34px;
    background: #fff;
    border: 1px solid var(--mrd-line);
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--mrd-slate-3);
    transition: background .2s, color .2s, border-color .2s;
}
.role-tab div { display: flex; flex-direction: column; }
.role-tab strong {
    font-weight: 800;
    font-size: 13px;
    color: var(--mrd-ink);
}
.role-tab span {
    font-size: 11px;
    color: var(--mrd-slate-3);
}
.role-tab.active {
    background: #fff;
    box-shadow: 0 6px 16px -8px rgba(11,36,71,.35);
}
.role-tab.active i {
    background: var(--mrd-blue);
    border-color: var(--mrd-blue);
    color: #fff;
}
.role-tab.active strong { color: var(--mrd-blue); }

/* ---------- FORM ---------- */
.auth-form { display: none; }
.auth-form.active { display: block; animation: authFadeIn .3s ease; }
@keyframes authFadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-form h2,
#verifyStep h3,
#forgotPhoneStep h3,
#forgotVerifyStep h3,
#forgotNewPassStep h3 {
    font-weight: 800;
    font-size: 22px;
    letter-spacing: -.01em;
    color: var(--mrd-ink);
    margin-bottom: 6px;
}
.auth-sub {
    font-size: 14px;
    color: var(--mrd-slate-2);
    line-height: 1.55;
    margin-bottom: 22px;
}

.auth-form .form-group {
    margin-bottom: 16px;
}
.auth-form .form-label {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--mrd-slate);
    margin-bottom: 8px;
}
.auth-input {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--mrd-surface);
    border: 1.5px solid var(--mrd-line);
    border-radius: 10px;
    padding: 12px 16px;
    transition: border-color .2s, background .2s, box-shadow .2s;
}
.auth-input:focus-within {
    border-color: var(--mrd-blue);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(37,99,235,.14);
}
.auth-input > i {
    color: var(--mrd-slate-3);
}
.auth-input:focus-within > i { color: var(--mrd-blue); }
.auth-input input {
    flex: 1;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 14px;
    color: var(--mrd-ink);
    outline: none;
    min-width: 0;
}
.auth-input input::placeholder { color: var(--mrd-slate-3); }
.eye-btn {
    border: none;
    background: transparent;
    color: var(--mrd-slate-3);
    cursor: pointer;
    font-size: 14px;
    padding: 0;
}
.eye-btn:hover { color: var(--mrd-blue); }

.auth-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin: 8px 0 22px;
    font-size: 13px;
}
.check-row {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--mrd-slate);
    cursor: pointer;
}
.check-row input { accent-color: var(--mrd-blue); width: 16px; height: 16px; }
.forgot-link {
    color: var(--mrd-blue);
    font-weight: 700;
}
.forgot-link:hover { color: var(--mrd-blue-2); }

/* Buttons (style.css yashil primary'ni Meridian ko'kiga almashtiramiz) */
.auth-body .btn { border-radius: 10px; font-weight: 700; }
.auth-body .btn.btn-block { width: 100%; }
.auth-body .btn-primary {
    background: var(--mrd-blue);
    color: #fff;
    border: none;
    box-shadow: 0 10px 24px -10px rgba(37,99,235,.6);
    transition: transform .2s, background .2s, box-shadow .2s;
}
.auth-body .btn-primary:hover {
    background: var(--mrd-blue-2);
    transform: translateY(-2px);
    box-shadow: 0 14px 30px -10px rgba(37,99,235,.7);
}

.auth-divider {
    text-align: center;
    position: relative;
    margin: 22px 0 18px;
    color: var(--mrd-slate-3);
    font-size: 13px;
}
.auth-divider span {
    background: #fff;
    padding: 0 12px;
    position: relative;
    z-index: 1;
}
.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%; left: 0; right: 0;
    height: 1px;
    background: var(--mrd-line);
}

.auth-foot {
    text-align: center;
    font-size: 14px;
    color: var(--mrd-slate-2);
    margin-top: 6px;
}
.auth-foot a {
    color: var(--mrd-blue);
    font-weight: 700;
}
.auth-foot a:hover { color: var(--mrd-blue-2); }

/* Verify timer */
#verifyTimer, #forgotVerifyTimer {
    font-size: 13px;
    color: var(--mrd-slate-2);
    margin-top: 10px;
    text-align: center;
}

.demo-hint {
    margin-top: 18px;
    padding: 12px 14px;
    background: var(--mrd-blue-soft);
    border-radius: 10px;
    font-size: 12.5px;
    color: var(--mrd-blue-2);
    display: flex;
    align-items: center;
    gap: 10px;
}
.demo-hint i { color: var(--mrd-blue); }
.demo-hint code {
    background: rgba(37,99,235,.15);
    padding: 2px 7px;
    border-radius: 5px;
    font-size: 11.5px;
    font-family: 'Courier New', monospace;
    color: var(--mrd-blue-2);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .auth-wrap { grid-template-columns: minmax(0, 1fr); }
    .auth-side {
        padding: 28px 24px 24px;
        min-height: auto;
    }
    .auth-side-content h1 { font-size: 26px; }
    .auth-side-content p { font-size: 14px; margin-bottom: 18px; }
    .auth-side-list { display: none; }
    .auth-side-decor { display: none; }
    .auth-main { padding: 32px 20px 40px; }
}
@media (max-width: 500px) {
    .auth-card { padding: 24px 20px; }
    .auth-main { padding: 24px 16px 36px; }
    .back-home { top: 16px; left: 16px; font-size: 13px; }
    .role-tab span { display: none; }
    .auth-side-content h1 { font-size: 23px; }
}
@media (max-width: 360px) {
    .auth-card { padding: 20px 14px; }
    .auth-main { padding: 20px 12px 32px; }
    .auth-side { padding: 22px 16px 18px; }
}

/* ===== Telefon tasdiqlash — 4 ta kod katakchasi (registratsiya va parolni tiklash) ===== */
.otp-cells { display: flex; gap: 9px; margin-top: 12px; }
.otp-cell {
    flex: 1; min-width: 0; height: 56px; padding: 0; text-align: center;
    font-family: inherit; font-size: 22px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums;
    border-radius: 13px; border: 1.5px solid var(--line, #262B3D);
    background: var(--field, #0D0F18); color: var(--ink, #F3F4FA);
    caret-color: #5A6CF6; transition: border-color .15s, box-shadow .15s;
}
.otp-cell:focus { outline: none; border-color: #4458F0; box-shadow: 0 0 0 3px rgba(68,88,240,.25); }
.otp-cell.filled { border-color: rgba(90,108,246,.55); }
@media (max-width: 360px) { .otp-cells { gap: 6px; } .otp-cell { height: 50px; font-size: 20px; } }

/* ===== Google bilan kirish ===== */
.google-auth { display: flex; justify-content: center; min-height: 44px; margin: 4px 0 6px; }
.google-auth[hidden] { display: none; }
.google-auth > div { max-width: 100%; }
