/* DATADELIRIUM — hall base
   Built from Figma "DATADELIRIUM REDISIGN" (frames 1:165 hall, 1:379 hall locked).
   Desktop values are 1:1 with the 1920px frames. Store-specific styles live in hall.css. */

:root {
  --fg: #d9d9d9;
  --bg: #000;
  --white: #fff;
  --link: #d8ce92; /* warm khaki accent, lifted for contrast */
  --ghost: rgba(217, 217, 217, 0.15);
  --container: 1280px;
  --gutter: 24px;
  --ls: 0.04em;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-weight: 500;
  font-size: 14px;
  line-height: 1.21;
  letter-spacing: var(--ls);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: none;
}

a {
  color: inherit;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- page shell ---------- */

.site {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 64px;
  padding-top: 24px;
  overflow-x: clip;
}

/* halftone statues (STATUE frame, 1384×1020 at x=296,y=31) — always above content, never clickable */
.statue {
  position: absolute;
  z-index: 5;
  top: 31px;
  left: calc(50% - 664px);
  width: 1384px;
  height: auto;
  pointer-events: none;
  user-select: none;
}

.header {
  position: relative;
  z-index: 6;
  display: flex;
  justify-content: center;
  width: 100%;
  height: 139px;
}

.header__logo {
  display: block;
  width: 259px;
  margin-top: 7px;
}

.header__logo img {
  width: 100%;
  height: auto;
}

/* ---------- hub / hall switch ---------- */

.switch {
  position: relative;
  z-index: 6;
  width: 510px;
  height: 99px;
}

.switch__nav {
  display: flex;
  justify-content: center;
  gap: 32px;
  padding-top: 2px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 43px;
  border: 1px solid var(--fg);
  border-radius: 5px;
  background: var(--fg);
  color: var(--bg);
  font: 700 16px/1.21 var(--font);
  letter-spacing: var(--ls);
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.btn:hover {
  background: var(--bg);
  color: var(--fg);
}

.btn:focus-visible,
.switch__btn:focus-visible,
.product:focus-visible {
  outline: 2px solid var(--white);
  outline-offset: 3px;
}

.switch__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 239px;
  height: 43px;
  border: 2px solid var(--fg);
  border-radius: 5px;
  background: var(--bg);
  color: var(--fg);
  font: 700 16px/1.21 var(--font);
  letter-spacing: var(--ls);
  text-transform: lowercase;
  text-decoration: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.switch__btn:hover {
  background: rgba(217, 217, 217, 0.12);
}

.switch__btn[aria-current="page"] {
  border-width: 1px;
  background: var(--fg);
  color: var(--bg);
}

.switch__info {
  margin: 0;
  padding-top: 15px;
  text-align: justify;
  text-align-last: left;
  text-transform: lowercase;
}

/* ---------- footer ---------- */

.footer {
  position: relative;
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: min(var(--container), 100% - 2 * var(--gutter));
  height: 139px;
  padding-top: 18px;
  background: var(--bg);
}

.footer--wide {
  width: min(1440px, 100% - 2 * var(--gutter));
}

.footer__rule {
  width: 100%;
  height: 0;
  margin: 0;
  border: 0;
  border-top: 2px solid var(--fg);
}

.footer__copy {
  margin: 17px 0 0;
  font-weight: 600;
  font-size: 16px;
}

.footer__logo {
  width: 224px;
  height: auto;
  margin-top: 7px;
}

/* ---------- hall: market ---------- */

.market {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(5, 260px);
  justify-content: center;
  gap: 10px;
  width: min(1440px, 100%);
  padding: 10px;
}

.market__ghost {
  aspect-ratio: 1;
  border: 1px solid var(--ghost);
  border-radius: 4px;
}

.product {
  position: relative;
  display: flex;
  flex-direction: column;
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid var(--fg);
  border-radius: 4px;
  color: var(--white);
  text-decoration: none;
}

.product__media {
  height: 73.5%;
  background: var(--white);
}

.product__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.product:hover .product__media img {
  transform: scale(1.04);
}

.product__info {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: space-between;
  padding: 1px 26px 6px;
}

.product__title {
  margin: 0;
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0;
  text-transform: uppercase;
}

.product__price {
  align-self: flex-end;
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 0;
}

/* ---------- hall: locked ---------- */

.locked {
  position: relative;
  z-index: 6;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 76px;
  width: 100%;
  min-height: 506px;
  padding: 10px;
}

.locked__title {
  margin: 0;
  color: var(--white);
  font-weight: 600;
  font-size: 16px;
  text-align: center;
}

.locked__form {
  width: min(510px, 100%);
}

.locked__input {
  display: block;
  width: 100%;
  height: 53px;
  padding: 0 16px;
  border: 2px solid var(--fg);
  border-radius: 5px;
  background: transparent;
  color: var(--white);
  font: italic 600 16px/1.21 var(--font);
  letter-spacing: var(--ls);
  text-align: center;
}

.locked__input::placeholder {
  color: rgba(255, 255, 255, 0.2);
  opacity: 1;
}

.locked__input:focus {
  outline: none;
  border-color: var(--white);
}

.locked__input.is-wrong {
  animation: shake 0.35s ease;
  border-color: #ff4d4d;
}

@keyframes shake {
  25% { transform: translateX(-6px); }
  50% { transform: translateX(6px); }
  75% { transform: translateX(-3px); }
}

/* ---------- first-load intro / page enter / scroll reveal ---------- */

.intro .header__logo { animation: dd-logo 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.1s backwards; }
.intro .statue { animation: dd-statue 2s cubic-bezier(0.3, 0.6, 0.2, 1) 0.35s backwards; }
.intro .switch__btn { animation: dd-up 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) 0.55s backwards; }
.intro .switch__btn + .switch__btn { animation-delay: 0.65s; }
.intro .switch__info { animation: dd-up 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) 0.75s backwards; }
.intro .product { animation: dd-card 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) calc(0.85s + var(--i, 0) * 70ms) backwards; }
.intro .market__ghost { animation: dd-fade 1.2s ease 1.4s backwards; }
.intro .locked > * { animation: dd-up 0.8s cubic-bezier(0.2, 0.7, 0.2, 1) 0.85s backwards; }
.intro .locked > * + * { animation-delay: 0.95s; }
.enter .site { animation: dd-fade 0.45s ease backwards; }

