:root {
  color-scheme: dark;
  --ink: #07090f;
  --ink-soft: #0b111d;
  --surface: #131b2a;
  --surface-strong: #1b2538;
  --white: #fffaf2;
  --secondary: #d7d4cf;
  --muted: #8e98aa;
  --gold: #e9c778;
  --aurora: #78d7cf;
  --violet: #9b8ee6;
  --rose: #ff8290;
  --green: #8ad6a8;
  --sidebar-width: 82px;
  --content-max: 1680px;
  --ease: cubic-bezier(0.2, 0.75, 0.2, 1);
  font-family: "Segoe UI Variable Display", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont,
    sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: var(--ink);
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 82% -8%, rgba(74, 132, 159, 0.16), transparent 31rem),
    linear-gradient(135deg, #05070c 0%, #07101c 48%, #080910 100%);
  color: var(--white);
  -webkit-font-smoothing: antialiased;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 200;
  top: 12px;
  left: 98px;
  padding: 10px 14px;
  transform: translateY(-180%);
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
}

.skip-link:focus {
  transform: translateY(0);
}

.sidebar {
  position: fixed;
  z-index: 50;
  inset: 0 auto 0 0;
  display: flex;
  width: var(--sidebar-width);
  flex-direction: column;
  align-items: center;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(4, 7, 13, 0.92);
  backdrop-filter: blur(20px);
}

.brand-button,
.mobile-wordmark {
  border: 0;
  background: transparent;
}

.brand-button {
  display: grid;
  width: 56px;
  height: 76px;
  place-items: center;
  margin-top: 6px;
}

.brand-letter {
  grid-area: 1 / 1;
  font-size: 1.34rem;
  font-weight: 900;
}

.brand-plus {
  grid-area: 1 / 1;
  margin: 33px 0 0 2px;
  color: var(--aurora);
  font-size: 1.25rem;
  font-weight: 900;
  text-shadow: 0 0 16px rgba(120, 215, 207, 0.7);
}

.side-nav {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
}

