/* dumpd.lol — minimal dark UI (catbox-like layout, white accents) */

:root {
    --bg: #0c0c0e;
    --bg-elevated: #141418;
    --bg-hover: #1a1a1f;
    --border: #2e2e34;
    --border-strong: #45454e;
    --text: #f0f0f3;
    --muted: #9898a4;
    --muted2: #6e6e78;
    --accent: #f5f5f7;
    --accent-soft: rgba(255, 255, 255, 0.08);
    --accent-glow: rgba(255, 255, 255, 0.18);
    --accent-contrast: #121214;
    --link: #b8d4f0;
    --link-hover: #d8eaff;
    --danger: #f07178;
    --danger-soft: rgba(240, 113, 120, 0.12);
    --ok: #8fdfaa;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 8px 36px rgba(0, 0, 0, 0.55);
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
    --max: 1180px;
    --header-h: 68px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font);
    background: var(--bg);
    background-image:
        radial-gradient(ellipse 100% 70% at 50% -25%, rgba(255, 255, 255, 0.045), transparent 50%),
        radial-gradient(ellipse 70% 50% at 95% 40%, rgba(184, 212, 240, 0.035), transparent 45%);
    color: var(--text);
    line-height: 1.55;
}

a {
    color: var(--link);
    text-decoration: none;
}
a:hover {
    color: var(--link-hover);
    text-decoration: underline;
}

/* Header — slim bar like catbox */
.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: calc(var(--max) + 4rem);
    margin: 0 auto;
    padding: 0 1.35rem;
    min-height: var(--header-h);
    border-bottom: 1px solid var(--border);
    background: rgba(15, 15, 18, 0.85);
    backdrop-filter: blur(10px);
    position: sticky;
    top: 0;
    z-index: 50;
}

.site-brand {
    font-family: var(--font-mono);
    font-size: 1.28rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--text);
}
.site-brand-with-logo {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}
.site-logo {
    width: 46px;
    height: 46px;
    border-radius: 10px;
    flex-shrink: 0;
    object-fit: cover;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.site-brand-text span {
    color: var(--muted);
    font-weight: 400;
}
.site-brand span {
    color: var(--muted);
    font-weight: 400;
}

.site-nav {
    display: flex;
    gap: 1.35rem;
    font-size: 0.95rem;
}
.site-nav a {
    color: var(--muted);
    text-decoration: none;
}
.site-nav a:hover {
    color: var(--accent);
    text-decoration: none;
}

.site-main {
    max-width: var(--max);
    margin: 0 auto;
    padding: 2.25rem 1.25rem 2rem;
}

/* ——— Home (catbox-style centered hero + no dashed upload frame) ——— */
.site-header--home {
    flex-direction: column;
    align-items: stretch;
    max-width: none;
    border-bottom-color: rgba(255, 255, 255, 0.06);
    padding-top: 0.65rem;
    padding-bottom: 0.65rem;
}

.home-header-row {
    width: 100%;
    max-width: calc(var(--max) + 4rem);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.65rem 1rem;
}

.site-main--home {
    max-width: 560px;
    margin: 0 auto;
    padding: 1.5rem 1.35rem 2.5rem;
    text-align: center;
}

.home-hero {
    padding: 0.5rem 0 1.75rem;
}

.home-hero-brand {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem 1.25rem;
    margin-bottom: 1rem;
}

.home-hero-logo {
    width: 88px;
    height: 88px;
    border-radius: 16px;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}

.home-hero-title {
    margin: 0;
    font-family: var(--font);
    font-size: clamp(2.35rem, 7vw, 3.5rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    line-height: 1.05;
    color: var(--text);
}

.home-hero-tld {
    color: var(--muted);
    font-weight: 500;
}

.home-hero-line {
    margin: 0 auto;
    max-width: 34rem;
    font-size: 0.95rem;
    color: var(--muted);
    line-height: 1.55;
}

.home-upload-heading {
    margin: 0 0 0.6rem;
    font-size: 1.2rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--text);
}

.field-retention--home {
    margin-bottom: 1.35rem;
    text-align: center;
    position: relative;
    z-index: 25;
}

.field-retention-label-text {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
    margin-bottom: 0.45rem;
}

.field-retention--home select {
    max-width: 100%;
}

.retention-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    justify-content: center;
    max-width: 100%;
}

.retention-chip {
    appearance: none;
    border: 1px solid var(--border-strong);
    background: var(--bg);
    color: var(--text);
    font-size: 0.82rem;
    padding: 0.45rem 0.75rem;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-family: inherit;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}

