:root {
    --maroon: #7b1113;
    --maroon-deep: #4f0007;
    --maroon-soft: #8d4b52;
    --gold: #f4ae25;
    --ink: #17211e;
    --muted: #68736f;
    --line: #d9dfdc;
    --white: #fff;
    --font-ui: Arial, Helvetica, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    background: var(--maroon-deep);
}

body {
    margin: 0;
    color: var(--ink);
    font-family: var(--font-ui);
    -webkit-font-smoothing: antialiased;
}

button,
input {
    font: inherit;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.login-stage {
    display: grid;
    place-items: center;
    position: relative;
    min-height: 100svh;
    overflow: hidden;
    padding: clamp(30px, 6vh, 66px) 24px;
    background:
        linear-gradient(rgba(79, 0, 7, .30), rgba(79, 0, 7, .30)),
        url("../images/up-cebu-campus-login.png") center center / cover no-repeat;
}

.login-card {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr);
    width: min(100%, 1200px);
    min-height: 590px;
    overflow: hidden;
    border: 2px solid transparent;
    border-radius: 28px;
    background:
        linear-gradient(rgba(255, 255, 255, .72), rgba(255, 255, 255, .72)) padding-box,
        linear-gradient(
            135deg,
            rgba(206, 100, 113, .88) 0%,
            rgba(123, 17, 19, .30) 28%,
            rgba(79, 0, 7, .82) 64%,
            rgba(168, 55, 69, .68) 100%
        ) border-box;
    box-shadow:
        inset 0 1px 0 rgba(255, 193, 201, .30),
        0 42px 90px rgba(38, 0, 4, .32),
        0 8px 26px rgba(38, 0, 4, .14);
    backdrop-filter: blur(28px) saturate(130%);
}

.login-intro {
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    padding: 50px 54px 44px;
    background:
        radial-gradient(circle at 15% 12%, rgba(255, 255, 255, .11), transparent 34%),
        linear-gradient(155deg, rgba(137, 48, 58, .88) 0%, rgba(105, 12, 24, .92) 46%, rgba(65, 0, 8, .95) 100%);
    color: var(--white);
    box-shadow: inset -1px 0 rgba(255, 255, 255, .12);
    backdrop-filter: blur(18px) saturate(125%);
}

.login-intro::before {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .025) 1px, transparent 1px);
    background-size: 64px 64px;
    content: "";
    opacity: .55;
    pointer-events: none;
    mask-image: linear-gradient(to bottom right, #000, transparent 72%);
}

.login-intro::after {
    position: absolute;
    right: -188px;
    bottom: -220px;
    width: 500px;
    height: 500px;
    border: 1px solid rgba(255, 255, 255, .09);
    border-radius: 50%;
    box-shadow:
        0 0 0 54px rgba(255, 255, 255, .028),
        0 0 0 108px rgba(255, 255, 255, .018);
    content: "";
    pointer-events: none;
}

.campus-label {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    position: relative;
    z-index: 2;
    gap: 10px;
    min-height: 38px;
    border: 1px solid rgba(255, 255, 255, .32);
    border-radius: 999px;
    padding: 8px 15px 8px 12px;
    background: rgba(255, 255, 255, .075);
    font-size: 12px;
    font-weight: 520;
    letter-spacing: .005em;
    white-space: nowrap;
    backdrop-filter: blur(12px);
}

.campus-label span {
    flex: 0 0 auto;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow:
        0 0 0 4px rgba(244, 174, 37, .15),
        0 0 18px rgba(244, 174, 37, .35);
}

.intro-copy {
    position: relative;
    z-index: 2;
    margin: auto 0;
    animation: intro-reveal .55s cubic-bezier(.2, .8, .2, 1) both;
}

.intro-brand-logo {
    display: block;
    width: 126px;
    height: 126px;
    margin: 0 auto 34px;
    border: 0;
    border-radius: 0;
    background: transparent;
    object-fit: contain;
    box-shadow: none;
    filter: drop-shadow(0 18px 26px rgba(31, 0, 4, .24));
}

.intro-copy h1 {
    margin: 0;
    max-width: none;
    font-size: clamp(32px, 3.45vw, 52px);
    font-weight: 680;
    line-height: .99;
    letter-spacing: -.052em;
    white-space: nowrap;
}

.intro-copy p {
    max-width: 360px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, .82);
    font-size: 15px;
    line-height: 1.65;
}