.side-nav button {
  position: relative;
  display: grid;
  width: 52px;
  min-height: 52px;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 13px;
  background: transparent;
  color: var(--muted);
  transition:
    color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.side-nav button:hover,
.side-nav button[aria-current="page"] {
  background: rgba(255, 255, 255, 0.09);
  color: var(--white);
}

.side-nav button[aria-current="page"]::before {
  position: absolute;
  left: -16px;
  width: 3px;
  height: 24px;
  border-radius: 99px;
  background: var(--gold);
  content: "";
  box-shadow: 0 0 16px rgba(233, 199, 120, 0.55);
}

.nav-icon {
  font-size: 1.3rem;
  line-height: 1;
}

.nav-label {
  position: absolute;
  left: 60px;
  display: none;
  width: max-content;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 7px;
  background: #101725;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
  font-size: 0.75rem;
  font-weight: 700;
}

.side-nav button:hover .nav-label,
.side-nav button:focus-visible .nav-label {
  display: block;
}

.profile-button,
.mobile-profile {
  display: grid;
  place-items: center;
  border: 1px solid rgba(233, 199, 120, 0.76);
  border-radius: 12px;
  background: linear-gradient(145deg, #25354a, #131a27);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 900;
}

.profile-button {
  width: 46px;
  height: 46px;
  margin-bottom: 22px;
}

.mobile-header,
.bottom-nav {
  display: none;
}

.app-main {
  min-height: 100dvh;
  margin-left: var(--sidebar-width);
}

.view {
  width: 100%;
  max-width: var(--content-max);
  min-height: 100dvh;
  margin: 0 auto;
  padding: clamp(30px, 4vw, 70px) clamp(24px, 4.5vw, 74px) 90px;
}

.home-view {
  max-width: none;
  padding-top: 0;
  padding-right: 0;
  padding-left: 0;
}

.hero {
  --art-a: #0b2738;
  --art-b: #277982;
  --art-c: #e9c778;
  position: relative;
  display: flex;
  min-height: clamp(560px, 68vh, 760px);
  align-items: flex-end;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(circle at 78% 26%, color-mix(in srgb, var(--art-c) 82%, white), transparent 5%),
    radial-gradient(circle at 78% 27%, color-mix(in srgb, var(--art-c) 48%, transparent), transparent 17%),
    linear-gradient(118deg, var(--ink) 9%, var(--art-a) 51%, var(--art-b) 100%);
}

.hero::before {
  position: absolute;
  z-index: -1;
  top: 4%;
  right: -10%;
  width: min(74vw, 1180px);
  aspect-ratio: 1.65 / 1;
  transform: rotate(-7deg);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  background:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    rgba(2, 9, 18, 0.34);
  background-size: 48px 48px;
  box-shadow:
    0 0 0 64px rgba(255, 255, 255, 0.018),
    inset 0 -100px 130px rgba(0, 0, 0, 0.48);
  content: "";
}

.hero::after {
  position: absolute;
  z-index: 0;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(5, 7, 12, 0.98) 0%, rgba(5, 7, 12, 0.78) 33%, transparent 71%),
    linear-gradient(0deg, var(--ink) 0%, transparent 39%);
  content: "";
  pointer-events: none;
}

.hero-copy {
  position: relative;
  z-index: 1;
  width: min(680px, 67%);
  padding: clamp(82px, 10vh, 130px) clamp(28px, 7vw, 116px) 74px;
}

.eyebrow {
  margin: 0 0 20px;
  color: var(--gold);
  font-size: 0.69rem;
  font-weight: 800;
  letter-spacing: 0.24em;
  line-height: 1.5;
  text-transform: uppercase;
}

.hero h1,
.page-header h1,
.details-copy h2 {
  margin: 0;
  font-size: clamp(3.2rem, 6.8vw, 7.3rem);
  font-weight: 850;
  letter-spacing: -0.065em;
  line-height: 0.88;
  text-wrap: balance;
}

.hero-description {
  max-width: 610px;
  margin: 24px 0 0;
  color: var(--secondary);
  font-size: clamp(1rem, 1.25vw, 1.28rem);
  line-height: 1.62;
}

.metadata {
  display: flex;
  flex-wrap: wrap;
  gap: 9px 17px;
  align-items: center;
  margin: 22px 0 0;
  color: #c3cbd8;
  font-size: 0.8rem;
  font-weight: 650;
}

.metadata span:not(:last-child)::after {
  margin-left: 17px;
  color: #697487;
  content: "•";
}

.metadata .format {
  padding: 3px 6px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 4px;
}

.metadata .format::after {
  display: none;
}

.hero-actions,
.details-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 11px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  font-size: 0.88rem;
  font-weight: 800;
  transition:
    transform 150ms var(--ease),
    background 150ms ease,
    border-color 150ms ease;
}

.button:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.3);
  background: rgba(255, 255, 255, 0.15);
}

.button.primary {
  border-color: var(--white);
  background: var(--white);
  color: var(--ink);
}

.button.quiet {
  border-color: transparent;
  background: transparent;
}

.button.saved {
  border-color: rgba(233, 199, 120, 0.45);
  background: rgba(233, 199, 120, 0.13);
  color: var(--gold);
}

.button.full-width {
  width: 100%;
}

.hero-corner-label {
  position: absolute;
  z-index: 1;
  right: 28px;
  bottom: 126px;
  color: rgba(255, 255, 255, 0.45);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  writing-mode: vertical-rl;
}

.home-sections {
  position: relative;
  z-index: 2;
  margin-top: -18px;
  padding: 0 clamp(24px, 4.5vw, 74px) 92px;
}

.section-block {
  margin-top: 46px;
}

.section-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 20px;
  margin: 0 0 18px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.35rem, 2vw, 2rem);
  letter-spacing: -0.035em;
}

.section-heading span {
  color: var(--muted);
  font-size: 0.75rem;
}

.rail {
  display: grid;
  grid-auto-columns: clamp(235px, 21vw, 340px);
  grid-auto-flow: column;
  gap: 16px;
  overflow-x: auto;
  padding: 6px 5px 24px;
  scroll-padding-inline: 5px;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
}

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

.film-card,
.collection-card {
  min-width: 0;
  overflow: hidden;
  scroll-snap-align: start;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 12px;
  background: rgba(18, 25, 38, 0.86);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.3);
  text-align: left;
  transition:
    transform 170ms var(--ease),
    border-color 170ms ease,
    box-shadow 170ms ease;
}

