/* Vazirmatn - Thin 100 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Thin.ttf') format('truetype');
    font-weight: 100;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - ExtraLight 200 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-ExtraLight.ttf') format('truetype');
    font-weight: 200;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - Light 300 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - Regular 400 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - Medium 500 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - SemiBold 600 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - Bold 700 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - ExtraBold 800 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-ExtraBold.ttf') format('truetype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

/* Vazirmatn - Black 900 */
@font-face {
    font-family: 'Vazirmatn';
    src: url('../fonts/Vazirmatn/static/Vazirmatn-Black.ttf') format('truetype');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

* {
    font-family: 'Vazirmatn', sans-serif !important;
}

:root {
    --bb-auth-primary: #17a887;
    --bb-auth-primary-dark: #0e8c70;
    --bb-auth-primary-soft: #eff9f6;
    --bb-auth-ink: #1e2427;
    --bb-auth-muted: #778186;
    --bb-auth-line: #e2e8e6;
    --bb-auth-card: #ffffff;
    --bb-auth-page: #f5f7f6;
    --bb-auth-danger: #bd4f4f;
    --bb-auth-success: #277b5b;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }

body.bb-auth-body {
    margin: 0;
    direction: rtl;
    color: var(--bb-auth-ink);
    background: var(--bb-auth-page);
    overflow-x: hidden;
}

body.bb-auth-body,
body.bb-auth-body input,
body.bb-auth-body button,
body.bb-auth-body textarea,
body.bb-auth-body select {
    font-family: inherit;
}

body.bb-auth-body a { text-decoration: none; }

.bb-auth-page {
    min-height: 100vh;
    padding: 28px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 50% 12%, rgba(23,168,135,.045), transparent 30%),
        var(--bb-auth-page);
}

.bb-auth-shell {
    width: min(430px, 100%);
    min-height: auto;
    display: block;
    margin: 0 auto;
    padding: 0;
    border: 1px solid #edf1ef;
    border-radius: 18px;
    background: var(--bb-auth-card);
    box-shadow: 0 16px 46px rgba(31, 51, 45, .08);
    opacity: 0;
    transform: translateY(14px);
    overflow: visible;
}

body.is-ready .bb-auth-shell {
    animation: bbAuthShellIn .42s ease forwards;
}

.bb-auth-visual,
.bb-auth-support-card {
    display: none !important;
}

.bb-auth-main {
    width: 100%;
    min-width: 0;
    padding: 30px 34px 28px;
    background: #fff;
    border-radius: 18px;
}

.bb-auth-main-inner {
    width: 100%;
    max-width: none;
    margin: 0;
}

.bb-auth-local-brand {
    margin: 0 0 34px;
    text-align: center;
    line-height: 1;
}

.bb-auth-local-brand strong {
    display: block;
    color: var(--bb-auth-primary);
    font-size: 36px;
    font-weight: 900;
    letter-spacing: -.8px;
}

.bb-auth-local-brand small {
    display: block;
    margin-top: 8px;
    color: #87918d;
    font-size: 12px;
    font-weight: 700;
}

.bb-auth-topline {
    margin: 0 0 4px;
    text-align: center;
}

.bb-auth-topline p {
    margin: 0;
    color: var(--bb-auth-muted);
    font-size: 12px;
    line-height: 1.9;
}

.bb-auth-heading { display: none !important; }

.bb-auth-tabs {
    width: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin: 14px 0 28px;
    padding: 0;
    border: 0;
    background: transparent;
}

.bb-auth-tab-link {
    min-height: auto;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #383f42;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0;
    box-shadow: none !important;
    font-size: 17px;
    font-weight: 800;
    transition: color .15s ease;
}

.bb-auth-tab-link:hover,
.bb-auth-tab-link.active {
    color: var(--bb-auth-primary-dark);
}

.bb-auth-tab-separator {
    color: #a8b0ad;
    font-size: 17px;
    line-height: 1;
}

.bb-auth-panel { display: none; }
.bb-auth-panel.active { display: block; }
.bb-auth-panel.is-entering { animation: bbAuthPanelIn .24s ease both; }

.bb-auth-form {
    width: 100%;
    margin: 0;
    padding: 0;
}

.bb-auth-form-title {
    margin: 0 0 16px;
    text-align: center;
    color: #323a3d;
    font-size: 14px;
    font-weight: 800;
}

.bb-auth-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.bb-auth-field {
    margin-bottom: 14px;
}

.bb-auth-field label {
    display: block;
    margin: 0 0 7px;
    color: #4d585c;
    font-size: 11px;
    font-weight: 800;
}

.bb-auth-required { color: #c65a5a; }

.bb-auth-input-wrap { position: relative; }

.bb-auth-input-icon {
    position: absolute;
    top: 50%;
    right: 15px;
    z-index: 2;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    color: #9ba6a2;
    pointer-events: none;
}

.bb-auth-input-icon svg,
.bb-auth-pass-toggle svg {
    width: 100%;
    height: 100%;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.bb-auth-field .form-control,
.bb-auth-field input.form-control,
.bb-auth-seller-box .form-control {
    width: 100%;
    height: 52px;
    min-height: 52px;
    padding: 0 45px 0 14px;
    border: 1px solid var(--bb-auth-line);
    border-radius: 8px;
    color: #22282b;
    background: #fff;
    font-size: 13px;
    box-shadow: none !important;
    outline: none;
    transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease;
}

.bb-auth-field .form-control::placeholder,
.bb-auth-seller-box .form-control::placeholder {
    color: #aab3af;
}

.bb-auth-field .form-control:focus,
.bb-auth-seller-box .form-control:focus {
    border-color: #8fd6c4;
    box-shadow: 0 0 0 3px rgba(23,168,135,.08) !important;
}

.bb-auth-has-toggle .form-control { padding-left: 47px; }

.bb-auth-pass-toggle {
    position: absolute;
    top: 50%;
    left: 9px;
    z-index: 3;
    width: 34px;
    height: 34px;
    padding: 8px;
    transform: translateY(-50%);
    border: 0;
    border-radius: 7px;
    color: #8f9995;
    background: transparent;
    cursor: pointer;
}

.bb-auth-pass-toggle:hover {
    color: var(--bb-auth-primary-dark);
    background: var(--bb-auth-primary-soft);
}

.bb-auth-check-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    margin: 11px 0;
}

.bb-auth-check-row input[type="checkbox"] {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    margin: 3px 0 0;
    accent-color: var(--bb-auth-primary);
}

.bb-auth-check-row label {
    margin: 0;
    color: #68736f;
    font-size: 11px;
    line-height: 1.9;
}

.bb-auth-check-row a {
    color: var(--bb-auth-primary-dark);
    font-weight: 800;
}

.bb-auth-submit,
.bb-auth-secondary-btn,
.bb-auth-ghost-link {
    width: 100%;
    min-height: 48px;
    border-radius: 7px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: transform .16s ease, background-color .16s ease, border-color .16s ease;
}

.bb-auth-submit {
    margin-top: 10px;
    border: 0;
    color: #fff;
    background: var(--bb-auth-primary);
}

.bb-auth-submit:hover {
    background: var(--bb-auth-primary-dark);
    transform: translateY(-1px);
}

.bb-auth-submit:disabled {
    opacity: .48;
    cursor: not-allowed;
    transform: none;
}

.bb-auth-secondary-btn {
    border: 1px solid #dce4e1;
    color: #33403b;
    background: #fff;
}

.bb-auth-secondary-btn:hover {
    border-color: #b8c7c1;
    transform: translateY(-1px);
}

.bb-auth-divider {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 16px 0;
    color: #a0aaa6;
    font-size: 11px;
}

.bb-auth-divider::before,
.bb-auth-divider::after {
    content: "";
    flex: 1 1 auto;
    height: 1px;
    background: #edf0ef;
}

.bb-auth-ghost-link {
    min-height: auto;
    margin: 12px 0 0;
    padding: 0;
    border: 0;
    color: var(--bb-auth-primary-dark);
    background: transparent;
}

.bb-auth-seller-box {
    margin: 7px 0 11px;
    padding: 12px;
    border: 1px solid #e5ebe9;
    border-radius: 8px;
    background: #fafcfb;
}

.bb-auth-seller-box small {
    display: block;
    margin-top: 6px;
    color: #818b87;
    font-size: 10px;
    line-height: 1.85;
}

.bb-auth-form-switch,
.bb-auth-bottom-copy,
.bb-auth-terms {
    margin: 15px 0 0;
    text-align: center;
    color: #737d79;
    font-size: 11px;
    line-height: 1.9;
}

.bb-auth-form-switch a,
.bb-auth-bottom-copy a,
.bb-auth-terms a {
    color: var(--bb-auth-primary-dark);
    font-weight: 800;
}

.bb-auth-terms {
    margin-top: 12px;
    padding-top: 2px;
}

.bb-auth-message {
    margin-top: 14px;
    padding: 11px 12px;
    border-radius: 8px;
    font-size: 11px;
    line-height: 1.9;
}

.bb-auth-message.is-error {
    color: #9a3f3f;
    background: #fff5f5;
    border: 1px solid #f2dddd;
}

.bb-auth-message.is-success {
    color: var(--bb-auth-success);
    background: #f2faf6;
    border: 1px solid #d9eee3;
}

.bb-auth-password-alert,
.bb-auth-helper-error {
    display: block;
    margin-top: 5px;
    color: var(--bb-auth-danger);
    font-size: 10px;
}
.bb-auth-helper-error { display: none; }

.bb-auth-route-tabs {
    margin-bottom: 24px;
}

@keyframes bbAuthShellIn {
    to { opacity: 1; transform: translateY(0); }
}

@keyframes bbAuthPanelIn {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}

@media (max-width: 575.98px) {
    .bb-auth-page {
        padding: 14px 10px;
        align-items: flex-start;
    }

    .bb-auth-shell {
        width: 100%;
        border-radius: 14px;
        box-shadow: 0 10px 28px rgba(31,51,45,.06);
    }

    .bb-auth-main {
        padding: 24px 18px 22px;
        border-radius: 14px;
    }

    .bb-auth-local-brand {
        margin-bottom: 26px;
    }

    .bb-auth-local-brand strong {
        font-size: 31px;
    }

    .bb-auth-tabs {
        margin-bottom: 23px;
    }

    .bb-auth-grid-2 {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .bb-auth-field .form-control,
    .bb-auth-field input.form-control,
    .bb-auth-seller-box .form-control {
        height: 50px;
        min-height: 50px;
    }
}

/* ==========================================================
   Auth modes: password / OTP + registration password confirm
   ========================================================== */
.bb-auth-login-modes {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    margin: 0 0 18px;
    padding: 4px;
    border: 1px solid var(--bb-auth-line);
    border-radius: 9px;
    background: #f8faf9;
}

.bb-auth-login-mode {
    min-height: 40px;
    padding: 0 10px;
    border: 0;
    border-radius: 7px;
    color: #78827e;
    background: transparent;
    font-family: inherit;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: color .16s ease, background-color .16s ease, box-shadow .16s ease;
}

.bb-auth-login-mode:hover {
    color: var(--bb-auth-primary-dark);
}

.bb-auth-login-mode.active {
    color: var(--bb-auth-primary-dark);
    background: #fff;
    box-shadow: 0 2px 8px rgba(31, 51, 45, .07);
}

.bb-auth-login-mode-panel {
    display: none;
}

.bb-auth-login-mode-panel.active {
    display: block;
    animation: bbAuthPanelIn .22s ease both;
}

.bb-auth-mode-hint,
.bb-auth-otp-note {
    margin: 0 0 12px;
    padding: 10px 11px;
    border-radius: 7px;
    color: #68736f;
    background: #f8faf9;
    font-size: 10px;
    line-height: 1.9;
}

.bb-auth-otp-note {
    color: var(--bb-auth-success);
    border: 1px solid #dceee6;
    background: #f4faf7;
}

.bb-auth-otp-input {
    direction: ltr;
    text-align: center;
    letter-spacing: 5px;
    font-size: 16px !important;
    font-weight: 800;
}

.bb-auth-resend-btn {
    margin-top: 9px;
}

.bb-auth-password-alert {
    visibility: hidden;
}

.bb-auth-helper-error[data-password-match-error] {
    margin-top: 6px;
}

@media (max-width: 575.98px) {
    .bb-auth-login-mode {
        min-height: 38px;
        padding-inline: 6px;
        font-size: 10px;
    }
}
