
:root {
  --bg: #f8fafc;
  --text: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --card: #ffffff;
  --dark: #0f172a;
  --darker: #020617;
  --cyan: #06b6d4;
  --blue: #2563eb;
  --orange: #f97316;
  --red: #dc2626;
  --green: #10b981;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  color: #fff;
  background: linear-gradient(90deg, #0f172a, #1e293b);
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.35);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 74px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 900;
  white-space: nowrap;
}

.brand-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 10px 24px rgba(6, 182, 212, 0.35);
}

.brand-text {
  background: linear-gradient(90deg, #22d3ee, #60a5fa);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-left: auto;
  font-weight: 600;
}

.desktop-nav a {
  opacity: 0.92;
  transition: color 0.2s ease, opacity 0.2s ease;
}

.desktop-nav a:hover {
  color: #22d3ee;
  opacity: 1;
}

.top-search {
  display: flex;
  align-items: center;
  border: 1px solid rgba(148, 163, 184, 0.28);
  border-radius: 999px;
  padding: 4px;
  background: rgba(15, 23, 42, 0.55);
}

.top-search input {
  width: 200px;
  border: 0;
  outline: 0;
  color: #fff;
  background: transparent;
  padding: 10px 12px;
}

.top-search input::placeholder {
  color: rgba(226, 232, 240, 0.8);
}

.top-search button,
.hero-search button {
  border: 0;
  cursor: pointer;
  color: #fff;
  font-weight: 800;
  border-radius: 999px;
  padding: 10px 16px;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.menu-button {
  display: none;
  border: 0;
  color: #fff;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  font-size: 22px;
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
}

.mobile-panel a {
  display: block;
  padding: 12px 10px;
  border-radius: 12px;
}

.mobile-panel a:hover {
  background: rgba(255, 255, 255, 0.08);
}

.hero-carousel {
  position: relative;
  min-height: 680px;
  overflow: hidden;
  background: linear-gradient(135deg, #0891b2, #1d4ed8 45%, #020617);
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  display: flex;
  align-items: center;
  background-position: center;
  background-size: cover;
  transition: opacity 0.7s ease, transform 0.7s ease;
  transform: scale(1.04);
}

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

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 70% 20%, rgba(34, 211, 238, 0.35), transparent 28%),
    linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.26)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.1));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  color: #fff;
  padding: 90px 0 210px;
}

.hero-content h1 {
  max-width: 780px;
  margin: 14px 0 20px;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.05em;
}

.hero-content p {
  max-width: 680px;
  color: #dbeafe;
  font-size: clamp(18px, 2.2vw, 24px);
  line-height: 1.8;
  margin: 0 0 24px;
}

.hero-kicker {
  color: #fde68a;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.hero-tags,
.tag-row,
.detail-tags,
.filter-chip-row,
.hero-category-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags span,
.tag-row span,
.detail-tags span {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #e0f2fe;
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 700;
}

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

.primary-button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 0 26px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
  color: #fff;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
  box-shadow: 0 16px 30px rgba(37, 99, 235, 0.28);
}

.primary-button:hover,
.ghost-button:hover,
.category-card:hover,
.movie-card:hover,
.wide-card:hover {
  transform: translateY(-3px);
}

.ghost-button {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
}

.hero-search-card {
  position: absolute;
  left: 50%;
  bottom: 38px;
  z-index: 5;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 18px;
  align-items: center;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 28px;
  padding: 22px;
  background: rgba(15, 23, 42, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: 0 24px 70px rgba(2, 6, 23, 0.45);
}

.hero-search-card strong {
  display: block;
  font-size: 22px;
}

.hero-search-card span {
  color: #bae6fd;
}

.hero-search {
  display: flex;
  gap: 10px;
  padding: 6px;
  border-radius: 999px;
  background: #fff;
}

.hero-search input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 0 16px;
  font-size: 16px;
}

.hero-category-links {
  grid-column: 1 / -1;
}

.hero-category-links a {
  color: #cffafe;
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.1);
}

.hero-dots {
  position: absolute;
  right: calc((100% - min(1180px, calc(100% - 32px))) / 2);
  bottom: 170px;
  z-index: 6;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.36);
}

.hero-dot.active {
  width: 36px;
  border-radius: 999px;
  background: #22d3ee;
}

.section-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0;
}

.section-head {
  margin-bottom: 34px;
}

.section-head h2 {
  margin: 0 0 8px;
  font-size: clamp(28px, 3vw, 40px);
  letter-spacing: -0.03em;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 17px;
}

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

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

.movie-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

.movie-link {
  display: block;
  height: 100%;
}

.poster-frame {
  position: relative;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #1e293b);
}

.movie-card.compact .poster-frame {
  aspect-ratio: 16 / 21;
}

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

