:root {
    --auth-ink: #183c33;
    --auth-muted: #71847c;
    --auth-rose: #34745f;
    --auth-rose-dark: #245f4d;
    --auth-sage: #54816d;
    --auth-line: #dfe8e2;
    --auth-paper: #fbfdfb;
}

body.auth-page {
    min-height: 100vh;
    min-height: 100svh;
    margin: 0;
    color: var(--auth-ink);
    background: #edf3ef;
    font-family: 'DM Sans', sans-serif;
}

.auth-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(420px, 0.82fr);
    min-height: 100vh;
    min-height: 100svh;
}

.auth-story {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
    padding: clamp(2rem, 5vw, 5rem);
    overflow: hidden;
    color: #fff;
    background-color: #183c33;
    background-image:
        radial-gradient(circle at 78% 24%, rgb(180 220 195 / 14%), transparent 34%),
        linear-gradient(145deg, #245f4d, #183c33 72%);
}

.auth-story-brand img,
.auth-mobile-brand img {
    display: block;
    width: auto;
    height: 42px;
    object-fit: contain;
}

.auth-story-brand img {
    filter: brightness(0) invert(1);
}

.auth-mobile-brand img {
    filter: brightness(0) saturate(100%) invert(24%) sepia(21%) saturate(1046%) hue-rotate(108deg) brightness(91%) contrast(88%);
}

.auth-story-copy {
    position: relative;
    z-index: 1;
    max-width: 620px;
    margin-top: auto;
    padding-top: 5rem;
}

.auth-story-copy .eyebrow {
    margin: 0 0 1rem;
    color: #c8e2d4;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.auth-story-copy h1 {
    margin: 0 0 1rem;
    color: #fff;
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(3rem, 5vw, 5rem);
    font-weight: 600;
    line-height: 0.98;
}

.auth-story-copy p:last-child {
    max-width: 480px;
    margin: 0;
    color: rgb(255 255 255 / 84%);
    font-size: 1rem;
}

.auth-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    padding: 3rem clamp(1.25rem, 4vw, 4rem);
    background: var(--auth-paper);
}

.auth-panel-inner {
    width: min(100%, 440px);
}

.auth-mobile-brand {
    display: none;
    width: fit-content;
    margin: 0 auto 2rem;
}

.auth-card {
    width: 100%;
    padding: 0;
    overflow: visible;
    color: var(--auth-ink);
    background: transparent;
}

.auth-heading {
    margin-bottom: 1.75rem;
}

.auth-heading .eyebrow {
    margin: 0 0 0.4rem;
    color: var(--auth-rose-dark);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.auth-heading h2 {
    margin: 0;
    color: var(--auth-ink);
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2.7rem;
    font-weight: 600;
    line-height: 1;
}

.auth-heading p {
    margin: 0.65rem 0 0;
    color: var(--auth-muted);
    font-size: 0.93rem;
}

.auth-page .auth-card {
    max-width: 440px;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    backdrop-filter: none;
    animation: none;
}

.auth-page .auth-card h2 {
    color: var(--auth-ink);
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-weight: 600;
}

.auth-page .auth-card > .mb-6.text-center p {
    color: var(--auth-muted);
}

.auth-page .auth-tabs {
    gap: 0.35rem;
    padding: 0.3rem;
    border: 1px solid var(--auth-line);
    border-radius: 6px;
    background: #edf4ef;
}

.auth-page .auth-tabs .tab {
    min-height: 42px;
    border-radius: 4px;
    color: var(--auth-muted);
    font: inherit;
    font-weight: 700;
}

.auth-page .auth-tabs .tab.active {
    color: #fff;
    background: var(--auth-rose-dark);
    box-shadow: none;
}

.auth-page .auth-form h2 {
    margin: 0 0 1.25rem;
    color: var(--auth-ink);
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 2.5rem;
    font-weight: 600;
    line-height: 1;
}

.auth-page .form-group {
    margin-bottom: 1rem;
}

.auth-page .form-group label {
    color: #3f5b50;
    font-size: 0.88rem;
}

.auth-page .form-group input {
    min-height: 46px;
    padding: 0.65rem 0.8rem;
    border: 1px solid #d2ded6;
    border-radius: 6px;
    color: var(--auth-ink);
    background: #fff;
    font: inherit;
}

.auth-page .form-group input:focus {
    border-color: var(--auth-rose);
    outline: 3px solid rgb(52 116 95 / 18%);
    outline-offset: 1px;
    box-shadow: none;
}

.auth-page .auth-btn.primary {
    min-height: 46px;
    padding: 0.65rem 1rem;
    border: 1px solid var(--auth-rose-dark);
    border-radius: 6px;
    color: #fff;
    background: var(--auth-rose-dark);
    box-shadow: none;
    font: inherit;
    font-weight: 700;
}

.auth-page .auth-btn.primary:hover {
    transform: none;
    background: #1c503f;
    box-shadow: none;
}

.auth-page .google-btn {
    min-height: 46px;
    padding: 0.65rem 1rem;
    border-radius: 6px;
    color: var(--auth-ink);
    background: #fff;
}

.auth-page .google-btn:hover {
    border-color: var(--auth-rose);
    background: #f3f7f4;
}

.auth-page .auth-card a {
    color: var(--auth-rose-dark);
}

.auth-page .auth-card a:hover {
    color: var(--auth-rose);
}

.auth-card form>div+div {
    margin-top: 1rem;
}

.auth-card label,
.auth-card label span {
    color: #3f5b50;
    font-size: 0.88rem;
    font-weight: 600;
}

.auth-card input:not([type="checkbox"]):not([type="hidden"]) {
    width: 100%;
    min-height: 46px;
    padding: 0.65rem 0.8rem;
    border: 1px solid #d2ded6;
    border-radius: 6px;
    color: var(--auth-ink);
    background: #fff;
    font: inherit;
}

.auth-card input:focus {
    border-color: var(--auth-rose);
    outline: 3px solid rgb(52 116 95 / 18%);
    outline-offset: 1px;
    --tw-ring-color: transparent;
}

.auth-card input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border-color: #c3d3c9;
    accent-color: var(--auth-rose-dark);
}

