:root {
    --page-bg: #f3f7fc;
    --surface: #ffffff;
    --ink: #10233f;
    --muted: #60718c;
    --line: #d8e2ee;
    --blue: #0868c9;
    --blue-dark: #0756a8;
    --blue-soft: #e7f1fd;
    --danger: #b42323;
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    color: var(--ink);
    background: var(--page-bg);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
    overflow-x: hidden;
}

button,
input {
    font: inherit;
}

.portal-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.simple-login-header {
    flex: 0 0 auto;
    border-bottom: 1px solid #083f5d;
    background: #0b4f71;
    box-shadow: 0 3px 12px rgba(16, 35, 63, 0.14);
}

.simple-login-header-inner {
    width: min(1460px, 100%);
    min-height: 84px;
    margin: 0 auto;
    padding: 12px 36px;
    display: flex;
    align-items: center;
    gap: 13px;
}

.header-brand-logo {
    width: 52px;
    height: 52px;
    padding: 5px;
    border-radius: 13px;
    border: 1px solid #d7e6ee;
    background: #ffffff;
    object-fit: contain;
}

.header-brand-copy strong,
.header-brand-copy span {
    display: block;
}

.header-brand-copy strong {
    color: #ffffff;
    font-size: 24px;
    line-height: 1.05;
    letter-spacing: -0.035em;
}

.header-brand-copy span {
    margin-top: 5px;
    color: #d8e8f0;
    font-size: 13px;
    font-weight: 500;
}

.staff-portal-label {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #edf6fa;
    font-size: 15px;
    font-weight: 750;
}

.staff-portal-label svg {
    width: 23px;
    height: 23px;
    stroke: currentColor;
}

.portal-main {
    width: min(1420px, 100%);
    flex: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(420px, 0.9fr);
    align-items: center;
    gap: clamp(48px, 6vw, 92px);
    margin: 0 auto;
    padding: 48px 38px 34px;
    animation: none;
}

.hero-panel {
    position: relative;
    min-height: auto;
    padding: 12px 0 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    backdrop-filter: none;
    overflow: visible;
}

.hero-panel::before,
.hero-panel::after {
    display: none;
}

.service-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border: 0;
    border-radius: 999px;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    box-shadow: none;
}

.service-badge svg {
    width: 17px;
    height: 17px;
    stroke: currentColor;
}

.hero-panel h1 {
    max-width: 580px;
    margin: 28px 0 16px;
    color: var(--ink);
    font-size: clamp(44px, 4.4vw, 66px);
    line-height: 0.98;
    letter-spacing: -0.055em;
}

.hero-panel h1 span {
    color: var(--blue);
}

.hero-rule {
    width: 58px;
    height: 4px;
    margin: 0 0 18px;
    border-radius: 99px;
    background: var(--blue);
}

.hero-copy {
    max-width: 570px;
    margin: 0;
    color: #465a75;
    font-size: 16px;
    line-height: 1.65;
    font-weight: 450;
}

.utility-art {
    display: block;
    width: min(100%, 700px);
    height: 150px;
    margin: 16px 0 0;
    object-fit: contain;
    object-position: center bottom;
    clip-path: inset(2px 0 0 0);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
    margin-top: 4px;
}

.feature-item {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 10px;
    min-width: 0;
}

.feature-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    background: var(--blue-soft);
    color: var(--blue);
}

.feature-icon svg {
    width: 23px;
    height: 23px;
    stroke: currentColor;
}

.feature-item strong {
    display: block;
    color: var(--ink);
    font-size: 13px;
    line-height: 1.3;
}

.feature-item p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.45;
}

.login-card {
    position: relative;
    width: 100%;
    max-width: 600px;
    justify-self: end;
    margin: 0;
    padding: clamp(38px, 4vw, 54px);
    border: 1px solid #dce5ef;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 20px 55px rgba(49, 76, 109, 0.11);
    backdrop-filter: none;
    overflow: hidden;
}

.login-card::before,
.login-card::after {
    display: none;
}

.login-logo {
    display: block;
    width: 66px;
    height: 66px;
    margin: 0 auto 20px;
    padding: 6px;
    border-radius: 15px;
    background: var(--blue);
    object-fit: contain;
}

.login-card h2 {
    margin: 0;
    color: var(--ink);
    font-size: 27px;
    line-height: 1.2;
    letter-spacing: -0.035em;
    text-align: center;
}

