:root {
  --emerald: #059669;
  --emerald-dark: #047857;
  --teal: #0d9488;
  --cyan: #0891b2;
  --rose: #e11d48;
  --amber: #d97706;
  --blue: #2563eb;
  --slate: #111827;
  --muted: #6b7280;
  --border: #e5e7eb;
  --soft: #f8fafc;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--slate);
  background: linear-gradient(180deg, #f9fafb 0%, #ffffff 46%, #f8fafc 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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

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

button,
input,
select {
  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.9);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  color: var(--emerald);
}

.brand-mark,
.footer-logo span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--emerald), var(--cyan));
  box-shadow: 0 10px 24px rgba(5, 150, 105, 0.3);
}

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

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

.nav-link {
  color: #374151;
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--emerald);
}

.header-search,
.mobile-search {
  display: flex;
  align-items: center;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #ffffff;
}

.header-search input,
.mobile-search input {
  width: 170px;
  border: 0;
  outline: 0;
  padding: 9px 12px;
  color: #111827;
}

.header-search button,
.mobile-search button {
  border: 0;
  padding: 9px 14px;
  color: #ffffff;
  background: var(--emerald);
  cursor: pointer;
}

.menu-toggle {
  display: none;
  border: 0;
  color: var(--emerald);
  background: transparent;
  font-size: 26px;
}

.mobile-nav {
  display: none;
  padding: 0 24px 18px;
  border-top: 1px solid var(--border);
  background: #ffffff;
}

.mobile-nav.is-open {
  display: grid;
  gap: 14px;
}

.hero {
  position: relative;
  min-height: 620px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--emerald), var(--teal) 45%, var(--cyan));
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.26), transparent 28%),
    radial-gradient(circle at 80% 0%, rgba(255, 255, 255, 0.16), transparent 34%),
    rgba(0, 0, 0, 0.08);
}

.hero-slider {
  position: relative;
  max-width: 1280px;
  min-height: 620px;
  margin: 0 auto;
  padding: 76px 24px 112px;
}

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

.hero-slide.is-active {
  display: grid;
  animation: heroFade 0.7s ease both;
}

@keyframes heroFade {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 700;
}

.hero h1 {
  max-width: 840px;
  margin: 0 0 20px;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 1.05;
  letter-spacing: -0.04em;
}

.hero h2 {
  margin: 0 0 18px;
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.08;
}

.hero-desc {
  max-width: 760px;
  margin: 0 0 28px;
  color: #ecfeff;
  font-size: 20px;
}

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

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

.btn-primary {
  color: var(--emerald-dark);
  background: #ffffff;
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.16);
}

.btn-secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.28);
}

.btn-ghost {
  color: var(--emerald);
  background: #ecfdf5;
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-ghost:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}

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

.hero-tags a,
.tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags a {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
}

.hero-card {
  overflow: hidden;
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.16);
  box-shadow: 0 30px 72px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(16px);
}

.hero-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.hero-card-body {
  padding: 22px;
}

.hero-card-body h3 {
  margin: 0 0 8px;
  font-size: 24px;
}

.hero-card-body p {
  margin: 0 0 16px;
  color: #ecfeff;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #f0fdfa;
  font-size: 14px;
}

.hero-dots {
  position: absolute;
  right: 24px;
  bottom: 48px;
  display: flex;
  gap: 10px;
}

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

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

.featured-lift {
  position: relative;
  z-index: 4;
  max-width: 1280px;
  margin: -62px auto 10px;
  padding: 0 24px;
}

.featured-banner {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  overflow: hidden;
  border-radius: 28px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.featured-banner img {
  width: 100%;
  height: 100%;
  min-height: 340px;
  object-fit: cover;
}

.featured-copy {
  padding: 34px;
}

.featured-copy h2 {
  margin: 0 0 14px;
  font-size: 32px;
  line-height: 1.2;
}

.featured-copy p {
  color: var(--muted);
}

.main-section,
.page-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 58px 24px;
}

.section-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 26px;
}

.section-title {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.section-title span {
  font-size: 28px;
}

.section-title h2 {
  margin: 0;
  font-size: 32px;
  line-height: 1.2;
}

.section-line {
  height: 4px;
  flex: 1;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--emerald), rgba(5, 150, 105, 0));
}

.section-more {
  color: var(--emerald);
  font-weight: 800;
}

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

.movie-card {
  overflow: hidden;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.09);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.card-cover {
  position: relative;
  display: block;
  overflow: hidden;
  background: #e5e7eb;
}

.card-cover img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.score-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  background: rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(10px);
}

.score-badge {
  right: 12px;
}

.rank-badge {
  left: 12px;
  background: linear-gradient(135deg, var(--rose), var(--amber));
}

.card-body {
  padding: 15px;
}

.card-title {
  display: -webkit-box;
  overflow: hidden;
  margin-bottom: 8px;
  color: #111827;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.35;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-title:hover {
  color: var(--emerald);
}

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

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  color: #6b7280;
  font-size: 12px;
}

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

