.auth-shell {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 36px 18px 54px;
    box-sizing: border-box;
}

.auth-card {
    width: min(100%, 470px);
    border: 1px solid rgba(0, 115, 204, 0.34);
    border-radius: 0;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(27, 37, 48, 0.98), rgba(19, 26, 34, 0.95));
    box-shadow: 0 22px 50px rgba(0, 0, 0, 0.28);
}

.auth-header {
    padding: 24px 28px 20px;
    background:
        radial-gradient(circle at top right, rgba(255, 255, 255, 0.14), transparent 34%),
        linear-gradient(135deg, #0073cc 0%, #00539b 100%);
    color: #fff;
}

.auth-header h1 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 2.6rem);
    line-height: 1;
}

.auth-kicker {
    margin: 0 0 10px;
    font-family: Monaco, monospace;
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.82;
}

.auth-subtitle {
    margin: 12px 0 0;
    font-size: 1rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.88);
}

.auth-body {
    padding: 26px 28px 30px;
}

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

.auth-field {
    display: grid;
    gap: 8px;
}

.auth-field label {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.92);
}

.auth-field input[type="text"],
.auth-field input[type="password"] {
    width: 100%;
    border: 1px solid rgba(125, 166, 207, 0.34);
    border-radius: 0;
    background: rgba(8, 14, 20, 0.9);
    color: #fff;
    padding: 12px 14px;
    font-size: 1rem;
    font-family: Monaco, monospace;
    box-sizing: border-box;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease;
}

.auth-field input[type="text"]::placeholder,
.auth-field input[type="password"]::placeholder {
    color: rgba(255, 255, 255, 0.42);
}

.auth-field input[type="text"]:focus,
.auth-field input[type="password"]:focus {
    outline: none;
    border-color: #53b4ff;
    box-shadow: 0 0 0 3px rgba(83, 180, 255, 0.18);
    background: rgba(10, 17, 24, 0.96);
}

.auth-submit {
    width: 100%;
    border: none;
    border-radius: 0;
    background: linear-gradient(135deg, #0073cc 0%, #00539b 100%);
    color: #fff;
    padding: 13px 16px;
    font-size: 1rem;
    font-family: YoungSerif, serif;
    cursor: pointer;
    transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
    box-shadow: 0 10px 24px rgba(0, 83, 155, 0.28);
}

.auth-submit:hover,
.auth-submit:focus {
    filter: brightness(1.04);
    transform: translateY(-1px);
}

.auth-submit:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(83, 180, 255, 0.22), 0 10px 24px rgba(0, 83, 155, 0.28);
}

.auth-submit:active {
    transform: translateY(0);
}

.auth-errors,
.auth-field-errors {
    border-radius: 0;
    background: rgba(255, 93, 115, 0.12);
    border: 1px solid rgba(255, 93, 115, 0.34);
    color: #ffd7dd;
    padding: 10px 12px;
}

.auth-errors p,
.auth-field-errors p {
    margin: 0;
}

.auth-field.has-error input[type="text"],
.auth-field.has-error input[type="password"] {
    border-color: rgba(255, 93, 115, 0.56);
}

.auth-help-text {
    border: 1px solid rgba(125, 166, 207, 0.24);
    background: rgba(255, 255, 255, 0.04);
    color: rgba(255, 255, 255, 0.78);
    padding: 10px 12px;
    font-size: 0.92rem;
    line-height: 1.55;
}

.auth-help-text ul {
    margin: 0;
    padding-left: 18px;
}

.auth-help-text li + li {
    margin-top: 6px;
}

.auth-message-body {
    display: grid;
    gap: 18px;
}

.auth-message-copy {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
}

.auth-link-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-sizing: border-box;
}

body.site-shell[data-profile-theme="light"] .auth-card {
    border-color: rgba(127, 169, 207, 0.42);
    background: linear-gradient(180deg, rgba(251, 248, 240, 0.98), rgba(244, 241, 232, 0.96));
    box-shadow: 0 22px 50px rgba(54, 64, 76, 0.14);
}

body.site-shell[data-profile-theme="light"] .auth-field label {
    color: #1b2530;
}

body.site-shell[data-profile-theme="light"] .auth-field input[type="text"],
body.site-shell[data-profile-theme="light"] .auth-field input[type="password"] {
    background: #fbf8f0;
    border-color: rgba(127, 169, 207, 0.58);
    color: #1b2530;
}

body.site-shell[data-profile-theme="light"] .auth-field input[type="text"]::placeholder,
body.site-shell[data-profile-theme="light"] .auth-field input[type="password"]::placeholder {
    color: rgba(27, 37, 48, 0.46);
}

body.site-shell[data-profile-theme="light"] .auth-field input[type="text"]:focus,
body.site-shell[data-profile-theme="light"] .auth-field input[type="password"]:focus {
    background: #fffdf8;
}

body.site-shell[data-profile-theme="light"] .auth-errors,
body.site-shell[data-profile-theme="light"] .auth-field-errors {
    background: rgba(255, 93, 115, 0.1);
    color: #7a1d2d;
}

body.site-shell[data-profile-theme="light"] .auth-help-text {
    background: rgba(27, 37, 48, 0.04);
    border-color: rgba(127, 169, 207, 0.42);
    color: rgba(27, 37, 48, 0.78);
}

body.site-shell[data-profile-theme="light"] .auth-message-copy {
    color: #1b2530;
}

@media (max-width: 750px) {
    .auth-shell {
        padding: 18px 10px 22px;
    }

    .auth-header {
        padding: 20px 20px 18px;
    }

    .auth-body {
        padding: 20px;
    }
}
