:root {
    color: #111118;
    font-family: Inter, "Helvetica Neue", Arial, sans-serif;
    font-synthesis: none;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-width: 320px;
    background: #0c0c11;
}

button,
input {
    font: inherit;
}

.login-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(280px, 0.72fr) minmax(520px, 1.28fr);
    background:
        radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.16), transparent 22%),
        radial-gradient(circle at 82% 86%, rgba(255, 255, 255, 0.07), transparent 30%),
        linear-gradient(145deg, #191920 0%, #0d0d13 58%, #08080c 100%);
}

.portal-context {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(36px, 5vw, 72px);
    color: #fff;
    border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.portal-context::after {
    content: "";
    position: absolute;
    width: min(36vw, 520px);
    height: min(36vw, 520px);
    right: -55%;
    bottom: -16%;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
}

.portal-context__brand,
.portal-context__message {
    position: relative;
    z-index: 1;
}

.portal-context__brand {
    display: flex;
    flex-direction: column;
    width: max-content;
    line-height: 0.86;
    font-size: clamp(1.55rem, 2.35vw, 2.45rem);
    font-weight: 300;
    letter-spacing: -0.035em;
}

.portal-context__brand small {
    margin-top: 10px;
    font-size: 0.55em;
    font-style: italic;
    letter-spacing: 0;
}

.portal-context__message {
    max-width: 330px;
}

.portal-context__message > p:last-child {
    margin: 0;
    color: #cfcfd4;
    font-size: 1.05rem;
    line-height: 1.6;
}

.eyebrow {
    margin: 0 0 12px;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.16em;
}

.access {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: clamp(28px, 6vw, 80px);
}

.login-card {
    width: min(100%, 560px);
    padding: clamp(32px, 5vw, 56px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
}

.login-card__header {
    margin-bottom: 34px;
}

.eyebrow--muted {
    color: #8b8b92;
}

.login-card h1 {
    margin: 0;
    font-size: clamp(2.45rem, 4vw, 4rem);
    font-weight: 900;
    letter-spacing: -0.045em;
    line-height: 0.96;
}

.login-card__header > p:last-child {
    margin: 16px 0 0;
    color: #66666d;
    font-size: 1.06rem;
    line-height: 1.5;
}

.alert {
    margin-bottom: 24px;
    padding: 14px 16px;
    border-radius: 10px;
    font-size: 0.95rem;
    line-height: 1.45;
}

.alert--error {
    color: #8f1717;
    border: 1px solid #dfb0b0;
    background: #fff1f1;
}

.alert--success {
    color: #1e6a3d;
    border: 1px solid #c5e3d1;
    background: #effaf3;
}

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

.login-form label {
    margin-top: 8px;
    font-size: 0.84rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.field {
    min-height: 60px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 16px;
    border: 1px solid #d1d1d7;
    border-radius: 10px;
    background: #fff;
    transition: border-color 160ms ease, box-shadow 160ms ease;
}

.field:focus-within {
    border-color: #2f2f32;
    box-shadow: 0 0 0 3px rgba(47, 47, 50, 0.12);
}

.field--error {
    border-color: #b93434;
}

.field--error:focus-within {
    border-color: #971f1f;
    box-shadow: 0 0 0 3px rgba(151, 31, 31, 0.12);
}

.field svg,
.submit-button svg {
    width: 22px;
    height: 22px;
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 1.8;
}

.field > svg {
    color: #77777e;
}

.field input {
    width: 100%;
    min-width: 0;
    padding: 17px 0;
    border: 0;
    outline: 0;
    color: #15151a;
    background: transparent;
}

.field input::placeholder {
    color: #96969d;
}

.password-toggle {
    display: grid;
    place-items: center;
    padding: 8px;
    border: 0;
    color: #68686f;
    background: transparent;
    cursor: pointer;
}

.submit-button {
    min-height: 68px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
    border: 0;
    border-radius: 10px;
    color: #fff;
    background: #303030;
    box-shadow: 0 16px 28px rgba(0, 0, 0, 0.2);
    font-size: 1.05rem;
    font-weight: 900;
    cursor: pointer;
    transition: background 160ms ease, transform 160ms ease;
}

.submit-button:hover {
    background: #151515;
    transform: translateY(-1px);
}

.submit-button:focus-visible,
.password-toggle:focus-visible {
    outline: 3px solid #a31818;
    outline-offset: 3px;
}

@media (max-width: 820px) {
    .login-shell {
        display: block;
        padding: 24px;
    }

    .portal-context {
        min-height: auto;
        display: block;
        padding: 10px 4px 30px;
        border: 0;
    }

    .portal-context__brand {
        font-size: 1.5rem;
    }

    .portal-context__message {
        display: none;
    }

    .access {
        min-height: auto;
        display: block;
        padding: 0;
    }

    .login-card {
        margin: 0 auto;
        border-radius: 18px;
    }
}

@media (max-width: 480px) {
    .login-shell {
        padding: 22px 16px;
    }

    .login-card {
        padding: 32px 22px;
    }

    .login-card h1 {
        font-size: 2.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    * {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}
