:root {
  color-scheme: dark;
  font-family: system-ui, sans-serif;
  color: #fcf1e3;
  background: #0e0c0b;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  background: radial-gradient(ellipse at 50% 22%, #261b14, #0e0c0b 70%);
}

.landing {
  display: grid;
  justify-items: center;
  align-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  gap: clamp(1rem, 3vw, 1.75rem);
  padding:
    max(1.5rem, env(safe-area-inset-top))
    max(clamp(1rem, 4vw, 3rem), env(safe-area-inset-right))
    max(1.5rem, env(safe-area-inset-bottom))
    max(clamp(1rem, 4vw, 3rem), env(safe-area-inset-left));
}

.release-title {
  margin: 0;
  text-align: center;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.75rem, 4vw, 3rem);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.release-date {
  color: #f6ca94;
  white-space: nowrap;
}

.cinema {
  position: relative;
  width: min(100%, 62rem);
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid rgb(246 202 148 / 23%);
  border-radius: 0.75rem;
  background: #0e0c0b;
  box-shadow: 0 1rem 3.75rem rgb(0 0 0 / 45%);
}

@media (min-width: 48rem) {
  .cinema {
    width: min(86%, 62rem);
    max-width: max(26rem, calc((100dvh - 8.5rem) * 16 / 9));
  }
}

.cinema:fullscreen {
  width: 100%;
  max-width: none;
  height: 100%;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

button {
  font: inherit;
  color: inherit;
  cursor: pointer;
  touch-action: manipulation;
}

button:focus-visible,
.start:focus-visible,
.timeline:focus-visible {
  outline: 2px solid #f6ca94;
  outline-offset: 3px;
}

button:disabled {
  opacity: 0.5;
  cursor: default;
}

.dock {
  position: absolute;
  bottom: max(1rem, env(safe-area-inset-bottom));
  width: min(calc(100% - 1.5rem), 36rem);
  padding: 0.25rem 0.625rem 0.5rem;
  border: 1px solid rgb(252 241 227 / 18%);
  border-radius: 0.875rem;
  background: rgb(19 15 13 / 92%);
  box-shadow: 0 0.5rem 2.25rem rgb(0 0 0 / 30%);
  transition: opacity 240ms ease, transform 240ms ease;
}

.cinema[data-idle] .dock {
  opacity: 0;
  transform: translateY(0.375rem);
  pointer-events: none;
}

.fullscreen-status {
  margin: 0.375rem 0.3125rem 0;
  color: #dbcbb8;
  font-size: 0.875rem;
}

.actions {
  display: flex;
  align-items: center;
  gap: 0.375rem;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 2.75rem;
  min-height: 2.75rem;
  border: 0;
  border-radius: 0.5rem;
  background: transparent;
}

.icon-button:hover:not(:disabled) {
  background: rgb(252 241 227 / 12%);
}

.time {
  margin-inline-start: auto;
  padding-inline: 0.25rem;
  color: #dbcbb8;
  font-size: 0.875rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.timeline {
  --progress: 0%;
  appearance: none;
  display: block;
  width: calc(100% - 0.625rem);
  height: 1.375rem;
  margin: 0 auto;
  border-radius: 0.25rem;
  background: transparent;
  cursor: pointer;
}

.timeline:disabled { cursor: default; }

.timeline::-webkit-slider-runnable-track {
  height: 0.1875rem;
  border-radius: 1rem;
  background: linear-gradient(to right, #f6ca94 var(--progress), #665951 var(--progress));
}

.timeline::-moz-range-track {
  height: 0.1875rem;
  border-radius: 1rem;
  background: linear-gradient(to right, #f6ca94 var(--progress), #665951 var(--progress));
}

.timeline::-webkit-slider-thumb {
  appearance: none;
  width: 0.625rem;
  height: 0.625rem;
  margin-top: -0.21875rem;
  border: 0;
  border-radius: 50%;
  background: #fcf1e3;
}

.timeline::-moz-range-thumb {
  width: 0.625rem;
  height: 0.625rem;
  border: 0;
  border-radius: 50%;
  background: #fcf1e3;
}

.play-icon {
  width: 0;
  height: 0;
  margin-inline-start: 0.125rem;
  border-block: 0.4375rem solid transparent;
  border-inline-start: 0.6875rem solid currentColor;
}

[data-icon="pause"] .play-icon {
  width: 0.6875rem;
  height: 0.875rem;
  margin: 0;
  border: solid currentColor;
  border-width: 0 0.1875rem;
}

.fullscreen-icon {
  display: block;
  width: 1rem;
  height: 1rem;
  background:
    linear-gradient(currentColor 0 0) left top / 6px 2px,
    linear-gradient(currentColor 0 0) left top / 2px 6px,
    linear-gradient(currentColor 0 0) right top / 6px 2px,
    linear-gradient(currentColor 0 0) right top / 2px 6px,
    linear-gradient(currentColor 0 0) left bottom / 6px 2px,
    linear-gradient(currentColor 0 0) left bottom / 2px 6px,
    linear-gradient(currentColor 0 0) right bottom / 6px 2px,
    linear-gradient(currentColor 0 0) right bottom / 2px 6px;
  background-repeat: no-repeat;
}

.cinema:fullscreen .fullscreen-icon { transform: scale(0.75); }

.prompt {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 0.75rem;
  max-width: calc(100% - 2rem);
  text-align: center;
}

.prompt p {
  margin: 0;
  padding: 0.5rem 0.75rem;
  border-radius: 0.5rem;
  background: #17110e;
}

.start {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 3.5rem;
  padding: 0.75rem 1.375rem;
  border: 1px solid rgb(252 241 227 / 32%);
  border-radius: 0.75rem;
  background: #17110e;
  color: inherit;
  box-shadow: 0 0.5rem 2rem rgb(0 0 0 / 35%);
  font-weight: 650;
  text-decoration: none;
}

.start:hover { background: #30231c; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

@media (prefers-reduced-motion: reduce) {
  .dock { transition: none; }
}
