:root {
  color-scheme: light;
  --bg: #f8faf9;
  --surface: #ffffff;
  --surface-soft: #ecfdf5;
  --ink: #0f172a;
  --muted: #64748b;
  --line: #d1fae5;
  --green: #059669;
  --green-deep: #064e3b;
  --green-dark: #022c22;
  --cyan: #06b6d4;
  --shadow: 0 24px 70px rgba(6, 78, 59, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(16, 185, 129, 0.12), transparent 34rem),
    linear-gradient(180deg, #f0fdf4 0%, var(--bg) 36rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
  min-height: 74px;
  padding: 0 18px;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(16, 185, 129, 0.14);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: auto;
  margin: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
  font-weight: 900;
  color: var(--green-deep);
  white-space: nowrap;
}

.brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--green), #16a34a);
  border-radius: 14px;
  box-shadow: 0 12px 30px rgba(5, 150, 105, 0.28);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  height: 42px;
  padding: 0 18px;
  color: #315045;
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background: var(--green);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  padding: 10px;
  border: 0;
  border-radius: 14px;
  background: var(--surface-soft);
}

.menu-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--green-deep);
  border-radius: 3px;
}

.hero-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 350px;
  gap: 24px;
  width: min(1280px, calc(100% - 32px));
  margin: 26px auto 0;
}

.hero-carousel {
  position: relative;
  min-height: 580px;
  overflow: hidden;
  border-radius: 34px;
  box-shadow: var(--shadow);
  background: var(--green-dark);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  align-items: center;
  gap: 44px;
  padding: 64px;
  color: #ffffff;
  background-position: center;
  background-size: cover;
  opacity: 0;
  transform: scale(1.015);
  pointer-events: none;
  transition: opacity 0.65s ease, transform 0.65s ease;
}

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

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

.hero-kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  margin-bottom: 14px;
  padding: 7px 13px;
  color: #a7f3d0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

.eyebrow {
  color: var(--green);
  background: #d1fae5;
  border-color: #bbf7d0;
}

.hero-content h1,
.sub-hero h1,
.detail-copy h1 {
  margin: 0;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.05em;
}

.hero-content p,
.sub-hero p,
.detail-copy p {
  margin: 22px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
  line-height: 1.9;
}

.hero-tags,
.card-meta,
.tag-row,
.detail-meta,
.sub-actions,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

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

.hero-tags span,
.tag-row span,
.card-meta span,
.detail-meta span {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  color: #ecfdf5;
  font-size: 13px;
  font-weight: 700;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-actions,
.sub-actions {
  margin-top: 32px;
}

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

.primary-button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--green), #16a34a);
  box-shadow: 0 16px 36px rgba(5, 150, 105, 0.32);
}

.soft-button {
  color: #ecfdf5;
  background: rgba(255, 255, 255, 0.13);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

.ghost-button {
  min-height: 44px;
  color: var(--green-deep);
  background: #d1fae5;
  border: 0;
}

.primary-button:hover,
.soft-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(6, 78, 59, 0.2);
}

