:root {
    --red: #3A0F34;
    --red-deep: #2A0B26;
    --gold: #EAAA00;
    --gold-soft: #F5D56A;
    --ink: #2A1026;
    --muted: #5c6670;
    --line: #c5ced6;
    --field: #ffffff;
    --sans: "Outfit", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body.auth-body {
    font-family: var(--sans);
    color: var(--ink);
    background: #2A0B26;
    min-height: 100vh;
    overflow-x: hidden;
}

.gallery {
    position: fixed;
    inset: 0;
    display: flex;
    gap: 16px;
    padding: 16px;
    pointer-events: none;
}
.col { flex: 1; overflow: hidden; min-width: 0; }
.track {
    display: flex;
    flex-direction: column;
    animation: drift var(--speed, 42s) linear infinite;
    will-change: transform;
}
.col.reverse .track { animation-direction: reverse; }
.set { display: flex; flex-direction: column; gap: 16px; padding-bottom: 16px; }
.tile {
    position: relative;
    height: 360px;
    border-radius: 20px;
    overflow: hidden;
    flex: none;
    box-shadow: 0 12px 28px rgba(20, 8, 12, 0.16);
}
.tile img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: saturate(1.12) contrast(1.05);
}
.tile::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 46%;
    background: linear-gradient(to top, rgba(18, 6, 8, 0.62), transparent);
}
.tile figcaption {
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 14px;
    z-index: 1;
    color: white;
}
.tile strong { display: block; font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.tile span {
    display: inline-block;
    margin-top: 6px;
    padding: 3px 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    font-size: 12px;
    font-weight: 650;
}

@keyframes drift {
    from { transform: translateY(0); }
    to { transform: translateY(-50%); }
}

.veil {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(42, 11, 38, 0.55), rgba(58, 15, 52, 0.28) 42%, rgba(42, 11, 38, 0.62));
}
.card-glow {
    position: fixed;
    top: 50%;
    right: 6vw;
    width: min(520px, 46vw);
    height: 86vh;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.28);
    filter: blur(22px);
    border-radius: 48px;
    pointer-events: none;
}

.stage {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: grid;
    grid-template-columns: minmax(280px, 1.05fr) minmax(340px, 440px);
    align-items: safe center;
    gap: 48px;
    padding: 48px 6vw;
}
.headline {
    max-width: 640px;
    padding: 36px 40px 32px;
    border-radius: 28px;
    background: rgba(250, 248, 247, 0.94);
    border: 1px solid rgba(244, 217, 148, 0.55);
    box-shadow: 0 18px 50px rgba(28, 8, 12, 0.1);
    backdrop-filter: blur(16px);
}
.headline h1 {
    margin: 0;
    font-size: clamp(38px, 4.4vw, 62px);
    line-height: 1.02;
    letter-spacing: -0.045em;
    font-weight: 800;
    color: var(--ink);
}
.headline h1 span { color: var(--red); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.chips span {
    background: #fff;
    border: 1px solid var(--line);
    color: var(--red);
    border-radius: 999px;
    padding: 7px 13px;
    font-size: 13px;
    font-weight: 650;
}

.auth-card {
    background: #fff;
    border-radius: 22px;
    overflow: hidden;
    box-shadow: 0 22px 60px rgba(20, 8, 12, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-top: 4px solid var(--gold);
}
.auth-card-head {
    background: transparent;
    color: #8d8d8d;
    text-align: left;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    padding: 22px 30px 0;
    font-size: 12px;
}
.auth-card-body { padding: 16px 30px 28px; }
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.brand-mark {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    color: var(--ink);
    font-weight: 800;
    font-size: 20px;
    background: var(--gold);
    box-shadow: none;
}
.auth-brand strong { display: block; font-size: 16px; letter-spacing: -0.03em; }
.auth-brand small { display: block; margin-top: 2px; color: var(--muted); font-weight: 600; font-size: 13px; }
.auth-card h2 {
    margin: 0;
    color: var(--red);
    font-size: 34px;
    line-height: 1.05;
    letter-spacing: -0.04em;
    font-weight: 800;
}
.auth-card .sub {
    margin: 8px 0 20px;
    color: var(--muted);
    font-size: 15px;
    line-height: 1.45;
}

.auth-form { display: grid; gap: 16px; }
.auth-field { display: grid; gap: 7px; }
.auth-field label { font-size: 13px; font-weight: 700; color: #3a3a3a; }
.auth-field input {
    width: 100%;
    height: 52px;
    border: 1.5px solid #e4e4e6;
    border-radius: 10px;
    padding: 0 14px;
    font: inherit;
    font-size: 15px;
    color: var(--ink);
    background: var(--field);
}
.auth-field input::placeholder { color: #a3a3a3; }
.auth-field input:focus {
    outline: 3px solid rgba(72, 24, 88, 0.18);
    border-color: var(--red);
    background: #fff;
}
.auth-field input:-webkit-autofill,
.auth-field input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--ink);
    -webkit-box-shadow: 0 0 0 1000px #fff inset;
    caret-color: var(--ink);
}
.auth-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    font-size: 14px;
}
.auth-row label { display: flex; align-items: center; gap: 8px; font-weight: 600; color: #3f3f3f; }
.auth-row input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--red); }
.auth-row a { color: var(--red); font-weight: 750; text-decoration: none; }
.auth-row a:hover { text-decoration: underline; }

