:root {
  --emerald: #059669;
  --emerald-dark: #047857;
  --teal: #0d9488;
  --cyan: #0891b2;
  --gold: #f59e0b;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #e2e8f0;
  --soft: #f8fafc;
  --card: #ffffff;
  --shadow: 0 20px 50px rgba(15, 23, 42, 0.12);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: linear-gradient(180deg, #f8fafc 0%, #eefdfa 48%, #f8fafc 100%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  font: inherit;
}

[hidden] {
  display: none !important;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: linear-gradient(90deg, var(--emerald), var(--teal), var(--cyan));
  box-shadow: 0 12px 34px rgba(4, 120, 87, 0.25);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  max-width: 1280px;
  height: 72px;
  margin: 0 auto;
  padding: 0 24px;
}

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

.brand-name {
  white-space: nowrap;
  font-size: 22px;
}

.brand-mark {
  position: relative;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.28);
}

.brand-mark::after {
  position: absolute;
  top: 50%;
  left: 52%;
  width: 0;
  height: 0;
  content: "";
  transform: translate(-38%, -50%);
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 12px solid #fff;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}

.nav-links a {
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 650;
  transition: background 0.2s ease, color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}

.top-search {
  position: relative;
  display: flex;
  align-items: center;
  width: min(280px, 28vw);
  margin-left: 8px;
}

.top-search input {
  width: 100%;
  height: 42px;
  padding: 0 74px 0 18px;
  color: #0f172a;
  border: 0;
  border-radius: 999px;
  outline: 0;
  background: #fff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.12);
}

.top-search button {
  position: absolute;
  right: 4px;
  height: 34px;
  padding: 0 14px;
  color: #fff;
  cursor: pointer;
  border: 0;
  border-radius: 999px;
  background: var(--emerald);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  padding: 10px;
  cursor: pointer;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.16);
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 99px;
  background: #fff;
}

main {
  overflow: hidden;
}

.hero {
  position: relative;
  min-height: 680px;
  color: #fff;
  isolation: isolate;
  background: radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.24), transparent 34%), linear-gradient(135deg, #059669 0%, #0d9488 50%, #0891b2 100%);
}

.hero::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 120px;
  content: "";
  background: linear-gradient(180deg, rgba(248, 250, 252, 0), #f8fafc);
  z-index: -1;
}

.hero-inner {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  padding: 78px 24px 120px;
}

.hero-grid {
  display: grid;
  align-items: center;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 44px;
}

.hero-copy {
  max-width: 680px;
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(36px, 6vw, 68px);
  line-height: 1.05;
  letter-spacing: -0.055em;
}

.hero-copy > p {
  margin: 0 0 24px;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(18px, 2vw, 24px);
}

.hero-feature {
  position: relative;
  min-height: 420px;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  align-items: end;
  overflow: hidden;
  border-radius: 34px;
  background: rgba(15, 23, 42, 0.35);
  box-shadow: 0 32px 80px rgba(15, 23, 42, 0.32);
  opacity: 0;
  transform: translateY(16px) scale(0.98);
  transition: opacity 0.45s ease, transform 0.45s ease;
}

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

.hero-slide img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.08) contrast(1.03);
}

.hero-slide::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.06), rgba(15, 23, 42, 0.82));
}

.hero-slide-content {
  position: relative;
  z-index: 1;
  padding: 28px;
}

.hero-slide-content h2 {
  margin: 8px 0 8px;
  font-size: clamp(26px, 3.2vw, 42px);
  line-height: 1.08;
}

.hero-slide-content p {
  display: -webkit-box;
  margin: 0 0 20px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.86);
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

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

.primary-btn,
.secondary-btn,
.text-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 999px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
  color: var(--emerald-dark);
  background: #fff;
  box-shadow: 0 14px 36px rgba(15, 23, 42, 0.16);
}

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

.text-btn {
  min-height: 38px;
  color: var(--emerald-dark);
  background: #ecfdf5;
}

.primary-btn:hover,
.secondary-btn:hover,
.text-btn:hover {
  transform: translateY(-2px);
}

.section-kicker,
.eyebrow {
  margin: 0 0 10px;
  color: var(--emerald);
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero .section-kicker,
.hero .eyebrow {
  color: rgba(255, 255, 255, 0.86);
}

.hero-dots {
  position: absolute;
  right: 28px;
  bottom: 28px;
  z-index: 4;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  cursor: pointer;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  transition: width 0.2s ease, background 0.2s ease;
}

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

.quick-cats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  max-width: 1280px;
  margin: -58px auto 0;
  padding: 0 24px;
  position: relative;
  z-index: 5;
}

