html,
body {
  height: 100dvh;
  max-height: 100dvh;
  overflow: hidden;
  overscroll-behavior: none;
}

.scroller {
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #e879f9 transparent;
}
.scroller.is-dragging { cursor: grabbing; }
.scroller::-webkit-scrollbar { height: 10px; }
.scroller::-webkit-scrollbar-thumb {
  background: linear-gradient(90deg, #e879f9, #fbbf24);
  border-radius: 99px;
}

.track {
  padding-inline: 40vw;
  height: 100%;
}

.rail {
  min-height: 0;
}

.years-line::before {
  content: "";
  position: absolute;
  left: 0;
  right: 1.5rem;
  top: 50%;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, #e879f9, #f59e0b, #22d3ee, #a78bfa);
  transform: translateY(-50%);
}

.year-tick {
  flex: 0 0 min(78vw, 34rem);
  width: min(78vw, 34rem);
  margin-right: 1.5rem;
  position: relative;
  border: 0;
  background: transparent;
  color: #a1a1aa;
  font: inherit;
  cursor: pointer;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.year-tick span:empty { display: none; }
.year-tick.is-start span {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: #18181b;
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.year-tick.is-on span,
.year-tick.is-start.is-on span {
  color: #0a0a0a;
  background: #f0abfc;
  border-color: #f0abfc;
}
.year-tick::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -2px;
  width: 10px;
  height: 10px;
  margin-left: -5px;
  border-radius: 50%;
  background: #52525b;
  box-shadow: 0 0 0 4px #09090b;
}
.year-tick.is-on::after {
  background: #f0abfc;
  box-shadow: 0 0 0 4px #09090b, 0 0 18px #e879f9;
}

.card {
  flex: 0 0 min(78vw, 34rem);
  width: min(78vw, 34rem);
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  margin-right: 1.5rem;
  scroll-snap-align: center;
  border-radius: 1.75rem;
  overflow: hidden;
  background: rgba(24, 24, 27, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.1);
  cursor: pointer;
  opacity: 0.38;
  transform: scale(0.82);
  transform-origin: center center;
  filter: saturate(0.65) brightness(0.72);
  z-index: 0;
  transition:
    transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.35s ease,
    filter 0.35s ease,
    box-shadow 0.35s ease,
    border-color 0.35s ease;
}
.card.is-active {
  opacity: 1;
  transform: scale(1);
  filter: none;
  z-index: 2;
  border-color: #e879f9;
  box-shadow:
    0 0 0 1px rgba(232, 121, 249, 0.45),
    0 28px 80px rgba(232, 121, 249, 0.38),
    0 12px 32px rgba(0, 0, 0, 0.45);
}
.card.is-future .shot {
  background:
    radial-gradient(circle at 50% 40%, rgba(232, 121, 249, 0.35), transparent 55%),
    #18181b;
}

.browser {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #09090b;
  padding: 10px 10px 0;
}
.dots { display: flex; gap: 6px; margin-bottom: 8px; flex-shrink: 0; }
.dots i { width: 8px; height: 8px; border-radius: 50%; background: #3f3f46; }
.dots i:nth-child(1) { background: #fb7185; }
.dots i:nth-child(2) { background: #fbbf24; }
.dots i:nth-child(3) { background: #34d399; }

.shot {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  background: #27272a;
}
.shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  -webkit-user-drag: none;
}

.ph {
  height: 100%;
  display: grid;
  place-items: center;
  font-family: Fraunces, Georgia, serif;
  color: #e4e4e7;
}
.ph.surprise { display: flex; flex-direction: column; gap: 8px; }
.ph.surprise .q { font-size: 5.5rem; line-height: 1; font-style: normal; }
.ph.surprise em {
  font-style: normal;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 11px;
  border: 1px solid rgba(240, 171, 252, 0.5);
  border-radius: 999px;
  padding: 4px 10px;
  color: #f0abfc;
}

.card-body { flex-shrink: 0; padding: 1rem 1.1rem 1.15rem; }
.card-year {
  margin: 0 0 4px;
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #e879f9;
  font-weight: 600;
}
.card h3 {
  margin: 0;
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 800;
}
.card p {
  margin: 6px 0 0;
  font-size: 0.9rem;
  color: #a1a1aa;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(240, 171, 252, 0.15);
  color: #f0abfc;
}
.dock-links a { text-decoration: underline; text-underline-offset: 3px; }

.nav-btn,
.stack-btn {
  background: rgba(255, 255, 255, 0.05);
  color: #e4e4e7;
  transition: background 0.15s ease, color 0.15s ease, opacity 0.15s ease, border-color 0.15s ease;
}
.nav-btn:not(:disabled):not(.is-on):hover,
.stack-btn:not(:disabled):not(.is-on):hover {
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
}
.nav-btn.is-on,
.stack-btn.is-on {
  background: #fff;
  color: #09090b;
}
.nav-btn.is-on:hover,
.stack-btn.is-on:hover {
  background: #fff;
  color: #09090b;
}
.nav-btn:disabled,
.stack-btn:disabled {
  opacity: 0.38;
  color: #71717a;
  background: rgba(255, 255, 255, 0.03);
  cursor: not-allowed;
  pointer-events: none;
}

dialog::backdrop { background: rgba(0, 0, 0, 0.7); }