.login-card .subtext {
    margin: 8px 0 28px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.5;
    font-weight: 450;
    text-align: center;
}

.field-group {
    margin-bottom: 18px;
}

.field-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--ink);
    font-size: 13px;
    font-weight: 750;
    letter-spacing: 0;
    text-transform: none;
}

.input-wrap {
    position: relative;
}

.field-icon {
    position: absolute;
    top: 50%;
    left: 15px;
    width: 21px;
    height: 21px;
    color: #314c70;
    pointer-events: none;
    transform: translateY(-50%);
}

.field-icon svg {
    width: 100%;
    height: 100%;
    stroke: currentColor;
}

input[type="text"],
input[type="password"] {
    width: 100%;
    height: 52px;
    padding: 0 48px;
    border: 1px solid #cbd8e7;
    border-radius: 9px;
    background: #ffffff;
    color: var(--ink);
    font-size: 14px;
    font-weight: 500;
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

input[type="password"] {
    padding-right: 78px;
}

input::placeholder {
    color: #7b8da7;
    font-weight: 400;
}

input:focus {
    border-color: var(--blue);
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(8, 104, 201, 0.11);
    transform: none;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 13px;
    min-width: auto;
    height: auto;
    padding: 5px;
    border: 0;
    border-radius: 5px;
    background: transparent;
    color: var(--blue);
    font-size: 13px;
    font-weight: 750;
    cursor: pointer;
    transform: translateY(-50%);
}

.password-toggle:hover {
    background: var(--blue-soft);
    box-shadow: none;
    transform: translateY(-50%);
}

.login-options {
    display: flex;
    justify-content: flex-end;
    margin: -2px 0 22px;
}

.help-link {
    color: var(--blue);
    font-size: 13px;
    font-weight: 750;
    text-decoration: none;
}

.help-link:hover {
    color: var(--blue-dark);
    text-decoration: underline;
}

.login-button {
    position: relative;
    width: 100%;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border: 0;
    border-radius: 9px;
    background: var(--blue);
    color: #ffffff;
    font-weight: 750;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(8, 104, 201, 0.18);
    overflow: hidden;
    transition: background 0.18s ease, box-shadow 0.18s ease;
}

.login-button svg {
    width: 19px;
    height: 19px;
    stroke: currentColor;
}

.login-button:hover {
    background: var(--blue-dark);
    box-shadow: 0 10px 24px rgba(8, 86, 168, 0.2);
    filter: none;
    transform: none;
}

.login-button:active {
    transform: none;
}

.water-ripple {
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.3);
    transform: scale(0);
    animation: waterRipple 700ms ease-out;
    pointer-events: none;
}

@keyframes waterRipple {
    to {
        transform: scale(2.55);
        opacity: 0;
    }
}

.error {
    display: none;
    margin: 0 0 18px;
    padding: 11px 12px;
    border: 1px solid #efc7c7;
    border-radius: 8px;
    background: #fff5f5;
    color: var(--danger);
    font-size: 13px;
    font-weight: 600;
}

.security-note {
    position: relative;
    display: grid;
    justify-items: center;
    gap: 10px;
    margin: 24px 0 0;
    padding: 20px 0 0;
    border: 0;
    border-top: 1px solid var(--line);
    border-radius: 0;
    background: transparent;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.55;
    font-weight: 450;
    text-align: center;
}

.security-note::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 50%;
    width: 56px;
    height: 1px;
    background: #ffffff;
    transform: translateX(-50%);
}

.security-note strong {
    z-index: 1;
    width: 24px;
    height: 24px;
    margin-top: -32px;
    display: grid;
    place-items: center;
    border-radius: 99px;
    background: #ffffff;
    color: var(--blue);
    font-size: 12px;
}

.security-note strong svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
}

.portal-footer {
    width: 100%;
    margin: 0;
    padding: 16px 24px;
    border-top: 1px solid #e0e8f1;
    background: #ffffff;
    color: #617493;
    font-size: 12px;
    font-weight: 450;
    text-align: center;
}

