@import url('https://fonts.googleapis.com/css2?family=Google+Sans+Flex:opsz,wght@6..144,1..1000&family=Plus+Jakarta+Sans:wght@500;600;700;800;900&family=Outfit:wght@600;700;800;900&display=swap');

:root {
    --role: #2933AA;
    --role-deep: #1E2585;
    --role-soft: #EEF0FF;
    --ink: #071A33;
    --muted: #334155;
    --line: #CBD5E1;
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: #060F2D;
}

body.nycet-login-page {
    min-height: 100vh;
    margin: 0;
    font-family: 'Google Sans Flex', 'Plus Jakarta Sans', 'Inter', -apple-system, sans-serif;
    color: var(--ink);
    background: 
        radial-gradient(ellipse at 85% 15%, rgba(41, 51, 170, 0.35), transparent 55%),
        radial-gradient(ellipse at 15% 85%, rgba(250, 100, 0, 0.15), transparent 45%),
        linear-gradient(135deg, rgba(6, 15, 45, 0.65) 0%, rgba(10, 25, 75, 0.58) 50%, rgba(4, 10, 30, 0.72) 100%),
        url('../images/computer_education_bg.jpg') center center / cover no-repeat fixed;
    font-size: 15px;
    line-height: 1.6;
    overflow-x: hidden;
}

body.role-admin {
    --role: #FA6400;
    --role-deep: #D94800;
    --role-soft: #FFF4ED;
}

body.role-centre {
    --role: #2933AA;
    --role-deep: #1E2585;
    --role-soft: #EEF0FF;
}

body.role-teacher {
    --role: #7C3AED;
    --role-deep: #5B21B6;
    --role-soft: #F5F3FF;
}

body.role-student {
    --role: #00A86B;
    --role-deep: #008755;
    --role-soft: #ECFDF5;
}

a {
    text-decoration: none;
}

.nycet-login-wrap {
    position: relative;
    z-index: 2;
    width: min(520px, calc(100% - 32px));
    margin: 0 auto;
    padding: 36px 0 48px;
}

.login-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 22px;
    color: #E2E8F0;
}

.login-topbar > a {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #FFFFFF;
    font-size: 13.5px;
    font-weight: 800;
}

.login-topbar > a svg {
    width: 18px;
    height: 18px;
}

.login-topbar > span {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #72DFE9;
}

.login-topbar > span svg {
    width: 16px;
    height: 16px;
}

.nycet-login-shell {
    display: block;
    min-height: auto;
    overflow: hidden;
    border: 1.5px solid rgba(255, 255, 255, 0.4);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 35px 90px -15px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.6) inset, 0 0 45px rgba(41, 51, 170, 0.25);
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.login-brand-panel {
    display: none !important;
}

.login-form-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 38px 36px;
    background: transparent;
}

.login-form-head {
    margin-bottom: 24px;
}

.login-form-head > span {
    display: inline-block;
    color: var(--role);
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
    margin-bottom: 4px;
}

.login-form-head h2 {
    margin: 4px 0 8px;
    color: var(--ink);
    font-family: 'Outfit', sans-serif;
    font-size: 32px;
    font-weight: 900;
    line-height: 1.15;
    letter-spacing: -.03em;
}

.login-form-head p {
    margin: 0;
    color: #334155;
    font-size: 14px;
    font-weight: 550;
    line-height: 1.6;
}

.modern-login-form {
    display: grid;
    gap: 18px;
}

.modern-field {
    display: grid;
    gap: 7px;
}

.modern-field > label {
    margin: 0;
    color: #071A33;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.modern-input-wrap {
    position: relative;
}

.modern-input-wrap > svg {
    position: absolute;
    left: 15px;
    top: 50%;
    width: 20px;
    height: 20px;
    transform: translateY(-50%);
    color: var(--role);
    pointer-events: none;
}

.modern-input-wrap input {
    width: 100%;
    height: 52px;
    padding: 0 48px 0 48px;
    border: 1.5px solid #CBD5E1;
    border-radius: 12px;
    background: #F8FAFC;
    color: #071A33;
    font-family: inherit;
    font-size: 15px;
    font-weight: 650;
    outline: none;
    transition: .2s;
}

