:root {
    color-scheme: dark;
    font-family: Arial, Helvetica, sans-serif;
    background: #050505;
    --wine: #8f2038;
    --wine-light: #ad2946;
    --rose: #cc6d7d;
    --cream: #f4eee9;
    --muted: #c6bdbb;
    --line: rgba(205, 180, 180, .22);
}
* { box-sizing: border-box; }
html, body { margin: 0; min-width: 0; min-height: 100%; }
.login-page {
    overflow-x: hidden;
    color: var(--cream);
    background: #050505 url('/assets/morgana-hero-final.jpg') center 16% / cover no-repeat fixed;
}
.login-page::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(90deg, rgba(0,0,0,.78), rgba(0,0,0,.34) 50%, rgba(0,0,0,.78)), linear-gradient(180deg, rgba(0,0,0,.38), rgba(0,0,0,.2) 50%, rgba(0,0,0,.62));
}
.login-shell {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    min-height: 100vh;
    min-height: 100svh;
    padding: max(24px, env(safe-area-inset-top)) max(18px, env(safe-area-inset-right)) max(24px, env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left));
}
.login-card {
    width: min(100%, 520px);
    padding: clamp(30px, 5vw, 48px);
    border: 1px solid var(--line);
    border-radius: 30px;
    background: rgba(8, 6, 7, .88);
    box-shadow: 0 28px 80px rgba(0,0,0,.62), inset 0 1px 0 rgba(255,255,255,.035);
    backdrop-filter: blur(12px);
}
.login-brand { position: relative; display: flex; align-items: center; justify-content: center; margin-bottom: 28px; }
.login-brand img { display: block; width: min(330px, 84%); height: auto; object-fit: contain; }
.login-edition { position: absolute; top: -14px; right: -14px; padding: 5px 8px; border: 1px solid rgba(190,87,105,.38); border-radius: 999px; color: #d5a3ab; font-size: 9px; font-weight: 700; letter-spacing: .15em; }
.login-heading { margin-bottom: 28px; text-align: center; }
.login-kicker { margin: 0 0 18px; color: var(--rose) !important; font-size: 12px !important; font-weight: 800; letter-spacing: .22em; }
.login-heading h1 { display: none; }
.login-heading p { margin: 0; color: var(--muted); font-size: 16px; line-height: 1.5; }
.login-error { margin: 0 0 17px; padding: 11px 13px; border: 1px solid rgba(194,65,86,.42); border-radius: 10px; color: #ffd9df; background: rgba(114,23,39,.34); font-size: 14px; }
.login-form { display: grid; gap: 10px; }
.login-form label { margin-top: 7px; color: #ded6d3; font-size: 13px; font-weight: 500; }
.login-form input {
    display: block; width: 100%; min-width: 0; height: 54px; padding: 0 15px;
    border: 1px solid rgba(191,171,171,.2); border-radius: 5px; outline: none;
    color: #fff; background: rgba(3,3,3,.72); font: inherit; font-size: 16px;
    transition: border-color .18s, box-shadow .18s, background .18s;
}
.login-form input:focus { border-color: #9b3349; background: rgba(2,2,2,.9); box-shadow: 0 0 0 2px rgba(143,32,56,.18); }
.login-form button {
    width: 100%; min-height: 54px; margin-top: 16px; border: 1px solid #b23950; border-radius: 5px;
    color: #fff; background: linear-gradient(100deg, #a21f3a, #7d1b31); box-shadow: 0 12px 28px rgba(91,16,30,.34);
    font: inherit; font-size: 16px; font-weight: 500; cursor: pointer;
}
.login-form button:hover { background: linear-gradient(100deg, #b42643, #92213a); }
.login-form button:focus-visible { outline: 3px solid rgba(190,87,105,.48); outline-offset: 3px; }
@media (max-width: 480px) {
    .login-page { background-position: 52% top; }
    .login-shell { place-items: center; padding: max(18px,env(safe-area-inset-top)) 16px max(18px,env(safe-area-inset-bottom)); }
    .login-card { padding: 30px 24px 34px; border-radius: 25px; }
    .login-brand { margin-bottom: 24px; }
    .login-brand img { width: min(300px, 88%); }
    .login-edition { top: -13px; right: -11px; }
    .login-heading { margin-bottom: 23px; }
}
@media (max-height: 700px), (orientation: landscape) and (max-height: 560px) {
    .login-shell { place-items: start center; padding-top: max(12px,env(safe-area-inset-top)); padding-bottom: max(12px,env(safe-area-inset-bottom)); }
    .login-card { margin: auto 0; padding-top: 20px; padding-bottom: 20px; }
    .login-brand { margin-bottom: 13px; }
    .login-brand img { max-height: 52px; width: auto; max-width: 75%; }
    .login-heading { margin-bottom: 10px; }
    .login-kicker { margin-bottom: 7px; }
    .login-heading p { font-size: 14px; }
    .login-form input { height: 43px; }
    .login-form button { min-height: 43px; margin-top: 7px; }
}
@media (prefers-reduced-motion: reduce) { .login-form input { transition: none; } }
