:root {
    --navy: #0f2a5f;
    --navy-dark: #071a3c;
    --blue: #2563eb;
    --gold: #f59e0b;
    --slate-900: #0f172a;
    --slate-600: #475569;
    --slate-300: #cbd5e1;
    --slate-200: #e2e8f0;
    --background: #f4f7fb;
    --white: #ffffff;
    --red: #dc2626;
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
    background: var(--background);
    color: var(--slate-900);
    font-family: "DM Sans", Arial, sans-serif;
}

.login-page {
    display: grid;
    min-height: 100vh;
    grid-template-columns: 1.05fr 0.95fr;
}

.login-brand-panel {
    position: relative;
    display: flex;
    overflow: hidden;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
    padding: 52px 68px;
    background:
        linear-gradient(135deg, rgba(7, 26, 60, 0.96), rgba(15, 42, 95, 0.88)),
        url("../images/portal-login-bg.jpg") center / cover;
    color: var(--white);
}

.login-brand-panel::before,
.login-brand-panel::after {
    position: absolute;
    border-radius: 50%;
    content: "";
}

.login-brand-panel::before {
    right: -140px;
    bottom: -120px;
    width: 420px;
    height: 420px;
    border: 1px solid rgba(255, 255, 255, 0.14);
}

.login-brand-panel::after {
    top: -130px;
    left: -120px;
    width: 310px;
    height: 310px;
    background: rgba(245, 158, 11, 0.12);
}

.login-school-logo,
.login-content,
.login-brand-footer {
    position: relative;
    z-index: 1;
}

.login-school-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.login-logo-icon {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--gold), #fbbf24);
    color: var(--navy-dark);
    font-size: 23px;
}

.login-school-logo strong,
.login-school-logo span {
    display: block;
}

.login-school-logo strong {
    font-size: 16px;
}

.login-school-logo span {
    margin-top: 3px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
}

.login-content {
    max-width: 520px;
    margin: auto 0;
}

.login-content .portal-label {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 11px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.09);
    color: #fcd34d;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.07em;
}

.login-content h1 {
    max-width: 500px;
    margin: 18px 0 14px;
    font-family: "Playfair Display", Georgia, serif;
    font-size: clamp(37px, 4vw, 55px);
    line-height: 1.1;
}

.login-content p {
    max-width: 460px;
    color: rgba(255, 255, 255, 0.76);
    font-size: 15px;
    line-height: 1.75;
}

.login-feature-list {
    display: grid;
    gap: 13px;
    margin-top: 32px;
}

.login-feature-list div {
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
}

.login-feature-list i {
    display: grid;
    width: 25px;
    height: 25px;
    place-items: center;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.19);
    color: #6ee7b7;
    font-size: 13px;
}

.login-brand-footer {
    color: rgba(255, 255, 255, 0.54);
    font-size: 12px;
}

.login-form-panel {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 35px;
}

.login-form-container {
    width: 100%;
    max-width: 435px;
}

.login-form-header {
    margin-bottom: 30px;
}

.login-form-header h2 {
    margin: 0 0 8px;
    color: var(--navy);
    font-family: "Playfair Display", Georgia, serif;
    font-size: 32px;
}

.login-form-header p {
    margin: 0;
    color: var(--slate-600);
    font-size: 14px;
    line-height: 1.6;
}

.login-card {
    padding: 30px;
    border: 1px solid var(--slate-200);
    border-radius: 18px;
    background: var(--white);
    box-shadow: 0 16px 45px rgba(15, 42, 95, 0.08);
}

.login-alert {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    padding: 12px 13px;
    border-radius: 10px;
    background: #fee2e2;
    color: #991b1b;
    font-size: 13px;
    line-height: 1.5;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--slate-900);
    font-size: 13px;
    font-weight: 700;
}

.input-wrapper {
    position: relative;
}

.input-wrapper > i {
    position: absolute;
    top: 50%;
    left: 14px;
    color: #94a3b8;
    font-size: 17px;
    transform: translateY(-50%);
}

.input-wrapper input {
    width: 100%;
    height: 49px;
    padding: 0 45px;
    border: 1px solid var(--slate-300);
    border-radius: 10px;
    outline: none;
    background: #fff;
    color: var(--slate-900);
    font-size: 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-wrapper input:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 12px;
    border: 0;
    background: transparent;
    color: #64748b;
    cursor: pointer;
    font-size: 17px;
    transform: translateY(-50%);
}

.login-button {
    display: flex;
    width: 100%;
    height: 50px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--navy), var(--blue));
    box-shadow: 0 9px 18px rgba(37, 99, 235, 0.18);
    color: var(--white);
    cursor: pointer;
    font-size: 14px;
    font-weight: 700;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.login-button:hover {
    opacity: 0.95;
    transform: translateY(-2px);
}

.login-help {
    margin: 21px 0 0;
    color: var(--slate-600);
    font-size: 12px;
    line-height: 1.65;
    text-align: center;
}

.login-help i {
    color: var(--gold);
}

@media (max-width: 950px) {
    .login-page {
        grid-template-columns: 1fr;
    }

    .login-brand-panel {
        display: none;
    }

    .login-form-panel {
        min-height: 100vh;
    }
}

@media (max-width: 500px) {
    .login-form-panel {
        padding: 20px;
    }

    .login-card {
        padding: 23px 20px;
    }
}