
:root {
  --bg: #07111f;
  --bg-2: #0b1728;
  --panel: rgba(11, 23, 40, 0.82);
  --panel-2: rgba(15, 23, 42, 0.9);
  --line: rgba(148, 163, 184, 0.16);
  --text: #e2e8f0;
  --muted: #94a3b8;
  --accent: #34d399;
  --accent-2: #22d3ee;
  --accent-3: #8b5cf6;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.15), transparent 28%),
    radial-gradient(circle at top right, rgba(52, 211, 153, 0.12), transparent 25%),
    linear-gradient(180deg, #050b14 0%, var(--bg) 35%, #050b14 100%);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.65;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

button,
input,
select {
  font: inherit;
}

.container {
  width: min(1380px, calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 60;
  backdrop-filter: blur(18px);
  background: linear-gradient(180deg, rgba(7, 17, 31, 0.94), rgba(7, 17, 31, 0.78));
  border-bottom: 1px solid var(--line);
}

.topbar-inner {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #04111b;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 10px 30px rgba(34, 211, 238, 0.22);
}

.brand-name {
  font-size: 1.05rem;
}

.brand-sub {
  display: block;
  margin-top: 2px;
  font-size: 0.76rem;
  color: var(--muted);
  font-weight: 500;
}

.nav {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}

.nav a,
.nav button {
  border: 0;
  background: transparent;
  color: var(--text);
  padding: 10px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: 0.2s ease;
}

.nav a:hover,
.nav button:hover,
.nav a.active {
  background: rgba(52, 211, 153, 0.12);
  color: #9ff7d1;
}

.mobile-toggle {
  display: none;
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.9);
  color: var(--text);
  border-radius: 14px;
  padding: 10px 14px;
}

.hero {
  padding: 28px 0 8px;
}

.hero-shell {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background:
    radial-gradient(circle at 22% 22%, rgba(34, 211, 238, 0.22), transparent 30%),
    radial-gradient(circle at 78% 20%, rgba(52, 211, 153, 0.18), transparent 28%),
    linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.92));
  box-shadow: var(--shadow);
}

.hero-shell::before,
.hero-shell::after {
  content: '';
  position: absolute;
  inset: auto;
  border-radius: 999px;
  filter: blur(42px);
  pointer-events: none;
}

.hero-shell::before {
  width: 280px;
  height: 280px;
  background: rgba(34, 211, 238, 0.12);
  right: -80px;
  top: -90px;
}

.hero-shell::after {
  width: 320px;
  height: 320px;
  background: rgba(139, 92, 246, 0.12);
  left: -120px;
  bottom: -120px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 20px;
  min-height: 520px;
  padding: 24px;
}

.hero-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 10px 10px 10px 12px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  color: #bffbe4;
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.2);
  font-size: 0.9rem;
}

.hero-title {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 4.8rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
}

.hero-title span {
  display: block;
  background: linear-gradient(90deg, #ffffff, #9ff7d1 40%, #7dd3fc 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-desc {
  max-width: 760px;
  color: var(--muted);
  font-size: 1.02rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.08);
  border: 1px solid rgba(148, 163, 184, 0.12);
  color: #d5deeb;
  font-size: 0.88rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 14px;
  border: 1px solid transparent;
  transition: 0.22s ease;
  font-weight: 700;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #04111b;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 12px 28px rgba(34, 211, 238, 0.18);
}

.btn-ghost {
  color: var(--text);
  background: rgba(15, 23, 42, 0.62);
  border-color: rgba(148, 163, 184, 0.16);
}

.hero-panel {
  position: relative;
  z-index: 2;
  min-height: 100%;
}

.hero-slider {
  position: relative;
  height: 100%;
  min-height: 470px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateX(18px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.hero-slide.is-active {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.hero-card {
  height: 100%;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.16);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.82), rgba(8, 15, 28, 0.95));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.hero-card-top {
  min-height: 66%;
  padding: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  background:
    linear-gradient(135deg, rgba(59, 130, 246, 0.18), rgba(34, 211, 238, 0.10) 40%, rgba(139, 92, 246, 0.16)),
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.08), transparent 28%);
}

.hero-card-year {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 7px 12px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.10);
  color: #dbeafe;
  font-size: 0.86rem;
}

.hero-card-title {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 3rem);
  line-height: 1.05;
}

.hero-card-copy {
  color: rgba(226, 232, 240, 0.88);
  max-width: 420px;
}

.hero-card-bottom {
  padding: 16px 20px 20px;
  display: grid;
  gap: 14px;
  background: linear-gradient(180deg, rgba(7, 13, 24, 0.12), rgba(7, 13, 24, 0.68));
}

.hero-card-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.slider-controls {
  position: absolute;
  right: 16px;
  top: 16px;
  z-index: 3;
  display: flex;
  gap: 8px;
}

.slider-controls button {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.10);
  background: rgba(8, 15, 28, 0.55);
  color: white;
  backdrop-filter: blur(10px);
}

.section {
  padding: 30px 0 0;
}

.section-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.section-title {
  margin: 0;
  font-size: 1.55rem;
}

.section-subtitle {
  margin-top: 4px;
  color: var(--muted);
}

.section-link {
  color: #9ff7d1;
  font-weight: 700;
}

.grid {
  display: grid;
  gap: 16px;
}

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

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

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

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