.film-card:hover,
.collection-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.44);
}

.film-art,
.collection-art,
.detail-art,
.player-visual {
  --art-a: #162b45;
  --art-b: #2f6e82;
  --art-c: #e9c778;
}

.palette-teal {
  --art-a: #0d2637;
  --art-b: #277782;
  --art-c: #efd487;
}

.palette-violet {
  --art-a: #27213f;
  --art-b: #7c6395;
  --art-c: #e9b77a;
}

.palette-rose {
  --art-a: #3d1d35;
  --art-b: #9e536d;
  --art-c: #f1bd75;
}

.palette-blue {
  --art-a: #122740;
  --art-b: #356b96;
  --art-c: #8ee1dc;
}

.palette-amber {
  --art-a: #392319;
  --art-b: #a96543;
  --art-c: #f4d79b;
}

.palette-green {
  --art-a: #102e2b;
  --art-b: #39796a;
  --art-c: #b9e18c;
}

.film-art {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background:
    radial-gradient(circle at 72% 29%, var(--art-c), transparent 6%),
    radial-gradient(circle at 72% 29%, color-mix(in srgb, var(--art-c) 45%, transparent), transparent 22%),
    linear-gradient(138deg, var(--art-a), var(--art-b));
}

.film-art::before,
.collection-art::before {
  position: absolute;
  top: -62%;
  right: -13%;
  width: 78%;
  height: 170%;
  transform: rotate(28deg);
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  box-shadow:
    0 0 0 22px rgba(255, 255, 255, 0.025),
    inset 0 -40px 50px rgba(0, 0, 0, 0.3);
  content: "";
}

.film-index {
  position: absolute;
  right: 11px;
  bottom: -7px;
  color: rgba(255, 255, 255, 0.24);
  font-size: 3.1rem;
  font-weight: 900;
  letter-spacing: -0.08em;
}

.film-place {
  position: absolute;
  top: 12px;
  left: 13px;
  padding: 5px 7px;
  border-radius: 5px;
  background: rgba(3, 8, 14, 0.48);
  color: rgba(255, 255, 255, 0.86);
  font-size: 0.55rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.film-copy {
  display: block;
  padding: 14px 15px 16px;
}

.film-copy strong {
  display: block;
  overflow: hidden;
  font-size: 0.93rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.film-copy small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.68rem;
}

.progress-track {
  display: block;
  height: 3px;
  margin-top: 12px;
  overflow: hidden;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.14);
}

.progress-track i {
  display: block;
  width: var(--progress, 0%);
  height: 100%;
  border-radius: inherit;
  background: var(--aurora);
  box-shadow: 0 0 8px rgba(120, 215, 207, 0.6);
}

.collection-rail {
  grid-auto-columns: clamp(240px, 19vw, 320px);
}

.collection-card {
  min-height: 150px;
}

.collection-art {
  position: relative;
  display: grid;
  min-height: 150px;
  align-content: end;
  padding: 18px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--art-a), var(--art-b));
}

.collection-art small,
.collection-art strong,
.collection-art em {
  position: relative;
  z-index: 1;
}

.collection-art small {
  margin-bottom: 6px;
  color: var(--art-c);
  font-size: 0.54rem;
  font-weight: 850;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.collection-art strong {
  max-width: 78%;
  font-size: 1.05rem;
}

.collection-art em {
  margin-top: 5px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.62rem;
  font-style: normal;
}

.collection-number {
  position: absolute;
  z-index: 0;
  right: 12px;
  bottom: -9px;
  color: rgba(255, 255, 255, 0.16);
  font-size: 4rem;
  font-weight: 900;
  letter-spacing: -0.08em;
}

.page-header {
  display: flex;
  min-height: 158px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
}

.page-header h1 {
  font-size: clamp(3rem, 5.6vw, 6.2rem);
}

.page-header .eyebrow {
  margin-bottom: 13px;
}

.page-header-copy {
  max-width: 720px;
  margin: 15px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 30px;
}

.content-grid .film-card,
.content-grid .collection-card {
  width: 100%;
}

.content-grid .collection-art {
  min-height: 210px;
}

.search-panel {
  display: grid;
  grid-template-columns: minmax(260px, 0.7fr) minmax(0, 1.5fr);
  gap: clamp(28px, 5vw, 78px);
  margin-top: 38px;
}

.search-box {
  position: sticky;
  top: 30px;
  align-self: start;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 15px;
  background: rgba(18, 27, 42, 0.66);
}

.search-box label {
  display: block;
  margin-bottom: 10px;
  color: var(--secondary);
  font-size: 0.85rem;
  font-weight: 700;
}

.search-input-wrap {
  display: flex;
  min-height: 56px;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 10px;
  background: rgba(3, 7, 13, 0.7);
}

.search-input-wrap span {
  color: var(--aurora);
  font-size: 1.35rem;
}

.search-input-wrap input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--white);
  font-size: 1rem;
}