.retention-chip:hover {
    border-color: var(--accent);
    background: var(--accent-soft);
}

.retention-chip--active {
    border-color: var(--accent);
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    font-weight: 600;
}

#home-turnstile {
    position: relative;
    z-index: 1;
}

.home-dropzone-wrap {
    width: 100%;
    margin: 0 auto;
}

/* No dashed “frame” — soft panel only */
.dropzone--home {
    min-height: 240px;
    padding: 3rem 1.75rem 2.75rem;
    border: none;
    border-radius: 16px;
    background: var(--bg-elevated);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.06) inset,
        0 12px 40px rgba(0, 0, 0, 0.35);
    transition: background 0.2s, box-shadow 0.2s, transform 0.2s;
}
.dropzone--home:hover,
.dropzone--home:focus-visible {
    border: none;
    background: #1a1a22;
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.08) inset,
        0 16px 48px rgba(0, 0, 0, 0.45);
    transform: translateY(-1px);
}
.dropzone--home.dragover {
    border: none;
    background: rgba(255, 255, 255, 0.06);
    box-shadow:
        0 0 0 2px rgba(255, 255, 255, 0.2),
        0 16px 48px rgba(0, 0, 0, 0.45);
}

.dropzone-icon--home {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hint--home {
    font-size: 1.1rem;
    margin-bottom: 0.4rem;
}

.sub--home {
    font-size: 0.92rem;
    margin-bottom: 1.5rem;
    color: var(--muted);
}

.btn--home-upload {
    padding: 0.7rem 1.75rem;
    font-size: 1rem;
    border-radius: 10px;
}

.home-result {
    margin-top: 1.35rem;
    text-align: left;
}

.site-footer--home {
    max-width: none;
    padding-bottom: max(2.5rem, calc(env(safe-area-inset-bottom) + 1.5rem));
}
.site-footer--home .site-footer-note {
    display: block;
    margin-bottom: 0.65rem;
    font-size: 0.82rem;
    color: var(--muted);
}
.site-footer--home .site-footer-links {
    display: inline-block;
    font-size: 0.88rem;
    line-height: 1.5;
}
.site-footer--home .site-footer-links a {
    color: var(--link);
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 0.15em;
}
.site-footer--home .site-footer-links a:hover {
    color: var(--text);
}

.site-nav--home a {
    font-weight: 500;
    color: var(--link);
}
.site-nav--home a:hover {
    color: var(--text);
}

.home-legal {
    margin-top: 2rem;
    padding: 1rem 1.1rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.03);
    text-align: center;
    font-size: 0.88rem;
    line-height: 1.55;
    color: var(--muted);
}
.home-legal-label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--muted2);
}
.home-legal-link {
    color: var(--link);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 0.18em;
    white-space: nowrap;
}
.home-legal-link:hover {
    color: var(--text);
}
.home-legal-sep {
    margin: 0 0.35rem;
    color: var(--muted2);
}

.home-page .site-main--home {
    padding-bottom: max(6rem, 18vw);
}

@media (max-width: 520px) {
    .home-hero-brand {
        flex-direction: column;
    }
    .dropzone--home {
        min-height: 200px;
        padding: 2.25rem 1.25rem;
    }
}

/* Home: one random spotlight image — bottom-right of the viewport, not centered */
.gallery-corner {
    position: fixed;
    right: max(1rem, env(safe-area-inset-right));
    bottom: max(1rem, env(safe-area-inset-bottom));
    z-index: 40;
    width: 280px;
    height: 280px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    pointer-events: none;
}
.gallery-corner[hidden] {
    display: none !important;
}
.gallery-corner a {
    pointer-events: auto;
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    line-height: 0;
}
.gallery-corner img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}
.gallery-corner a:hover img {
    opacity: 0.9;
}

@media (max-width: 600px) {
    .gallery-corner {
        width: min(200px, 42vw);
        height: min(200px, 42vw);
        right: 0.5rem;
        bottom: 0.5rem;
    }
}

.field-retention {
    margin-bottom: 1rem;
}
.field-retention label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
    margin-bottom: 0.45rem;
}
.field-retention select {
    width: 100%;
    padding: 0.55rem 0.75rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-strong);
    background: var(--bg);
    color: var(--text);
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
}
.field-retention select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}

.page-title {
    font-size: 1.35rem;
    font-weight: 600;
    letter-spacing: -0.03em;
    margin: 0 0 0.5rem;
    color: var(--text);
}

