/* =========================================================
   AUTH WRAPPER
========================================================= */

.auth-wrap,
.wrap {
    width: min(100%, 500px);

    margin: 0 auto;
}


/* =========================================================
   BRAND
========================================================= */

.brand {
    margin: 0 0 22px;

    text-align: center;
}

.brand-name {
    margin: 0;

    color: var(--auth-dark);

    font-family: var(--auth-serif);

    font-size: 32px;
    line-height: 1.15;

    font-weight: 700;

    letter-spacing: -0.02em;
}

.brand-sub {
    margin-top: 5px;

    color: var(--auth-gold);

    font-size: 10px;
    line-height: 1.2;

    font-weight: 800;

    letter-spacing: 0.22em;

    text-transform: uppercase;
}


/* =========================================================
   AUTH CARD
========================================================= */

.auth-card,
.card {
    width: 100%;

    padding: 34px;

    border: 1px solid var(--auth-border);

    border-radius: var(--auth-radius);

    background:
        rgba(255, 255, 255, 0.96);

    box-shadow: var(--auth-shadow);

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}


/* =========================================================
   OPTIONAL ICON
========================================================= */

.icon {
    width: 56px;
    height: 56px;

    margin: 0 0 18px;

    display: grid;
    place-items: center;

    border: 1px solid #ead8c8;

    border-radius: 16px;

    background:
        linear-gradient(
            145deg,
            #faf1e8,
            #f5e9dd
        );

    color: var(--auth-gold);

    font-size: 23px;

    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.8);
}


/* =========================================================
   HEADINGS
========================================================= */

h1 {
    margin: 0;

    color: var(--auth-dark);

    font-family: var(--auth-serif);

    font-size: 30px;

    line-height: 1.2;

    font-weight: 700;

    letter-spacing: -0.015em;
}


/* =========================================================
   INTRO / DESCRIPTION
========================================================= */

.intro {
    margin: 10px 0 25px;

    color: var(--auth-muted);

    font-size: 13px;

    line-height: 1.7;
}


/* =========================================================
   ALERTS
========================================================= */

.alert {
    width: 100%;

    margin: 0 0 18px;

    padding: 12px 14px;

    border-radius: 11px;

    font-size: 12px;

    line-height: 1.55;
}

.alert-error,
.error {
    border: 1px solid var(--auth-error-border);

    background: var(--auth-error-bg);

    color: var(--auth-error-text);
}

.alert-success,
.success {
    border: 1px solid var(--auth-success-border);

    background: var(--auth-success-bg);

    color: var(--auth-success-text);
}


/* =========================================================
   FORM
========================================================= */

form {
    width: 100%;
}


/* =========================================================
   FIELD
========================================================= */

.field {
    width: 100%;

    margin: 0 0 17px;
}


/* =========================================================
   LABEL
========================================================= */

label {
    display: block;

    margin: 0 0 7px;

    color: var(--auth-text);

    font-size: 12px;

    line-height: 1.4;

    font-weight: 700;
}


/* =========================================================
   INPUT
========================================================= */

input {
    width: 100%;

    height: 48px;

    margin: 0;

    padding: 0 14px;

    border: 1px solid var(--auth-border);

    border-radius: 11px;

    outline: none;

    background: var(--auth-white);

    color: var(--auth-text);

    font-family: var(--auth-sans);

    font-size: 13px;

    line-height: 48px;

    transition:
        border-color .2s ease,
        box-shadow .2s ease,
        background-color .2s ease;
}

input::placeholder {
    color: #a3a3a3;

    opacity: 1;
}

input:hover {
    border-color: #d8d1ca;
}

input:focus {
    border-color: var(--auth-border-focus);

    background: #fff;

    box-shadow:
        0 0 0 3px rgba(168, 107, 50, 0.10);
}


/* =========================================================
   PASSWORD WRAPPERS
========================================================= */

.password-row,
.password-box {
    position: relative;

    width: 100%;
}

.password-row input,
.password-box input {
    padding-right: 78px;
}


