﻿/*
:root {
    --bg1: #0d6efd;
    --bg2: #20c997;
    --card: #ffffff;
    --muted: #6c757d;
    --text: #0b1320;
    --border: rgba(16,24,40,.10);
    --shadow: 0 18px 50px rgba(16,24,40,.12);
    --radius: 18px;
}

body {
    background: radial-gradient(1200px 420px at 20% -10%, rgba(13,110,253,.28) 0%, rgba(13,110,253,0) 60%), radial-gradient(1100px 420px at 90% 0%, rgba(32,201,151,.20) 0%, rgba(32,201,151,0) 55%), linear-gradient(180deg, #f6f8ff 0%, #ffffff 65%);
}*/

.auth-wrap {
    min-height: calc(100vh - 40px);
    display: flex;
    align-items: center;
    padding: 24px 0;
}

.auth-card {
    border: 0;
    border-radius: var(--radius);
    background: rgba(255,255,255,.82);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.auth-hero {
    padding: 18px 18px 8px 18px;
    background: radial-gradient(900px 240px at 50% -20%, rgba(13,110,253,.40) 0%, rgba(13,110,253,0) 65%), radial-gradient(800px 220px at 0% 0%, rgba(32,201,151,.22) 0%, rgba(32,201,151,0) 55%);
    border-bottom: 1px solid rgba(255,255,255,.55);
}

.brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    text-align: center;
}

    .brand img {
        width: 176px;
        height: 108px;
        object-fit: contain;
        filter: drop-shadow(0 8px 18px rgba(0,0,0,.08));
        user-select: none;
        -webkit-user-drag: none;
    }

.brand-title {
    font-weight: 800;
    font-size: 18px;
    color: var(--text);
    letter-spacing: -.2px;
}

.brand-sub {
    color: rgba(11,19,32,.65);
    font-size: 13px;
}

.steps {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.step-pill {
    flex: 1;
    padding: 10px 12px;
    border-radius: 999px;
    text-align: center;
    font-weight: 800;
    font-size: 13px;
    border: 1px solid rgba(108,117,125,.18);
    background: rgba(108,117,125,.10);
    color: rgba(108,117,125,.85);
    transition: all .25s ease;
    user-select: none;
}

    .step-pill.active {
        background: rgba(13,110,253,.14);
        border-color: rgba(13,110,253,.25);
        color: rgba(13,110,253,.98);
    }

.auth-body {
    padding: 18px 18px 20px 18px;
}

.panel {
    border: 1px solid var(--border);
    background: var(--card);
    border-radius: 16px;
    padding: 14px;
}

.label {
    font-weight: 800;
    font-size: 13px;
    margin-bottom: 8px;
    color: rgba(11,19,32,.92);
}

.help {
    font-size: 12px;
    color: rgba(108,117,125,.92);
    margin-top: 8px;
}

.btn-strong {
    border-radius: 14px;
    padding: 12px 14px;
    font-weight: 900;
    letter-spacing: -.2px;
}

.btn-ghost {
    border-radius: 14px;
    padding: 12px 14px;
    font-weight: 900;
}

/* Message box (Bootstrap alert classes used by JS) */
.msg {
    border-radius: 14px;
    padding: 12px 12px;
    font-weight: 700;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 12px;
}

    .msg i {
        margin-top: 2px;
    }

    .msg.hidden {
        display: none;
    }

/* ✅ OTP: Force 4 columns ALWAYS (even on very small screens) */
.otp-grid {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 10px !important;
    direction: ltr !important;
    width: 100% !important;
    align-items: center !important;
}

.otp-box {
    width: 100% !important;
    min-width: 0 !important;
    height: 54px !important;
    border-radius: 14px !important;
    text-align: center !important;
    font-weight: 900 !important;
    font-size: 18px !important;
    border: 1px solid rgba(16,24,40,.14) !important;
    outline: none !important;
    transition: all .2s ease !important;
    background: #fff !important;
    caret-color: transparent; /* ظاهر حرفه‌ای‌تر (caret وسط) */
}

    .otp-box:focus {
        border-color: rgba(13,110,253,.55) !important;
        box-shadow: 0 0 0 4px rgba(13,110,253,.12) !important;
    }

/* Prevent any overlay/click issues in some browsers */
#stepOtp {
    position: relative;
    z-index: 1;
}

.panel {
    position: relative;
    z-index: 2;
}

.tiny-link {
    font-weight: 800;
    font-size: 12px;
    text-decoration: none;
}

.timer {
    border-radius: 14px;
    padding: 10px 12px;
    font-weight: 800;
    background: rgba(13,110,253,.10);
    border: 1px solid rgba(13,110,253,.18);
    color: rgba(13,110,253,.95);
    white-space: nowrap;
}

.support {
    border-radius: 16px;
    padding: 14px;
    background: rgba(13,110,253,.08);
    border: 1px solid rgba(13,110,253,.16);
    margin-top: 14px;
}

    .support .title {
        font-weight: 900;
        margin-bottom: 6px;
    }

    .support .desc {
        color: rgba(108,117,125,.95);
        font-size: 13px;
    }

.debug {
    margin-top: 12px;
    border-radius: 14px;
    padding: 10px 12px;
    border: 1px dashed rgba(108,117,125,.30);
    background: #f8f9fa;
    font-size: 12px;
    color: rgba(108,117,125,.92);
    white-space: pre-wrap;
    display: none;
}

.shake {
    animation: shake .18s linear 0s 2;
}

@@keyframes shake {
    0% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(5px);
    }

    50% {
        transform: translateX(0);
    }

    75% {
        transform: translateX(-5px);
    }

    100% {
        transform: translateX(0);
    }
}

@@media (min-width: 992px) {
    .auth-body {
        padding: 22px 22px 24px 22px;
    }

    .auth-hero {
        padding: 20px 22px 10px 22px;
    }

    .panel {
        padding: 16px;
    }
}


