:root {
    --auth-primary: #80BB01;
    --auth-primary-dark: #6a9e01;
    --auth-primary-soft: rgba(128, 187, 1, 0.12);
    --auth-text: #2d2d2d;
    --auth-muted: #6b7280;
    --auth-border: #e5e7eb;
    --auth-bg: #f3f4f6;
    --auth-font: "iransans", "sans-serif", "Arial", "Verdana", "Trebuchet MS";
}

* {
    direction: rtl;
    box-sizing: border-box;
}

body,
button,
input,
textarea,
select {
    font-family: var(--auth-font);
}

body {
    margin: 0;
    background: var(--auth-bg);
}

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 1rem;
    background: var(--auth-bg);
}

.auth-card {
    display: flex;
    width: 100%;
    max-width: 920px;
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    box-shadow:
        0 20px 60px rgba(15, 23, 42, 0.1),
        0 8px 24px rgba(15, 23, 42, 0.06);
}

.auth-card__brand {
    flex: 0 0 42%;
    background: var(--auth-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 2rem;
}

.auth-card__brand-inner {
    text-align: center;
    max-width: 260px;
}

.auth-card__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    margin-bottom: 1.25rem;
    border-radius: 50%;
    background: #fff;
    padding: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.auth-card__logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.auth-card__site-name {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
    line-height: 1.4;
}

.auth-card__tagline {
    margin: 0;
    font-size: 0.95rem;
    opacity: 0.9;
}

.auth-card__form {
    flex: 1;
    padding: 2.5rem 2.25rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.auth-card__mobile-logo {
    display: none;
    text-align: center;
    margin-bottom: 1.5rem;
}

.auth-card__mobile-logo img {
    width: 72px;
    height: 72px;
    object-fit: contain;
}

.auth-card__mobile-title {
    margin: 0.75rem 0 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--auth-primary);
}

.auth-tabs {
    display: flex;
    gap: 0.5rem;
    background: #f3f4f6;
    border-radius: 12px;
    padding: 0.35rem;
    margin-bottom: 1.75rem;
}

.auth-tabs__item {
    flex: 1;
    border: none;
    background: transparent;
    color: var(--auth-muted);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 0.7rem 1rem;
    border-radius: 10px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

.auth-tabs__item--active {
    background: var(--auth-primary);
    color: #fff;
}

.auth-card__heading {
    text-align: center;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--auth-text);
    margin: 0 0 0.75rem;
}

.auth-card__subtext {
    text-align: center;
    font-size: 0.9rem;
    color: var(--auth-muted);
    margin: 0 0 1.75rem;
    line-height: 1.6;
}

.auth-card__subtext strong {
    color: var(--auth-text);
    font-weight: 600;
    direction: ltr;
    display: inline-block;
}

.auth-field {
    margin-bottom: 1.5rem;
}

.auth-field__wrap {
    position: relative;
    border: 1.5px solid var(--auth-border);
    border-radius: 12px;
    background: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.auth-field__wrap:focus-within {
    border-color: var(--auth-primary);
    box-shadow: 0 0 0 3px var(--auth-primary-soft);
}

.auth-field__legend {
    position: absolute;
    top: -0.6rem;
    right: 0.85rem;
    background: #fff;
    padding: 0 0.45rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--auth-muted);
    margin: 0;
    line-height: 1.2;
    z-index: 1;
    pointer-events: none;
}

.auth-field__input {
    display: block;
    width: 100%;
    border: none;
    outline: none;
    background: transparent;
    padding: 1.1rem 1rem 0.85rem;
    font-size: 1rem;
    color: var(--auth-text);
    border-radius: 12px;
    direction: ltr;
    text-align: right;
}

.auth-field__input::placeholder {
    color: #9ca3af;
    font-size: 0.9rem;
    direction: rtl;
    text-align: right;
}

.auth-field__error {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.85rem;
    color: #dc2626;
}

.auth-btn {
    width: 100%;
    border: none;
    border-radius: 12px;
    background: var(--auth-primary);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.9rem 1.25rem;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}

.auth-resend {
    text-align: center;
    font-size: 0.875rem;
    color: var(--auth-muted);
    margin: 0 0 1.25rem;
}

.auth-resend #time {
    font-weight: 600;
    color: var(--auth-text);
    direction: ltr;
    display: inline-block;
}

.auth-resend-btn {
    display: block;
    width: 100%;
    border: none;
    background: transparent;
    color: var(--auth-primary);
    font-size: 0.9rem;
    font-weight: 600;
    padding: 0;
    margin: -0.75rem 0 1.25rem;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.auth-resend-btn:hover {
    color: var(--auth-primary-dark);
}

.auth-btn:hover {
    background: var(--auth-primary-dark);
}

.auth-btn:active {
    transform: scale(0.99);
}

@media (max-width: 767.98px) {
    .auth-page {
        padding: 1rem 0.75rem;
        align-items: flex-start;
        padding-top: 2rem;
    }

    .auth-card {
        flex-direction: column;
        max-width: 420px;
        border-radius: 16px;
        box-shadow:
            0 16px 40px rgba(15, 23, 42, 0.1),
            0 6px 16px rgba(15, 23, 42, 0.05);
    }

    .auth-card__brand {
        display: none;
    }

    .auth-card__mobile-logo {
        display: block;
    }

    .auth-card__form {
        padding: 1.75rem 1.25rem 2rem;
    }

    .auth-tabs {
        margin-bottom: 1.25rem;
    }

    .auth-card__heading {
        margin-bottom: 0.5rem;
        font-size: 1rem;
    }

    .auth-card__subtext {
        margin-bottom: 1.25rem;
        font-size: 0.85rem;
    }
}
