:root {
  --accent-a: #f97316;
  --accent-b: #ec4899;
  --accent-c: #06b6d4;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #f8fafc;
  --line: #e5e7eb;
  --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 48%, #ecfeff 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(229, 231, 235, 0.8);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(18px);
}

.site-nav,
.container,
.detail-container,
.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.site-nav {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent-a), var(--accent-b));
  box-shadow: 0 12px 24px rgba(236, 72, 153, 0.25);
}

.brand-text {
  font-size: 22px;
  color: transparent;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
  -webkit-background-clip: text;
  background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-weight: 700;
  color: #374151;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--accent-a);
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 12px;
  color: #374151;
  background: #f3f4f6;
  cursor: pointer;
}

.hero {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  color: #fff;
  background: #111827;
}

.hero-track,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s ease, transform 0.7s ease;
  transform: scale(1.02);
}

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-layer {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 38%, rgba(249, 115, 22, 0.48), transparent 32%),
    linear-gradient(90deg, rgba(10, 15, 28, 0.94), rgba(10, 15, 28, 0.66) 48%, rgba(10, 15, 28, 0.2)),
    linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.1) 45%);
}

.hero-copy {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding-top: 120px;
}

.eyebrow {
  margin: 0 0 14px;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fed7aa;
}

.hero-copy h1,
.page-hero h1 {
  max-width: 820px;
  margin: 0 0 20px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.02;
  font-weight: 950;
  letter-spacing: -0.06em;
}

.hero-summary,
.page-hero p {
  max-width: 720px;
  margin: 0 0 26px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(18px, 2.2vw, 24px);
  line-height: 1.75;
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.hero-tags span,
.tag-chip {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 7px 14px;
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 14px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn.primary {
  color: #fff;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
  box-shadow: 0 16px 32px rgba(236, 72, 153, 0.28);
}

.btn.glass,
.btn.ghost {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.25);
  backdrop-filter: blur(14px);
}

.btn.full {
  width: 100%;
}

.hero-dots {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: 34px;
  display: flex;
  gap: 10px;
  transform: translateX(-50%);
}

.hero-dots button {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.42);
  cursor: pointer;
}

.hero-dots button.is-active {
  width: 36px;
  background: #fff;
}

.hero-thumbs {
  position: absolute;
  z-index: 3;
  right: max(32px, calc((100% - 1180px) / 2));
  bottom: 78px;
  width: 310px;
  display: grid;
  gap: 10px;
}

.hero-thumb {
  display: grid;
  grid-template-columns: 56px 1fr;
  align-items: center;
  gap: 12px;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 16px;
  color: #fff;
  background: rgba(15, 23, 42, 0.46);
  backdrop-filter: blur(16px);
  cursor: pointer;
  text-align: left;
}

.hero-thumb img {
  width: 56px;
  height: 72px;
  border-radius: 12px;
  object-fit: cover;
}

.hero-thumb.is-active {
  border-color: rgba(255, 255, 255, 0.72);
  background: rgba(249, 115, 22, 0.42);
}

.content-section {
  padding: 72px 0;
}

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

.section-heading h2 {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 950;
  letter-spacing: -0.04em;
}

.section-heading p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.section-heading a {
  flex: 0 0 auto;
  color: #fff;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 900;
}

.featured-grid,
.movie-grid,
.rank-grid,
.category-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #111827;
}

.featured-grid .poster-link {
  aspect-ratio: 4 / 5;
}

.poster-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.movie-card:hover img {
  transform: scale(1.08);
}

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.82), transparent 62%);
}

