:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #dbeafe;
    --accent: #06b6d4;

    --dark: #08111f;
    --dark-soft: #111e31;
    --dark-card: #152338;

    --background: #f4f7fb;
    --surface: #ffffff;

    --text: #0f172a;
    --text-soft: #64748b;
    --text-light: #94a3b8;

    --border: #e2e8f0;
    --danger: #dc2626;
    --danger-background: #fff1f2;

    --shadow:
        0 30px 80px rgba(15, 23, 42, 0.12);

    --font-main:
        "Inter",
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    --font-display:
        "Manrope",
        "Inter",
        sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    min-height: 100%;
    background: var(--background);
}

body {
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden;
    color: var(--text);
    background: var(--background);
    font-family: var(--font-main);
    -webkit-font-smoothing: antialiased;
}

button,
input,
a {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

a {
    color: inherit;
    text-decoration: none;
}

.auth-shell {
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    grid-template-columns:
        minmax(420px, 1.02fr)
        minmax(500px, 0.98fr);
}

.auth-showcase {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    overflow: hidden;
    color: #ffffff;
    background:
        radial-gradient(
            circle at 18% 15%,
            rgba(37, 99, 235, 0.3),
            transparent 35%
        ),
        radial-gradient(
            circle at 88% 78%,
            rgba(6, 182, 212, 0.2),
            transparent 32%
        ),
        linear-gradient(
            145deg,
            #07101d 0%,
            #0c1829 45%,
            #102139 100%
        );
}

.showcase-grid {
    position: absolute;
    inset: 0;
    opacity: 0.15;
    background-image:
        linear-gradient(
            rgba(255, 255, 255, 0.08) 1px,
            transparent 1px
        ),
        linear-gradient(
            90deg,
            rgba(255, 255, 255, 0.08) 1px,
            transparent 1px
        );
    background-size: 48px 48px;
    mask-image:
        linear-gradient(
            to bottom,
            black,
            transparent 92%
        );
}

.showcase-glow {
    position: absolute;
    border-radius: 999px;
    filter: blur(4px);
    pointer-events: none;
}

.showcase-glow-one {
    top: -180px;
    right: -120px;
    width: 520px;
    height: 520px;
    background:
        radial-gradient(
            circle,
            rgba(37, 99, 235, 0.26),
            transparent 68%
        );
    animation: floatGlow 8s ease-in-out infinite;
}

.showcase-glow-two {
    bottom: -230px;
    left: -120px;
    width: 580px;
    height: 580px;
    background:
        radial-gradient(
            circle,
            rgba(6, 182, 212, 0.17),
            transparent 70%
        );
    animation: floatGlow 10s ease-in-out infinite reverse;
}

.showcase-content {
    position: relative;
    z-index: 2;
    width: 100%;
    min-height: 100%;
    padding:
        clamp(34px, 5vw, 70px)
        clamp(34px, 6vw, 90px);

    display: flex;
    flex-direction: column;
}

.brand {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 13px;
}

.brand-symbol {
    position: relative;
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    overflow: hidden;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 17px;
    color: #ffffff;
    background:
        linear-gradient(
            145deg,
            var(--primary),
            var(--accent)
        );
    box-shadow:
        0 15px 34px rgba(37, 99, 235, 0.3);
}

.brand-letter {
    position: relative;
    z-index: 2;
    font-family: var(--font-display);
    font-size: 17px;
    font-weight: 800;
    letter-spacing: -1px;
}

.brand-road {
    position: absolute;
    z-index: 1;
    bottom: 9px;
    width: 38px;
    height: 9px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    transform: rotate(-6deg);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
}

.brand-copy strong {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.8px;
}

.brand-copy small {
    margin-top: 6px;
    color: rgba(255, 255, 255, 0.58);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.7px;
    text-transform: uppercase;
}

.showcase-main {
    width: min(650px, 100%);
    margin: auto 0;
    padding: 70px 0;
}

.eyebrow {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 25px;
    padding: 10px 14px;
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 999px;
    color: #bfdbfe;
    background: rgba(37, 99, 235, 0.1);
    backdrop-filter: blur(12px);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.9px;
    text-transform: uppercase;
}

.eyebrow i {
    color: #67e8f9;
    font-size: 14px;
}

.showcase-main h1 {
    max-width: 620px;
    font-family: var(--font-display);
    font-size: clamp(42px, 5.2vw, 76px);
    line-height: 0.99;
    letter-spacing: -4px;
}

.showcase-main h1 span {
    display: block;
    margin-top: 10px;
    color: transparent;
    background:
        linear-gradient(
            90deg,
            #60a5fa,
            #67e8f9
        );
    background-clip: text;
    -webkit-background-clip: text;
}

.showcase-main > p {
    max-width: 580px;
    margin-top: 25px;
    color: rgba(226, 232, 240, 0.72);
    font-size: clamp(15px, 1.5vw, 18px);
    line-height: 1.8;
}

.feature-list {
    width: min(540px, 100%);
    margin-top: 42px;
    display: grid;
    gap: 14px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 17px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 17px;
    background: rgba(255, 255, 255, 0.045);
    backdrop-filter: blur(12px);
    transition:
        transform 0.25s ease,
        border-color 0.25s ease,
        background 0.25s ease;
}

.feature-item:hover {
    transform: translateX(6px);
    border-color: rgba(96, 165, 250, 0.24);
    background: rgba(255, 255, 255, 0.065);
}

.feature-item > span {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    color: #bfdbfe;
    background: rgba(37, 99, 235, 0.16);
    font-size: 18px;
}

.feature-item div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.feature-item strong {
    font-size: 13px;
    font-weight: 750;
}

.feature-item small {
    color: rgba(203, 213, 225, 0.62);
    font-size: 11px;
    line-height: 1.5;
}

.showcase-footer {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
}

.security-badge {
    display: flex;
    align-items: center;
    gap: 11px;
}

.security-badge > i {
    color: #67e8f9;
    font-size: 22px;
}

.security-badge span {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.security-badge strong {
    font-size: 11px;
    font-weight: 700;
}

.security-badge small,
.version-label {
    color: rgba(203, 213, 225, 0.45);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.auth-form-side {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: grid;
    place-items: center;
    padding: 44px;
    background:
        radial-gradient(
            circle at 95% 5%,
            rgba(37, 99, 235, 0.07),
            transparent 28%
        ),
        var(--background);
}

.auth-card {
    width: min(480px, 100%);
}

.mobile-brand-wrap {
    display: none;
}

.auth-heading {
    display: flex;
    align-items: flex-start;
    gap: 17px;
    margin-bottom: 32px;
}

.auth-heading-icon {
    width: 52px;
    height: 52px;
    flex: 0 0 52px;
    display: grid;
    place-items: center;
    border: 1px solid #dbeafe;
    border-radius: 16px;
    color: var(--primary);
    background: #eff6ff;
    font-size: 21px;
}

.auth-kicker {
    display: block;
    margin-bottom: 7px;
    color: var(--primary);
    font-size: 10px;
    font-weight: 850;
    letter-spacing: 1.5px;
}

.auth-heading h2 {
    font-family: var(--font-display);
    font-size: clamp(28px, 3vw, 36px);
    line-height: 1.1;
    letter-spacing: -1.5px;
}

.auth-heading p {
    margin-top: 9px;
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.65;
}

.alert-error {
    margin-bottom: 22px;
    padding: 15px;
    display: flex;
    gap: 12px;
    border: 1px solid #fecdd3;
    border-radius: 16px;
    color: #881337;
    background: var(--danger-background);
    animation: alertIn 0.35s ease;
}

.alert-error > span {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    color: #ffffff;
    background: #e11d48;
}

.alert-error strong {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
}

.alert-error p {
    font-size: 11px;
    line-height: 1.55;
}

.auth-form {
    display: grid;
    gap: 21px;
}

.form-group {
    display: grid;
    gap: 9px;
}

.form-group label {
    color: #334155;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.25px;
}

.label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.forgot-link {
    color: var(--primary);
    font-size: 10px;
    font-weight: 750;
    transition: color 0.2s ease;
}

.forgot-link:hover {
    color: var(--primary-dark);
}

.input-wrap {
    position: relative;
}

.input-wrap input {
    width: 100%;
    height: 57px;
    padding: 0 52px;
    border: 1px solid var(--border);
    outline: none;
    border-radius: 16px;
    color: var(--text);
    background: var(--surface);
    box-shadow:
        0 7px 24px rgba(15, 23, 42, 0.035);
    font-size: 13px;
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.input-wrap input::placeholder {
    color: #a8b2c1;
}

.input-wrap input:focus {
    border-color: #60a5fa;
    box-shadow:
        0 0 0 4px rgba(37, 99, 235, 0.1),
        0 10px 28px rgba(15, 23, 42, 0.055);
    transform: translateY(-1px);
}

.input-icon {
    position: absolute;
    z-index: 2;
    top: 50%;
    left: 18px;
    transform: translateY(-50%);
    color: #94a3b8;
    pointer-events: none;
    transition: color 0.2s ease;
}

.input-wrap:focus-within .input-icon {
    color: var(--primary);
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 11px;
    width: 38px;
    height: 38px;
    transform: translateY(-50%);
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 11px;
    color: #64748b;
    background: transparent;
    cursor: pointer;
    transition:
        color 0.2s ease,
        background 0.2s ease;
}

.password-toggle:hover {
    color: var(--primary);
    background: #eff6ff;
}

.submit-button {
    position: relative;
    width: 100%;
    min-height: 58px;
    margin-top: 3px;
    overflow: hidden;
    border: 0;
    border-radius: 17px;
    color: #ffffff;
    background:
        linear-gradient(
            115deg,
            var(--primary),
            #2677e9 55%,
            var(--accent)
        );
    box-shadow:
        0 18px 34px rgba(37, 99, 235, 0.25);
    cursor: pointer;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        filter 0.2s ease;
}

.submit-button::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            110deg,
            transparent 20%,
            rgba(255, 255, 255, 0.22) 45%,
            transparent 70%
        );
    transform: translateX(-130%);
    transition: transform 0.6s ease;
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 23px 42px rgba(37, 99, 235, 0.32);
}

.submit-button:hover::before {
    transform: translateX(130%);
}

.submit-button:active {
    transform: translateY(0);
}

.submit-button:disabled {
    cursor: wait;
    filter: saturate(0.7);
}

.button-content,
.button-loading {
    position: relative;
    z-index: 2;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 11px;
    font-weight: 850;
    letter-spacing: 0.65px;
}

.button-content {
    display: flex;
}

.button-loading {
    display: none;
}

.submit-button.is-loading .button-content {
    display: none;
}

.submit-button.is-loading .button-loading {
    display: flex;
}

.spinner {
    width: 17px;
    height: 17px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

.support-box {
    margin-top: 25px;
    padding: 14px 15px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.65);
}

.support-box > span {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--primary);
    background: var(--primary-soft);
}

.support-box div {
    min-width: 0;
}

.support-box strong {
    display: block;
    margin-bottom: 3px;
    font-size: 10px;
}

.support-box p {
    color: var(--text-soft);
    font-size: 9px;
    line-height: 1.5;
}

.support-box > a {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #ffffff;
    background: #16a34a;
    box-shadow:
        0 8px 20px rgba(22, 163, 74, 0.2);
    transition:
        transform 0.2s ease,
        background 0.2s ease;
}

.support-box > a:hover {
    transform: translateY(-2px);
    background: #15803d;
}

.auth-footer {
    margin-top: 27px;
    text-align: center;
}

.auth-footer p {
    color: #94a3b8;
    font-size: 9px;
    line-height: 1.7;
}

.auth-footer strong {
    color: #64748b;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes alertIn {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatGlow {
    0%,
    100% {
        transform: translate3d(0, 0, 0) scale(1);
    }

    50% {
        transform: translate3d(18px, -13px, 0) scale(1.04);
    }
}

@media (max-width: 1050px) {
    .auth-shell {
        grid-template-columns: 0.9fr 1.1fr;
    }

    .showcase-content {
        padding: 45px;
    }

    .showcase-main h1 {
        font-size: 49px;
        letter-spacing: -3px;
    }

    .feature-list {
        margin-top: 32px;
    }
}

@media (max-width: 820px) {
    .auth-shell {
        display: block;
    }

    .auth-showcase {
        display: none;
    }

    .auth-form-side {
        min-height: 100vh;
        min-height: 100dvh;
        display: flex;
        flex-direction: column;
        justify-content: center;
        padding:
            max(26px, env(safe-area-inset-top))
            22px
            max(26px, env(safe-area-inset-bottom));
        background:
            radial-gradient(
                circle at 90% 5%,
                rgba(37, 99, 235, 0.12),
                transparent 30%
            ),
            radial-gradient(
                circle at 5% 90%,
                rgba(6, 182, 212, 0.08),
                transparent 32%
            ),
            var(--background);
    }

    .mobile-brand-wrap {
        width: min(480px, 100%);
        margin: 0 auto 38px;
        display: block;
    }

    .brand-mobile .brand-copy strong {
        color: var(--text);
    }

    .brand-mobile .brand-copy small {
        color: var(--text-light);
    }
}

@media (max-width: 520px) {
    .auth-form-side {
        justify-content: flex-start;
        padding-left: 18px;
        padding-right: 18px;
    }

    .mobile-brand-wrap {
        margin-top: 5px;
        margin-bottom: 34px;
    }

    .brand-symbol {
        width: 49px;
        height: 49px;
        flex-basis: 49px;
        border-radius: 15px;
    }

    .brand-copy strong {
        font-size: 20px;
    }

    .auth-heading {
        gap: 13px;
        margin-bottom: 27px;
    }

    .auth-heading-icon {
        width: 46px;
        height: 46px;
        flex-basis: 46px;
        border-radius: 14px;
        font-size: 18px;
    }

    .auth-heading h2 {
        font-size: 28px;
    }

    .auth-heading p {
        font-size: 12px;
    }

    .input-wrap input {
        height: 56px;
        border-radius: 15px;
        font-size: 16px;
    }

    .submit-button {
        min-height: 57px;
        border-radius: 15px;
    }

    .support-box {
        margin-top: 22px;
    }

    .auth-footer {
        margin-top: 24px;
        padding-bottom: 8px;
    }
}

@media (max-width: 370px) {
    .auth-heading-icon {
        display: none;
    }

    .label-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .forgot-link {
        align-self: flex-end;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}