.text-end {
    text-align: end;
}

.auth-page {
    min-height: 100vh;
    background: linear-gradient(135deg,#fdfbf7,#f5f0e7)
}

.auth-referral-note {
    display: grid;
    gap: 6px;
    margin: 0 0 16px;
    padding: 13px 15px;
    border: 1px solid #dce8dd;
    border-radius: 12px;
    background: #f2f7f1;
    color: #23483f;
    font-size: 12px;
    line-height: 1.8;
    animation: step-pulse 1.8s ease-in-out infinite
}

    .auth-referral-note span {
        color: #59675e;
        font-size: 11px;
    }
    .auth-referral-note span strong{
        color: #6a4336;
        font-size: 13px;
    }

@keyframes step-pulse {
    0%,100% {
        box-shadow: 0 0 0 0 #315e5180,0 0 0 0 #315e5130
    }

    50% {
        box-shadow: 0 0 0 9px #315e5100,0 0 14px 3px #315e5160
    }
}

.auth-header {
    border-bottom: 0;
    min-height: 94px
}

    .auth-header .brand small {
        display: block
    }

/* SweetAlert2 positions its animated status marks relative to a content-box icon. */
.swal2-icon {
    box-sizing: content-box;
}

.auth-main {
    display: grid;
    grid-template-columns: minmax(0,1fr) minmax(430px,500px);
    gap: 90px;
    align-items: center;
    min-height: calc(100vh - 190px);
    padding: 35px 0 70px
}

.auth-intro {
    position: relative;
    min-height: 500px;
    padding: 35px 0 50px
}

.auth-kicker {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--copper);
    font-size: 11px
}

    .auth-kicker i {
        width: 25px;
        height: 1px;
        background: var(--copper)
    }

.auth-intro h1 {
    font-size: 48px;
    line-height: 1.6;
    color: var(--forest);
    margin: 24px 0 12px
}

    .auth-intro h1 em {
        color: var(--copper);
        font-style: normal
    }

.auth-intro > p {
    color: var(--muted);
    font-size: 13px;
    line-height: 2.4;
    max-width: 450px
}

.auth-promise {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 35px
}

.promise-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: #e9dfd1;
    color: var(--copper)
}

    .promise-icon .icon {
        width: 22px
    }

.auth-promise strong, .auth-promise small {
    display: block
}

.auth-promise strong {
    font-size: 12px;
    font-weight: 400
}

.auth-promise small {
    font-size: 10px;
    color: var(--muted)
}

.auth-ornament {
    position: absolute;
    left: -80px;
    bottom: -30px;
    width: 335px;
    height: 335px;
    opacity: .2;
    pointer-events: none
}

    .auth-ornament img {
        width: 100%;
        height: 100%;
        object-fit: contain
    }

.auth-card {
    background: #fff;
    border: 1px solid #ece6dc;
    border-radius: 16px;
    padding: 34px 38px;
    box-shadow: 0 24px 70px #23483f0d
}

.auth-card-heading {
    text-align: center;
    margin-bottom: 24px
}

.auth-card-kicker {
    color: var(--copper);
    font-size: 10px
}

.auth-card h2 {
    font-size: 29px;
    color: var(--forest);
    margin: 4px 0 2px
}

.auth-card-heading p, .dialog-lead {
    font-size: 11px;
    color: var(--muted)
}

.auth-methods {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    background: #f5f1e9;
    padding: 5px;
    border-radius: 8px;
    margin-bottom: 24px;
    transition: all .3s ease-in-out
}

.auth-method {
    position: relative;
    min-height: 56px;
    border-radius: 6px;
    color: var(--muted);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-size: 11px
}

    .auth-method .icon {
        width: 17px
    }

    .auth-method small {
        position: absolute;
        top: 4px;
        left: 5px;
        font-size: 7px;
        color: var(--copper)
    }

    .auth-method.is-active {
        background: #fff;
        color: var(--forest);
        box-shadow: 0 4px 12px #273b340d
    }

.auth-panel {
    animation: auth-in .25s ease
}

.auth-label {
    display: block;
    font-size: 10px;
    color: #626b60;
    margin: 0 0 7px
}

.auth-input-wrap {
    height: 49px;
    border: 1px solid #e5e1d8;
    background: #fdfcf9;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 13px;
    margin-bottom: 16px;
    color: #a08b73
}

    .auth-input-wrap:focus-within {
        border-color: var(--copper);
        box-shadow: 0 0 0 3px #b36e4312
    }

    .auth-input-wrap > .icon {
        width: 18px
    }