.rating-badge,
.rank-badge {
  position: absolute;
  top: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  min-height: 28px;
  padding: 0 8px;
  border-radius: 999px;
  color: #fff;
  font-size: 13px;
  font-weight: 950;
  background: linear-gradient(90deg, #f59e0b, #f97316);
}

.rating-badge {
  right: 10px;
}

.rank-badge {
  left: 10px;
  background: linear-gradient(90deg, #ef4444, #ec4899);
}

.poster-title {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  color: #fff;
  font-weight: 950;
  line-height: 1.35;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.movie-card-body {
  padding: 16px;
}

.compact-card .movie-card-body {
  padding: 12px;
}

.movie-card h3 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.compact-card h3 {
  font-size: 15px;
}

.movie-meta,
.movie-desc,
.movie-tags {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.movie-desc {
  margin-top: 8px;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-tags {
  margin-top: 8px;
  color: #ea580c;
  font-weight: 700;
}

.ranking-band {
  padding: 72px 0;
  background: linear-gradient(90deg, #faf5ff, #fdf2f8, #fff7ed);
}

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

.category-tile {
  position: relative;
  min-height: 260px;
  overflow: hidden;
  border-radius: 24px;
  color: #fff;
  box-shadow: var(--shadow);
}

.category-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
  transition: transform 0.5s ease;
}

.category-tile:hover img {
  transform: scale(1.1);
}

.tile-layer {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.18));
}

.category-tile strong,
.category-tile em {
  position: relative;
  z-index: 2;
  display: block;
  padding: 0 18px;
}

.category-tile strong {
  padding-top: 166px;
  font-size: 24px;
  font-style: normal;
  font-weight: 950;
}

.category-tile em {
  padding-bottom: 18px;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  font-style: normal;
  line-height: 1.55;
}

.page-hero {
  color: #fff;
  background:
    radial-gradient(circle at 18% 35%, rgba(236, 72, 153, 0.45), transparent 34%),
    linear-gradient(135deg, #f97316, #ec4899 48%, #0f172a);
  padding: 96px max(32px, calc((100% - 1180px) / 2));
}

.compact-hero,
.category-hero,
.ranking-hero,
.search-hero {
  min-height: 360px;
  display: flex;
  align-items: center;
}

.category-panel-grid {
  display: grid;
  gap: 24px;
}

.category-panel {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 26px;
  padding: 24px;
  border-radius: 28px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.09);
}

.category-cover {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.category-cover img {
  width: 100%;
  aspect-ratio: 3 / 4;
  border-radius: 16px;
  object-fit: cover;
}

.category-panel h2 {
  margin: 0 0 12px;
  font-size: 30px;
  font-weight: 950;
}

.category-panel p {
  margin: 0 0 20px;
  color: var(--muted);
  line-height: 1.8;
}

.mini-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mini-links a {
  padding: 8px 12px;
  border-radius: 999px;
  color: #ea580c;
  background: #fff7ed;
  font-weight: 800;
}

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

.rank-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 18px;
}

.search-panel {
  padding-top: 44px;
}

.search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 18px;
  border-radius: 24px;
  background: #fff;
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.1);
}

.search-box input {
  width: 100%;
  min-height: 50px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  outline: none;
}

.search-box input:focus {
  border-color: var(--accent-a);
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

.search-box button,
.filter-row button {
  border: 0;
  cursor: pointer;
  font-weight: 900;
}

.search-box button {
  padding: 0 22px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
}

.filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 18px;
  padding: 16px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.82);
}

.filter-row strong {
  margin-right: 6px;
}

.filter-row button {
  padding: 8px 12px;
  border-radius: 999px;
  color: #374151;
  background: #f3f4f6;
}

.filter-row button.is-active {
  color: #fff;
  background: linear-gradient(90deg, var(--accent-a), var(--accent-b));
}

.search-status {
  min-height: 28px;
  margin: 18px 0;
  color: var(--muted);
  font-weight: 800;
}

.detail-shell {
  padding: 34px 0 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb a {
  color: #2563eb;
}

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(280px, 0.85fr);
  gap: 28px;
  align-items: start;
}

.player-card,
.detail-card,
.side-card {
  overflow: hidden;
  border-radius: 28px;
  background: #fff;
  box-shadow: var(--shadow);
}

.player-card {
  background: #020617;
  margin-bottom: 24px;
}

.player-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #020617;
}

.player-wrap video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #020617;
}

.player-start {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #fff;
  background: linear-gradient(0deg, rgba(2, 6, 23, 0.64), rgba(2, 6, 23, 0.14));
  cursor: pointer;
}

.player-start span {
  width: 84px;
  height: 84px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent-a), var(--accent-b));
  box-shadow: 0 20px 45px rgba(236, 72, 153, 0.38);
  font-size: 32px;
  text-indent: 4px;
}