.quick-cat {
  min-height: 116px;
  padding: 22px;
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.quick-cat:hover {
  transform: translateY(-4px);
  border-color: rgba(5, 150, 105, 0.3);
}

.quick-cat strong {
  display: block;
  margin-bottom: 8px;
  font-size: 20px;
}

.quick-cat span {
  color: var(--muted);
  font-size: 14px;
}

.content-section,
.page-hero,
.detail-layout,
.watch-section,
.text-panel,
.related-panel {
  max-width: 1280px;
  margin: 0 auto;
  padding: 72px 24px 0;
}

.page-hero {
  padding-top: 82px;
  padding-bottom: 16px;
}

.page-hero h1,
.section-heading h2,
.text-panel h2,
.related-panel h2 {
  margin: 0;
  color: #0f172a;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.page-hero p {
  max-width: 760px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 18px;
}

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

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

.movie-card {
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.08);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  border-color: rgba(5, 150, 105, 0.35);
  box-shadow: 0 22px 56px rgba(15, 23, 42, 0.13);
}

.poster-link {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #0f172a, #115e59);
}

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

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

.score-badge,
.rank-badge,
.hover-play {
  position: absolute;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 900;
}

.score-badge {
  top: 12px;
  right: 12px;
  min-width: 48px;
  height: 30px;
  color: #111827;
  background: #fbbf24;
  box-shadow: 0 10px 24px rgba(251, 191, 36, 0.3);
}

.rank-badge {
  top: 12px;
  left: 12px;
  width: 36px;
  height: 36px;
  color: #fff;
  background: rgba(15, 23, 42, 0.78);
  backdrop-filter: blur(14px);
}

.hover-play {
  left: 50%;
  bottom: 18px;
  height: 38px;
  padding: 0 18px;
  color: #fff;
  opacity: 0;
  transform: translate(-50%, 10px);
  background: linear-gradient(90deg, var(--emerald), var(--teal));
  box-shadow: 0 14px 32px rgba(5, 150, 105, 0.28);
  transition: opacity 0.24s ease, transform 0.24s ease;
}

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

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