.tagline {
    margin: 0 0 1.75rem;
    font-size: 0.875rem;
    color: var(--muted);
    line-height: 1.5;
}

/* Cards */
.card {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.25rem 1.35rem;
    box-shadow: var(--shadow);
}
.card--flat {
    box-shadow: none;
    padding: 0;
}

/* Drop zone — catbox-style dashed box */
.dropzone {
    padding: 2.5rem 1.5rem;
    text-align: center;
    border: 2px dashed var(--border-strong);
    border-radius: var(--radius);
    background: var(--bg-hover);
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
    cursor: pointer;
    outline: none;
}
.dropzone:hover,
.dropzone:focus-visible {
    border-color: var(--accent);
    background: var(--accent-soft);
    box-shadow: 0 0 0 1px var(--accent-glow);
}
.dropzone.dragover {
    border-color: var(--accent);
    background: var(--accent-soft);
    border-style: solid;
}

.dropzone-icon {
    font-size: 2rem;
    margin: 0 0 0.75rem;
    opacity: 0.85;
    line-height: 1;
    color: var(--accent);
}

.dropzone .hint {
    margin: 0 0 0.35rem;
    font-weight: 600;
    font-size: 0.95rem;
}
.dropzone .sub {
    margin: 0 0 1.25rem;
    font-size: 0.82rem;
    color: var(--muted);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.55rem 1.15rem;
    font-family: inherit;
    font-size: 0.875rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    text-decoration: none;
    color: inherit;
}
.btn-primary {
    background: var(--accent);
    color: var(--accent-contrast);
    border-color: #fff;
}
.btn-primary:hover {
    filter: brightness(1.06);
    text-decoration: none;
    color: var(--accent-contrast);
}
.btn-secondary {
    background: var(--bg-hover);
    border-color: var(--border-strong);
    color: var(--text);
}
.btn-secondary:hover {
    border-color: var(--muted);
    background: #22222a;
    text-decoration: none;
    color: var(--text);
}
.btn-danger {
    background: var(--danger-soft);
    border-color: rgba(240, 113, 120, 0.35);
    color: var(--danger);
}
.btn-danger:hover {
    background: rgba(240, 113, 120, 0.22);
    text-decoration: none;
    color: #ff9499;
}
.btn-ghost {
    background: transparent;
    border-color: var(--border);
    color: var(--muted);
}
.btn-ghost:hover {
    border-color: var(--muted);
    color: var(--text);
    text-decoration: none;
}

.btn-sm {
    padding: 0.35rem 0.65rem;
    font-size: 0.78rem;
}

/* Result box */
.result-box {
    margin-top: 1.25rem;
    padding: 1rem 1.15rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    word-break: break-all;
}
.result-box a {
    color: var(--link);
    font-weight: 500;
}
.result-box.error {
    border-color: rgba(240, 113, 120, 0.4);
    background: var(--danger-soft);
    color: #ffb4b8;
}

/* Footer */
.site-footer {
    max-width: calc(var(--max) + 4rem);
    margin: 0 auto;
    padding: 2rem 1.25rem 2.5rem;
    font-size: 0.78rem;
    color: var(--muted2);
    text-align: center;
    border-top: 1px solid var(--border);
}
.site-footer a {
    color: var(--muted);
}

/* Preview page */
.preview-wrap {
    max-width: 880px;
    margin: 0 auto;
    padding: 2rem 1.25rem 3rem;
}
.preview-card h2 {
    font-size: 1.05rem;
    font-weight: 600;
    margin: 0 0 0.35rem;
    word-break: break-all;
    letter-spacing: -0.02em;
}
.preview-actions {
    margin-top: 1.35rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    justify-content: center;
}
#preview-area {
    margin: 1.5rem 0;
    min-height: 2rem;
}
#preview-area img,
#preview-area video,
#preview-area audio {
    max-width: 100%;
    border-radius: var(--radius-sm);
    background: var(--bg);
    border: 1px solid var(--border);
}

#zip-contents {
    text-align: left;
    background: var(--bg);
    padding: 1rem 1.15rem;
    border-radius: var(--radius-sm);
    max-height: 320px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: var(--text);
    border: 1px solid var(--border);
    line-height: 1.55;
}
#zip-contents span.dim {
    color: var(--muted);
}