.hero-poster,
.detail-cover {
  position: relative;
  display: flex;
  align-items: end;
  justify-content: start;
  aspect-ratio: 2 / 3;
  min-height: 400px;
  padding: 22px;
  overflow: hidden;
  background-color: rgba(5, 150, 105, 0.24);
  background-position: center;
  background-size: cover;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 26px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.hero-poster span,
.detail-cover span,
.poster-play {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  color: #ffffff;
  font-weight: 900;
  background: rgba(5, 150, 105, 0.92);
  border-radius: 999px;
}

.hero-dots {
  position: absolute;
  left: 64px;
  bottom: 38px;
  display: flex;
  gap: 10px;
}

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

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

.hero-rank,
.side-card,
.article-card,
.player-card,
.filter-panel {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(16, 185, 129, 0.14);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-rank {
  padding: 24px;
}

.hero-rank-head,
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.hero-rank-head span,
.section-heading h2,
.side-card h2,
.article-card h2 {
  margin: 0;
  color: var(--green-dark);
  font-size: 26px;
  font-weight: 950;
  letter-spacing: -0.04em;
}

.hero-rank-head a,
.section-more {
  color: var(--green);
  font-weight: 900;
}

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

.compact-rank-item {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 8px 12px;
  align-items: center;
  padding: 12px;
  background: #f0fdf4;
  border: 1px solid rgba(16, 185, 129, 0.12);
  border-radius: 16px;
  transition: transform 0.2s ease, background 0.2s ease;
}

.compact-rank-item:hover {
  background: #dcfce7;
  transform: translateX(4px);
}

.compact-rank-item span {
  grid-row: span 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  color: #ffffff;
  font-weight: 950;
  background: var(--green);
  border-radius: 13px;
}

.compact-rank-item strong {
  overflow: hidden;
  color: var(--ink);
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-rank-item em {
  overflow: hidden;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.section-block {
  padding: 70px 0 0;
}

.section-heading h2 {
  font-size: clamp(28px, 4vw, 44px);
}

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

.category-tile,
.category-panel,
.sub-hero {
  overflow: hidden;
  background-color: var(--green-deep);
  background-position: center;
  background-size: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.category-tile {
  min-height: 170px;
  padding: 22px;
  color: #ffffff;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 28px 80px rgba(6, 78, 59, 0.22);
}

.category-tile span {
  display: block;
  margin-bottom: 12px;
  font-size: 24px;
  font-weight: 950;
}

.category-tile strong {
  color: rgba(255, 255, 255, 0.82);
  font-size: 14px;
}

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

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

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

.movie-card {
  overflow: hidden;
  background: var(--surface);
  border: 1px solid rgba(16, 185, 129, 0.13);
  border-radius: 22px;
  box-shadow: 0 14px 38px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.poster {
  position: relative;
  display: flex;
  align-items: end;
  justify-content: space-between;
  min-height: 260px;
  padding: 14px;
  background-color: #065f46;
  background-position: center;
  background-size: cover;
}

.compact-card .poster {
  min-height: 220px;
}

.poster-type,
.rank-mark {
  position: absolute;
  top: 12px;
  padding: 6px 10px;
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
  background: rgba(2, 44, 34, 0.74);
  border-radius: 999px;
}

.poster-type {
  right: 12px;
}

.rank-mark {
  left: 12px;
  min-width: 34px;
  text-align: center;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
}

.card-body {
  padding: 16px;
}

.card-title {
  display: block;
  overflow: hidden;
  margin-bottom: 8px;
  color: var(--green-dark);
  font-size: 18px;
  font-weight: 950;
  text-overflow: ellipsis;
  white-space: nowrap;
}

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

.card-meta {
  margin-bottom: 10px;
}

.card-meta span,
.tag-row span,
.detail-meta span {
  color: var(--green-deep);
  background: #d1fae5;
  border-color: #bbf7d0;
}

.tag-row {
  gap: 6px;
}

.tag-row span {
  min-height: 24px;
  padding: 2px 8px;
  color: #047857;
  font-size: 12px;
  background: #ecfdf5;
}

.filter-panel {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 26px;
  padding: 20px;
}

.search-box {
  flex: 1;
}

.search-box span {
  display: block;
  margin-bottom: 8px;
  color: var(--green-deep);
  font-weight: 900;
}

.search-box input,
.filter-actions select {
  width: 100%;
  min-height: 46px;
  padding: 0 16px;
  color: var(--ink);
  background: #f8fafc;
  border: 1px solid #bbf7d0;
  border-radius: 16px;
  outline: 0;
}

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

.filter-actions {
  display: flex;
  align-items: end;
  gap: 10px;
}

.filter-result {
  min-width: 92px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  text-align: right;
}

.sub-hero {
  margin-top: 26px;
  padding: 64px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--green-deep), var(--green-dark));
}

.sub-hero .eyebrow {
  color: #a7f3d0;
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.18);
}

.sub-hero p {
  max-width: 760px;
}

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

.category-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(180px, 0.72fr);
  gap: 24px;
  min-height: 250px;
  padding: 28px;
  color: #ffffff;
}

.category-panel span {
  color: #a7f3d0;
  font-weight: 900;
}

.category-panel h2 {
  margin: 6px 0 12px;
  font-size: 32px;
  line-height: 1.1;
}

.category-panel p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
}

.panel-links {
  display: grid;
  gap: 10px;
  align-content: center;
}

.panel-links a {
  overflow: hidden;
  padding: 10px 12px;
  color: #ecfdf5;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.11);
  border-radius: 12px;
}

.page-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  align-items: start;
}

.side-column {
  position: sticky;
  top: 96px;
  display: grid;
  gap: 18px;
}

.side-card,
.article-card,
.player-card {
  padding: 22px;
}

.detail-hero {
  margin-top: -1px;
  color: #ffffff;
  background-color: var(--green-dark);
  background-position: center;
  background-size: cover;
}

.detail-hero-inner {
  padding: 38px 0 64px;
}

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

.breadcrumb a:hover {
  color: #ffffff;
}

.detail-intro {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 38px;
  align-items: center;
}

.detail-cover {
  min-height: 420px;
}

.detail-copy p {
  max-width: 780px;
}

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

