:root {
    --login-bg: #050711;
    --login-panel: rgba(8, 11, 26, 0.82);
    --login-text: #f7f7fb;
    --login-muted: #929bb1;
    --login-dim: #59647d;
    --login-purple: #a33cff;
    --login-violet: #7048ff;
    --login-blue: #347dff;
    --login-border: rgba(145, 107, 255, 0.25);
    --login-line: rgba(255, 255, 255, 0.075);
}

*, *::before, *::after {
    box-sizing: border-box;
}

html,
body {
    margin: 0 !important;
    min-height: 100% !important;
    background: var(--login-bg) !important;
    color: var(--login-text);
    overflow-x: hidden;
}

body {
    min-height: 100vh !important;
}

button,
input {
    font: inherit;
}

.login-page {
    position: relative;
    isolation: isolate;
    display: grid;
    grid-template-columns: minmax(0, 51%) minmax(0, 49%);
    width: 100%;
    min-height: 100vh;
    overflow: hidden;
    background:
        radial-gradient(circle at 76% 32%, rgba(49, 95, 235, 0.09), transparent 27%),
        radial-gradient(circle at 36% 18%, rgba(132, 42, 235, 0.1), transparent 29%),
        #050711;
}

.login-institutional,
.login-access {
    position: relative;
    min-width: 0;
    min-height: 100vh;
}

.login-institutional {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(40px, 5.5vw, 88px);
    overflow: hidden;
    border-right: 1px solid rgba(133, 74, 236, 0.16);
    background:
        linear-gradient(142deg, rgba(8, 9, 24, 0.94), rgba(5, 7, 18, 0.8)),
        #060815;
}

.login-institutional::after {
    content: "";
    position: absolute;
    inset: auto -12% -20% -12%;
    height: 50%;
    z-index: 1;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 50% 100%, rgba(118, 39, 255, 0.3), transparent 57%),
        linear-gradient(to top, rgba(56, 24, 143, 0.19), transparent);
    filter: blur(12px);
}

.login-grid,
.access-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(147, 124, 220, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(147, 124, 220, 0.045) 1px, transparent 1px);
    background-size: 64px 64px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.78), transparent 92%);
}

.login-grid::before {
    content: "";
    position: absolute;
    inset: 10% 5%;
    background-image: radial-gradient(circle, rgba(179, 103, 255, 0.6) 1px, transparent 1.5px);
    background-size: 96px 92px;
    opacity: 0.28;
}

.login-orb,
.access-orb {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    filter: blur(70px);
}

.login-orb-top {
    width: 420px;
    height: 420px;
    top: -210px;
    right: -140px;
    background: rgba(138, 37, 229, 0.22);
}

.login-orb-bottom {
    width: 390px;
    height: 390px;
    left: -190px;
    bottom: -210px;
    background: rgba(68, 67, 240, 0.16);
}

.digital-sphere {
    position: absolute;
    width: clamp(580px, 46vw, 840px);
    aspect-ratio: 1;
    top: 5%;
    right: clamp(-490px, -25vw, -310px);
    z-index: 0;
    border-radius: 50%;
    opacity: 0.68;
    background:
        repeating-radial-gradient(circle at 40% 46%, transparent 0 21px, rgba(158, 75, 255, 0.065) 22px 23px),
        conic-gradient(from 205deg, transparent 0 12%, rgba(98, 33, 208, 0.2) 18%, rgba(161, 54, 255, 0.55) 22%, rgba(49, 124, 255, 0.36) 30%, transparent 39% 72%, rgba(125, 45, 230, 0.23) 81%, transparent 92%);
    box-shadow:
        inset 20px -20px 70px rgba(103, 42, 230, 0.2),
        inset -18px 14px 80px rgba(29, 75, 210, 0.15),
        0 0 90px rgba(113, 44, 227, 0.13);
    transform: rotate(-9deg);
}

.digital-sphere::before,
.digital-sphere::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(161, 87, 255, 0.23);
}

