:root {
  color-scheme: dark;
  --bg: #05060a;
  --surface: rgba(12, 14, 20, 0.64);
  --surface-strong: rgba(17, 19, 28, 0.88);
  --text: #f7f3ea;
  --muted: #aeb4c5;
  --soft: #d7dce8;
  --red: #e23045;
  --red-2: #9f2231;
  --cyan: #73d7e9;
  --gold: #f3c66b;
  --line: rgba(255, 255, 255, 0.14);
  --glow: rgba(226, 48, 69, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  margin: 0;
  min-width: 320px;
  background: #05060a;
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow: hidden;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

main {
  height: 100svh;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  overflow: hidden;
}

.experience {
  --release-backdrop: none;
  position: relative;
  min-height: 0;
  height: auto;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at 76% 42%, rgba(115, 215, 233, 0.12), transparent 28%),
    radial-gradient(circle at 42% 24%, rgba(226, 48, 69, 0.14), transparent 34%),
    #05060a;
}

.experience::before {
  content: "";
  position: absolute;
  inset: -12%;
  z-index: -2;
  background-image: var(--release-backdrop);
  background-size: cover;
  background-position: center;
  filter: blur(24px) saturate(1.15);
  opacity: 0.2;
  transform: scale(1.04);
}

#scene-canvas {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: block;
}

.key-art {
  position: absolute;
  top: 10%;
  right: clamp(20px, 8vw, 150px);
  z-index: 0;
  width: min(58vw, 780px);
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background-image:
    linear-gradient(90deg, rgba(5, 6, 10, 0.08), rgba(5, 6, 10, 0.52)),
    var(--release-backdrop);
  background-size: cover;
  background-position: center;
  box-shadow: 0 32px 120px rgba(0, 0, 0, 0.62), 0 0 70px var(--glow);
  opacity: 0.64;
  transform: perspective(1200px) rotateY(-12deg) rotateX(2deg);
  transform-origin: center right;
  mask-image: linear-gradient(90deg, transparent 0%, black 18%, black 76%, transparent 100%);
}

.key-art::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    linear-gradient(0deg, rgba(5, 6, 10, 0.72), transparent 42%, rgba(5, 6, 10, 0.24)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.055) 0 1px, transparent 1px 7px);
  mix-blend-mode: screen;
  opacity: 0.32;
}

.scene-vignette {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(5, 6, 10, 0.9) 0%, rgba(5, 6, 10, 0.48) 31%, rgba(5, 6, 10, 0.08) 58%, rgba(5, 6, 10, 0.46) 100%),
    linear-gradient(0deg, rgba(5, 6, 10, 0.95) 0%, rgba(5, 6, 10, 0.28) 22%, rgba(5, 6, 10, 0) 58%, rgba(5, 6, 10, 0.58) 100%);
}

.hero {
  position: relative;
  z-index: 3;
  min-height: 100%;
  display: flex;
  align-items: center;
  padding: clamp(18px, 4vw, 44px) clamp(18px, 6vw, 88px) 118px;
  pointer-events: none;
}

.hero__content {
  width: min(540px, 100%);
  padding: clamp(18px, 2.4vw, 28px);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(14, 16, 24, 0.82), rgba(14, 16, 24, 0.52)),
    radial-gradient(circle at 0% 0%, rgba(115, 215, 233, 0.12), transparent 42%);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.44);
  backdrop-filter: blur(18px);
  pointer-events: auto;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--cyan);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  max-width: 720px;
  font-size: clamp(2.1rem, 4.8vw, 4.9rem);
  line-height: 0.96;
  letter-spacing: 0;
}

.hero__meta {
  margin: 16px 0 0;
  color: var(--soft);
  font-size: clamp(1rem, 1.5vw, 1.16rem);
  line-height: 1.45;
}

.hero__badges {
  margin-top: 18px;
}

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(68px, 1fr));
  gap: 8px;
  margin-top: 22px;
}

.countdown__unit,
.countdown__tba {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.055);
}

.countdown__unit {
  min-height: 72px;
  padding: 12px 10px;
}

.countdown__num {
  display: block;
  font-size: clamp(1.45rem, 3.8vw, 2.45rem);
  font-weight: 950;
  line-height: 1;
}

.countdown__label {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
}

.countdown__tba {
  display: block;
  grid-column: 1 / -1;
  padding: 14px;
  color: var(--muted);
  font-weight: 850;
}

