:root {
  --teal: #0f766e;
  --cyan: #0891b2;
  --cyan-bright: #06b6d4;
  --orange: #f97316;
  --rose: #e11d48;
  --pink: #db2777;
  --amber: #fbbf24;
  --ink: #111827;
  --muted: #6b7280;
  --soft: #f3f4f6;
  --card: #ffffff;
  --line: rgba(15, 23, 42, 0.08);
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.14);
  --soft-shadow: 0 12px 30px rgba(15, 23, 42, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #f8fafc;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, var(--teal), var(--cyan));
  box-shadow: 0 8px 24px rgba(15, 118, 110, 0.28);
}

.nav-shell {
  width: min(1180px, calc(100% - 32px));
  height: 64px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 22px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 23px;
  font-weight: 800;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.brand-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: #0f766e;
  background: var(--amber);
  border-radius: 12px;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.15);
  transition: transform 0.2s ease;
}

.brand:hover .brand-icon {
  transform: rotate(10deg) scale(1.04);
}

.menu-toggle {
  display: none;
  margin-left: auto;
  border: 0;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  padding: 8px 12px;
  cursor: pointer;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
  font-weight: 700;
}

.main-nav a,
.nav-dropdown > button {
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
  padding: 8px 0;
  font-weight: 700;
  transition: color 0.18s ease;
}

.main-nav a:hover,
.nav-dropdown > button:hover {
  color: var(--amber);
}

.nav-dropdown {
  position: relative;
}

.dropdown-panel {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 180px;
  padding: 8px;
  border-radius: 14px;
  background: #fff;
  box-shadow: var(--shadow);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.18s ease;
}

.nav-dropdown:hover .dropdown-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-panel a {
  display: block;
  color: #1f2937;
  padding: 9px 12px;
  border-radius: 10px;
}

.dropdown-panel a:hover {
  color: var(--teal);
  background: #ecfeff;
}

.top-search {
  display: flex;
  width: 260px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.top-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  padding: 8px 12px;
  color: #fff;
  background: transparent;
}

.top-search input::placeholder {
  color: rgba(255, 255, 255, 0.78);
}

.top-search button {
  border: 0;
  color: #0f766e;
  background: #fff;
  padding: 0 16px;
  font-weight: 800;
  cursor: pointer;
}

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

.hero-slider {
  position: relative;
  height: 520px;
  overflow: hidden;
  background: linear-gradient(110deg, var(--orange), var(--pink), var(--rose));
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.55s ease, visibility 0.55s ease;
}

.hero-slide.is-active {
  opacity: 1;
  visibility: visible;
}

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  filter: saturate(1.1) contrast(1.05);
}

.hero-shade {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 75% 35%, rgba(255, 255, 255, 0.2), transparent 28%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.86), rgba(15, 23, 42, 0.48) 48%, rgba(15, 23, 42, 0.25));
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  color: #fff;
  max-width: 1180px;
}

.hero-content h1 {
  width: min(720px, 100%);
  margin: 12px 0 16px;
  font-size: clamp(42px, 7vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero-content p {
  width: min(660px, 100%);
  margin: 0 0 18px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 19px;
}

.hero-kicker,
.section-kicker {
  color: var(--amber);
  font-weight: 900;
  letter-spacing: 0.08em;
}

.hero-tags,
.tag-row,
.mini-tags,
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.tag-row span,
.mini-tags span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  color: #0f766e;
  background: #ecfeff;
  font-size: 13px;
  font-weight: 800;
}

.hero-tags span {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(12px);
}

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

.primary-btn,
.ghost-btn,
.more-link,
.large-search button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 22px;
  border-radius: 999px;
  font-weight: 900;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(90deg, var(--teal), var(--cyan));
  box-shadow: 0 12px 26px rgba(8, 145, 178, 0.28);
}

.primary-btn:hover,
.ghost-btn:hover,
.more-link:hover,
.large-search button:hover {
  transform: translateY(-2px);
  box-shadow: var(--soft-shadow);
}

.ghost-btn {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}

.hero-dots {
  position: absolute;
  right: max(24px, calc((100% - 1180px) / 2));
  bottom: 90px;
  z-index: 3;
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.46);
  cursor: pointer;
}

.hero-dot.is-active {
  width: 34px;
  background: #fff;
}

.hero-category-strip {
  position: absolute;
  left: 50%;
  bottom: 22px;
  z-index: 4;
  width: min(1180px, calc(100% - 32px));
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.hero-category-strip a {
  text-align: center;
  padding: 13px 12px;
  border-radius: 16px;
  color: #fff;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(10px);
  font-weight: 900;
}

.intro-panel {
  display: grid;
  grid-template-columns: 1fr minmax(320px, 480px);
  gap: 28px;
  align-items: center;
}

.intro-panel h2,
.section-title-row h2,
.panel-head h2,
.story-panel h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.18;
}