.auth-input {
    border: 0;
    outline: 0;
    background: transparent;
    min-width: 0;
    flex: 1;
    color: var(--ink);
    font-size: 12px;
    direction: ltr;
}

.rtl {
    direction: rtl;
}

.gender-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px
}

    .gender-options > .auth-label {
        flex-basis: 100%;
        margin-bottom: -2px
    }

.gender-option {
    flex: 1;
    min-height: 58px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    border: 1px solid #e5e1d8;
    border-radius: 7px;
    color: var(--ink);
    background: #fdfcf9;
    cursor: pointer
}

    .gender-option input {
        accent-color: var(--forest);
        opacity: 0;
    }

    .gender-option .icon {
        width: 26px;
        height: 26px;
        color: var(--copper)
    }

    .gender-option:has(input:checked) {
        border-color: var(--copper);
        background: #fff7ed
    }

.register-otp-summary {
    margin: 8px 0 2px;
    color: var(--ink);
    font-size: 12px
}

[data-correct-mobile], [data-register-resend], [data-forgot-correct-mobile], [data-forgot-resend] {
    margin: 0 0 12px;
    cursor: pointer
}

    [data-register-resend]:not([hidden]), [data-forgot-resend]:not([hidden]) {
        display: inline-flex
    }

.password-toggle {
    width: 28px;
    height: 32px;
    color: #979a8d;
    display: grid;
    place-items: center
}

    .password-toggle .icon {
        width: 17px
    }

.auth-submit {
    width: 100%;
    margin-top: 14px;
    justify-content: space-between
}

.auth-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 10px;
    margin: -3px 0 17px
}

.check-label {
    color: var(--muted);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer
}

    .check-label input {
        accent-color: var(--forest)
    }

        .check-label input[type=checkbox] {
            cursor: pointer;
        }

.auth-link {
    color: var(--copper);
    font-size: 10px;
    padding: 0
}

    .auth-link:hover {
        text-decoration: underline
    }

.auth-link-strong {
    font-weight: 600
}

.otp-step {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px dashed #ded8ca
}

.otp-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: #626b60;
    margin-bottom: 13px
}

.auth-change {
    font-size: 10px;
    color: var(--copper)
}

.otp-fields {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 12px 0 10px
}

    .otp-fields input {
        width: 48px;
        height: 52px;
        text-align: center;
        border: 1px solid #dfdbd0;
        border-radius: 7px;
        background: #fdfcf9;
        color: var(--forest);
        font-size: 22px;
        outline: 0
    }

        .otp-fields input:focus {
            border-color: var(--copper);
            box-shadow: 0 0 0 3px #b36e4315
        }

.otp-countdown {
    text-align: center;
    color: #929487;
    font-size: 10px;
    margin: 7px 0 17px
}

.auth-divider {
    height: 1px;
    background: #e8e4db;
    margin: 28px 0 17px;
    position: relative
}

    .auth-divider span {
        position: absolute;
        top: -12px;
        right: 50%;
        transform: translateX(50%);
        background: #fff;
        padding: 0 12px;
        color: #aaa99c;
        font-size: 10px
    }

.auth-register {
    text-align: center;
    font-size: 11px;
    color: var(--muted)
}

.auth-demo-note {
    text-align: center;
    font-size: 8px;
    color: #aaa99c;
    margin-top: 22px
}

.auth-dialog {
    width: min(470px,calc(100% - 30px));
    padding: 35px 34px;
    background: #fff;
    border: 0;
    border-radius: 16px;
    color: var(--ink)
}

    .auth-dialog h2 {
        font-size: 28px;
        margin: 7px 0 4px;
        color: var(--forest)
    }

    .auth-dialog .dialog-lead {
        line-height: 2;
        margin-bottom: 22px
    }

    .auth-dialog .dialog-close {
        position: absolute;
        left: 12px;
        top: 12px;
        color: #888d7f
    }

.captcha-row {
    display: grid;
    grid-template-columns: minmax(0,1fr) 118px 42px;
    align-items: end;
    gap: 8px
}

.captcha-input {
    width: 100%;
    height: 43px;
    border: 1px solid #e5e1d8;
    border-radius: 6px;
    background: #fdfcf9;
    padding: 0 12px;
    outline: 0;
    direction: ltr;
    font-size: 12px
}

