:root {
  color-scheme: dark;
  --page: #11191b;
  --panel: #182224;
  --border: #354344;
  --text: #fcf4e7;
  --muted: #b7c1bd;
  --amber: #efb774;
  --ink: #211609;
  font: 16px/1.5 "Segoe UI", system-ui, sans-serif;
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--page); color: var(--text); }
h1, .art-title { font-family: Georgia, serif; font-weight: 400; }
h1 { margin: 0; font-size: clamp(3rem, 5vw, 4.65rem); line-height: .99; letter-spacing: -.065em; }
a { color: inherit; }
button, input { font: inherit; }
button, input[type="checkbox"] { cursor: pointer; }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 4px; }
.icon { width: 20px; height: 20px; flex: none; }
.brand { display: flex; align-items: center; gap: .75rem; width: fit-content; font-weight: 650; letter-spacing: -.035em; font-size: 1.15rem; }
.brand img { display: block; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.split { display: grid; grid-template-columns: minmax(0, 1.07fr) minmax(0, 1fr); min-height: 100svh; }
.art { position: relative; isolation: isolate; overflow: hidden; min-height: 42rem; background: #0c2022; }
.art > img { position: absolute; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: center 36%; }
.art::after { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(0deg,#081719 0%,#08171944 32%,transparent 55%); }
.art-copy { position: absolute; inset: auto clamp(1.75rem, 5.2vw, 5.75rem) clamp(2rem, 6vh, 4.5rem); }
.eyebrow { display: flex; gap: .75rem; align-items: center; margin: 0 0 .45rem; color: #ffd297; font-size: .79rem; text-transform: uppercase; letter-spacing: .19em; font-weight: 700; }
.eyebrow span { width: 1.75rem; height: 1px; background: currentColor; }
.art-title { margin: 0; font-size: clamp(3.75rem, 7.5vw, 8rem); line-height: .95; letter-spacing: -.075em; }
.art-title span, .archive h1 span { color: var(--amber); }
.access { display: grid; grid-template-rows: auto 1fr auto; min-width: 0; border-left: 1px solid #354241; padding: 2rem clamp(1.75rem, 5vw, 5.75rem) 1.85rem; background: radial-gradient(ellipse at 30% 18%, #202c29 0%, transparent 65%); }
.access-content { align-self: center; justify-self: center; width: min(100%, 25rem); padding: 4rem 0 3rem; }
.access-symbol { width: 3rem; height: 3rem; border: 1px solid #5b5443; border-radius: 12px; color: var(--amber); background: #292b24; display: grid; place-items: center; margin-bottom: 1.5rem; }
.access-symbol .icon { width: 24px; height: 24px; }
.intro { color: var(--muted); margin: 1.1rem 0 1.75rem; max-width: 29rem; }
.login-form { display: grid; gap: .65rem; }
.pin-label { font-weight: 650; font-size: .94rem; }
.pin { width: 100%; background: #0f1719; color: var(--text); border: 1px solid #485655; border-radius: .6rem; padding: .8rem 1rem; font-size: 1.38rem; line-height: 1.25; letter-spacing: .27em; }
.pin::placeholder { color: #899794; opacity: 1; }
.pin[aria-invalid="true"] { border-color: #ff9a84; }
.form-error { color: #ffb39e; font-size: .94rem; margin: 0; }
.remember { display: flex; align-items: center; gap: .55rem; margin: .35rem 0 .85rem; color: var(--muted); font-size: .94rem; width: fit-content; cursor: pointer; }
.remember input { margin: 0; width: 1rem; height: 1rem; accent-color: var(--amber); }
.primary { background: var(--amber); color: var(--ink); border: 1px solid transparent; border-radius: .6rem; min-height: 3.25rem; font-weight: 700; padding: .5rem 1rem; }
.primary:hover { background: #ffd198; }
.access-footer { display: flex; align-items: center; gap: .5rem; color: var(--muted); border-top: 1px solid var(--border); padding-top: 1.05rem; font-size: .875rem; }
.access-footer .icon { width: 16px; height: 16px; color: var(--amber); }

.container { width: min(100% - 3rem, 70rem); margin-inline: auto; }
.topbar { background: #172121; border-bottom: 1px solid var(--border); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; min-height: 4.75rem; gap: 1rem; }
.secondary, .icon-button { display: inline-flex; align-items: center; justify-content: center; background: var(--panel); border: 1px solid var(--border); border-radius: .55rem; padding: .5rem .85rem; color: var(--text); text-decoration: none; }
.secondary:hover, .icon-button:hover { border-color: var(--amber); }
.archive { padding-block: clamp(2.5rem, 7vw, 5rem); }
.crumbs { display: flex; flex-wrap: wrap; gap: .65rem; margin: 1.15rem 0 1.75rem; color: var(--muted); overflow-wrap: anywhere; }
.crumbs a:hover { color: var(--amber); }
.file-panel { border: 1px solid var(--border); border-radius: .75rem; overflow: hidden; background: var(--panel); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .6rem 1.1rem; text-align: left; }
th { padding-block: .9rem; color: var(--muted); background: #202b2c; font-size: .875rem; font-weight: 600; }
td { border-top: 1px solid var(--border); color: var(--muted); }
td:nth-child(2), td:nth-child(3) { white-space: nowrap; }
tr:hover td { background: #1b2728; }
.filename { display: flex; align-items: center; gap: .7rem; width: fit-content; min-height: 2.45rem; color: var(--text); text-decoration: none; overflow-wrap: anywhere; }
.filename:hover { text-decoration: underline; }
.filename .icon, .icon-button { color: var(--amber); }
.action { width: 1%; }
.icon-button { padding: .5rem; }
.empty { padding: 2rem 1.1rem; }

@media (max-width: 750px) {
  .split { grid-template-columns: 1fr; min-height: 0; }
  .art { min-height: 0; height: clamp(14rem, 56vw, 22rem); }
  .art-copy { inset-block-end: 1.25rem; }
  .art-title { font-size: clamp(3rem, 11vw, 5rem); }
  .art > img { object-position: center 9%; }
  .access { border-left: 0; border-top: 1px solid var(--border); padding-top: 1.25rem; }
  .access-content { padding: 2.2rem 0; justify-self: start; }
  .access-symbol { margin-bottom: .95rem; }
  .container { width: calc(100% - 2rem); }
  th, td { padding-inline: .65rem; }
}

@media (max-width: 520px) {
  th:nth-child(3), td:nth-child(3) { display: none; }
  .archive h1 { font-size: 2.85rem; }
}

.monster-eyes { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.monster-lid {
  transform-box: fill-box;
  transform-origin: center top;
  transform: scaleY(0);
  animation: monster-blink 6.1s infinite;
}
.monster-eyes g:last-child .monster-lid { animation-delay: .12s; }
@keyframes monster-blink {
  0%, 42%, 48%, 91%, 98%, 100% { transform: scaleY(0); }
  45%, 94%, 96% { transform: scaleY(1); }
}
.monster-arm { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; overflow: hidden; }
.monster-arm path { fill: none; stroke-linecap: round; }
.monster-arm-shadow { stroke: #2e1d10; stroke-width: 12; opacity: .8; }
.monster-arm-noodle { stroke: url(#pasta-strand); stroke-width: 8; }
.monster-arm-highlight { stroke: #ffdd9b; stroke-width: 1.5; opacity: .6; transform: translateY(-2px); }
.lock-video { display: block; width: 100%; height: auto; min-height: 200px; aspect-ratio: 16 / 9; border: 0; border-radius: .6rem; }
.pin-admin { max-width: 26rem; margin-block: 1.75rem; }
.pin-admin .primary { margin-top: .5rem; }
.pin-admin .primary:disabled { opacity: .55; cursor: default; }
.pin-admin #admin-password { letter-spacing: normal; }
@media (max-width: 750px) {
  .monster-arm-shadow { stroke-width: 8; }
  .monster-arm-noodle { stroke-width: 5; }
}
@media (prefers-reduced-motion: reduce) {
  .monster-lid { animation: none; }
}