.hero__actions {
  margin-top: 18px;
}

.selector {
  position: absolute;
  left: clamp(16px, 4.5vw, 64px);
  right: clamp(16px, 4.5vw, 64px);
  bottom: 14px;
  z-index: 4;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr) 48px;
  gap: 10px;
  align-items: stretch;
}

.selector__track {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 4px;
  scrollbar-width: none;
  scroll-padding-inline: 12px;
}

.selector__track::-webkit-scrollbar {
  display: none;
}

.selector-dot,
.nav-button,
.filter,
.action,
.icon-button {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(13, 15, 23, 0.72);
  color: var(--text);
  font-size: 0.84rem;
  font-weight: 850;
  cursor: pointer;
  backdrop-filter: blur(16px);
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.details-toggle {
  display: none;
}

.selector-dot:hover,
.nav-button:hover,
.filter:hover,
.action:hover,
.icon-button:hover {
  border-color: rgba(255, 255, 255, 0.32);
}

.selector-dot {
  flex: 0 0 clamp(156px, 18vw, 230px);
  min-height: 58px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 9px 12px;
  text-align: left;
}

.selector-dot__title,
.selector-dot__date {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.selector-dot__date {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 760;
}

.selector-dot.is-active {
  background: linear-gradient(135deg, rgba(226, 48, 69, 0.95), rgba(159, 34, 49, 0.86));
  border-color: rgba(255, 122, 135, 0.58);
  box-shadow: 0 10px 28px rgba(226, 48, 69, 0.22);
}

.selector-dot.is-active .selector-dot__date {
  color: rgba(255, 255, 255, 0.76);
}

.nav-button {
  min-height: 58px;
  padding: 0;
  font-size: 0;
}

.nav-button::before {
  display: block;
  font-size: 1.6rem;
  line-height: 1;
}

#prev-release::before {
  content: "‹";
}

#next-release::before {
  content: "›";
}

.toolbar {
  position: relative;
  top: auto;
  z-index: 8;
  display: flex;
  gap: 9px;
  align-items: center;
  padding: 14px clamp(16px, 5vw, 56px);
  background: rgba(5, 6, 10, 0.86);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(18px);
  overflow-x: auto;
}

.filter {
  min-height: 40px;
  padding: 0 15px;
}

.filter.is-active,
.action--primary {
  background: linear-gradient(135deg, var(--red), var(--red-2));
  border-color: rgba(255, 122, 135, 0.58);
}

.status {
  margin-left: auto;
  min-width: max-content;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 760;
}

.release-grid {
  display: none;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 18px;
  padding: 28px clamp(16px, 5vw, 56px) 56px;
}

.experience.is-fallback ~ .release-grid {
  display: grid;
}

.card {
  min-height: 470px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(15, 17, 25, 0.9);
}

.poster {
  aspect-ratio: 2 / 3;
  background: linear-gradient(145deg, rgba(52, 56, 72, 0.9), rgba(99, 24, 34, 0.78));
  background-size: cover;
  background-position: center;
}

.card__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
}

.card h2 {
  margin: 0;
  font-size: 1.15rem;
  line-height: 1.2;
  letter-spacing: 0;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.pill {
  padding: 5px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 820;
}

.release-date {
  margin-top: auto;
  color: var(--gold);
  font-size: 1.02rem;
  font-weight: 850;
}

.mini-countdown {
  color: var(--muted);
  font-size: 0.92rem;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.action,
.icon-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 0 14px;
  text-decoration: none;
}

.action--quiet {
  color: var(--muted);
}

.overview {
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
}

.discovery {
  display: none;
  grid-template-columns: minmax(180px, 280px) minmax(0, 1fr);
  gap: 28px;
  padding: 38px clamp(16px, 5vw, 56px) 58px;
  background:
    radial-gradient(circle at 82% 10%, rgba(115, 215, 233, 0.08), transparent 28%),
    #07080d;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.discovery h2 {
  margin: 0;
  font-size: 1.32rem;
  letter-spacing: 0;
}

.discovery-list {
  display: grid;
  gap: 10px;
  color: var(--muted);
}

.discovery-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 8px;
  background: rgba(15, 17, 25, 0.68);
}

.discovery-item h3 {
  margin: 0 0 5px;
  font-size: 0.98rem;
  color: var(--text);
}

