
    :root {
        --ink: #191447;
        --muted: #777396;
        --purple: #5b39e3;
        --violet: #844efa;
        --edge: #dcd7f4;
    }

    * {
        box-sizing: border-box;
    }

    html, body {
        margin: 0;
        min-height: 100%;
    }

    body {
        font-family: 'Quicksand',Arial,sans-serif;
        color: var(--ink);
        background: #e9dfff;
        background-image: radial-gradient(ellipse at 6% 0%,rgba(154,105,255,.5),transparent 38%),radial-gradient(ellipse at 94% 96%,rgba(140,94,255,.45),transparent 34%),linear-gradient(135deg,#efe9ff 0%,#ede9ff 55%,#d7cbff 100%);
    }

    .auth-page {
        min-height: 100vh;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 38px 28px;
        position: relative;
        overflow: hidden;
        isolation: isolate;
    }

        .auth-page:before, .auth-page:after {
            content: "";
            position: absolute;
            z-index: -1;
            border: 2px solid rgba(255,255,255,.45);
            border-radius: 50%;
            pointer-events: none;
        }

        .auth-page:before {
            width: 660px;
            height: 660px;
            left: -320px;
            top: -490px;
        }

        .auth-page:after {
            width: 760px;
            height: 760px;
            right: -440px;
            bottom: -570px;
        }

    .auth-shell {
        width: min(1160px,100%);
        min-height: 650px;
        display: grid;
        grid-template-columns: 1fr 1fr;
        align-items: stretch;
        padding: 48px 54px;
        gap: 50px;
        border: 1px solid rgba(255,255,255,.86);
        border-radius: 42px;
        background: rgba(255,255,255,.68);
        box-shadow: 0 28px 80px rgba(73,47,146,.18),inset 0 1px 0 rgba(255,255,255,.8);
        backdrop-filter: blur(22px);
        -webkit-backdrop-filter: blur(22px);
    }

    .auth-art {
        display: flex;
        justify-content: center;
        align-items: center;
        flex-direction: column;
        position: relative;
        padding: 22px 10px 10px;
        border-right: 1px solid rgba(114,92,204,.14);
    }

    .art-glow {
        position: absolute;
        z-index: 0;
        width: 88%;
        max-width: 470px;
        aspect-ratio: 1;
        top: 20%;
        border-radius: 50%;
        background: radial-gradient(circle,rgba(156,125,255,.23),rgba(189,171,255,.1) 65%,transparent 71%);
    }

    .store-svg {
        position: relative;
        z-index: 1;
        width: min(100%,480px);
        height: auto;
        filter: drop-shadow(0 14px 16px rgba(94,61,186,.11));
    }

    .art-subtitle {
        position: relative;
        z-index: 1;
        text-align: center;
        margin-top: 4px;
        max-width: 400px;
    }

        .art-subtitle h2 {
            font-size: 27px;
            font-weight: 800;
            letter-spacing: -.7px;
            margin: 0 0 10px;
            color: #4431ab;
        }

        .art-subtitle p {
            font-size: 15px;
            line-height: 1.7;
            color: #777099;
            margin: 0;
        }

    .auth-panel {
        display: flex;
        flex-direction: column;
        justify-content: center;
        min-width: 0;
        padding: 16px 8px 20px 0;
    }

    .brand {
        display: flex;
        align-items: center;
        gap: 16px;
        margin-bottom: 44px;
    }

    .brand-icon {
        width: 66px;
        height: 66px;
        border-radius: 20px;
        background: linear-gradient(140deg,#9255ff 0%,#5033df 95%);
        box-shadow: 0 12px 22px rgba(86,53,222,.2);
        display: grid;
        place-items: center;
        flex-shrink: 0;
    }

        .brand-icon svg {
            width: 36px;
            height: 36px;
        }

    .brand-name {
        margin: 0;
        font-size: 31px;
        line-height: 1.05;
        letter-spacing: -1px;
        font-weight: 800;
    }

    .brand-caption {
        display: block;
        font-size: 14px;
        color: #7e789d;
        margin-top: 7px;
        font-weight: 600;
    }

    .intro {
        margin-bottom: 31px;
    }

        .intro h1 {
            font-size: 39px;
            font-weight: 800;
            letter-spacing: -1.35px;
            margin: 0 0 6px;
        }

        .intro p {
            font-size: 16px;
            margin: 0;
            color: var(--muted);
            font-weight: 600;
        }

    .field {
        margin-bottom: 21px;
    }

        .field label {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 10px;
            font-size: 14px;
            font-weight: 800;
        }

            .field label svg {
                width: 17px;
                height: 17px;
                color: var(--purple);
            }

    .input-wrap {
        display: flex;
        align-items: center;
        height: 57px;
        border: 1.5px solid var(--edge);
        border-radius: 14px;
        background: rgba(251,250,255,.82);
        transition: border-color .2s,box-shadow .2s;
        overflow: hidden;
    }

        .input-wrap:focus-within {
            border-color: #7a56eb;
            box-shadow: 0 0 0 4px rgba(112,79,236,.12);
        }

        .input-wrap input {
            min-width: 0;
            flex: 1;
            width: 100%;
            border: 0;
            outline: 0;
            background: transparent;
            color: var(--ink);
            font: 700 15px 'Quicksand',Arial,sans-serif;
            padding: 0 18px;
        }

            .input-wrap input::placeholder {
                color: #a39dbb;
                font-weight: 500;
            }

    .show-password {
        border: 0;
        border-left: 1px solid #e2def4;
        background: rgba(237,234,249,.85);
        height: 100%;
        width: 54px;
        cursor: pointer;
        display: grid;
        place-items: center;
        color: #777190;
    }

        .show-password:focus-visible, .submit-btn:focus-visible {
            outline: 3px solid #ab95ff;
            outline-offset: 3px;
        }

        .show-password svg {
            width: 21px;
            height: 21px;
        }

    .submit-btn {
        width: 100%;
        height: 59px;
        border: 0;
        border-radius: 14px;
        background: linear-gradient(110deg,#6650f0,#823ef2);
        color: #fff;
        box-shadow: 0 14px 26px rgba(101,68,227,.25);
        font: 800 17px 'Quicksand',Arial,sans-serif;
        cursor: pointer;
        margin-top: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
        transition: transform .2s,box-shadow .2s;
    }

        .submit-btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 18px 28px rgba(101,68,227,.3);
        }

        .submit-btn:disabled {
            cursor: wait;
            opacity: .7;
            transform: none;
        }

        .submit-btn svg {
            width: 20px;
            height: 20px;
        }

    .error {
        display: none;
        border: 1px solid #f3b4bd;
        border-radius: 12px;
        padding: 12px 15px;
        background: #fff2f3;
        color: #9c263b;
        font-size: 13px;
        font-weight: 700;
        margin-top: 18px;
    }

        .error.show {
            display: block;
        }

    .foot {
        border-top: 1px solid #dedaf0;
        margin-top: 39px;
        padding-top: 23px;
        text-align: center;
    }

        .foot span {
            display: inline-flex;
            gap: 9px;
            align-items: center;
            border-radius: 30px;
            padding: 10px 17px;
            background: rgba(112,77,225,.09);
            color: #674cd9;
            font-size: 12px;
            font-weight: 800;
        }

        .foot svg {
            width: 15px;
            height: 15px;
        }

    @media (max-width:980px) {
        .auth-shell {
            gap: 25px;
            padding: 34px;
        }

        .brand-name {
            font-size: 26px;
        }

        .intro h1 {
            font-size: 33px;
        }

        .auth-art {
            padding: 12px 8px;
            border-right: 1px solid rgba(114,92,204,.14);
        }
    }

    @media (max-width:730px) {
        .auth-page {
            padding: 20px 14px;
        }

        .auth-shell {
            grid-template-columns: 1fr;
            border-radius: 28px;
            min-height: 0;
            padding: 25px 24px;
            max-width: 500px;
        }

        .auth-art {
            display: none;
        }

        .auth-panel {
            padding: 7px 0 5px;
        }

        .brand {
            margin-bottom: 31px;
        }

        .brand-icon {
            width: 56px;
            height: 56px;
            border-radius: 16px;
        }

        .intro {
            margin-bottom: 25px;
        }

            .intro h1 {
                font-size: 34px;
            }

        .foot {
            margin-top: 27px;
        }
    }

    @media (prefers-reduced-motion:reduce) {
        .submit-btn, .input-wrap {
            transition: none;
        }
    }

    /* Desktop: keep the original spacious composition, but fit the viewport. */
    @media (min-width: 731px) and (min-height: 601px) {
        html, body {
            height: 100%;
        }

        .auth-page {
            height: 100vh;
            height: 100dvh;
            min-height: 0;
            padding: 16px 24px;
        }

        .auth-shell {
            width: min(1060px, 100%);
            height: min(620px, calc(100vh - 32px));
            height: min(620px, calc(100dvh - 32px));
            min-height: 0;
            max-height: calc(100dvh - 32px);
            padding: clamp(18px, 3.4dvh, 34px) clamp(24px, 3.2vw, 43px);
            gap: clamp(22px, 3vw, 40px);
        }

        .auth-art {
            padding: 5px 12px;
            min-height: 0;
        }

        .store-svg {
            width: min(100%, 390px);
            max-height: min(49dvh, 365px);
            flex-shrink: 1;
        }

        .art-subtitle {
            margin-top: 8px;
        }

            .art-subtitle h2 {
                font-size: clamp(20px, 2.1vw, 25px);
                margin-bottom: 6px;
            }

            .art-subtitle p {
                font-size: 13px;
                line-height: 1.5;
            }

        .auth-panel {
            padding: 6px 6px 6px 0;
        }

        .brand {
            margin-bottom: clamp(15px, 2.5dvh, 26px);
        }

        .brand-icon {
            width: 56px;
            height: 56px;
            border-radius: 17px;
        }

        .brand-name {
            font-size: 27px;
        }

        .brand-caption {
            font-size: 12px;
            margin-top: 4px;
        }

        .intro {
            margin-bottom: clamp(13px, 2.5dvh, 23px);
        }

            .intro h1 {
                font-size: 34px;
            }

            .intro p {
                font-size: 14px;
            }

        .field {
            margin-bottom: clamp(10px, 1.7dvh, 16px);
        }

            .field label {
                margin-bottom: 7px;
            }

        .input-wrap {
            height: clamp(45px, 6.3dvh, 53px);
        }

        .submit-btn {
            height: clamp(46px, 6.5dvh, 54px);
            margin-top: 5px;
        }

        .foot {
            margin-top: clamp(12px, 2.2dvh, 20px);
            padding-top: 12px;
        }

            .foot span {
                padding: 7px 14px;
            }

        .error {
            margin-top: 8px;
            padding: 8px 12px;
        }
    }
    /* Small laptop windows: trim gaps before allowing content to overflow. */
    @media (min-width: 731px) and (min-height: 601px) and (max-height: 700px) {
        .auth-shell {
            padding-top: 16px;
            padding-bottom: 16px;
        }

        .store-svg {
            max-height: 44dvh;
        }

        .brand {
            margin-bottom: 12px;
        }

        .brand-icon {
            width: 48px;
            height: 48px;
        }

        .intro {
            margin-bottom: 11px;
        }

        .field {
            margin-bottom: 9px;
        }

        .input-wrap {
            height: 44px;
        }

        .submit-btn {
            height: 46px;
        }

        .foot {
            margin-top: 9px;
            padding-top: 8px;
        }
    }
    /* Very short windows and phones must remain accessible; no clipping forms. */
    @media (min-width: 731px) and (max-height: 600px) {
        .auth-page {
            padding: 12px 16px;
        }

        .auth-shell {
            min-height: 0;
            padding: 20px 24px;
            gap: 25px;
        }

        .store-svg {
            max-height: 42vh;
        }

        .brand {
            margin-bottom: 13px;
        }

        .intro {
            margin-bottom: 12px;
        }

        .field {
            margin-bottom: 9px;
        }

        .input-wrap {
            height: 43px;
        }

        .submit-btn {
            height: 45px;
        }

        .foot {
            margin-top: 10px;
            padding-top: 9px;
        }
    }

    /* Server-generated five-character security verification. */
    .captcha-field {
        margin: 2px 0 11px;
    }

        .captcha-field > label {
            display: block;
            font-size: 13px;
            font-weight: 800;
            margin-bottom: 7px;
        }

        .captcha-field .required-mark {
            color: #df3967;
        }

    .captcha-row {
        display: grid;
        grid-template-columns: 152px minmax(0,1fr) 42px;
        gap: 8px;
        align-items: center;
    }

    .captcha-image {
        width: 152px;
        height: 47px;
        border: 1px solid #d7cef5;
        border-radius: 11px;
        background: #f9f7ff;
        display: block;
    }

    .captcha-entry {
        width: 100%;
        min-width: 0;
        height: 47px;
        border: 1.5px solid var(--edge);
        border-radius: 11px;
        background: rgba(251,250,255,.85);
        padding: 0 12px;
        font: 700 14px 'Quicksand',Arial,sans-serif;
        color: var(--ink);
        outline: none;
        letter-spacing: 1px;
        text-transform: uppercase;
    }

        .captcha-entry:focus {
            border-color: #7a56eb;
            box-shadow: 0 0 0 3px rgba(112,79,236,.12);
        }

    .captcha-refresh {
        width: 42px;
        height: 47px;
        border: 1px solid #d7cef5;
        background: rgba(255,255,255,.78);
        color: #6545d5;
        border-radius: 11px;
        display: grid;
        place-items: center;
        cursor: pointer;
    }

        .captcha-refresh:hover {
            background: #f1eaff;
        }

        .captcha-refresh:focus-visible {
            outline: 3px solid #ab95ff;
            outline-offset: 2px;
        }

        .captcha-refresh svg {
            width: 19px;
            height: 19px;
        }

    .captcha-help {
        font-size: 11px;
        line-height: 1.3;
        color: var(--muted);
        margin: 5px 0 0;
    }

    @media (min-width:731px) and (max-height:760px) {
        .captcha-row {
            grid-template-columns: 132px minmax(0,1fr) 38px;
            gap: 7px;
        }

        .captcha-image {
            width: 132px;
            height: 40px;
        }

        .captcha-entry, .captcha-refresh {
            height: 40px;
        }

        .captcha-refresh {
            width: 38px;
        }

        .captcha-field {
            margin-bottom: 8px;
        }

            .captcha-field > label {
                margin-bottom: 5px;
            }

        .captcha-help {
            font-size: 10px;
            margin-top: 3px;
        }
    }

    @media (min-width:731px) and (max-height:700px) {
        .brand {
            margin-bottom: 8px;
        }

        .intro {
            margin-bottom: 8px;
        }

        .field {
            margin-bottom: 7px;
        }

        .foot {
            margin-top: 7px;
            padding-top: 6px;
        }

        .captcha-field {
            margin-bottom: 6px;
        }
    }

    @media (max-width:420px) {
        .captcha-row {
            grid-template-columns: 115px minmax(0,1fr) 38px;
            gap: 6px;
        }

        .captcha-image {
            width: 115px;
            height: 43px;
        }

        .captcha-entry, .captcha-refresh {
            height: 43px;
        }

        .captcha-refresh {
            width: 38px;
        }
    }

    /* =========================================================
       FLAT LOGIN DESIGN — screenshot-inspired, no glass/card
       Placed last so it overrides the older glass styles above.
       ========================================================= */
    html, body {
        width: 100%;
        background: #eeeff3;
    }

    body {
        background: #eeeff3;
        background-image: none;
    }

    .auth-page {
        min-height: 100vh;
        min-height: 100dvh;
        padding: 14px 28px;
        background: transparent;
        overflow-x: hidden;
        overflow-y: visible;
    }

    /* Remove decorative rings, background card and divider. */
    .auth-page::before,
    .auth-page::after {
        content: none;
        display: none;
    }

    .auth-shell {
        width: min(1130px, 100%);
        min-height: 0;
        height: auto;
        max-height: none;
        grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr);
        align-items: center;
        gap: clamp(32px, 6vw, 90px);
        padding: 10px 0;
        border: 0;
        border-radius: 0;
        background: transparent;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .auth-art {
        padding: 4px 8px;
        border: 0;
        background: transparent;
        min-width: 0;
    }

    .art-glow {
        display: none;
    }

    .store-svg {
        width: min(100%, 420px);
        max-height: min(48dvh, 390px);
        height: auto;
        filter: none;
        overflow: visible;
    }

    .art-subtitle {
        margin-top: 12px;
    }

    .art-subtitle h2 {
        color: #4431ab;
        font-size: clamp(21px, 2vw, 26px);
        margin-bottom: 7px;
    }

    .art-subtitle p {
        color: #8a8d9f;
        font-size: 14px;
        line-height: 1.55;
    }

    .auth-panel {
        background: transparent;
        border: 0;
        box-shadow: none;
        padding: 8px 0;
        width: 100%;
        max-width: 440px;
        justify-self: center;
    }

    .brand {
        margin-bottom: 25px;
    }

    .intro {
        margin-bottom: 22px;
    }

    .field {
        margin-bottom: 15px;
    }

    .input-wrap {
        height: 50px;
        background: #e7ecf8;
        border-color: #cfd6e7;
    }

    .input-wrap input {
        background: transparent;
    }

    .show-password {
        background: #e1e6ed;
        border-left-color: #ccd3df;
    }

    .captcha-entry {
        background: #e7ecf8;
        border-color: #cfd6e7;
    }

    .captcha-image {
        background: #fafaff;
    }

    .captcha-refresh {
        background: #e9e9f0;
    }

    .submit-btn {
        height: 52px;
        margin-top: 8px;
    }

    .foot {
        margin-top: 23px;
        padding-top: 16px;
        border-top: 1px solid #d2d5de;
    }

    /* Desktop: fit inside the visible window, not a forced tall card. */
    @media (min-width: 731px) and (min-height: 601px) {
        .auth-page {
            height: 100vh;
            height: 100dvh;
            min-height: 0;
            padding: 12px 28px;
        }

        .auth-shell {
            width: min(1130px, 100%);
            height: min(620px, calc(100dvh - 24px));
            min-height: 0;
            max-height: calc(100dvh - 24px);
            padding: 8px 0;
            gap: clamp(32px, 6vw, 90px);
        }

        .auth-art { padding: 4px 8px; }
        .store-svg { width: min(100%, 420px); max-height: min(47dvh, 370px); }
        .auth-panel { padding: 8px 0; }
        .brand { margin-bottom: clamp(12px, 2.9dvh, 25px); }
        .intro { margin-bottom: clamp(11px, 2.5dvh, 22px); }
        .field { margin-bottom: clamp(9px, 1.8dvh, 15px); }
        .input-wrap { height: clamp(42px, 6dvh, 50px); }
        .submit-btn { height: clamp(45px, 6.6dvh, 52px); }
        .foot { margin-top: clamp(9px, 2.6dvh, 23px); padding-top: 12px; }
    }

    @media (min-width: 731px) and (max-height: 760px) {
        .store-svg { max-height: 40dvh; }
        .art-subtitle { margin-top: 7px; }
        .art-subtitle h2 { font-size: 21px; }
        .art-subtitle p { font-size: 12px; }
        .brand { margin-bottom: 12px; }
        .intro { margin-bottom: 11px; }
        .field { margin-bottom: 9px; }
        .captcha-field { margin-bottom: 7px; }
        .foot { margin-top: 10px; padding-top: 9px; }
    }

    @media (min-width: 731px) and (max-height: 600px) {
        .auth-page { height: auto; min-height: 100dvh; padding: 12px 20px; }
        .auth-shell { height: auto; max-height: none; padding: 12px 0; gap: 26px; }
        .store-svg { max-height: 38dvh; }
    }

    @media (max-width: 730px) {
        .auth-page { padding: 22px 16px; overflow-y: visible; }
        .auth-shell {
            width: 100%;
            max-width: 440px;
            height: auto;
            min-height: 0;
            max-height: none;
            grid-template-columns: 1fr;
            padding: 0;
            gap: 0;
        }
        .auth-art { display: none; }
        .auth-panel { padding: 10px 0; }
        .brand { margin-bottom: 24px; }
        .intro { margin-bottom: 20px; }
        .foot { margin-top: 20px; }
    }