.modern-input-wrap input::placeholder {
    color: #64748B;
    font-weight: 500;
}

.modern-input-wrap input:focus {
    border-color: var(--role);
    background: #FFFFFF;
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--role) 14%, transparent);
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #64748B;
    transform: translateY(-50%);
    cursor: pointer;
}

.password-toggle:hover {
    background: var(--role-soft);
    color: var(--role);
}

.password-toggle svg {
    width: 19px;
    height: 19px;
}

.login-form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.remember-choice {
    display: flex !important;
    align-items: center;
    gap: 8px;
    margin: 0 !important;
    color: #1E293B !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    cursor: pointer;
}

.remember-choice input {
    width: 17px;
    height: 17px;
    margin: 0;
    accent-color: var(--role);
    cursor: pointer;
}

.forgot-action {
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--role);
    font-family: inherit;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.forgot-action:hover {
    text-decoration: underline;
}

.modern-submit {
    position: relative;
    width: 100%;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 4px;
    border: 0;
    border-radius: 12px;
    background: var(--role);
    color: #FFFFFF;
    font-family: inherit;
    font-size: 15px;
    font-weight: 900;
    letter-spacing: .02em;
    box-shadow: 0 10px 24px color-mix(in srgb, var(--role) 28%, transparent);
    cursor: pointer;
    transition: .25s ease;
}

.modern-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 32px color-mix(in srgb, var(--role) 35%, transparent);
}

.modern-submit svg {
    width: 18px;
    height: 18px;
    transition: .2s;
}

.modern-submit:hover svg {
    transform: translateX(4px);
}

.login-hint {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 4px 0 0;
    padding: 12px 14px;
    border: 1.5px solid #CBD5E1;
    border-radius: 10px;
    background: #F8FAFC;
    color: #1E293B;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.5;
}

.login-hint svg {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    color: var(--role);
    margin-top: 1px;
}

.role-switcher {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1.5px solid #E2E8F0;
}

.role-switcher > span {
    display: block;
    margin-bottom: 12px;
    color: #475569;
    font-size: 11.5px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.role-switcher-links {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.role-switcher-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    min-height: 42px;
    border: 1.5px solid #CBD5E1;
    border-radius: 10px;
    background: #FFFFFF;
    color: #1E293B;
    font-size: 12.5px;
    font-weight: 850;
    transition: .2s;
}

.role-switcher-links a:hover {
    border-color: var(--role);
    background: #F8FAFC;
}

.role-switcher-links a.is-current {
    border-color: var(--role);
    background: var(--role-soft);
    color: var(--role);
}

.role-switcher-links svg {
    width: 15px;
    height: 15px;
}

.login-security-note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    padding: 8px 14px;
    background: #F1F5F9;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    color: #334155;
    font-size: 12.5px;
    font-weight: 700;
    text-align: center;
}

.login-security-note svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #0284C7;
}

/* Password Modal */
.password-modal[hidden] {
    display: none;
}

.password-modal {
    position: fixed;
    z-index: 100;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(3,16,40,.8);
    backdrop-filter: blur(8px);
}

.password-modal-card {
    width: min(460px, 100%);
    padding: 30px;
    border: 1.5px solid rgba(255,255,255,.3);
    border-radius: 20px;
    background: #FFFFFF;
    box-shadow: 0 35px 80px rgba(0,0,0,.4);
}

.password-modal-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.password-modal-head h3 {
    margin: 0;
    color: var(--ink);
    font-size: 22px;
    font-weight: 900;
}

.password-modal-head p {
    margin: 6px 0 0;
    color: #334155;
    font-size: 13px;
    font-weight: 550;
    line-height: 1.55;
}

.password-modal-close {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: 9px;
    background: #EEF2F7;
    color: #1E293B;
    cursor: pointer;
    font-size: 16px;
}

@media(max-width: 560px) {
    .nycet-login-wrap {
        width: min(100% - 24px, 520px);
        padding-top: 20px;
    }
    .login-form-panel {
        padding: 30px 22px;
    }
    .role-switcher-links {
        grid-template-columns: 1fr 1fr;
    }
}