.discovery-item p {
  margin: 0;
  font-size: 0.86rem;
  line-height: 1.4;
}

footer {
  display: none;
  justify-content: space-between;
  gap: 18px;
  padding: 22px clamp(16px, 5vw, 56px);
  border-top: 1px solid rgba(255, 255, 255, 0.09);
  background: #07080d;
  color: var(--muted);
  font-size: 0.84rem;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal.is-open {
  display: flex;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
}

.modal__panel {
  position: relative;
  width: min(980px, 100%);
  max-height: calc(100vh - 40px);
  overflow: auto;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #101119;
}

.modal__panel h2 {
  margin: 0 46px 14px 0;
  font-size: 1.15rem;
}

.modal__close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  padding: 0;
}

.video-frame {
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

@media (max-width: 860px) {
  body {
    position: fixed;
    inset: 0;
    width: 100%;
  }

  main {
    grid-template-rows: minmax(0, 1fr) 58px;
  }

  .scene-vignette {
    background:
      linear-gradient(0deg, rgba(5, 6, 10, 0.98) 0%, rgba(5, 6, 10, 0.82) 28%, rgba(5, 6, 10, 0.18) 62%, rgba(5, 6, 10, 0.32) 100%),
      linear-gradient(90deg, rgba(5, 6, 10, 0.48), rgba(5, 6, 10, 0.04), rgba(5, 6, 10, 0.48));
  }

  .key-art {
    display: none;
  }

  .hero {
    align-items: end;
    min-height: 100%;
    padding: 12px 10px 98px;
  }

  .hero__content {
    width: 100%;
    max-height: calc(100svh - 164px);
    overflow: hidden;
    padding: 14px;
    border-radius: 8px;
  }

  h1 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    font-size: clamp(1.9rem, 9.6vw, 2.75rem);
    line-height: 0.96;
  }

  .eyebrow {
    margin-bottom: 10px;
    font-size: 0.7rem;
  }

  .hero__meta {
    margin-top: 12px;
    font-size: 0.94rem;
  }

  .details-toggle {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    justify-content: center;
    margin-top: 12px;
    padding: 0 14px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.07);
    color: var(--text);
    font: inherit;
    font-size: 0.82rem;
    font-weight: 850;
  }

  .hero__badges {
    margin-top: 12px;
  }

  .hero__badges,
  .countdown,
  .hero__actions {
    display: none;
  }

  .details-open .hero__badges {
    display: flex;
  }

  .pill {
    padding: 4px 7px;
    font-size: 0.68rem;
  }

  .countdown {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 16px;
  }

  .details-open .countdown {
    display: grid;
  }

  .countdown__unit {
    min-height: 58px;
    padding: 9px 10px;
  }

  .countdown__num {
    font-size: 1.55rem;
  }

  .countdown__label {
    margin-top: 4px;
    font-size: 0.62rem;
  }

  .hero__actions {
    margin-top: 14px;
  }

  .details-open .hero__actions {
    display: flex;
  }

  .action {
    min-height: 40px;
    padding: 0 12px;
    font-size: 0.82rem;
  }

  .selector {
    left: 10px;
    right: 10px;
    bottom: 8px;
    grid-template-columns: 48px minmax(0, 1fr) 48px;
    gap: 8px;
  }

  .selector-dot {
    flex-basis: min(68vw, 244px);
    min-height: 54px;
    padding: 8px 10px;
  }

  .nav-button {
    min-height: 54px;
  }

  .toolbar {
    gap: 8px;
    padding: 7px 10px;
    overflow-x: auto;
    border-top-color: rgba(255, 255, 255, 0.16);
  }

  .filter {
    min-height: 40px;
    flex: 0 0 auto;
    padding: 0 14px;
    font-size: 0.8rem;
  }

  .status {
    display: none;
  }

  .discovery,
  .discovery-item {
    grid-template-columns: 1fr;
  }

  footer {
    flex-direction: column;
  }

  .action {
    flex: 1 1 auto;
  }
}

@media (max-width: 420px) and (max-height: 760px) {
  .hero__content {
    padding: 14px;
  }

  h1 {
    font-size: clamp(1.68rem, 8.8vw, 2.35rem);
  }

  .details-open .hero__badges {
    display: none;
  }

  .countdown {
    margin-top: 12px;
  }

  .countdown__unit {
    min-height: 52px;
  }
}