.movie-card:hover .poster-frame img,
.wide-card:hover img {
  transform: scale(1.08);
}

.type-pill {
  position: absolute;
  top: 12px;
  right: 12px;
  color: #fff;
  font-size: 12px;
  font-weight: 900;
  border-radius: 999px;
  padding: 5px 10px;
  background: linear-gradient(90deg, var(--orange), var(--red));
}

.play-hover {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  color: #fff;
  background: rgba(6, 182, 212, 0.92);
  transform: translate(-50%, -50%) scale(0.82);
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-hover {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.movie-body {
  padding: 18px;
}

.movie-body h3 {
  margin: 0 0 10px;
  font-size: 19px;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-body p {
  min-height: 48px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.movie-meta,
.wide-meta,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #64748b;
  font-size: 13px;
  margin-bottom: 12px;
}

.movie-meta span,
.wide-meta span,
.detail-meta span {
  border-radius: 999px;
  padding: 4px 9px;
  background: #f1f5f9;
}

.tag-row span {
  color: #475569;
  background: #f1f5f9;
}

.warm-block {
  width: 100%;
  max-width: none;
  padding-left: max(16px, calc((100% - 1180px) / 2));
  padding-right: max(16px, calc((100% - 1180px) / 2));
  background: linear-gradient(135deg, #fff7ed, #fdf2f8);
}

.wide-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.wide-card {
  position: relative;
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.wide-link {
  display: grid;
  grid-template-columns: 146px 1fr;
  min-height: 180px;
  overflow: hidden;
  border-radius: 18px;
}

.wide-link img {
  width: 146px;
  height: 100%;
  min-height: 180px;
  object-fit: cover;
  background: #0f172a;
  transition: transform 0.5s ease;
}

.wide-link div {
  padding: 20px;
}

.wide-link h3 {
  margin: 0 0 10px;
  font-size: 20px;
}

.wide-link p {
  margin: 0 0 14px;
  color: var(--muted);
  line-height: 1.7;
}

.list-rank,
.rank-badge {
  position: absolute;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 900;
  background: linear-gradient(135deg, var(--orange), var(--red));
  box-shadow: 0 12px 24px rgba(249, 115, 22, 0.32);
}

.list-rank {
  left: -10px;
  top: -10px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
}

.rank-badge {
  left: 12px;
  top: 12px;
  width: 42px;
  height: 42px;
  border-radius: 14px;
}

.center-action {
  margin-top: 30px;
  text-align: center;
}

.category-section {
  color: #fff;
  background: linear-gradient(135deg, #0f172a, #1e293b);
}

.category-section .section-head p {
  color: #cbd5e1;
}

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

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

.category-card {
  min-height: 166px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  border-radius: 22px;
  color: #fff;
  padding: 26px;
  box-shadow: var(--shadow);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card h2,
.category-card h3 {
  margin: 0 0 8px;
  font-size: 24px;
}

.category-card p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.65;
}

.category-card span {
  margin-top: 18px;
  font-weight: 900;
}

.tone-0 {
  background: linear-gradient(135deg, #06b6d4, #2563eb);
}

.tone-1 {
  background: linear-gradient(135deg, #f97316, #dc2626);
}

.tone-2 {
  background: linear-gradient(135deg, #10b981, #0f766e);
}

.tone-3 {
  background: linear-gradient(135deg, #f59e0b, #ca8a04);
}

.tone-4 {
  background: linear-gradient(135deg, #8b5cf6, #4f46e5);
}

.tone-5 {
  background: linear-gradient(135deg, #ec4899, #be123c);
}

.page-hero {
  color: #fff;
  background:
    radial-gradient(circle at 25% 10%, rgba(34, 211, 238, 0.45), transparent 30%),
    linear-gradient(135deg, #0891b2, #1d4ed8 48%, #0f172a);
  padding: 96px 16px;
}

.page-hero div {
  width: min(1180px, 100%);
  margin: 0 auto;
}

.page-hero span {
  display: inline-block;
  color: #fde68a;
  font-weight: 900;
  margin-bottom: 12px;
}

.page-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(38px, 5vw, 64px);
  letter-spacing: -0.04em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: #dbeafe;
  font-size: 19px;
  line-height: 1.8;
}

.compact-hero {
  padding: 72px 16px;
}

.ranking-hero {
  background:
    radial-gradient(circle at 70% 10%, rgba(249, 115, 22, 0.38), transparent 30%),
    linear-gradient(135deg, #7c2d12, #1e293b 60%, #020617);
}

.search-hero {
  background:
    radial-gradient(circle at 70% 10%, rgba(16, 185, 129, 0.38), transparent 30%),
    linear-gradient(135deg, #065f46, #0f172a 60%, #020617);
}

.filter-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  margin-bottom: 30px;
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.filter-panel input {
  flex: 1;
  min-width: 240px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: 0;
  padding: 14px 18px;
  font-size: 16px;
}

.filter-chip {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 10px 14px;
  color: #334155;
  background: #f1f5f9;
  font-weight: 800;
}

.filter-chip.active,
.filter-chip:hover {
  color: #fff;
  background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.empty-state {
  display: none;
  margin-top: 24px;
  padding: 40px;
  border-radius: 22px;
  text-align: center;
  color: #64748b;
  background: #fff;
}

.empty-state.show {
  display: block;
}

.breadcrumb {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #64748b;
  font-size: 14px;
}

.breadcrumb a {
  color: #0891b2;
  font-weight: 800;
}

.detail-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 30px;
  align-items: start;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  background: #000;
  box-shadow: 0 28px 70px rgba(2, 6, 23, 0.35);
}

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

.player-start {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  border: 0;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.74));
}

.player-start span {
  width: 78px;
  height: 78px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  padding-left: 5px;
  font-size: 34px;
  background: linear-gradient(135deg, var(--cyan), var(--blue));
  box-shadow: 0 20px 42px rgba(6, 182, 212, 0.32);
}

.player-start strong {
  font-size: 18px;
}

.player-box.playing .player-start {
  display: none;
}

.detail-card,
.side-panel,
.text-page {
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--shadow);
}

.detail-card {
  margin-top: 24px;
  padding: 28px;
}

.detail-card h1 {
  margin: 0 0 18px;
  font-size: clamp(28px, 4vw, 42px);
  letter-spacing: -0.04em;
}

.detail-card h2 {
  margin: 24px 0 10px;
  font-size: 22px;
}

.detail-card p,
.text-page p {
  margin: 0;
  color: #334155;
  line-height: 1.9;
  font-size: 16px;
}

.detail-tags {
  margin-top: 24px;
}

.detail-tags span {
  color: #0f766e;
  background: #ccfbf1;
}

.side-panel {
  overflow: hidden;
  position: sticky;
  top: 98px;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #0f172a;
}

.side-info {
  padding: 22px;
}

.side-info h2 {
  margin: 0 0 10px;
}

.side-info p {
  color: var(--muted);
  line-height: 1.7;
}

.primary-button.full {
  width: 100%;
  margin-top: 12px;
}

.related-wrap {
  padding-top: 48px;
}

.text-page {
  width: min(900px, calc(100% - 32px));
  margin: 56px auto;
  padding: 34px;
}

.text-page h2 {
  margin: 26px 0 10px;
}

.text-page h2:first-child {
  margin-top: 0;
}

.site-footer {
  color: #cbd5e1;
  background: linear-gradient(180deg, #0f172a, #020617);
  padding: 58px 16px 26px;
}

.footer-grid {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 34px;
}

.footer-brand {
  color: #fff;
  font-size: 24px;
  font-weight: 900;
  margin-bottom: 14px;
}

.site-footer h2 {
  color: #fff;
  font-size: 18px;
  margin: 0 0 14px;
}

.site-footer p {
  margin: 0;
  line-height: 1.8;
}

.site-footer a {
  display: block;
  margin: 8px 0;
  color: #cbd5e1;
}

.site-footer a:hover {
  color: #22d3ee;
}

.footer-bottom {
  width: min(1180px, 100%);
  margin: 34px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  color: #94a3b8;
}

@media (max-width: 1040px) {
  .desktop-nav,
  .top-search {
    display: none;
  }

  .menu-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
  }

  .mobile-panel.open {
    display: block;
  }

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

  .movie-grid,
  .featured-grid,
  .category-grid,
  .category-grid.large {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .side-panel {
    position: static;
  }

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

@media (max-width: 680px) {
  .header-inner {
    min-height: 66px;
  }

  .brand {
    font-size: 20px;
  }

  .hero-carousel {
    min-height: 760px;
  }

  .hero-content {
    padding: 70px 0 290px;
  }

  .hero-search-card {
    bottom: 24px;
    border-radius: 22px;
  }

  .hero-search {
    flex-direction: column;
    border-radius: 18px;
  }

  .hero-search input {
    min-height: 46px;
  }

  .hero-dots {
    left: 16px;
    right: auto;
    bottom: 240px;
  }

  .section-wrap {
    padding: 48px 0;
  }

  .movie-grid,
  .featured-grid,
  .category-grid,
  .category-grid.large,
  .wide-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .wide-link {
    grid-template-columns: 118px 1fr;
  }

  .wide-link img {
    width: 118px;
  }

  .detail-card,
  .text-page {
    padding: 22px;
  }
}