.search-input-wrap input::placeholder {
  color: #747e8f;
}

.recent-label {
  display: block;
  margin: 20px 0 9px;
  color: var(--muted);
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

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

.chip,
.decade-button {
  min-height: 42px;
  padding: 0 13px;
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--secondary);
  font-size: 0.72rem;
}

.chip:hover,
.decade-button:hover,
.decade-button.active {
  border-color: rgba(120, 215, 207, 0.42);
  background: rgba(120, 215, 207, 0.1);
  color: var(--white);
}

.results-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.results-heading h2 {
  margin: 0;
  font-size: 1.5rem;
}

.results-heading span {
  color: var(--muted);
  font-size: 0.76rem;
}

.search-results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.empty-state {
  display: grid;
  min-height: 320px;
  place-items: center;
  padding: 36px;
  border: 1px dashed rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  color: var(--muted);
  text-align: center;
}

.empty-state strong {
  display: block;
  margin-bottom: 8px;
  color: var(--white);
  font-size: 1.25rem;
}

.timeline-controls {
  display: flex;
  gap: 10px;
  margin: 30px 0 12px;
  overflow-x: auto;
  padding: 5px;
  scrollbar-width: none;
}

.decade-button {
  flex: 0 0 auto;
  min-width: 95px;
  border-radius: 9px;
}

.timeline-list {
  position: relative;
  margin-top: 28px;
}

.timeline-list::before {
  position: absolute;
  inset: 0 auto 0 74px;
  width: 1px;
  background: rgba(255, 255, 255, 0.11);
  content: "";
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 75px 170px minmax(0, 1fr) 44px;
  gap: 18px;
  align-items: center;
  width: 100%;
  min-height: 116px;
  padding: 14px 0;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: transparent;
  text-align: left;
}

.timeline-year {
  position: relative;
  align-self: start;
  padding-top: 12px;
  font-size: 0.9rem;
  font-weight: 850;
}

.timeline-year::after {
  position: absolute;
  top: 18px;
  right: -4px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 13px rgba(233, 199, 120, 0.7);
  content: "";
}

.timeline-thumb {
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  background:
    radial-gradient(circle at 72% 30%, var(--art-c), transparent 8%),
    linear-gradient(135deg, var(--art-a), var(--art-b));
}

.timeline-copy strong {
  display: block;
  font-size: 0.98rem;
}