.digital-sphere::before {
    inset: 8%;
    border-style: dashed;
    box-shadow: 0 0 32px rgba(130, 65, 255, 0.15);
}

.digital-sphere::after {
    inset: 19%;
    border-color: rgba(64, 121, 255, 0.2);
}

.sphere-ring {
    position: absolute;
    inset: 13%;
    border-radius: 50%;
    border: 1px solid transparent;
    border-top-color: rgba(183, 83, 255, 0.82);
    border-right-color: rgba(64, 136, 255, 0.42);
    box-shadow: 0 -4px 20px rgba(151, 55, 255, 0.22);
}

.sphere-ring-two {
    inset: 27% 8%;
    transform: rotate(38deg);
    border-top-color: rgba(104, 59, 244, 0.5);
}

.sphere-ring-three {
    inset: 8% 33%;
    transform: rotate(71deg);
    border-top-color: rgba(64, 135, 255, 0.65);
}

.sphere-axis {
    position: absolute;
    left: 3%;
    right: 4%;
    top: 50%;
    height: 1px;
    background: linear-gradient(90deg, transparent, #8f46ee 20%, #4388ff 78%, transparent);
    transform: rotate(-12deg);
    box-shadow: 0 0 10px rgba(119, 63, 240, 0.8);
}

.sphere-glow {
    position: absolute;
    width: 9px;
    height: 9px;
    top: 49%;
    left: 15%;
    border-radius: 50%;
    background: #ca72ff;
    box-shadow: 0 0 18px 5px rgba(166, 60, 255, 0.74);
}

.digital-wave {
    position: absolute;
    z-index: 1;
    left: -12%;
    right: -10%;
    bottom: -8%;
    height: 31%;
    opacity: 0.58;
    transform: skewY(-5deg);
    background:
        repeating-linear-gradient(8deg, transparent 0 11px, rgba(126, 54, 238, 0.13) 12px 13px),
        radial-gradient(ellipse at 45% 100%, rgba(133, 48, 255, 0.38), transparent 64%);
    mask-image: linear-gradient(to top, #000, transparent 94%);
}

.digital-wave span {
    position: absolute;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #9e4eff;
    box-shadow: 0 0 13px #8139ff;
}

.digital-wave span:nth-child(1) { left: 19%; top: 29%; }
.digital-wave span:nth-child(2) { left: 44%; top: 65%; width: 3px; height: 3px; }
.digital-wave span:nth-child(3) { left: 68%; top: 32%; background: #3c82ff; }
.digital-wave span:nth-child(4) { left: 87%; top: 58%; width: 3px; height: 3px; }

.institutional-shell {
    position: relative;
    z-index: 3;
    width: min(100%, 690px);
    animation: loginLeftIn 480ms cubic-bezier(.2, .8, .2, 1) both;
}

.login-brand {
    display: inline-flex;
    align-items: center;
    min-height: 46px;
    margin-bottom: clamp(48px, 7vh, 80px);
    text-decoration: none;
}

.login-brand img {
    display: block;
    width: clamp(190px, 17vw, 220px);
    max-width: 100%;
    height: auto;
    object-fit: contain;
    object-position: left center;
}

.login-wordmark {
    display: inline-block;
    font-size: clamp(1.7rem, 2.5vw, 2.25rem);
    font-weight: 900;
    letter-spacing: -0.05em;
    background: linear-gradient(120deg, #ca73ff, #8648ff 48%, #4d8cff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.welcome-copy {
    max-width: 590px;
}

.welcome-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    color: #a9a2c1;
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.welcome-eyebrow svg {
    width: 17px;
    fill: #a653ff;
}

.welcome-copy h1 {
    margin: 0;
    color: #f8f8fc;
    font-size: clamp(3.25rem, 5.05vw, 5rem);
    line-height: 0.98;
    letter-spacing: -0.058em;
    font-weight: 900;
    text-wrap: balance;
}

.welcome-copy h1 > span {
    display: block;
    margin-top: 8px;
    background: linear-gradient(106deg, #b943ff 4%, #7a50ff 45%, #4a86ff 91%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.wave-hand {
    display: inline-block;
    font-size: 0.72em;
    color: initial;
    -webkit-text-fill-color: initial;
    filter: drop-shadow(0 0 14px rgba(110, 79, 255, 0.35));
    transform: translateY(-3px);
}

.welcome-copy p {
    max-width: 565px;
    margin: 24px 0 18px;
    color: #b1b7c9;
    font-size: clamp(1rem, 1.25vw, 1.22rem);
    line-height: 1.6;
}

.welcome-accent {
    display: block;
    width: 54px;
    height: 4px;
    margin: 22px 0 32px;
    border-radius: 999px;
    background: linear-gradient(90deg, #b63dff, #4486ff);
    box-shadow: 0 0 17px rgba(120, 66, 255, 0.56);
}

.benefit-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.benefit-card {
    position: relative;
    display: flex;
    min-width: 0;
    min-height: 202px;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px 15px;
    overflow: hidden;
    text-align: center;
    border: 1px solid rgba(137, 91, 229, 0.28);
    border-radius: 17px;
    background:
        linear-gradient(145deg, rgba(87, 43, 162, 0.15), rgba(9, 13, 31, 0.42)),
        rgba(10, 11, 28, 0.55);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
    backdrop-filter: blur(9px);
    transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.benefit-card::after {
    content: "";
    position: absolute;
    width: 85px;
    height: 85px;
    top: -40px;
    left: calc(50% - 42px);
    border-radius: 50%;
    background: rgba(124, 55, 245, 0.16);
    filter: blur(20px);
}

.benefit-card:hover {
    transform: translateY(-4px);
    border-color: rgba(157, 91, 255, 0.49);
    box-shadow: 0 12px 35px rgba(25, 10, 63, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.055);
}

.benefit-icon {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 49px;
    height: 49px;
    margin-bottom: 12px;
    border: 1px solid rgba(164, 75, 255, 0.28);
    border-radius: 50%;
    color: #ae5aff;
    background: radial-gradient(circle at 34% 25%, rgba(182, 73, 255, 0.28), rgba(71, 31, 137, 0.13) 58%, transparent);
    box-shadow: 0 0 20px rgba(130, 51, 255, 0.14);
}

.benefit-icon svg {
    width: 27px;
    height: 27px;
    fill: currentColor;
}

.benefit-card:nth-child(2) .benefit-icon {
    color: #a96aff;
}

.benefit-card:nth-child(2) .benefit-icon svg {
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.benefit-card:nth-child(3) .benefit-icon {
    color: #4f89ff;
    border-color: rgba(63, 125, 255, 0.32);
    background: radial-gradient(circle at 34% 25%, rgba(59, 119, 255, 0.29), rgba(39, 38, 138, 0.14) 58%, transparent);
}

.benefit-card strong {
    color: #f4f4fb;
    font-size: clamp(1.45rem, 1.65vw, 1.8rem);
    line-height: 1.1;
    letter-spacing: -0.035em;
}

.benefit-card b {
    margin-top: 7px;
    color: #b968ff;
    font-size: 0.9rem;
}

.benefit-card:nth-child(3) b {
    color: #668dff;
}

.benefit-card p {
    min-height: 38px;
    margin: 8px 0 0;
    color: #8f98af;
    font-size: 0.76rem;
    line-height: 1.45;
}

.trust-strip {
    display: flex;
    align-items: center;
    gap: 13px;
    width: min(100%, 570px);
    margin-top: 25px;
    padding: 13px 20px;
    color: #9ba3b8;
    font-size: 0.79rem;
    line-height: 1.4;
    border: 1px solid rgba(132, 77, 235, 0.24);
    border-radius: 13px;
    background: linear-gradient(90deg, rgba(79, 35, 147, 0.21), rgba(10, 15, 35, 0.55));
    backdrop-filter: blur(8px);
}

.trust-strip > span {
    display: grid;
    flex: 0 0 auto;
    width: 31px;
    height: 31px;
    place-items: center;
    border-radius: 9px;
    background: rgba(115, 54, 218, 0.17);
}

.trust-strip svg {
    width: 19px;
    fill: #9c5bff;
}

.login-access {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(36px, 4vw, 70px);
    background:
        radial-gradient(circle at 14% 20%, rgba(128, 40, 220, 0.1), transparent 28%),
        linear-gradient(145deg, rgba(7, 10, 22, 0.97), rgba(5, 10, 22, 0.98));
}

.access-grid {
    opacity: 0.32;
    mask-image: radial-gradient(circle at 50% 45%, #000, transparent 78%);
}

.access-orb {
    width: 430px;
    height: 430px;
    top: 11%;
    right: -180px;
    background: rgba(31, 93, 224, 0.1);
}

.access-shell {
    position: relative;
    z-index: 2;
    width: min(100%, 690px);
    animation: loginPanelIn 450ms 80ms cubic-bezier(.2, .8, .2, 1) both;
}

.mobile-brand {
    display: none;
}

.login-panel {
    position: relative;
    width: 100%;
    padding: clamp(38px, 4.4vw, 64px) clamp(34px, 4.7vw, 66px) 40px;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: 22px;
    background:
        linear-gradient(160deg, rgba(18, 19, 43, 0.93), rgba(5, 11, 25, 0.92)) padding-box,
        linear-gradient(135deg, rgba(173, 69, 255, 0.78), rgba(77, 78, 177, 0.31) 47%, rgba(51, 121, 255, 0.42)) border-box;
    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.35),
        0 0 50px rgba(102, 43, 200, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.035);
    backdrop-filter: blur(22px);
}

.login-panel::before {
    content: "";
    position: absolute;
    width: 320px;
    height: 230px;
    top: -150px;
    left: -100px;
    pointer-events: none;
    border-radius: 50%;
    background: rgba(141, 48, 232, 0.18);
    filter: blur(68px);
}

.login-panel::after {
    content: "";
    position: absolute;
    width: 240px;
    height: 240px;
    right: -130px;
    bottom: -160px;
    pointer-events: none;
    border-radius: 50%;
    background: rgba(44, 113, 238, 0.12);
    filter: blur(70px);
}

.panel-heading {
    position: relative;
    z-index: 1;
    text-align: center;
}

.security-icon {
    position: relative;
    display: grid;
    width: 63px;
    height: 63px;
    margin: 0 auto 28px;
    place-items: center;
    color: #8f68ff;
    border: 1px solid rgba(128, 91, 255, 0.65);
    border-radius: 16px;
    background:
        linear-gradient(145deg, rgba(119, 50, 221, 0.25), rgba(18, 48, 94, 0.32)),
        rgba(13, 18, 40, 0.8);
    box-shadow:
        0 0 27px rgba(102, 54, 242, 0.25),
        inset 0 0 24px rgba(85, 45, 203, 0.12);
    animation: securityAppear 400ms 350ms ease both, securityPulse 3.8s 1s ease-in-out infinite;
}

.security-icon::before,
.security-icon::after {
    content: "";
    position: absolute;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #8d58ff;
    box-shadow:
        24px -8px 0 rgba(78, 129, 255, 0.58),
        -24px 12px 0 rgba(173, 70, 255, 0.55),
        29px 18px 0 rgba(129, 61, 246, 0.33),
        -29px -13px 0 rgba(57, 120, 255, 0.3);
}

.security-icon::after {
    transform: rotate(92deg);
    opacity: 0.5;
}

.security-icon svg {
    width: 31px;
    height: 31px;
    fill: currentColor;
}

.panel-heading h2 {
    margin: 0;
    color: #f8f8fb;
    font-size: clamp(1.9rem, 2.35vw, 2.4rem);
    line-height: 1.15;
    letter-spacing: -0.035em;
    font-weight: 850;
}

.panel-heading p {
    margin: 9px 0 27px;
    color: var(--login-muted);
    font-size: 0.96rem;
}

.login-alert {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin: 0 0 20px;
    padding: 13px 15px;
    border-radius: 11px;
    font-size: 0.83rem;
    line-height: 1.45;
    animation: alertIn 220ms ease both;
}

.login-alert svg {
    flex: 0 0 auto;
    width: 18px;
    margin-top: 1px;
    fill: currentColor;
}

.login-alert p {
    margin: 0;
}

.login-alert p + p {
    margin-top: 4px;
}

.login-alert-info {
    color: #a9c9ff;
    border: 1px solid rgba(57, 126, 242, 0.28);
    background: rgba(42, 94, 185, 0.12);
}

.login-alert-error {
    color: #ffb5c1;
    border: 1px solid rgba(240, 70, 98, 0.28);
    background: rgba(174, 37, 65, 0.13);
}

.login-form {
    position: relative;
    z-index: 1;
}

.form-field + .form-field {
    margin-top: 22px;
}

.form-field > label {
    display: block;
    margin: 0 0 9px;
    color: #b0b7ca;
    font-size: 0.78rem;
    font-weight: 750;
    letter-spacing: 0.065em;
    text-transform: uppercase;
}

.input-shell {
    position: relative;
}

.input-shell input {
    display: block;
    width: 100%;
    height: 59px;
    padding: 0 52px 0 58px;
    color: #f3f4f9;
    font-size: 1rem;
    font-weight: 500;
    outline: none;
    border: 1px solid rgba(117, 129, 160, 0.42);
    border-radius: 12px;
    background: rgba(4, 9, 22, 0.64);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
    caret-color: #ac59ff;
    transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.input-shell input::placeholder {
    color: #69758f;
    opacity: 1;
}

.input-shell input:hover {
    border-color: rgba(144, 136, 183, 0.52);
}

.input-shell input:focus {
    border-color: #a747ec;
    background: rgba(5, 9, 23, 0.82);
    box-shadow:
        0 0 0 3px rgba(148, 60, 232, 0.1),
        0 0 24px rgba(119, 49, 227, 0.12);
}

.input-shell.has-error input {
    border-color: rgba(246, 74, 105, 0.75);
    box-shadow: 0 0 0 3px rgba(238, 55, 90, 0.08);
}

.input-icon {
    position: absolute;
    z-index: 2;
    left: 19px;
    top: 50%;
    display: grid;
    width: 21px;
    height: 21px;
    place-items: center;
    color: #77839e;
    pointer-events: none;
    transform: translateY(-50%);
    transition: color 160ms ease, filter 160ms ease;
}

.input-icon svg,
.password-toggle svg,
.field-state svg {
    width: 100%;
    height: 100%;
    fill: currentColor;
}

.input-shell:focus-within .input-icon {
    color: #a75eff;
    filter: drop-shadow(0 0 8px rgba(153, 76, 255, 0.45));
}

.password-toggle {
    position: absolute;
    z-index: 3;
    right: 12px;
    top: 50%;
    display: grid;
    width: 37px;
    height: 37px;
    padding: 8px;
    place-items: center;
    color: #78849d;
    cursor: pointer;
    border: 0;
    border-radius: 9px;
    background: transparent;
    transform: translateY(-50%);
    transition: color 160ms ease, background 160ms ease;
}

.password-toggle:hover,
.password-toggle:focus-visible {
    color: #b171ff;
    background: rgba(136, 66, 231, 0.11);
    outline: none;
}

.field-state {
    position: absolute;
    z-index: 2;
    right: 18px;
    top: 50%;
    display: none;
    width: 19px;
    height: 19px;
    color: #46d795;
    transform: translateY(-50%);
}

.input-shell:not(.has-error) input[type="email"]:valid:not(:placeholder-shown) ~ .field-state {
    display: block;
}

.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin: 20px 0 27px;
}

.remember-option {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #969fb5;
    font-size: 0.86rem;
    cursor: pointer;
    user-select: none;
}

.remember-option input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.custom-checkbox {
    display: grid;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    place-items: center;
    color: #fff;
    border: 1px solid rgba(130, 141, 168, 0.6);
    border-radius: 4px;
    background: rgba(8, 13, 29, 0.75);
    transition: border-color 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.custom-checkbox svg {
    width: 15px;
    fill: currentColor;
    opacity: 0;
    transform: scale(0.65);
    transition: opacity 140ms ease, transform 140ms ease;
}

.remember-option input:checked + .custom-checkbox {
    border-color: #9f46ee;
    background: linear-gradient(145deg, #a23beb, #654cff);
    box-shadow: 0 0 12px rgba(141, 55, 238, 0.32);
}

.remember-option input:checked + .custom-checkbox svg {
    opacity: 1;
    transform: scale(1);
}

.remember-option input:focus-visible + .custom-checkbox {
    outline: 2px solid #c37bff;
    outline-offset: 3px;
}

.forgot-link {
    color: #bf58ff;
    font-size: 0.86rem;
    font-weight: 700;
    text-decoration: none;
    transition: color 160ms ease, text-shadow 160ms ease;
}

.forgot-link:hover,
.forgot-link:focus-visible {
    color: #d493ff;
    text-shadow: 0 0 15px rgba(181, 75, 255, 0.35);
    outline: none;
}

.login-submit {
    position: relative;
    display: block;
    width: 100%;
    min-height: 59px;
    padding: 0 22px;
    overflow: hidden;
    color: #fff;
    cursor: pointer;
    border: 1px solid rgba(203, 138, 255, 0.8);
    border-radius: 12px;
    background: linear-gradient(105deg, #a433e8 0%, #764ff5 49%, #3781f7 100%);
    box-shadow:
        0 10px 27px rgba(89, 43, 199, 0.26),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: transform 170ms ease, box-shadow 170ms ease, filter 170ms ease;
}

.login-submit::before {
    content: "";
    position: absolute;
    top: -70%;
    bottom: -70%;
    left: -30%;
    width: 28%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.16), transparent);
    transform: skewX(-18deg);
    transition: left 450ms ease;
}

.login-submit > span {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    font-size: 1rem;
    font-weight: 800;
}

.login-submit svg {
    width: 21px;
    height: 21px;
    fill: currentColor;
}

.login-submit:hover:not(:disabled) {
    filter: brightness(1.07);
    transform: translateY(-2px);
    box-shadow:
        0 16px 34px rgba(89, 43, 199, 0.34),
        0 0 25px rgba(93, 74, 237, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.login-submit:hover:not(:disabled)::before {
    left: 110%;
}

.login-submit:active:not(:disabled) {
    transform: translateY(0);
}

.login-submit:focus-visible {
    outline: 2px solid #d796ff;
    outline-offset: 3px;
}

.login-submit:disabled {
    cursor: wait;
    filter: saturate(0.7);
    opacity: 0.76;
}

.loading-spinner {
    animation: spin 800ms linear infinite;
}

.secure-divider {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    margin: 29px 0 21px;
}

.secure-divider span {
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(139, 149, 177, 0.35));
}

.secure-divider span:last-child {
    background: linear-gradient(90deg, rgba(139, 149, 177, 0.35), transparent);
}

.secure-divider svg {
    width: 20px;
    fill: #62708d;
}

.register-prompt {
    margin: 0;
    text-align: center;
    color: #929bae;
    font-size: 0.9rem;
}

.register-prompt a {
    margin-left: 5px;
    color: #bc5aff;
    font-weight: 750;
    text-decoration: none;
    transition: color 160ms ease;
}

.register-prompt a:hover,
.register-prompt a:focus-visible {
    color: #dc9dff;
    outline: none;
}

.security-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 13px;
    margin: 28px auto 0;
    color: #7d879d;
    font-size: 0.72rem;
}

.security-footer span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

.security-footer svg {
    width: 18px;
    height: 18px;
    fill: #7787a7;
}

.security-footer i {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #536079;
}

@keyframes loginLeftIn {
    from { opacity: 0; transform: translate3d(-18px, 0, 0); }
    to { opacity: 1; transform: translate3d(0, 0, 0); }
}

@keyframes loginPanelIn {
    from { opacity: 0; transform: translate3d(0, 15px, 0); }
    to { opacity: 1; transform: translate3d(0, 0, 0); }
}

@keyframes securityAppear {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

@keyframes securityPulse {
    0%, 100% { box-shadow: 0 0 27px rgba(102, 54, 242, 0.22), inset 0 0 24px rgba(85, 45, 203, 0.12); }
    50% { box-shadow: 0 0 34px rgba(102, 54, 242, 0.31), inset 0 0 27px rgba(85, 45, 203, 0.16); }
}

@keyframes alertIn {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

@media (max-width: 1240px) {
    .login-page {
        grid-template-columns: minmax(0, 48%) minmax(0, 52%);
    }

    .login-institutional {
        padding: 46px;
    }

    .login-brand {
        margin-bottom: 48px;
    }

    .welcome-copy h1 {
        font-size: clamp(3rem, 5vw, 4rem);
    }

    .benefit-card {
        min-height: 190px;
        padding-inline: 10px;
    }

    .login-access {
        padding: 34px;
    }

    .login-panel {
        padding-inline: clamp(32px, 4.2vw, 52px);
    }
}

@media (max-width: 1020px) {
    .login-page {
        grid-template-columns: minmax(0, 43%) minmax(0, 57%);
    }

    .login-institutional {
        padding: 38px 30px;
    }

    .welcome-copy h1 {
        font-size: 3.15rem;
    }

    .welcome-copy p {
        font-size: 0.96rem;
    }

    .benefit-grid {
        gap: 9px;
    }

    .benefit-card {
        min-height: 166px;
        padding: 15px 8px;
    }

    .benefit-icon {
        width: 42px;
        height: 42px;
        margin-bottom: 9px;
    }

    .benefit-icon svg {
        width: 23px;
        height: 23px;
    }

    .benefit-card p {
        display: none;
    }

    .trust-strip {
        padding: 12px 14px;
        font-size: 0.73rem;
    }

    .login-access {
        padding: 28px 24px;
    }
}

@media (max-width: 820px) {
    html,
    body {
        background: #060816 !important;
    }

    .login-page {
        display: block;
        min-height: 100vh;
        overflow: visible;
        background:
            radial-gradient(circle at 18% 9%, rgba(140, 45, 229, 0.15), transparent 28%),
            radial-gradient(circle at 90% 44%, rgba(45, 101, 230, 0.09), transparent 34%),
            #060816;
    }

    .login-institutional {
        display: none;
    }

    .login-access {
        display: block;
        min-height: 100vh;
        padding: 24px clamp(18px, 5vw, 40px) 28px;
        background: transparent;
    }

    .access-grid {
        position: fixed;
        opacity: 0.25;
        background-size: 48px 48px;
    }

    .mobile-brand {
        position: relative;
        z-index: 2;
        display: block;
        width: min(100%, 600px);
        margin: 0 auto 20px;
        animation: loginLeftIn 400ms ease both;
    }

    .mobile-brand a {
        display: inline-flex;
        min-height: 42px;
        align-items: center;
        text-decoration: none;
    }

    .mobile-brand img {
        display: block;
        width: 190px;
        max-width: 72vw;
        height: auto;
        object-fit: contain;
        object-position: left center;
    }

    .mobile-brand p {
        margin: 8px 0 0;
        color: #7f89a0;
        font-size: 0.78rem;
    }

    .access-shell {
        width: min(100%, 600px);
        margin: 0 auto;
    }

    .login-panel {
        padding: 32px clamp(22px, 6vw, 42px) 30px;
        border-radius: 18px;
    }

    .security-icon {
        width: 57px;
        height: 57px;
        margin-bottom: 20px;
        border-radius: 15px;
    }

    .panel-heading h2 {
        font-size: 1.8rem;
    }

    .panel-heading p {
        margin-bottom: 25px;
    }

    .security-footer {
        margin-top: 22px;
    }
}

@media (max-width: 520px) {
    .login-access {
        padding: 18px 12px 24px;
    }

    .mobile-brand {
        padding: 0 7px;
        margin-bottom: 16px;
    }

    .mobile-brand img {
        width: 172px;
        max-width: 70vw;
        height: auto;
    }

    .mobile-brand p {
        display: none;
    }

    .login-panel {
        padding: 27px 18px 25px;
        border-radius: 16px;
    }

    .security-icon {
        width: 51px;
        height: 51px;
        margin-bottom: 17px;
    }

    .security-icon svg {
        width: 27px;
        height: 27px;
    }

    .panel-heading h2 {
        font-size: 1.62rem;
    }

    .panel-heading p {
        margin: 7px 0 22px;
        font-size: 0.86rem;
    }

    .form-field + .form-field {
        margin-top: 18px;
    }

    .input-shell input {
        height: 56px;
        padding-left: 52px;
        font-size: 16px;
    }

    .input-icon {
        left: 17px;
    }

    .form-options {
        margin: 18px 0 23px;
    }

    .remember-option,
    .forgot-link {
        font-size: 0.8rem;
    }

    .login-submit {
        min-height: 56px;
    }

    .secure-divider {
        margin: 25px 0 18px;
    }

    .security-footer {
        gap: 10px 13px;
        padding: 0 7px;
        font-size: 0.67rem;
    }

    .security-footer i {
        display: none;
    }

    .security-footer span:last-child {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 360px) {
    .form-options {
        align-items: flex-start;
        flex-direction: column;
        gap: 13px;
    }

    .forgot-link {
        align-self: flex-end;
        margin-top: -29px;
    }

    .register-prompt {
        font-size: 0.82rem;
    }
}

@media (max-height: 960px) and (min-width: 821px) {
    .login-access {
        padding-block: 24px;
    }

    .login-institutional {
        padding-block: 40px;
    }

    .login-brand {
        margin-bottom: 38px;
    }

    .welcome-copy h1 {
        font-size: clamp(3.1rem, 4.45vw, 4.55rem);
    }

    .welcome-copy p {
        margin-block: 19px 13px;
    }

    .welcome-accent {
        margin: 17px 0 25px;
    }

    .benefit-card {
        min-height: 188px;
    }

    .trust-strip {
        margin-top: 20px;
    }
}

@media (max-height: 820px) and (min-width: 821px) {
    .login-institutional {
        padding-block: 30px;
    }

    .login-brand {
        margin-bottom: 28px;
    }

    .welcome-copy h1 {
        font-size: clamp(2.8rem, 4.4vw, 4rem);
    }

    .welcome-copy p {
        margin-block: 18px 12px;
        line-height: 1.5;
    }

    .welcome-accent {
        margin: 15px 0 22px;
    }

    .benefit-card {
        min-height: 157px;
        padding-block: 13px;
    }

    .benefit-icon {
        width: 42px;
        height: 42px;
        margin-bottom: 8px;
    }

    .benefit-card p {
        display: none;
    }

    .trust-strip {
        margin-top: 18px;
        padding-block: 10px;
    }

    .login-access {
        padding-block: 24px;
    }

    .login-panel {
        padding-top: 34px;
        padding-bottom: 29px;
    }

    .security-icon {
        width: 54px;
        height: 54px;
        margin-bottom: 18px;
    }

    .panel-heading p {
        margin-bottom: 22px;
    }

    .form-field + .form-field {
        margin-top: 17px;
    }

    .input-shell input {
        height: 54px;
    }

    .form-options {
        margin-block: 17px 22px;
    }

    .login-submit {
        min-height: 54px;
    }

    .secure-divider {
        margin: 23px 0 17px;
    }

    .security-footer {
        margin-top: 18px;
    }
}

@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;
    }
}