.captcha-code {
    height: 43px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    background: repeating-linear-gradient(-18deg,#eee3d4 0 3px,#f9f4ec 3px 7px);
    color: var(--forest);
    font-family: monospace;
    letter-spacing: 5px;
    font-size: 18px;
    font-weight: 700;
    user-select: none;
    text-decoration: line-through;
    text-decoration-color: #b36e43aa
}

.captcha-image {
    display: block;
    object-fit: cover;
    border: 1px solid #e5e1d8;
    text-decoration: none;
    letter-spacing: normal;
}

.register-otp-step {
    margin-top: 18px;
}

.captcha-refresh {
    height: 43px;
    border: 1px solid #e5e1d8;
    border-radius: 8px;
    display: grid;
    place-items: center;
    color: var(--copper);
    background: #fffaf3;
    cursor: pointer;
    transition: background .2s ease, color .2s ease, transform .2s ease
}

    .captcha-refresh:hover {
        background: #f2e8da;
        color: var(--forest)
    }

    .captcha-refresh:active {
        transform: rotate(-25deg)
    }

    .captcha-refresh .icon {
        width: 20px;
        height: 20px
    }

.auth-dialog .auth-submit {
    margin-top: 23px
}

@keyframes auth-in {
    from {
        opacity: .4;
        transform: translateY(3px)
    }

    to {
        opacity: 1;
        transform: none
    }
}

@media(max-width:900px) {
    .auth-main {
        grid-template-columns: 1fr;
        gap: 25px;
        max-width: 560px;
        overflow: hidden
    }

    .auth-intro {
        min-height: 260px;
        padding: 20px 0 0
    }

        .auth-intro h1 {
            font-size: 43px;
            margin: 15px 0 8px
        }

        .auth-intro > p {
            font-size: 11px
        }

    .auth-promise {
        margin-top: 19px
    }

    .auth-ornament {
        width: 220px;
        height: 220px;
        left: auto;
        right: -30px;
        bottom: -35px;
        opacity: .14
    }

    .auth-card {
        position: relative;
        z-index: 1
    }
}

@media(max-width:560px) {
    .auth-header {
        min-height: 80px
    }

        .auth-header .text-link {
            font-size: 9px
        }

    .auth-main {
        width: calc(100% - 28px);
        padding-top: 10px
    }

    .auth-intro {
        min-height: 225px
    }

        .auth-intro h1 {
            font-size: 37px
        }

        .auth-intro > p {
            font-size: 10px;
            line-height: 2.1;
            max-width: 285px
        }

    .auth-card {
        padding: 27px 20px;
        border-radius: 13px
    }

        .auth-card h2 {
            font-size: 26px
        }

    .auth-method {
        font-size: 10px;
        min-height: 52px
    }

    .otp-fields {
        gap: 6px
    }

        .otp-fields input {
            width: 43px;
            height: 49px;
            font-size: 20px
        }

    .auth-dialog {
        padding: 31px 20px
    }

    .captcha-row {
        grid-template-columns: minmax(0,1fr) 100px 38px
    }

    .captcha-code {
        letter-spacing: 3px;
        font-size: 16px
    }

    .auth-referral-note {
        margin:14px;
    }
}

.auth-stage {
    position: relative;
    min-height: 560px;
    perspective: 1200px
}

.auth-face {
    display: none;
    transform-origin: center;
    animation: auth-face-in .35s ease both
}

    .auth-face.is-active {
        display: block
    }

.auth-face-login {
    display: block
}

    .auth-face-login:not(.is-active) {
        display: none
    }

.auth-card-heading {
    position: relative
}

.auth-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--copper);
    font-size: 10px;
    padding: 0;
    margin-bottom: 12px
}

    .auth-back .icon {
        width: 15px
    }

.auth-face[data-auth-face="register"] .auth-card-heading, .auth-face[data-auth-face="forgot"] .auth-card-heading {
    padding-top: 2px
}

    .auth-face[data-auth-face="register"] .auth-card-heading h2, .auth-face[data-auth-face="forgot"] .auth-card-heading h2 {
        margin-top: 2px
    }

.captcha-code {
    position: relative;
    overflow: hidden
}

    .captcha-code:before, .captcha-code:after {
        content: '';
        position: absolute;
        left: -8%;
        right: -8%;
        height: 2px;
        background: #b36e43b8;
        transform: rotate(-11deg);
        pointer-events: none
    }

    .captcha-code:before {
        top: 38%;
        transform: rotate(11deg)
    }

    .captcha-code:after {
        top: 61%;
        transform: rotate(-13deg)
    }

@keyframes auth-face-in {
    from {
        opacity: 0;
        transform: rotateY(-8deg) translateY(8px)
    }

    to {
        opacity: 1;
        transform: none
    }
}

@media(max-width:560px) {
    .auth-stage {
        min-height: 575px
    }

    .auth-face[data-auth-face="register"], .auth-face[data-auth-face="forgot"] {
        padding-top: 2px
    }
}

.captcha-code {
    text-decoration: none
}