@keyframes dd-logo {
  from { opacity: 0; filter: blur(12px); transform: scale(0.9); }
}
@keyframes dd-statue {
  from { opacity: 0; clip-path: inset(0 0 100% 0); }
  to { opacity: 1; clip-path: inset(0 0 0 0); }
}
@keyframes dd-up {
  from { opacity: 0; transform: translateY(14px); }
}
@keyframes dd-card {
  from { opacity: 0; transform: translateY(28px) scale(0.97); }
}
@keyframes dd-fade {
  from { opacity: 0; }
}

.reveal {
  transition: opacity 0.9s cubic-bezier(0.2, 0.7, 0.2, 1), transform 0.9s cubic-bezier(0.2, 0.7, 0.2, 1);
}
.reveal-ready .reveal:not(.is-in) {
  opacity: 0;
  transform: translateY(32px);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
    animation: none !important;
  }
}

/* =========================================================
   Tablet (768–1329)
   ========================================================= */

@media (max-width: 1329px) {
  .market {
    grid-template-columns: repeat(3, minmax(0, 260px));
  }

  .market__ghost {
    display: none;
  }
}

/* =========================================================
   Mobile (390px)
   ========================================================= */

@media (max-width: 767px) {
  :root {
    --gutter: 24px;
  }

  .site {
    gap: 0;
    padding-top: 4px;
  }

  .statue {
    top: 4px;
    left: 0;
    width: 100%;
  }

  .header {
    height: 84px;
  }

  .header__logo {
    width: 164px;
    margin-top: 0;
  }

  .switch {
    width: min(273px, 100% - 2 * var(--gutter));
    height: auto;
    margin-top: 77px;
  }

  .switch__nav {
    gap: 17px;
    padding-top: 0;
  }

  .switch__btn {
    width: 128px;
    height: 34px;
    border-width: 1px;
    font-size: 12px;
  }

  .switch__info {
    padding-top: 8px;
    font-size: 11px;
    letter-spacing: 0.02em;
    hyphens: auto;
  }

  .footer {
    height: auto;
    margin-top: 16px;
    padding: 8px 0 32px;
  }

  .footer__rule { border-top-width: 1px; }
  .footer__copy { margin-top: 10px; font-size: 12px; }
  .footer__logo { width: 115px; margin-top: 5px; }

  .market {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 30px;
    padding: 0 var(--gutter);
  }

  .product { aspect-ratio: auto; }
  .product__media { height: auto; aspect-ratio: 260 / 191; }
  .product__info { gap: 6px; padding: 6px 10px 8px; }
  .product__title { font-size: 10px; }
  .product__price { font-size: 13px; }

  .locked {
    gap: 40px;
    min-height: 360px;
    margin-top: 40px;
    padding: 0 var(--gutter);
  }
}

.link-plain {
  color: var(--link);
  text-decoration: underline;
  text-decoration-color: rgba(216, 206, 146, 0.3);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.link-plain:hover {
  color: var(--white);
  text-decoration-color: var(--white);
}
