:root {
    --auth-navy: #0b2342;
    --auth-blue: #173b63;
    --auth-blue-light: #245481;
    --auth-accent: #70b7ff;
    --auth-ink: #172033;
    --auth-muted: #718096;
    --auth-line: #dfe5ec;
    --auth-surface: #ffffff;
    --auth-canvas: #eef2f7;
    --auth-radius: 18px;
    --auth-control-radius: 10px;
    --auth-shadow: 0 24px 70px rgba(3, 17, 34, 0.28);
}

body {
    height: 100dvh;
    min-height: 0;
    padding: clamp(14px, 2.5vh, 28px) clamp(18px, 3vw, 46px);
    display: grid;
    place-items: center;
    overflow: hidden;
    background:
        radial-gradient(circle at 12% 12%, rgba(91, 151, 211, 0.2), transparent 30%),
        linear-gradient(135deg, #071a31, var(--auth-navy));
}

.login-shell {
    width: min(1120px, 100%);
    height: min(760px, calc(100dvh - clamp(28px, 5vh, 56px)));
    min-height: 0;
    grid-template-columns: minmax(360px, 1.04fr) minmax(390px, 0.96fr);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--auth-radius);
    background: var(--auth-surface);
    box-shadow: var(--auth-shadow);
}

.brand-panel {
    padding: clamp(28px, 4.5vh, 46px) clamp(34px, 5vw, 70px);
    background:
        radial-gradient(circle at 85% 13%, rgba(112, 183, 255, 0.22), transparent 32%),
        linear-gradient(145deg, var(--auth-blue), var(--auth-navy));
}

.brand-panel::before,
.brand-panel::after {
    border-color: rgba(255, 255, 255, 0.1);
}

.brand-icon {
    color: var(--auth-navy);
    border-radius: 12px;
}

.brand-panel .eyebrow {
    color: var(--auth-accent);
}

.brand-content h1 {
    font-size: clamp(36px, min(4.1vw, 6.2vh), 56px);
}

.brand-copy {
    margin-top: clamp(14px, 2.4vh, 22px);
    color: #d2deeb;
    line-height: 1.6;
}

.agency-card {
    padding: 9px 15px;
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.11);
}

.access-panel {
    padding: clamp(22px, 3.5vh, 38px) clamp(30px, 4vw, 52px);
    background:
        linear-gradient(rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.96)),
        radial-gradient(circle at 50% 7%, #dce9f5, transparent 46%);
}

.access-card {
    width: min(410px, 100%);
}

.access-mark {
    width: 52px;
    height: 52px;
    margin-bottom: 17px;
    color: var(--auth-blue);
    background: #e7eef6;
}

.access-card h2 {
    margin-top: 3px;
    color: var(--auth-blue);
}

.instruction {
    margin-bottom: 20px;
}

.input-group {
    margin-bottom: 13px;
}

.divider {
    margin: 18px 0 14px;
}

.workspace-note {
    margin-top: 7px;
}

.privacy-note {
    margin-top: 18px;
}

.footer {
    margin-top: 18px;
}

.input-group label {
    color: #4d5f73;
}

input {
    border-color: var(--auth-line);
    border-radius: var(--auth-control-radius);
}

input:focus {
    border-color: var(--auth-blue);
    box-shadow: 0 0 0 3px rgba(23, 59, 99, 0.12);
}

.primary-button {
    border-radius: var(--auth-control-radius);
    background: var(--auth-navy);
    box-shadow: 0 9px 24px rgba(11, 35, 66, 0.22);
}

.primary-button:hover,
.primary-button:focus-visible {
    background: var(--auth-blue);
}

.workspace-link {
    border-radius: var(--auth-control-radius);
    color: var(--auth-blue);
}

.workspace-link:hover,
.workspace-link:focus-visible {
    border-color: var(--auth-blue);
    color: var(--auth-navy);
    background: #f2f6fa;
}

@media (max-width: 1200px) and (min-width: 901px) {
    .login-shell {
        grid-template-columns: minmax(0, 1fr) minmax(390px, 0.92fr);
    }

    .brand-panel {
        padding-inline: clamp(30px, 4vw, 48px);
    }

    .brand-content h1 {
        max-width: 520px;
        font-size: clamp(34px, 4vw, 44px);
        line-height: 1.06;
    }

    .brand-copy {
        max-width: 470px;
        font-size: 13px;
    }
}

@media (min-width: 901px) and (max-height: 900px) {
    .brand-panel {
        padding-block: clamp(24px, 3.5vh, 34px);
    }

    .brand-content h1 {
        font-size: clamp(34px, min(4vw, 5.6vh), 48px);
    }

    .brand-copy {
        margin-top: 14px;
    }

    .agency-card img {
        max-height: 50px;
    }

    .access-panel {
        padding-block: clamp(18px, 2.8vh, 28px);
    }
}

@media (min-width: 901px) and (max-height: 800px) {
    .brand-panel {
        padding-block: 22px;
    }

    .brand-content h1 {
        font-size: clamp(32px, 5vh, 42px);
    }

    .brand-copy {
        max-width: 500px;
        font-size: 13px;
        line-height: 1.5;
    }

    .agency-card {
        padding: 7px 12px;
    }

    .agency-card img {
        max-height: 42px;
    }

    .access-mark {
        width: 48px;
        height: 48px;
        margin-bottom: 12px;
    }

    .access-card h2 {
        font-size: 27px;
    }

    .instruction,
    .divider {
        margin-bottom: 14px;
    }

    .input-group {
        margin-bottom: 11px;
    }

    .privacy-note,
    .footer {
        margin-top: 13px;
    }
}

@media (min-width: 901px) and (max-height: 700px) {
    .brand-panel::before {
        width: 380px;
        height: 380px;
    }

    .brand-panel::after {
        width: 250px;
        height: 250px;
    }

    .brand-copy {
        line-height: 1.4;
    }

    .access-panel {
        padding-block: 14px;
    }

    .workspace-note {
        display: none;
    }
}

@media (max-width: 900px) {
    body {
        height: auto;
        min-height: 100dvh;
        padding: 0;
        display: block;
        overflow: auto;
    }

    .login-shell {
        width: 100%;
        height: auto;
        min-height: 100vh;
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto auto;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }

    .brand-panel {
        min-height: clamp(220px, 31vh, 320px);
    }

    .access-panel {
        min-height: calc(100dvh - clamp(220px, 31vh, 320px));
    }
}

@media (max-width: 520px) {
    .brand-panel {
        min-height: clamp(165px, 23vh, 210px);
        padding: 20px 24px;
    }

    .brand-content {
        margin: 14px 0 0;
    }

    .brand-content .eyebrow,
    .brand-copy {
        display: none;
    }

    .brand-content h1 {
        font-size: 34px;
    }

    .access-panel {
        min-height: calc(100dvh - clamp(165px, 23vh, 210px));
        padding: 30px 20px;
    }

    .workspace-link,
    .primary-button,
    input {
        min-height: 44px;
    }
}

@media (max-width: 520px) and (max-height: 700px) {
    .brand-panel {
        min-height: 165px;
        padding-block: 20px;
    }

    .system-brand {
        font-size: 14px;
    }

    .brand-icon {
        width: 36px;
        height: 36px;
    }

    .brand-content {
        margin-top: 16px;
    }

    .brand-content .eyebrow,
    .brand-copy {
        display: none;
    }

    .brand-content h1 {
        font-size: 29px;
    }

    .access-panel {
        min-height: calc(100dvh - 165px);
        padding-block: 24px;
    }
}