.player-wrap.is-playing .player-start {
  opacity: 0;
  pointer-events: none;
}

.detail-card {
  padding: 30px;
}

.title-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 20px;
  align-items: start;
}

.title-row h1 {
  margin: 0 0 12px;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.15;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.title-row p {
  margin: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
}

.score-pill {
  min-width: 72px;
  padding: 10px 14px;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(90deg, #f59e0b, #f97316);
  text-align: center;
  font-size: 24px;
  font-weight: 950;
}

.info-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 28px 0;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--line);
}

.info-strip span {
  padding: 9px 14px;
  border-radius: 999px;
  color: #374151;
  background: #f3f4f6;
  font-weight: 800;
}

.detail-card h2 {
  margin: 28px 0 12px;
  font-size: 24px;
}

.long-text {
  margin: 0;
  color: #374151;
  font-size: 17px;
  line-height: 1.9;
  white-space: pre-line;
}

.review-box {
  padding: 22px;
  border-radius: 20px;
  background: linear-gradient(135deg, #fff7ed, #fdf2f8);
}

.detail-side {
  position: sticky;
  top: 96px;
}

.side-poster {
  width: 100%;
  border-radius: 28px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
}

.side-card {
  padding: 24px;
}

.side-card h2 {
  margin: 0 0 18px;
}

.side-card dl {
  margin: 0 0 22px;
}

.side-card dl div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}

.side-card dt {
  color: var(--muted);
}

.side-card dd {
  margin: 0;
  font-weight: 900;
}

.related-section {
  padding-bottom: 0;
}

.site-footer {
  color: #fff;
  background: #111827;
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 36px;
  padding: 48px 0;
}

.footer-brand p {
  max-width: 520px;
  color: #9ca3af;
  line-height: 1.8;
}

.brand.compact .brand-text {
  color: #fff;
  background: none;
  -webkit-background-clip: initial;
  background-clip: initial;
}

.footer-column {
  display: grid;
  align-content: start;
  gap: 10px;
}

.footer-column h2 {
  margin: 0 0 8px;
  font-size: 18px;
}

.footer-column a {
  color: #9ca3af;
}

.footer-column a:hover {
  color: #fff;
}

@media (max-width: 1100px) {
  .featured-grid,
  .movie-grid,
  .rank-grid,
  .rank-list,
  .category-grid,
  .large-list {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .hero-thumbs {
    display: none;
  }

  .detail-grid {
    grid-template-columns: 1fr;
  }

  .detail-side {
    position: static;
  }
}

@media (max-width: 760px) {
  .site-nav {
    min-height: 64px;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .nav-links {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 10px;
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow);
  }

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

  .nav-links a {
    padding: 14px;
    border-radius: 12px;
  }

  .nav-links a:hover {
    background: #fff7ed;
  }

  .hero {
    min-height: 640px;
  }

  .hero-copy {
    padding-top: 92px;
  }

  .hero-copy h1,
  .page-hero h1 {
    font-size: 42px;
  }

  .hero-summary,
  .page-hero p {
    font-size: 17px;
  }

  .hero-actions,
  .small-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .content-section,
  .ranking-band {
    padding: 46px 0;
  }

  .section-heading {
    display: block;
  }

  .section-heading a {
    display: inline-flex;
    margin-top: 16px;
  }

  .featured-grid,
  .movie-grid,
  .rank-grid,
  .rank-list,
  .category-grid,
  .large-list,
  .related-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .category-panel {
    grid-template-columns: 1fr;
  }

  .category-cover {
    grid-template-columns: repeat(4, 1fr);
  }

  .category-panel h2 {
    font-size: 24px;
  }

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

  .detail-card,
  .side-card {
    padding: 20px;
  }

  .title-row {
    grid-template-columns: 1fr;
  }

  .footer-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 420px) {
  .brand-text {
    font-size: 18px;
  }

  .featured-grid,
  .movie-grid,
  .rank-grid,
  .rank-list,
  .category-grid,
  .large-list,
  .related-grid {
    grid-template-columns: 1fr 1fr;
  }

  .movie-card h3 {
    font-size: 14px;
  }

  .movie-desc,
  .movie-tags {
    display: none;
  }
}