.movie-title {
  display: block;
  overflow: hidden;
  color: #0f172a;
  font-size: 18px;
  font-weight: 850;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-meta {
  margin: 7px 0 10px;
  overflow: hidden;
  color: var(--muted);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.movie-card-body p {
  display: -webkit-box;
  min-height: 48px;
  margin: 0;
  overflow: hidden;
  color: #475569;
  font-size: 14px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 14px;
}

.tag-row span,
.detail-chip,
.meta-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: #047857;
  border-radius: 999px;
  background: #ecfdf5;
  font-size: 12px;
  font-weight: 800;
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(140px, 180px) minmax(160px, 220px);
  gap: 14px;
  max-width: 1280px;
  margin: 28px auto 0;
  padding: 0 24px;
}

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

.filter-panel input,
.filter-panel select {
  width: 100%;
  height: 48px;
  padding: 0 16px;
  color: #0f172a;
  border: 1px solid var(--line);
  border-radius: 16px;
  outline: 0;
  background: #fff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.05);
}

.filter-panel input:focus,
.filter-panel select:focus {
  border-color: rgba(5, 150, 105, 0.45);
  box-shadow: 0 0 0 4px rgba(5, 150, 105, 0.12);
}

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

.category-card {
  display: grid;
  gap: 18px;
  padding: 28px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 26px 62px rgba(15, 23, 42, 0.13);
}

.category-card h2 {
  margin: 0;
  font-size: 28px;
}

.category-card p {
  margin: 0;
  color: var(--muted);
}

.category-preview {
  display: flex;
  gap: 10px;
}

.category-preview img {
  width: 92px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 16px;
  background: #0f172a;
}

.ranking-list {
  display: grid;
  gap: 18px;
}

.ranking-item {
  display: grid;
  grid-template-columns: 68px 110px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 16px;
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.ranking-num {
  color: var(--emerald);
  font-size: 28px;
  font-weight: 950;
  text-align: center;
}

.ranking-item img {
  width: 110px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 18px;
}

.ranking-item h2 {
  margin: 0 0 8px;
  font-size: 24px;
}

.ranking-item p {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: var(--muted);
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.ranking-score {
  padding: 10px 16px;
  color: #111827;
  border-radius: 999px;
  background: #fbbf24;
  font-size: 20px;
  font-weight: 950;
}

.breadcrumb {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 24px 0;
  color: var(--muted);
  font-size: 14px;
}

.breadcrumb a {
  color: var(--emerald-dark);
  font-weight: 800;
}

.detail-layout {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
  padding-top: 34px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 32px;
  box-shadow: var(--shadow);
}

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

.detail-info h1 {
  margin: 0 0 14px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.detail-summary {
  max-width: 820px;
  margin: 20px 0 24px;
  color: #475569;
  font-size: 18px;
}

.detail-meta,
.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.meta-pill {
  color: #155e75;
  background: #ecfeff;
}

.watch-section {
  padding-top: 44px;
}

.movie-player {
  position: relative;
  overflow: hidden;
  border-radius: 32px;
  background: #020617;
  box-shadow: 0 28px 78px rgba(15, 23, 42, 0.32);
}

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

.player-cover {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  cursor: pointer;
  border: 0;
  background: radial-gradient(circle at 50% 50%, rgba(5, 150, 105, 0.2), rgba(2, 6, 23, 0.72));
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

.player-cover.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-button {
  display: inline-grid;
  place-items: center;
  width: 96px;
  height: 96px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--emerald), var(--teal));
  box-shadow: 0 24px 60px rgba(5, 150, 105, 0.42);
}

.player-button::before {
  width: 0;
  height: 0;
  margin-left: 8px;
  content: "";
  border-top: 18px solid transparent;
  border-bottom: 18px solid transparent;
  border-left: 26px solid #fff;
}

.player-label {
  position: absolute;
  bottom: 26px;
  left: 50%;
  font-size: 18px;
  font-weight: 900;
  transform: translateX(-50%);
}

.text-panel {
  display: grid;
  gap: 28px;
  max-width: 980px;
}

.text-panel article {
  padding: 32px;
  border: 1px solid rgba(226, 232, 240, 0.92);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.06);
}

.text-panel p {
  margin: 16px 0 0;
  color: #334155;
  font-size: 17px;
}

.related-panel {
  padding-bottom: 80px;
}

.site-footer {
  margin-top: 70px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  max-width: 1280px;
  margin: 0 auto;
  padding: 44px 24px;
}

.footer-inner p {
  max-width: 560px;
  margin: 12px 0 0;
  color: #94a3b8;
}

.footer-brand {
  color: #fff;
  font-size: 24px;
}

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

.footer-links a {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
}

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px 28px;
  color: #64748b;
  font-size: 14px;
}

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

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

  .hero-feature {
    min-height: 500px;
  }

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

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

@media (max-width: 760px) {
  .header-inner {
    flex-wrap: wrap;
    height: auto;
    min-height: 66px;
    padding: 12px 16px;
  }

  .brand-name {
    font-size: 19px;
  }

  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding-top: 10px;
  }

  .site-header.menu-open .nav-links {
    display: flex;
  }

  .nav-links a {
    background: rgba(255, 255, 255, 0.12);
  }

  .hero {
    min-height: auto;
  }

  .hero-inner {
    padding: 48px 16px 96px;
  }

  .hero-grid {
    gap: 28px;
  }

  .hero-feature {
    min-height: 420px;
  }

  .quick-cats,
  .movie-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    padding-right: 16px;
    padding-left: 16px;
  }

  .content-section,
  .page-hero,
  .detail-layout,
  .watch-section,
  .text-panel,
  .related-panel,
  .breadcrumb {
    padding-right: 16px;
    padding-left: 16px;
  }

  .filter-panel {
    grid-template-columns: 1fr;
    padding-right: 16px;
    padding-left: 16px;
  }

  .ranking-item {
    grid-template-columns: 48px 82px minmax(0, 1fr);
  }

  .ranking-score {
    grid-column: 3;
    justify-self: start;
    margin-top: -8px;
  }

  .ranking-item img {
    width: 82px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    padding-right: 16px;
    padding-left: 16px;
  }
}

@media (max-width: 520px) {
  .quick-cats,
  .movie-grid {
    grid-template-columns: 1fr;
  }

  .hero-feature {
    min-height: 360px;
  }

  .hero-slide-content {
    padding: 22px;
  }

  .detail-poster {
    max-width: 280px;
  }

  .player-button {
    width: 76px;
    height: 76px;
  }
}