.auth-card button[type="button"] {
    min-width: 44px;
    min-height: 44px;
    color: var(--auth-muted);
}

.auth-card button[type="button"]:hover {
    color: var(--auth-rose-dark);
}

.auth-card button[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0.65rem 1.2rem;
    border: 1px solid var(--auth-rose-dark);
    border-radius: 6px;
    color: #fff;
    background: var(--auth-rose-dark);
    font: inherit;
    font-weight: 700;
}

.auth-card button[type="submit"]:hover {
    background: #1c503f;
}

.auth-card form a {
    color: var(--auth-rose-dark);
    font-size: 0.85rem;
    text-decoration-color: #9abdab;
    text-underline-offset: 3px;
}

.auth-card form a:hover {
    color: var(--auth-rose);
}

.auth-card [role="status"],
.auth-card .text-green-600 {
    color: var(--auth-sage) !important;
}

.auth-card .bg-blue-50 {
    border-color: #d4e6da;
    background: #edf5f0;
}

.auth-card .text-blue-500 {
    color: var(--auth-sage);
}

.auth-card .text-blue-700,
.auth-card .text-blue-800 {
    color: var(--auth-ink);
}

.auth-back-home {
    margin: 1.5rem 0 0;
    color: var(--auth-muted);
    font-size: 0.85rem;
    text-align: center;
}

.auth-back-home a {
    color: var(--auth-rose-dark);
    font-weight: 700;
    text-decoration: none;
}

.auth-back-home a:hover {
    text-decoration: underline;
    text-underline-offset: 3px;
}

@media (max-width: 820px) {
    .auth-layout {
        display: block;
        min-height: 100vh;
        min-height: 100svh;
        padding: 1.25rem;
        background: #edf3ef;
    }

    .auth-story {
        display: none;
    }

    .auth-panel {
        min-height: calc(100vh - 2.5rem);
        min-height: calc(100svh - 2.5rem);
        padding: 2rem 1.25rem;
        border: 1px solid var(--auth-line);
        border-radius: 14px;
        box-shadow: 0 16px 40px rgb(24 60 51 / 7%);
    }

    .auth-mobile-brand {
        display: block;
    }
}

@media (max-width: 480px) {
    .auth-layout {
        padding: 0;
        background: var(--auth-paper);
    }

    .auth-panel {
        min-height: 100vh;
        min-height: 100svh;
        padding: clamp(1.5rem, 7vh, 2.5rem) 1.25rem;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .auth-panel-inner {
        max-width: 440px;
        margin: auto;
    }

    .auth-mobile-brand {
        margin-bottom: 1.75rem;
    }

    .auth-heading h2 {
        font-size: 2.35rem;
    }

    .auth-page .auth-form h2 {
        margin-bottom: 1.1rem;
        font-size: 2.25rem;
    }

    .auth-page .form-group input,
    .auth-card input:not([type="checkbox"]):not([type="hidden"]) {
        min-height: 48px;
    }

    .auth-page .auth-btn.primary,
    .auth-card button[type="submit"],
    .auth-page .google-btn {
        min-height: 48px;
    }

    .auth-card form>.flex.items-center.justify-between {
        align-items: stretch;
        flex-direction: column;
        gap: 0.9rem;
    }

    .auth-card form>.flex.items-center.justify-between>* {
        margin-left: 0;
    }

    .auth-card form>.flex.items-center.justify-between button[type="submit"] {
        width: 100%;
    }

    .auth-page .auth-back-home {
        margin-top: 1rem;
        padding: 0.5rem;
    }
}

@media (max-width: 360px) {
    .auth-panel {
        padding-right: 1rem;
        padding-left: 1rem;
    }

    .auth-page .auth-tabs .tab {
        min-height: 44px;
    }

    .auth-page .auth-form h2 {
        font-size: 2rem;
    }
}

@media (prefers-reduced-motion: reduce) {

    .auth-page *,
    .auth-page *::before,
    .auth-page *::after {
        transition-duration: 0.01ms !important;
    }
}