.intro-panel p,
.section-title-row p,
.category-info p,
.page-hero p,
.story-panel p {
  color: var(--muted);
}

.large-search {
  display: flex;
  padding: 8px;
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.large-search input {
  width: 100%;
  border: 0;
  outline: 0;
  padding: 0 16px;
  background: transparent;
}

.large-search button {
  border: 0;
  color: #fff;
  background: linear-gradient(90deg, var(--orange), var(--rose));
  cursor: pointer;
  white-space: nowrap;
}

.section-title-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
}

.section-title-row.light h2,
.section-title-row.light p,
.more-link.light {
  color: #fff;
}

.more-link {
  color: var(--teal);
  background: #ecfeff;
}

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

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

.movie-card {
  border-radius: 22px;
  overflow: hidden;
  background: var(--card);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 22px 44px rgba(15, 23, 42, 0.16);
}

.poster-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: linear-gradient(135deg, #ccfbf1, #cffafe);
}

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

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

.poster-year {
  position: absolute;
  right: 10px;
  top: 10px;
  color: #fff;
  background: rgba(15, 23, 42, 0.74);
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}

.card-body {
  padding: 16px;
}

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

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

.meta-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: #64748b;
  font-size: 13px;
}

.meta-line span + span::before {
  content: "·";
  margin-right: 8px;
  color: #94a3b8;
}

.tag-row {
  margin-top: 12px;
}

.category-band {
  background: linear-gradient(135deg, var(--teal), var(--cyan-bright));
}

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