.auth-btn {
    height: 52px;
    border: 0;
    border-radius: 8px;
    cursor: pointer;
    font: inherit;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #3A0F34;
    background: #EAAA00;
    box-shadow: 0 10px 20px rgba(58, 15, 52, 0.22);
}
.auth-btn:hover { filter: brightness(1.05); }
.switch {
    margin: 18px 0 0;
    text-align: center;
    color: var(--muted);
    font-size: 14px;
}
.switch a { color: var(--red); font-weight: 800; text-decoration: none; }
.switch a:hover { text-decoration: underline; }
.fine {
    margin: 10px 0 0;
    text-align: center;
    color: #9a9a9a;
    font-size: 12px;
}
.banner {
    border-radius: 10px;
    padding: 10px 12px;
    margin-bottom: 14px;
    font-size: 14px;
    font-weight: 650;
}
.banner p { margin: 0; }
.banner.good { background: #F5D56A; color: #3A0F34; }
.banner.bad { background: #FCECEF; color: #8d2436; }

.preview { margin-top: 16px; }
.preview summary { cursor: pointer; color: #8a8a8a; font-size: 13px; font-weight: 700; }
.preview-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.preview-list button {
    border: 1px solid var(--line);
    background: #fff;
    color: var(--red);
    border-radius: 999px;
    padding: 6px 10px;
    font: inherit;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}
.preview-list button:hover { background: #fff5f5; }

@media (max-width: 980px) {
    .stage {
        grid-template-columns: 1fr;
        align-items: start;
        padding: 28px 18px 48px;
        min-height: 100vh;
    }
    .headline { text-align: center; margin: 0 auto; padding: 28px 22px 24px; }
    .chips { justify-content: center; }
    .auth-card { width: min(440px, 100%); margin: 0 auto; }
    .card-glow { display: none; }
    .col:nth-child(n+4) { display: none; }
    .veil {
        background: linear-gradient(180deg, rgba(33, 13, 47, 0.62), rgba(33, 13, 47, 0.42));
    }
}
@media (max-width: 640px) {
    .headline h1 { font-size: 34px; }
    .auth-card h2 { font-size: 30px; }
    .col:nth-child(n+3) { display: none; }
    .tile { height: 260px; }
    .auth-card-body, .auth-card-head { padding-left: 18px; padding-right: 18px; }
    .auth-row { align-items: flex-start; flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
    .track { animation: none; }
}
