:root {
    --bg: #050505;
    --bg-soft: #111111;
    --panel: rgba(18, 18, 18, 0.9);
    --panel-strong: rgba(28, 28, 28, 0.96);
    --line: rgba(255, 255, 255, 0.08);
    --text: #f7f1e8;
    --muted: #c3b9aa;
    --accent: #e53935;
    --accent-soft: #ffca28;
    --success: #1db954;
    --danger: #ff6b5f;
    --shadow: 0 20px 70px rgba(0, 0, 0, 0.35);
    --radius: 28px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    width: 100%;
    min-width: 100%;
    min-height: 100%;
    background:
        radial-gradient(circle at top right, rgba(229, 57, 53, 0.16), transparent 24rem),
        radial-gradient(circle at bottom left, rgba(255, 202, 40, 0.12), transparent 28rem),
        linear-gradient(180deg, #080808 0%, #040404 100%);
    color: var(--text);
    font-family: "Arial Narrow", Arial, sans-serif;
}

body {
    min-height: 100dvh;
}

.wall-page,
.wall-page html {
    width: 100%;
    height: 100%;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 2.5rem 2.5rem;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.6), transparent);
}

a {
    color: inherit;
    text-decoration: none;
}

img,
video {
    display: block;
    max-width: 100%;
}

[hidden] {
    display: none !important;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.95rem 1.25rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font: inherit;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
}

.button.primary {
    background: linear-gradient(135deg, var(--accent-soft), #f6a623);
    color: #161616;
}

.button.secondary {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--text);
}

.field {
    display: grid;
    gap: 0.55rem;
}

.field span {
    color: var(--accent-soft);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.13em;
    text-transform: uppercase;
}

.field input,
.field textarea {
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 18px;
    background: rgba(0, 0, 0, 0.34);
    color: var(--text);
    padding: 0.95rem 1rem;
    font: inherit;
}

.field input:focus,
.field textarea:focus {
    outline: none;
    border-color: rgba(255, 202, 40, 0.8);
    box-shadow: 0 0 0 3px rgba(255, 202, 40, 0.15);
}