/* =========================================================
   PASSWORD TOGGLE
========================================================= */

.toggle-password,
.toggle {
    position: absolute;

    top: 7px;
    right: 8px;

    width: auto;

    height: 34px;

    margin: 0;

    padding: 0 10px;

    border: 0;

    border-radius: 7px;

    background: #f5f3f1;

    color: #666;

    font-family: var(--auth-sans);

    font-size: 11px;

    line-height: 34px;

    font-weight: 700;

    cursor: pointer;

    transition:
        background-color .2s ease,
        color .2s ease;
}

.toggle-password:hover,
.toggle:hover {
    background: #eee9e4;

    color: var(--auth-dark);
}


/* =========================================================
   FORGOT PASSWORD
========================================================= */

.forgot {
    display: block;

    width: fit-content;

    margin:
        -5px
        0
        20px
        auto;

    color: var(--auth-gold);

    font-size: 11px;

    line-height: 1.4;

    font-weight: 700;

    text-decoration: none;

    transition: color .2s ease;
}

.forgot:hover {
    color: var(--auth-gold-dark);

    text-decoration: underline;
}


/* =========================================================
   PRIMARY SUBMIT BUTTON
========================================================= */

.submit,
.card > button,
form > button:not(.toggle),
form > .submit {
    width: 100%;

    min-height: 49px;

    margin: 5px 0 0;

    padding: 0 18px;

    border: 0;

    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            #202020,
            #111111
        );

    color: #fff;

    font-family: var(--auth-sans);

    font-size: 13px;

    line-height: 1;

    font-weight: 800;

    cursor: pointer;

    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.08);

    transition:
        transform .2s ease,
        box-shadow .2s ease,
        background .2s ease;
}

.submit:hover,
.card > button:hover,
form > button:not(.toggle):hover,
form > .submit:hover {
    transform: translateY(-1px);

    background:
        linear-gradient(
            135deg,
            #111111,
            #050505
        );

    box-shadow:
        0 12px 28px rgba(0, 0, 0, 0.14);
}

.submit:active,
.card > button:active,
form > button:not(.toggle):active,
form > .submit:active {
    transform: translateY(0);

    box-shadow:
        0 5px 14px rgba(0, 0, 0, 0.10);
}

.submit:focus-visible,
.card > button:focus-visible,
form > button:not(.toggle):focus-visible {
    outline: 3px solid rgba(168, 107, 50, .20);

    outline-offset: 2px;
}


/* =========================================================
   SECONDARY LINKS AREA
========================================================= */

.bottom,
.links {
    margin-top: 22px;

    padding-top: 19px;

    border-top: 1px solid var(--auth-border);

    color: var(--auth-muted);

    text-align: center;

    font-size: 12px;

    line-height: 1.6;
}

.bottom a,
.links a {
    color: var(--auth-gold);

    font-weight: 800;

    text-decoration: none;

    transition: color .2s ease;
}

.bottom a:hover,
.links a:hover {
    color: var(--auth-gold-dark);

    text-decoration: underline;
}


/* =========================================================
   BACK LINK
========================================================= */

.back {
    display: block;

    width: fit-content;

    margin: 16px auto 0;

    color: #777;

    font-size: 11px;

    line-height: 1.5;

    text-decoration: none;

    transition:
        color .2s ease,
        transform .2s ease;
}

.back:hover {
    color: var(--auth-dark);

    transform: translateX(-2px);
}


/* =========================================================
   OPTIONAL SMALL TEXT
========================================================= */

.optional {
    color: #999;

    font-weight: 500;
}


/* =========================================================
   DISABLED
========================================================= */

button:disabled,
input:disabled {
    cursor: not-allowed;

    opacity: .65;
}


/* =========================================================
   AUTOFILL
========================================================= */

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--auth-text);

    box-shadow:
        0 0 0 1000px #fff inset,
        0 0 0 3px rgba(168, 107, 50, 0.08);

    transition:
        background-color 9999s ease-in-out 0s;
}