.timeline-copy small {
  display: block;
  margin-bottom: 7px;
  color: var(--gold);
  font-size: 0.57rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.timeline-copy p {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
  line-height: 1.5;
}

.timeline-index {
  color: rgba(255, 255, 255, 0.13);
  font-size: 2rem;
  font-weight: 900;
}

dialog {
  color: var(--white);
}

dialog::backdrop {
  background: rgba(1, 3, 7, 0.78);
  backdrop-filter: blur(14px);
}

.details-dialog,
.player-dialog {
  width: min(1180px, calc(100vw - 44px));
  max-width: none;
  max-height: calc(100dvh - 44px);
  padding: 0;
  overflow: hidden auto;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 18px;
  background: #080d17;
  box-shadow: 0 38px 100px rgba(0, 0, 0, 0.65);
}

.details-layout {
  display: grid;
  min-height: min(700px, calc(100dvh - 46px));
  grid-template-columns: 1.05fr 0.95fr;
}

.detail-art {
  position: relative;
  min-height: 480px;
  overflow: hidden;
  background:
    radial-gradient(circle at 62% 29%, var(--art-c), transparent 6%),
    radial-gradient(circle at 62% 29%, color-mix(in srgb, var(--art-c) 38%, transparent), transparent 22%),
    linear-gradient(140deg, var(--art-a), var(--art-b));
}

.detail-art::before {
  position: absolute;
  width: 112%;
  height: 87%;
  right: -33%;
  bottom: -11%;
  transform: rotate(-16deg);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  box-shadow: 0 0 0 55px rgba(255, 255, 255, 0.025);
  content: "";
}

.detail-art span {
  position: absolute;
  right: 24px;
  bottom: 16px;
  color: rgba(255, 255, 255, 0.18);
  font-size: clamp(3.7rem, 7vw, 7rem);
  font-weight: 900;
  letter-spacing: -0.08em;
  text-transform: uppercase;
}

.details-copy {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(45px, 6vw, 84px);
}

.details-copy > .eyebrow {
  padding-right: 58px;
}

.details-copy h2 {
  font-size: clamp(2.8rem, 4.6vw, 5.1rem);
}

.details-copy .description {
  margin: 24px 0 0;
  color: var(--secondary);
  line-height: 1.65;
}

.details-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: 34px 0 0;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.details-facts dt {
  color: var(--muted);
  font-size: 0.59rem;
  font-weight: 800;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.details-facts dd {
  margin: 6px 0 0;
  color: var(--secondary);
  font-size: 0.76rem;
  line-height: 1.45;
}

.dialog-close {
  position: absolute;
  z-index: 4;
  top: 18px;
  right: 18px;
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 50%;
  background: rgba(4, 8, 14, 0.76);
  color: var(--white);
  font-size: 1.5rem;
}

.player-dialog {
  width: min(1320px, calc(100vw - 28px));
  max-height: calc(100dvh - 28px);
  overflow: hidden;
  background: #03050a;
}

.player-shell {
  position: relative;
  min-height: min(760px, calc(100dvh - 30px));
  overflow: hidden;
  background: #020307;
}

.player-visual {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 65% 34%, var(--art-c), transparent 5%),
    radial-gradient(circle at 65% 34%, color-mix(in srgb, var(--art-c) 36%, transparent), transparent 20%),
    linear-gradient(135deg, var(--art-a), var(--art-b));
}

.player-visual::before {
  position: absolute;
  top: 6%;
  left: 44%;
  width: 70%;
  height: 80%;
  transform: rotate(18deg);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 50%;
  box-shadow: 0 0 0 60px rgba(255, 255, 255, 0.025);
  content: "";
}

.player-visual.playing {
  animation: memory-shift 12s ease-in-out infinite alternate;
}

@keyframes memory-shift {
  to {
    filter: hue-rotate(17deg) brightness(1.08);
    transform: scale(1.035);
  }
}

.player-topbar,
.player-controls {
  position: absolute;
  z-index: 2;
  right: 0;
  left: 0;
  background: linear-gradient(rgba(2, 4, 8, 0.92), transparent);
}

.player-topbar {
  top: 0;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 22px 25px 90px;
}

.player-topbar .dialog-close {
  position: static;
  flex: 0 0 auto;
}

.player-title-group strong {
  display: block;
  font-size: 1.05rem;
}

.player-title-group span {
  color: var(--muted);
  font-size: 0.72rem;
}

.simulation-badge {
  margin-left: auto;
  padding: 7px 10px;
  border: 1px solid rgba(233, 199, 120, 0.25);
  border-radius: 6px;
  background: rgba(5, 8, 13, 0.42);
  color: var(--gold);
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.player-controls {
  bottom: 0;
  padding: 90px 28px 28px;
  background: linear-gradient(transparent, rgba(2, 4, 8, 0.96));
}

.player-range {
  width: 100%;
  height: 36px;
  margin: 0;
  accent-color: var(--aurora);
}

.player-times {
  display: flex;
  justify-content: space-between;
  color: var(--secondary);
  font-size: 0.68rem;
}

.player-buttons {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 10px;
}

.round-control {
  display: grid;
  min-width: 48px;
  height: 48px;
  place-items: center;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  font-weight: 800;
}

.round-control.main {
  width: 62px;
  height: 62px;
  background: var(--white);
  color: var(--ink);
  font-size: 1.15rem;
}

.profile-dialog {
  width: min(430px, calc(100vw - 32px));
  padding: 42px;
  overflow: visible;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 17px;
  background: #101724;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.6);
  text-align: center;
}

.profile-dialog .dialog-close {
  top: 12px;
  right: 12px;
}

.profile-dialog .eyebrow {
  margin: 17px 0 8px;
}

.profile-dialog h2 {
  margin: 0;
  font-size: 1.8rem;
}

.profile-dialog p:not(.eyebrow) {
  margin: 15px 0 25px;
  color: var(--muted);
  line-height: 1.6;
}

.profile-mark {
  display: grid;
  width: 82px;
  height: 82px;
  place-items: center;
  margin: 0 auto;
  border: 1px solid rgba(233, 199, 120, 0.55);
  border-radius: 22px;
  background: linear-gradient(145deg, #2b3c55, #151d2b);
  color: var(--white);
  font-size: 1.3rem;
  font-weight: 900;
}

.toast {
  position: fixed;
  z-index: 300;
  right: 24px;
  bottom: 24px;
  max-width: min(360px, calc(100vw - 32px));
  padding: 13px 16px;
  transform: translateY(30px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  opacity: 0;
  background: #182235;
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.45);
  color: var(--white);
  font-size: 0.78rem;
  pointer-events: none;
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.toast.visible {
  transform: translateY(0);
  opacity: 1;
}

@media (max-width: 1200px) {
  .content-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .search-results-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .details-layout {
    grid-template-columns: 0.9fr 1.1fr;
  }
}

@media (max-width: 900px) {
  :root {
    --sidebar-width: 70px;
  }

  .hero-copy {
    width: 76%;
    padding-left: 46px;
  }

  .content-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-panel {
    grid-template-columns: minmax(230px, 0.65fr) minmax(0, 1fr);
    gap: 24px;
  }

  .details-layout {
    grid-template-columns: 1fr;
  }

  .detail-art {
    min-height: 330px;
  }
}

@media (max-width: 720px) {
  body {
    padding-bottom: env(safe-area-inset-bottom);
  }

  .skip-link {
    left: 12px;
  }

  .sidebar {
    display: none;
  }

  .mobile-header {
    position: fixed;
    z-index: 45;
    top: 0;
    right: 0;
    left: 0;
    display: flex;
    min-height: calc(66px + env(safe-area-inset-top));
    align-items: flex-end;
    justify-content: space-between;
    padding: calc(10px + env(safe-area-inset-top)) 18px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(5, 8, 14, 0.88);
    backdrop-filter: blur(18px);
  }

  .mobile-wordmark {
    padding: 0;
    color: var(--white);
    font-size: 1.18rem;
    font-weight: 900;
    letter-spacing: -0.04em;
  }

  .mobile-wordmark span {
    margin-left: 2px;
    color: var(--aurora);
  }

  .mobile-profile {
    width: 42px;
    height: 42px;
    border-radius: 11px;
  }

  .bottom-nav {
    position: fixed;
    z-index: 50;
    right: 0;
    bottom: 0;
    left: 0;
    display: grid;
    min-height: calc(70px + env(safe-area-inset-bottom));
    grid-template-columns: repeat(5, 1fr);
    padding: 6px 4px env(safe-area-inset-bottom);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(5, 8, 14, 0.94);
    backdrop-filter: blur(20px);
  }

  .bottom-nav button {
    position: relative;
    display: grid;
    min-width: 0;
    min-height: 58px;
    place-items: center;
    align-content: center;
    gap: 2px;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
  }

  .bottom-nav button span {
    font-size: 1.15rem;
  }

  .bottom-nav button small {
    max-width: 100%;
    overflow: hidden;
    font-size: 0.57rem;
    font-weight: 700;
    text-overflow: ellipsis;
  }

  .bottom-nav button[aria-current="page"] {
    color: var(--white);
  }

  .bottom-nav button[aria-current="page"]::before {
    position: absolute;
    top: 0;
    width: 26px;
    height: 2px;
    border-radius: 99px;
    background: var(--gold);
    content: "";
  }

  .app-main {
    margin-left: 0;
  }

  .view {
    min-height: 100dvh;
    padding: calc(88px + env(safe-area-inset-top)) 17px calc(105px + env(safe-area-inset-bottom));
  }

  .home-view {
    padding: calc(66px + env(safe-area-inset-top)) 0 calc(92px + env(safe-area-inset-bottom));
  }

  .hero {
    min-height: 600px;
    align-items: flex-end;
  }

  .hero::before {
    top: 3%;
    right: -48%;
    width: 145vw;
    opacity: 0.74;
  }

  .hero::after {
    background:
      linear-gradient(0deg, var(--ink) 0%, rgba(5, 7, 12, 0.72) 48%, rgba(5, 7, 12, 0.08) 84%),
      linear-gradient(90deg, rgba(5, 7, 12, 0.68), transparent);
  }

  .hero-copy {
    width: 100%;
    padding: 120px 19px 51px;
  }

  .hero h1 {
    max-width: 95%;
    font-size: clamp(3.35rem, 15vw, 5.2rem);
  }

  .hero-description {
    display: -webkit-box;
    overflow: hidden;
    font-size: 0.98rem;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .hero-actions .button.quiet {
    grid-column: 1 / -1;
  }

  .hero-corner-label {
    display: none;
  }

  .home-sections {
    margin-top: 0;
    padding: 0 17px 30px;
  }

  .section-block {
    margin-top: 32px;
  }

  .section-heading {
    margin-bottom: 13px;
  }

  .section-heading span {
    display: none;
  }

  .rail,
  .collection-rail {
    grid-auto-columns: min(78vw, 305px);
    gap: 12px;
    margin-right: -17px;
    padding-right: 17px;
  }

  .collection-rail {
    grid-auto-columns: min(72vw, 285px);
  }

  .page-header {
    display: block;
    min-height: 0;
    padding-bottom: 23px;
  }

  .page-header h1 {
    font-size: clamp(3.1rem, 15vw, 4.6rem);
  }

  .page-header .toolbar {
    margin-top: 22px;
  }

  .content-grid,
  .search-results-grid {
    grid-template-columns: 1fr;
    gap: 13px;
  }

  .content-grid .collection-art {
    min-height: 165px;
  }

  .search-panel {
    display: block;
    margin-top: 26px;
  }

  .search-box {
    position: static;
    padding: 16px;
  }

  .search-results {
    margin-top: 30px;
  }

  .timeline-list::before {
    left: 53px;
  }

  .timeline-item {
    grid-template-columns: 54px 105px minmax(0, 1fr);
    gap: 11px;
    min-height: 98px;
  }

  .timeline-year {
    font-size: 0.76rem;
  }

  .timeline-year::after {
    right: -4px;
  }

  .timeline-copy p,
  .timeline-index {
    display: none;
  }

  .timeline-copy strong {
    font-size: 0.82rem;
  }

  .details-dialog,
  .player-dialog {
    width: 100vw;
    height: 100dvh;
    max-height: 100dvh;
    border: 0;
    border-radius: 0;
  }

  .details-layout {
    min-height: 100dvh;
  }

  .detail-art {
    min-height: 38dvh;
  }

  .detail-art span {
    right: 17px;
    font-size: 3.7rem;
  }

  .details-copy {
    justify-content: flex-start;
    padding: 32px 18px calc(45px + env(safe-area-inset-bottom));
  }

  .player-range {
    height: 44px;
  }

  .details-copy h2 {
    font-size: clamp(2.7rem, 13vw, 4rem);
  }

  .details-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .details-actions .button:last-child {
    grid-column: 1 / -1;
  }

  .player-shell {
    min-height: 100dvh;
  }

  .player-topbar {
    padding: calc(15px + env(safe-area-inset-top)) 15px 80px;
  }

  .simulation-badge {
    display: none;
  }

  .player-controls {
    padding: 80px 17px calc(24px + env(safe-area-inset-bottom));
  }

  .profile-dialog {
    padding: 38px 24px 28px;
  }

  .toast {
    right: 16px;
    bottom: calc(86px + env(safe-area-inset-bottom));
  }
}

@media (max-width: 390px) {
  .bottom-nav button small {
    font-size: 0.52rem;
  }

  .hero-actions .button {
    min-width: 0;
    padding: 0 11px;
    font-size: 0.78rem;
  }

  .metadata {
    gap: 7px 11px;
    font-size: 0.72rem;
  }

  .metadata span:not(:last-child)::after {
    margin-left: 11px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