.intro-features {
    display: grid;
    grid-template-columns: repeat(3, auto);
    align-items: center;
    justify-content: start;
    position: relative;
    z-index: 2;
    gap: 0;
    animation: intro-reveal .55s .12s cubic-bezier(.2, .8, .2, 1) both;
}

.intro-features span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 0;
    border-radius: 0;
    padding: 4px 20px;
    background: transparent;
    color: rgba(255, 255, 255, .72);
    font-size: 10px;
    font-weight: 720;
    letter-spacing: .12em;
}

.intro-features span:first-child {
    padding-left: 0;
}

.intro-features span + span {
    border-left: 1px solid rgba(255, 255, 255, .22);
}

.intro-features span::before {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--gold);
    content: "";
    box-shadow: 0 0 10px rgba(244, 174, 37, .38);
}

@keyframes intro-reveal {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-access {
    display: grid;
    place-items: center;
    position: relative;
    isolation: isolate;
    padding: 58px 64px;
    overflow: hidden;
    background: rgba(255, 255, 255, .86);
    backdrop-filter: blur(24px) saturate(125%);
}

.login-access::before {
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, .38) 0%, rgba(255, 255, 255, .08) 26%, transparent 48%),
        radial-gradient(circle at 88% 10%, rgba(255, 255, 255, .48), transparent 32%);
    content: "";
    pointer-events: none;
}

.login-form-wrap {
    position: relative;
    z-index: 1;
    width: min(100%, 360px);
}

.login-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 54px;
}

.login-logos img {
    display: block;
    width: 88px;
    height: 54px;
    object-fit: contain;
}

.form-heading {
    margin: 25px 0 34px;
    text-align: center;
}

.form-heading h2 {
    margin: 0;
    font-size: 30px;
    font-weight: 750;
    letter-spacing: -.035em;
}

.form-heading p {
    margin: 8px 0 0;
    color: #7a6d70;
    font-size: 10px;
    font-weight: 650;
    letter-spacing: .11em;
    text-transform: uppercase;
}

.google-sso-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 11px;
    min-height: 52px;
    border: 1px solid #d8cecf;
    border-radius: 14px;
    background: rgba(255, 255, 255, .72);
    color: #29332f;
    font-size: 13.5px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 5px 16px rgba(38, 0, 4, .05);
    transition: border-color .18s ease, background .18s ease, box-shadow .18s ease, transform .18s ease;
}

.google-sso-button svg {
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
}

.google-sso-button:hover {
    border-color: #bdaeb0;
    background: rgba(255, 255, 255, .94);
    box-shadow: 0 8px 20px rgba(38, 0, 4, .08);
    transform: translateY(-1px);
}

.google-sso-button:focus-visible {
    outline: 4px solid rgba(123, 17, 19, .15);
    outline-offset: 3px;
}

@media (max-width: 820px) {
    .login-stage {
        overflow: auto;
        padding: 28px 20px;
    }

    .login-card {
        grid-template-columns: 1fr;
        width: min(100%, 520px);
        min-height: auto;
    }

    .login-intro {
        min-height: 300px;
        padding: 28px 32px 30px;
    }

    .campus-label {
        min-height: 34px;
        font-size: 11px;
    }

    .intro-copy {
        margin: 35px 0 0;
    }

    .intro-brand-logo {
        width: 84px;
        height: 84px;
        margin-bottom: 20px;
    }

    .intro-copy h1 {
        font-size: 32px;
        white-space: normal;
    }

    .intro-copy p {
        margin-top: 12px;
        font-size: 13px;
        line-height: 1.5;
    }

    .intro-features {
        display: none;
    }

    .login-access {
        padding: 42px 34px 46px;
    }

}

@media (max-width: 430px) {
    .login-stage {
        display: block;
        padding: 16px;
    }

    .login-intro {
        min-height: 250px;
        padding: 24px;
    }

    .campus-label {
        max-width: 100%;
        overflow: hidden;
        padding-right: 12px;
        padding-left: 12px;
        text-overflow: ellipsis;
    }

    .intro-copy {
        margin-top: 29px;
    }

    .intro-brand-logo {
        width: 74px;
        height: 74px;
        margin: 0 auto 16px;
    }

    .intro-copy h1 {
        font-size: 29px;
    }

    .intro-copy p {
        display: none;
    }

    .login-access {
        padding: 34px 24px 38px;
    }

    .form-heading {
        margin: 19px 0 26px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition-duration: .01ms !important;
    }
}