/* Legal */
.legal {
    max-width: 720px;
    margin: 0 auto;
    padding: 2rem 1.25rem 4rem;
}
.legal h1 {
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0 0 1rem;
    letter-spacing: -0.03em;
}
.legal h2 {
    font-size: 1rem;
    margin: 2rem 0 0.65rem;
    color: var(--text);
    font-weight: 600;
}
.legal p {
    margin: 0 0 1rem;
    color: var(--muted);
    font-size: 0.92rem;
}
.legal strong {
    color: var(--danger);
    font-weight: 600;
}

/* Support / chat page */
.support-main {
    max-width: 560px;
    margin: 0 auto;
    padding: 2rem 1.25rem 3rem;
}
.support-main h1 {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0 0 0.5rem;
    text-align: center;
    letter-spacing: -0.03em;
}
.support-main .lead {
    text-align: center;
    color: var(--muted);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}
.join-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.join-row input[type="text"] {
    flex: 1;
    min-width: 200px;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9rem;
    background: var(--bg);
    color: var(--text);
}
.join-row input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
#messages {
    height: 300px;
    overflow-y: auto;
    background: var(--bg);
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    text-align: left;
    font-size: 0.9rem;
}
.msg {
    margin-bottom: 0.55rem;
    line-height: 1.45;
}
.msg-user {
    color: var(--muted);
}
.msg-admin {
    color: var(--link-hover);
}
.msg-system {
    color: var(--muted2);
    font-size: 0.82rem;
}
.chat-row {
    display: flex;
    gap: 0.5rem;
}
.chat-row input {
    flex: 1;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-family: inherit;
    background: var(--bg);
    color: var(--text);
}

/* Admin dashboard */
.admin-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 1.75rem 1.25rem 3rem;
}
.admin-panel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.35rem;
}
.admin-panel-head .admin-title {
    margin-bottom: 0;
}
.admin-title {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0 0 0.35rem;
    letter-spacing: -0.03em;
}
.admin-sub {
    margin: 0 0 1.75rem;
    font-size: 0.85rem;
    color: var(--muted);
}
.admin-panel {
    margin-bottom: 2rem;
    padding: 1.25rem 1.35rem;
}
.admin-panel h2 {
    margin: 0 0 0.65rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text);
}
.admin-panel .panel-note {
    margin: 0 0 1rem;
    font-size: 0.82rem;
    color: var(--muted);
}
#upload-lock-status {
    margin: 0 0 1rem;
    font-size: 0.88rem;
}
#upload-lock-status.ok {
    color: var(--ok);
}
#upload-lock-status.bad {
    color: var(--danger);
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
    background: var(--bg-elevated);
}
.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.82rem;
}
.admin-table th,
.admin-table td {
    padding: 0.65rem 0.85rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}
.admin-table th {
    background: var(--bg-hover);
    color: var(--muted);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.admin-table tr:last-child td {
    border-bottom: none;
}
.admin-table tbody tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.admin-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
}
.admin-section-title {
    font-size: 0.95rem;
    font-weight: 600;
    margin: 0 0 0.75rem;
    color: var(--text);
}

/* Chat modal */
#chat-modal {
    display: none;
    position: fixed;
    bottom: 1.25rem;
    right: 1.25rem;
    width: min(400px, calc(100vw - 2rem));
    background: var(--bg-elevated);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    z-index: 1000;
    overflow: hidden;
}
#chat-header {
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
    font-weight: 600;
    font-size: 0.85rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text);
    background: var(--bg-hover);
}
#chat-header .close-btn {
    cursor: pointer;
    color: var(--muted);
    font-size: 0.8rem;
}
#chat-header .close-btn:hover {
    color: var(--danger);
}
#chat-messages {
    height: 280px;
    overflow-y: auto;
    padding: 1rem;
    font-size: 0.85rem;
    background: var(--bg);
}
#chat-input-area {
    display: flex;
    gap: 0.5rem;
    padding: 0.75rem;
    border-top: 1px solid var(--border);
    background: var(--bg-elevated);
}
#chat-input-area input {
    flex: 1;
    padding: 0.5rem 0.65rem;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg);
    color: var(--text);
    font-family: inherit;
    font-size: 0.85rem;
}
#chat-input-area button {
    background: var(--accent);
    color: var(--accent-contrast);
    border: none;
    padding: 0.5rem 0.85rem;
    border-radius: var(--radius-sm);
    font-weight: 600;
    cursor: pointer;
    font-size: 0.8rem;
}
#chat-input-area button:hover {
    filter: brightness(1.08);
}

@media (max-width: 520px) {
    .page-title {
        font-size: 1.2rem;
    }
    .dropzone:not(.dropzone--home) {
        padding: 1.75rem 1rem;
    }
}