.tag {
  color: #065f46;
  background: #ecfdf5;
}

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

.channel-card,
.category-card {
  padding: 24px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.channel-card:hover,
.category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.channel-card h2,
.category-card h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

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

.page-hero {
  padding: 70px 24px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--emerald), var(--teal) 50%, var(--cyan));
}

.page-hero-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.page-hero h1 {
  max-width: 860px;
  margin: 0 0 16px;
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.08;
}

.page-hero p {
  max-width: 820px;
  margin: 0;
  color: #ecfeff;
  font-size: 20px;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 14px;
  margin-bottom: 28px;
  padding: 18px;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.filter-panel input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 999px;
  outline: 0;
  padding: 12px 16px;
}

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

.filter-button {
  border: 0;
  border-radius: 999px;
  padding: 10px 16px;
  color: #374151;
  background: #f3f4f6;
  cursor: pointer;
  font-weight: 800;
}

.filter-button.is-active {
  color: #ffffff;
  background: var(--emerald);
}

.detail-wrap {
  max-width: 1280px;
  margin: 0 auto;
  padding: 34px 24px 70px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 14px;
}

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

.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) 380px;
  gap: 28px;
}

.detail-main,
.detail-side {
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.09);
}

.detail-main {
  overflow: hidden;
}

.player-shell {
  position: relative;
  overflow: hidden;
  background: #000000;
  aspect-ratio: 16 / 9;
}

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.58));
  cursor: pointer;
  z-index: 2;
}

.player-overlay.is-hidden {
  display: none;
}

.play-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 86px;
  height: 86px;
  padding-left: 6px;
  border-radius: 999px;
  color: var(--emerald);
  background: #ffffff;
  font-size: 36px;
  box-shadow: 0 24px 54px rgba(0, 0, 0, 0.35);
}

.detail-content {
  padding: 28px;
}

.detail-content h1 {
  margin: 0 0 16px;
  font-size: 34px;
  line-height: 1.18;
}

.info-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
  color: #4b5563;
}

.info-list span {
  padding: 6px 12px;
  border-radius: 999px;
  background: #f3f4f6;
}

.detail-content h2,
.detail-side h2 {
  margin: 28px 0 12px;
  font-size: 22px;
}

.detail-content p {
  color: #374151;
  font-size: 16px;
}

.detail-side {
  padding: 22px;
  align-self: start;
}

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

.related-item {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border-radius: 16px;
  transition: background 0.2s ease;
}

.related-item:hover {
  background: #f3f4f6;
}

.related-item img {
  width: 120px;
  aspect-ratio: 16 / 10;
  border-radius: 12px;
  object-fit: cover;
}

.related-item h3 {
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.35;
}

.related-item p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

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

.movie-card-wide {
  display: grid;
  grid-template-columns: 260px 1fr;
}

.movie-card-wide .card-cover img {
  height: 100%;
  min-height: 160px;
}

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

.footer-grid {
  max-width: 1280px;
  margin: 0 auto;
  padding: 54px 24px;
  display: grid;
  grid-template-columns: 1.3fr 0.7fr 0.8fr;
  gap: 42px;
}

.footer-grid p {
  max-width: 470px;
  color: #9ca3af;
}

.footer-grid h2 {
  margin: 0 0 16px;
  color: #34d399;
  font-size: 18px;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.footer-grid a:hover {
  color: #34d399;
}

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding: 20px 24px;
  border-top: 1px solid #374151;
  color: #9ca3af;
  font-size: 14px;
}

.empty-state {
  display: none;
  padding: 42px;
  border-radius: 22px;
  text-align: center;
  color: var(--muted);
  background: #ffffff;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.empty-state.is-visible {
  display: block;
}

@media (max-width: 1120px) {
  .movie-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

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

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

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

  .menu-toggle {
    display: inline-flex;
    margin-left: auto;
  }

  .hero-slide,
  .featured-banner {
    grid-template-columns: 1fr;
  }

  .hero-slider {
    min-height: auto;
    padding: 52px 18px 88px;
  }

  .hero-card img,
  .featured-banner img {
    min-height: auto;
  }

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

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

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

  .movie-card-wide {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 580px) {
  .header-inner {
    height: 64px;
    padding: 0 16px;
  }

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

  .hero h1,
  .hero h2,
  .page-hero h1 {
    letter-spacing: -0.02em;
  }

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

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

  .main-section,
  .page-main,
  .detail-wrap {
    padding-left: 16px;
    padding-right: 16px;
  }

  .section-head {
    align-items: flex-start;
  }

  .section-line {
    display: none;
  }

  .section-title h2 {
    font-size: 25px;
  }

  .detail-content {
    padding: 20px;
  }

  .detail-content h1 {
    font-size: 27px;
  }

  .related-item {
    grid-template-columns: 94px 1fr;
  }

  .related-item img {
    width: 94px;
  }
}