.movie-card,
.bucket-card,
.rank-card,
.panel,
.summary-box,
.detail-box {
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.8), rgba(8, 15, 28, 0.92));
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.18);
}

.movie-card {
  overflow: hidden;
  transition: 0.25s ease;
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.movie-card:hover {
  transform: translateY(-4px);
  border-color: rgba(52, 211, 153, 0.26);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.32);
}

.movie-poster {
  position: relative;
  min-height: 220px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(255,255,255,0.08), transparent 30%),
    linear-gradient(135deg, rgba(34, 211, 238, 0.20), rgba(139, 92, 246, 0.18) 50%, rgba(52, 211, 153, 0.16));
}

.movie-poster::before {
  content: '';
  position: absolute;
  inset: auto -20% -48% -20%;
  height: 140px;
  background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.42));
  transform: skewY(-10deg);
}

.movie-badge {
  position: relative;
  z-index: 1;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(4, 10, 20, 0.36);
  border: 1px solid rgba(255, 255, 255, 0.10);
  font-size: 0.76rem;
  color: #e0f2fe;
}

.movie-title-on-card {
  position: relative;
  z-index: 1;
  margin-top: auto;
  font-size: 1.15rem;
  line-height: 1.25;
  font-weight: 800;
}

.movie-body {
  padding: 14px 14px 16px;
  display: grid;
  gap: 10px;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 0.88rem;
}

.movie-excerpt {
  color: #cbd5e1;
  font-size: 0.92rem;
}

.movie-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  color: #9ff7d1;
}

.bucket-card {
  padding: 18px;
}

.bucket-card .count {
  font-size: 2rem;
  font-weight: 900;
}

.bucket-card .name {
  font-weight: 800;
  font-size: 1.1rem;
}

.bucket-card .desc {
  color: var(--muted);
  margin-top: 6px;
}

.search-panel {
  padding: 18px;
  display: grid;
  gap: 16px;
}

.search-bar {
  display: grid;
  gap: 12px;
  grid-template-columns: 1fr auto auto;
}

.search-bar input,
.search-bar select,
.search-bar button {
  min-height: 48px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.82);
  color: var(--text);
  padding: 0 14px;
}

.search-bar input::placeholder {
  color: #64748b;
}

.filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-row button {
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.82);
  color: var(--text);
  padding: 8px 12px;
  border-radius: 999px;
}

.filter-row button.active {
  border-color: rgba(52, 211, 153, 0.28);
  color: #9ff7d1;
  background: rgba(52, 211, 153, 0.10);
}

.rank-list {
  display: grid;
  gap: 12px;
}

.rank-item {
  display: grid;
  grid-template-columns: 74px 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(15, 23, 42, 0.78);
}

.rank-no {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  font-weight: 900;
  color: #06131e;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
}

.rank-title {
  font-weight: 800;
}

.rank-meta {
  color: var(--muted);
  font-size: 0.9rem;
  margin-top: 4px;
}

.rank-score {
  color: #9ff7d1;
  font-weight: 800;
}

.detail-hero {
  margin-top: 24px;
  padding-bottom: 12px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  margin-bottom: 12px;
  font-size: 0.9rem;
}

.breadcrumbs a {
  color: #9ff7d1;
}

.detail-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 18px;
}

.player-shell {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #020617;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
}

.player-overlay button {
  pointer-events: auto;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  border: 0;
  background: rgba(15, 23, 42, 0.72);
  color: white;
  box-shadow: 0 15px 40px rgba(0,0,0,0.28);
  backdrop-filter: blur(10px);
}

.detail-box {
  padding: 18px;
}

.detail-title {
  margin: 0 0 10px;
  font-size: clamp(1.7rem, 3vw, 3rem);
  line-height: 1.1;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  margin-bottom: 14px;
}

.detail-meta strong {
  color: #e2e8f0;
}

.long-copy {
  display: grid;
  gap: 12px;
  color: #dbe6f3;
}

.long-copy p {
  margin: 0;
}

.summary-box {
  padding: 18px;
}

.summary-box h3 {
  margin: 0 0 10px;
}

.summary-box p {
  margin: 0;
  color: #dbe6f3;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.footer {
  margin-top: 36px;
  border-top: 1px solid var(--line);
  padding: 28px 0 36px;
  color: var(--muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 18px;
}

.small {
  font-size: 0.88rem;
  color: var(--muted);
}

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

.hidden {
  display: none !important;
}

@media (max-width: 1180px) {
  .grid.cards-6,
  .related-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .grid.cards-5 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .grid.cards-4,
  .grid.cards-3,
  .detail-grid,
  .footer-grid,
  .hero-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .topbar-inner {
    flex-wrap: wrap;
    padding: 12px 0;
  }

  .mobile-toggle {
    display: inline-flex;
  }

  .nav {
    width: 100%;
    display: none;
    padding-bottom: 12px;
  }

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

  .hero-grid {
    min-height: auto;
    padding: 16px;
  }

  .hero-slider {
    min-height: 390px;
  }

  .search-bar {
    grid-template-columns: 1fr;
  }

  .rank-item {
    grid-template-columns: 64px 1fr;
  }

  .rank-score {
    grid-column: 2;
  }

  .grid.cards-6,
  .grid.cards-5,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