.category-tile {
  min-height: 150px;
  padding: 22px;
  border-radius: 24px;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 15px 36px rgba(15, 23, 42, 0.18);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile:hover {
  transform: translateY(-6px) rotate(-1deg);
  box-shadow: 0 24px 46px rgba(15, 23, 42, 0.25);
}

.category-tile span {
  font-size: 22px;
  font-weight: 900;
}

.category-tile small {
  color: rgba(255, 255, 255, 0.82);
}

.tile-1,
.tile-6 { background: linear-gradient(135deg, #fb7185, #db2777); }
.tile-2,
.tile-7 { background: linear-gradient(135deg, #f59e0b, #f97316); }
.tile-3,
.tile-8 { background: linear-gradient(135deg, #10b981, #0f766e); }
.tile-4,
.tile-9 { background: linear-gradient(135deg, #3b82f6, #06b6d4); }
.tile-5,
.tile-10 { background: linear-gradient(135deg, #8b5cf6, #ec4899); }

.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 34px;
  align-items: start;
}

.rank-panel,
.player-card,
.story-panel,
.category-card,
.filter-panel {
  border: 1px solid var(--line);
  border-radius: 24px;
  background: #fff;
  box-shadow: var(--soft-shadow);
}

.rank-panel {
  position: sticky;
  top: 86px;
  padding: 22px;
}

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

.rank-item {
  border-radius: 18px;
  background: #fff;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.rank-item:hover {
  transform: translateY(-3px);
  box-shadow: var(--soft-shadow);
}

.rank-item a {
  display: grid;
  grid-template-columns: 42px 86px minmax(0, 1fr);
  gap: 13px;
  align-items: center;
  padding: 10px;
}

.rank-number {
  color: var(--orange);
  font-size: 22px;
  font-weight: 950;
  text-align: center;
}

.rank-item img {
  width: 86px;
  height: 58px;
  object-fit: cover;
  border-radius: 12px;
  background: linear-gradient(135deg, #ccfbf1, #cffafe);
}

.rank-item h3 {
  margin: 0 0 4px;
  font-size: 16px;
}

.rank-item p {
  display: -webkit-box;
  margin: 0 0 6px;
  color: var(--muted);
  font-size: 13px;
  overflow: hidden;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}

.primary-btn.wide {
  width: 100%;
  margin-top: 20px;
}

.page-hero {
  color: #fff;
  background: linear-gradient(120deg, var(--cyan), var(--teal));
}

.page-hero .section-shell {
  padding: 70px 0;
}

.page-hero h1 {
  margin: 8px 0 12px;
  font-size: clamp(38px, 5vw, 56px);
  line-height: 1.1;
}

.page-hero p {
  width: min(760px, 100%);
  color: rgba(255, 255, 255, 0.88);
  font-size: 18px;
}

.cyan-hero { background: linear-gradient(120deg, #06b6d4, #0f766e); }
.category-hero { background: linear-gradient(120deg, #0f766e, #10b981); }
.rank-hero { background: linear-gradient(120deg, #f97316, #db2777); }
.search-hero { background: linear-gradient(120deg, #0891b2, #3b82f6); }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
  margin-bottom: 20px;
}

.breadcrumb a:hover {
  color: var(--amber);
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 16px;
  padding: 18px;
  margin-bottom: 26px;
}

.filter-panel label {
  display: grid;
  gap: 8px;
  font-weight: 900;
  color: #334155;
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 46px;
  border: 1px solid #dbeafe;
  border-radius: 16px;
  outline: 0;
  padding: 0 14px;
  background: #f8fafc;
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: var(--cyan-bright);
  box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.empty-state {
  padding: 28px;
  border-radius: 22px;
  color: #0f766e;
  background: #ecfeff;
  font-weight: 900;
  text-align: center;
}

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

.rank-page-list .rank-item a {
  grid-template-columns: 58px 136px minmax(0, 1fr);
}

.rank-page-list .rank-item img {
  width: 136px;
  height: 88px;
}

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

.category-card {
  overflow: hidden;
}

.category-card a {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
}

.category-covers {
  min-height: 190px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  background: linear-gradient(135deg, #ccfbf1, #cffafe);
}

.category-covers img {
  width: 100%;
  height: 95px;
  object-fit: cover;
}

.category-info {
  padding: 22px;
}

.category-info h2 {
  margin: 0 0 10px;
  font-size: 25px;
}

.mini-tags {
  margin-top: 14px;
}

.detail-head {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  color: #fff;
  background: #0f172a;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(6px) saturate(1.18);
  transform: scale(1.08);
  opacity: 0.55;
}

.detail-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 75% 20%, rgba(6, 182, 212, 0.22), transparent 28%),
    linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.52));
}

.detail-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
  padding-top: 70px;
  padding-bottom: 70px;
}

.detail-poster {
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
  background: linear-gradient(135deg, #ccfbf1, #cffafe);
}

.detail-poster img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.detail-info h1 {
  margin: 8px 0 14px;
  font-size: clamp(40px, 6vw, 70px);
  line-height: 1.04;
}

.lead-text {
  width: min(780px, 100%);
  color: rgba(255, 255, 255, 0.88);
  font-size: 20px;
}

.detail-meta {
  margin: 18px 0;
}

.detail-tags {
  margin-bottom: 28px;
}

.detail-content {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
  gap: 28px;
  align-items: start;
}

.player-card {
  padding: 14px;
}

.video-shell {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  background: #020617;
  aspect-ratio: 16 / 9;
}

.video-shell video {
  width: 100%;
  height: 100%;
  display: block;
  background: #020617;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 10px;
  color: #fff;
  text-align: center;
  border: 0;
  cursor: pointer;
  background: linear-gradient(120deg, rgba(15, 23, 42, 0.76), rgba(15, 118, 110, 0.36));
}

.player-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.18s ease, visibility 0.18s ease;
}

.play-ring {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--teal);
  background: #fff;
  font-size: 32px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.32);
}

.player-overlay strong {
  font-size: 22px;
}

.player-overlay em {
  font-style: normal;
  color: rgba(255, 255, 255, 0.82);
}

.story-panel {
  padding: 28px;
}

.story-panel h2 + p {
  margin-top: 12px;
}

.story-panel p + h2 {
  margin-top: 26px;
}

.site-footer {
  color: #d1d5db;
  background: linear-gradient(90deg, #111827, #0f172a);
}

.footer-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0;
  display: flex;
  justify-content: space-between;
  gap: 24px;
}

.footer-shell p {
  margin: 8px 0 0;
  color: #9ca3af;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
}

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

@media (max-width: 1024px) {
  .top-search {
    display: none;
  }

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

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

  .split-layout,
  .detail-content,
  .intro-panel {
    grid-template-columns: 1fr;
  }

  .rank-panel {
    position: static;
  }

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

  .detail-grid {
    grid-template-columns: 260px minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  .nav-shell {
    height: auto;
    min-height: 62px;
    flex-wrap: wrap;
    padding: 12px 0;
  }

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

  .main-nav {
    display: none;
    width: 100%;
    margin: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 8px 0;
  }

  .site-header.is-open .main-nav {
    display: flex;
  }

  .nav-dropdown {
    display: none;
  }

  .main-nav a {
    padding: 10px 0;
  }

  .hero-slider {
    height: 620px;
  }

  .hero-content {
    justify-content: flex-start;
    padding-top: 70px;
  }

  .hero-content h1 {
    font-size: 42px;
  }

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

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

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

  .section-shell {
    padding: 38px 0;
  }

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

  .rank-item a,
  .rank-page-list .rank-item a {
    grid-template-columns: 42px 92px minmax(0, 1fr);
  }

  .rank-page-list .rank-item img,
  .rank-item img {
    width: 92px;
    height: 62px;
  }

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

  .detail-poster {
    width: min(260px, 100%);
  }

  .footer-shell {
    flex-direction: column;
  }
}

@media (max-width: 460px) {
  .movie-grid,
  .small-grid,
  .all-list,
  .category-grid,
  .category-list-grid {
    grid-template-columns: 1fr;
  }

  .large-search {
    flex-direction: column;
    gap: 8px;
  }

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

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