.alert {
    display: grid;
    gap: 0.35rem;
    margin-bottom: 1rem;
    padding: 1rem 1.1rem;
    border-radius: 18px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.alert strong {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.85rem;
}

.alert.error {
    background: rgba(229, 57, 53, 0.14);
    border-color: rgba(229, 57, 53, 0.35);
}

.alert.success {
    background: rgba(29, 185, 84, 0.15);
    border-color: rgba(29, 185, 84, 0.35);
}

.alert.info {
    background: rgba(255, 202, 40, 0.12);
    border-color: rgba(255, 202, 40, 0.28);
}

.eyebrow {
    margin: 0;
    color: var(--accent-soft);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.gate-shell,
.upload-shell {
    width: min(1300px, calc(100% - 2.5rem));
    margin: 0 auto;
    padding: 2rem 0 3rem;
}

.gate-panel,
.upload-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 1.5rem;
}

.upload-layout-simple {
    max-width: 34rem;
    margin: 0 auto;
    grid-template-columns: 1fr;
}

.gate-copy,
.gate-card,
.upload-card,
.upload-side,
.wall-rail {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    background:
        linear-gradient(135deg, rgba(229, 57, 53, 0.12), transparent 40%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0)),
        var(--panel);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.gate-copy,
.gate-card,
.upload-card,
.upload-side {
    padding: clamp(1.4rem, 2vw, 2.2rem);
}

.gate-copy h1,
.upload-card h1,
.upload-side h2 {
    margin: 0.35rem 0 0.8rem;
    font-size: clamp(2.2rem, 5vw, 4.8rem);
    line-height: 0.92;
    text-transform: uppercase;
}

.upload-layout-simple .upload-card h1 {
    margin: 0 0 1.25rem;
    font-size: clamp(2.4rem, 12vw, 4.2rem);
}

.gate-copy > p:last-of-type,
.upload-card > p:last-of-type,
.upload-side > p:last-of-type {
    max-width: 48rem;
    color: var(--muted);
    line-height: 1.6;
}

.gate-points,
.upload-tips,
.upload-links,
.status-grid,
.recent-list {
    display: grid;
    gap: 0.9rem;
}

.gate-points {
    margin-top: 1.5rem;
}

.gate-points article,
.upload-tips article,
.recent-item,
.status-card {
    padding: 1rem 1.05rem;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.gate-points span,
.upload-tips strong,
.status-card strong,
.recent-item strong {
    display: block;
    margin-bottom: 0.35rem;
}

.gate-points span {
    width: 2.3rem;
    height: 2.3rem;
    border-radius: 999px;
    display: inline-grid;
    place-items: center;
    background: rgba(255, 202, 40, 0.12);
    color: var(--accent-soft);
    font-weight: 700;
}

.gate-form,
.upload-form {
    display: grid;
    gap: 1rem;
}

.upload-topbar,
.wall-topbar {
    width: min(1500px, calc(100% - 2rem));
    margin: 0 auto;
    padding-top: 1.35rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.brandline,
.wall-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.8rem 1rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.brandline strong,
.wall-badge strong {
    display: block;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.brandline span,
.wall-badge span {
    font-size: 0.85rem;
    color: var(--muted);
}

.upload-form textarea {
    min-height: 8rem;
    resize: vertical;
}

.file-drop {
    padding: 1.1rem;
    border: 1px dashed rgba(255, 202, 40, 0.35);
    border-radius: 24px;
    background: rgba(255, 202, 40, 0.05);
}

.file-drop input[type="file"] {
    border: 0;
    padding: 0;
    background: transparent;
}

.upload-links {
    margin-top: 1.2rem;
}

.upload-links .button {
    width: 100%;
}

.upload-meta {
    color: var(--muted);
    font-size: 0.95rem;
    line-height: 1.55;
}

.upload-preview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(6.5rem, 1fr));
    gap: 0.75rem;
}

.upload-preview[hidden] {
    display: none;
}

.upload-preview-item {
    min-width: 0;
    overflow: hidden;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.upload-preview-thumb {
    width: 100%;
    aspect-ratio: 1;
    display: grid;
    place-items: center;
    overflow: hidden;
    background: #000;
}

.upload-preview-thumb img,
.upload-preview-thumb video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.upload-preview-video {
    color: var(--accent-soft);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.upload-preview-name {
    padding: 0.55rem 0.65rem;
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.25;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.upload-progress {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.85rem;
}

.upload-progress[hidden] {
    display: none;
}

.upload-progress-track {
    height: 0.9rem;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.upload-progress-track span {
    display: block;
    width: 0%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--accent-soft), var(--success));
    transition: width 0.2s ease;
}

.upload-progress strong {
    min-width: 3.4rem;
    text-align: right;
    color: var(--accent-soft);
}

.status-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 1.25rem;
}

.status-card p,
.recent-item p {
    margin: 0;
    color: var(--muted);
    line-height: 1.45;
}

.recent-item small {
    display: block;
    margin-top: 0.45rem;
    color: var(--muted);
}

.wall-page {
    width: 100vw;
    height: 100dvh;
    overflow: hidden;
    background: #000;
}

.wall-shell {
    width: 100vw;
    height: 100dvh;
    margin: 0;
    padding: 0;
    min-height: 0;
}

.wall-stage {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    width: 100vw;
    height: 100dvh;
    min-height: 0;
    padding: 0;
    display: grid;
    grid-template-rows: minmax(0, 1fr);
    gap: 0;
    border-radius: 0;
    background: #000;
    border: 0;
    box-shadow: none;
    overflow: hidden;
}

.wall-frame {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 0;
    background: #000;
    overflow: hidden;
    min-height: 0;
    border: 0;
}

.wall-empty {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 2rem;
    text-align: center;
    color: var(--muted);
    background:
        radial-gradient(circle at 50% 40%, rgba(255, 202, 40, 0.12), transparent 22rem),
        #000;
}

.wall-empty > div {
    display: grid;
    gap: 0.85rem;
    justify-items: center;
    max-width: min(42rem, 90vw);
}

.wall-qr {
    width: min(34vh, 24rem, 62vw);
    aspect-ratio: 1;
    padding: clamp(0.55rem, 1vw, 0.9rem);
    border-radius: 1.2rem;
    background: #fff;
    box-shadow: 0 1rem 4rem rgba(0, 0, 0, 0.45);
}

.wall-empty strong {
    display: block;
    color: var(--text);
    text-transform: uppercase;
    letter-spacing: 0;
    font-size: clamp(3rem, 8vw, 7rem);
    line-height: 0.95;
    margin: 0;
}

.wall-empty p {
    margin: 0;
    font-size: clamp(1.3rem, 2.2vw, 2.2rem);
    line-height: 1.25;
}

.wall-visual {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.wall-visual[hidden] {
    display: none;
}

.wall-uploader {
    position: absolute;
    left: clamp(1rem, 2.2vw, 2.4rem);
    right: clamp(1rem, 2.2vw, 2.4rem);
    bottom: clamp(1rem, 2.2vw, 2.4rem);
    max-width: min(70rem, calc(100vw - 2rem));
    padding: 0.9rem 1.05rem;
    border-radius: 18px;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.46));
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: var(--text);
    display: grid;
    gap: 0.15rem;
    line-height: 1.15;
    overflow: hidden;
    pointer-events: none;
}

.wall-uploader strong {
    display: block;
    font-size: clamp(1.05rem, 1.8vw, 1.8rem);
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.wall-uploader span {
    display: block;
    color: var(--muted);
    font-size: clamp(0.9rem, 1.35vw, 1.35rem);
    overflow: visible;
    white-space: normal;
    overflow-wrap: anywhere;
}

.wall-uploader[hidden] {
    display: none;
}

.recent-list {
    overflow: auto;
    padding-right: 0.3rem;
}

.recent-item.is-current {
    border-color: rgba(255, 202, 40, 0.45);
    background: rgba(255, 202, 40, 0.08);
}

.recent-item-header {
    display: flex;
    justify-content: space-between;
    gap: 0.75rem;
    align-items: center;
}

.recent-pill {
    flex-shrink: 0;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hidden {
    display: none !important;
}

@media (max-width: 1100px) {
    .gate-panel,
    .upload-layout {
        grid-template-columns: 1fr;
    }

    .wall-page {
        overflow: hidden;
    }
}

@media (max-width: 720px) {
    .gate-shell,
    .upload-shell,
    .wall-topbar {
        width: min(100% - 1rem, 100%);
    }

    .gate-copy h1,
    .upload-card h1 {
        font-size: clamp(2rem, 13vw, 3.4rem);
    }

    .status-grid {
        grid-template-columns: 1fr;
    }

    .upload-topbar {
        grid-template-columns: 1fr;
        display: grid;
    }
}