.detail-layout {
  padding-top: 38px;
}

.player-card {
  margin-bottom: 24px;
  padding: 0;
  overflow: hidden;
  background: #000000;
}

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

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

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: #ffffff;
  background:
    radial-gradient(circle, rgba(5, 150, 105, 0.42), rgba(0, 0, 0, 0.72)),
    linear-gradient(135deg, rgba(2, 44, 34, 0.72), rgba(0, 0, 0, 0.88));
  border: 0;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  padding-left: 5px;
  color: var(--green-deep);
  font-size: 34px;
  background: #ffffff;
  border-radius: 999px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.32);
}

.player-overlay strong {
  max-width: 90%;
  overflow: hidden;
  font-size: clamp(20px, 4vw, 38px);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.article-card {
  display: grid;
  gap: 12px;
}

.article-card p {
  margin: 0 0 12px;
  color: #334155;
  font-size: 17px;
  line-height: 1.95;
}

.info-list {
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  gap: 12px;
  margin: 0;
}

.info-list dt {
  color: var(--muted);
  font-weight: 800;
}

.info-list dd {
  margin: 0;
  color: var(--ink);
  font-weight: 900;
}

.detail-pager {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.detail-pager a {
  overflow: hidden;
  padding: 16px 18px;
  color: var(--green-deep);
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
  background: #d1fae5;
  border-radius: 18px;
}

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

.site-footer {
  margin-top: 86px;
  padding-top: 48px;
  color: #d1fae5;
  background: linear-gradient(135deg, var(--green-dark), var(--green-deep));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr 1fr;
  gap: 32px;
}

.footer-brand {
  color: #ffffff;
}

.site-footer p {
  max-width: 440px;
  margin: 18px 0 0;
  color: #a7f3d0;
}

.site-footer h3 {
  margin: 0 0 14px;
  color: #ffffff;
}

.footer-links {
  display: grid;
  gap: 10px;
}

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

.footer-links a {
  color: #d1fae5;
}

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

.footer-bottom {
  margin-top: 42px;
  padding: 18px;
  color: #a7f3d0;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.11);
}

.is-filter-hidden {
  display: none !important;
}

@media (max-width: 1100px) {
  .site-header {
    justify-content: space-between;
  }

  .header-inner {
    width: min(1180px, calc(100% - 32px));
    display: flex;
    justify-content: space-between;
  }

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

  .site-nav {
    position: fixed;
    left: 16px;
    right: 16px;
    top: 82px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    background: #ffffff;
    border: 1px solid #bbf7d0;
    border-radius: 22px;
    box-shadow: var(--shadow);
  }

  .site-nav.open {
    display: flex;
  }

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

  .hero-rank,
  .side-column {
    position: static;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    padding: 42px;
  }

  .hero-poster {
    display: none;
  }

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

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

@media (max-width: 760px) {
  .shell,
  .hero-wrap {
    width: min(100% - 24px, 1180px);
  }

  .site-header {
    min-height: 66px;
    padding: 0 12px;
  }

  .brand {
    font-size: 18px;
  }

  .brand-icon {
    width: 34px;
    height: 34px;
    border-radius: 12px;
  }

  .hero-carousel {
    min-height: 540px;
    border-radius: 24px;
  }

  .hero-slide {
    padding: 30px 24px 82px;
  }

  .hero-content h1,
  .sub-hero h1,
  .detail-copy h1 {
    font-size: 38px;
  }

  .hero-content p,
  .sub-hero p,
  .detail-copy p {
    font-size: 16px;
  }

  .hero-dots {
    left: 24px;
    bottom: 30px;
  }

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

  .category-grid,
  .movie-grid,
  .hot-grid,
  .library-grid,
  .ranking-grid,
  .ranking-link-grid,
  .category-panel-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .category-panel,
  .detail-intro,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .filter-panel,
  .filter-actions,
  .section-heading,
  .hero-rank-head {
    align-items: stretch;
    flex-direction: column;
  }

  .filter-result {
    text-align: left;
  }

  .poster {
    min-height: 210px;
  }

  .card-body {
    padding: 12px;
  }

  .card-title {
    font-size: 16px;
  }

  .sub-hero {
    padding: 34px 24px;
  }

  .detail-cover {
    width: 70%;
    min-height: 340px;
  }

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

@media (max-width: 480px) {
  .category-grid,
  .movie-grid,
  .hot-grid,
  .library-grid,
  .ranking-grid,
  .ranking-link-grid {
    grid-template-columns: 1fr;
  }

  .poster,
  .compact-card .poster {
    min-height: 300px;
  }

  .detail-cover {
    width: 100%;
  }
}