@media (max-width: 1050px) {
    .portal-main {
        grid-template-columns: 1fr;
        gap: 36px;
        padding-top: 38px;
    }

    .hero-panel {
        width: min(100%, 680px);
        margin: 0 auto;
        text-align: center;
    }

    .hero-panel h1,
    .hero-copy {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-rule {
        margin-left: auto;
        margin-right: auto;
    }

    .utility-art {
        margin-left: auto;
        margin-right: auto;
    }

    .login-card {
        width: min(100%, 600px);
        justify-self: center;
    }
}

@media (max-width: 680px) {
    .simple-login-header-inner {
        min-height: 68px;
        padding: 9px 16px;
    }

    .header-brand-logo {
        width: 44px;
        height: 44px;
        border-radius: 11px;
    }

    .header-brand-copy strong {
        font-size: 19px;
    }

    .header-brand-copy span {
        display: none;
    }

    .staff-portal-label {
        font-size: 12px;
    }

    .staff-portal-label svg {
        width: 19px;
        height: 19px;
    }

    .portal-main {
        display: flex;
        flex-direction: column;
        gap: 28px;
        padding: 28px 14px 24px;
    }

    .hero-panel {
        order: 2;
        display: block;
        width: min(100%, 500px);
        padding: 14px 8px 0;
        text-align: center;
    }

    .hero-panel h1 {
        margin: 18px auto 12px;
        font-size: 30px;
        line-height: 1.08;
        letter-spacing: -0.04em;
    }

    .hero-panel h1 br {
        display: none;
    }

    .hero-rule {
        width: 44px;
        height: 3px;
        margin: 0 auto 14px;
    }

    .hero-copy {
        max-width: 390px;
        margin: 0 auto;
        font-size: 13px;
        line-height: 1.55;
    }

    .utility-art {
        display: block;
        width: min(100%, 480px);
        height: 112px;
        margin: 12px auto 0;
    }

    .feature-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        width: min(100%, 360px);
        margin: 6px auto 0;
        text-align: left;
    }

    .feature-item {
        grid-template-columns: 40px 1fr;
        align-items: center;
    }

    .feature-icon {
        width: 40px;
        height: 40px;
    }

    .login-card {
        order: 1;
    }

    .login-card {
        padding: 30px 22px;
        border-radius: 14px;
    }

    .login-logo {
        width: 58px;
        height: 58px;
    }

    .login-card h2 {
        font-size: 24px;
    }
}

@media (max-width: 420px) {
    .hero-panel h1 {
        font-size: 28px;
    }

    .service-badge {
        font-size: 10px;
    }
}

@media (max-width: 360px) {
    .simple-login-header-inner {
        min-height: 62px;
        padding: 8px 12px;
        gap: 10px;
    }

    .header-brand-logo {
        width: 40px;
        height: 40px;
        padding: 4px;
    }

    .header-brand-copy strong {
        font-size: 17px;
    }

    .staff-portal-label {
        gap: 0;
    }

    .staff-portal-label svg {
        display: block;
        width: 20px;
        height: 20px;
    }

    .staff-label-text {
        display: none;
    }

    .portal-main {
        padding: 20px 10px;
    }

    .login-card {
        padding: 26px 16px;
        border-radius: 12px;
    }

    .login-logo {
        width: 54px;
        height: 54px;
        margin-bottom: 16px;
    }

    .login-card h2 {
        font-size: 22px;
    }

    .login-card .subtext {
        margin-bottom: 24px;
        font-size: 13px;
    }

    .field-icon {
        left: 12px;
        width: 19px;
        height: 19px;
    }

    input[type="text"],
    input[type="password"] {
        height: 50px;
        padding-left: 40px;
        padding-right: 12px;
        font-size: 13px;
    }

    input[type="password"] {
        padding-right: 56px;
    }

    .password-toggle {
        right: 7px;
        font-size: 12px;
    }

    .portal-footer {
        padding: 14px 12px;
        font-size: 11px;
    }
}

@media (max-height: 600px) and (max-width: 950px) and (orientation: landscape) {
    .portal-main {
        display: flex;
        flex-direction: column;
        gap: 26px;
        padding-top: 22px;
        padding-bottom: 22px;
    }

    .login-card {
        order: 1;
        width: min(100%, 560px);
        justify-self: center;
    }

    .hero-panel {
        order: 2;
        display: block;
        width: min(100%, 620px);
        padding: 12px 8px 0;
        text-align: center;
    }

    .hero-panel h1 {
        margin: 16px auto 12px;
        font-size: 32px;
        line-height: 1.08;
    }

    .hero-panel h1 br {
        display: none;
    }

    .hero-rule {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-copy {
        margin-left: auto;
        margin-right: auto;
        font-size: 13px;
    }

    .utility-art {
        height: 118px;
        margin-left: auto;
        margin-right: auto;
    }
}
