:root {
  --primary: #10b981;
  --primary-dark: #059669;
  --secondary: #14b8a6;
  --accent: #06b6d4;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e5e7eb;
  --soft: #f3f4f6;
  --white: #ffffff;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --shadow-soft: 0 10px 28px rgba(15, 23, 42, 0.08);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
  font: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid rgba(229, 231, 235, 0.9);
  backdrop-filter: blur(16px);
}

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

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 24px;
}

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #064e3b;
}

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: 12px;
  box-shadow: 0 12px 24px rgba(16, 185, 129, 0.28);
}

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

.nav-link {
  padding: 10px 14px;
  color: #374151;
  border-radius: 999px;
  font-weight: 650;
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

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

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 9px;
  border: 0;
  background: #ecfdf5;
  border-radius: 12px;
}

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

.hero-carousel {
  position: relative;
  min-height: 590px;
  overflow: hidden;
  background: linear-gradient(135deg, #064e3b 0%, #115e59 52%, #164e63 100%);
}

.hero-stage,
.hero-slide {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.8s ease;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-slide > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.02);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 25%, rgba(16, 185, 129, 0.32), transparent 34%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.58) 47%, rgba(0, 0, 0, 0.18) 100%);
}

.hero-content {
  position: relative;
  z-index: 3;
  display: flex;
  align-items: center;
  min-height: 590px;
  padding: 70px 0 90px;
}

.hero-copy {
  max-width: 720px;
  color: #ffffff;
}

.hero-pill,
.page-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  color: #d1fae5;
  background: rgba(16, 185, 129, 0.18);
  border: 1px solid rgba(167, 243, 208, 0.24);
  border-radius: 999px;
  backdrop-filter: blur(8px);
  font-size: 14px;
  font-weight: 700;
}

.hero-copy h1 {
  margin: 22px 0 18px;
  font-size: clamp(38px, 7vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.06em;
}

.hero-copy p {
  max-width: 650px;
  margin: 0 0 28px;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(17px, 2vw, 22px);
}

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

.hero-tags span,
.tag-row span,
.meta-pill {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  color: #065f46;
  background: #ecfdf5;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
}

.hero-tags span {
  color: #e0f2fe;
  background: rgba(255, 255, 255, 0.16);
}

.hero-actions,
.page-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 12px 18px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 14px;
  box-shadow: 0 14px 30px rgba(16, 185, 129, 0.24);
  font-weight: 800;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(16, 185, 129, 0.32);
}

.btn.secondary {
  color: #ecfeff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: none;
  backdrop-filter: blur(8px);
}

.hero-search {
  display: flex;
  width: min(560px, 100%);
  margin-top: 28px;
  padding: 6px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 18px;
  backdrop-filter: blur(10px);
}

.hero-search input {
  flex: 1;
  min-width: 0;
  height: 46px;
  padding: 0 16px;
  color: #ffffff;
  background: transparent;
  border: 0;
  outline: none;
}

.hero-search input::placeholder {
  color: rgba(255, 255, 255, 0.72);
}

.hero-search button {
  height: 46px;
  padding: 0 18px;
  border: 0;
  color: #064e3b;
  background: #ffffff;
  border-radius: 13px;
  font-weight: 800;
}

.hero-arrow {
  position: absolute;
  top: 50%;
  z-index: 6;
  width: 48px;
  height: 48px;
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  backdrop-filter: blur(10px);
  transform: translateY(-50%);
  transition: background 0.25s ease, transform 0.25s ease;
}

.hero-arrow:hover {
  background: rgba(255, 255, 255, 0.28);
  transform: translateY(-50%) scale(1.06);
}

.hero-arrow.prev {
  left: 22px;
}

.hero-arrow.next {
  right: 22px;
}

.hero-dots {
  position: absolute;
  z-index: 7;
  left: 50%;
  bottom: 28px;
  display: flex;
  gap: 8px;
  transform: translateX(-50%);
}

.hero-dots button {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  background: rgba(255, 255, 255, 0.48);
  border-radius: 999px;
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.active {
  width: 34px;
  background: #ffffff;
}

.section {
  padding: 68px 0;
}

.section.soft {
  background: linear-gradient(135deg, #f9fafb, #eef2f7);
}

.section.green {
  color: #ffffff;
  background: linear-gradient(135deg, #059669, #0f766e);
}

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

.section-line {
  display: inline-block;
  width: 5px;
  height: 32px;
  margin-right: 12px;
  vertical-align: -7px;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  border-radius: 999px;
}

.section-head h2 {
  display: inline;
  margin: 0;
  font-size: clamp(28px, 4vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.04em;
}

.section-head p {
  margin: 10px 0 0 18px;
  color: var(--muted);
}

.section.green .section-head p,
.section.green .section-more {
  color: rgba(255, 255, 255, 0.78);
}

.section-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #047857;
  font-weight: 800;
}

.grid {
  display: grid;
  gap: 22px;
}

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

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

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

.movie-card {
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.92);
  border-radius: 20px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(16, 185, 129, 0.26);
  box-shadow: var(--shadow);
}

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, #d1fae5, #cffafe);
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s ease;
}

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

.quality-badge,
.rank-number,
.compact-rank,
.hot-score {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.68);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.quality-badge {
  top: 12px;
  right: 12px;
  padding: 4px 9px;
}

.rank-number,
.compact-rank {
  top: 12px;
  left: 12px;
  min-width: 34px;
  height: 28px;
  background: linear-gradient(135deg, #f97316, #ef4444);
}

.play-bubble {
  position: absolute;
  left: 50%;
  top: 50%;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  color: #059669;
  background: rgba(255, 255, 255, 0.94);
  border-radius: 999px;
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.82);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
  padding: 17px;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.card-meta a {
  color: #047857;
}

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

.movie-card h3 a:hover {
  color: #059669;
}

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

.movie-card.horizontal {
  display: grid;
  grid-template-columns: 205px 1fr;
}

.movie-card.horizontal .card-cover {
  height: 100%;
  aspect-ratio: auto;
}

.movie-card.large .card-cover {
  aspect-ratio: 16 / 10;
}

.movie-card.large .card-body {
  padding: 22px;
}

.movie-card.large h3 {
  font-size: 23px;
}

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

.category-panel {
  position: relative;
  min-height: 190px;
  overflow: hidden;
  color: #ffffff;
  background: #064e3b;
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
}

.category-panel img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.55;
  transition: transform 0.55s ease;
}

.category-panel::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.74));
}

.category-panel span,
.category-panel strong,
.category-panel em {
  position: relative;
  z-index: 2;
}

.category-panel strong {
  display: block;
  padding: 92px 18px 0;
  font-size: 23px;
  line-height: 1.2;
}

.category-panel span,
.category-panel em {
  display: block;
  padding: 6px 18px 0;
  color: rgba(255, 255, 255, 0.85);
  font-size: 13px;
  font-style: normal;
}

.page-hero {
  padding: 72px 0;
  color: #ffffff;
  background:
    radial-gradient(circle at 82% 12%, rgba(6, 182, 212, 0.38), transparent 32%),
    linear-gradient(135deg, #059669, #0f766e 54%, #155e75);
}

.page-hero h1 {
  margin: 18px 0 12px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

.page-hero p {
  max-width: 760px;
  margin: 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: 18px;
}

.filter-bar {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 12px;
  padding: 18px;
  margin: -34px auto 34px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 22px;
  box-shadow: var(--shadow);
}

.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  color: #111827;
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
  border-color: rgba(16, 185, 129, 0.7);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.empty-state {
  display: none;
  padding: 44px;
  color: var(--muted);
  text-align: center;
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 22px;
}

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

.compact-card {
  display: grid;
  grid-template-columns: 155px 1fr;
  gap: 16px;
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.92);
  border-radius: 18px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.compact-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.compact-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #d1fae5;
}

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

.compact-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding: 12px 16px 12px 0;
}

.compact-info strong {
  overflow: hidden;
  font-size: 17px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-info em {
  margin: 5px 0;
  color: #047857;
  font-size: 13px;
  font-style: normal;
  font-weight: 750;
}

.compact-info span:last-child {
  display: -webkit-box;
  overflow: hidden;
  color: #4b5563;
  font-size: 13px;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.player-wrap {
  background: #000000;
}

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

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

.player-frame video {
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-cover-button {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  padding: 0;
  overflow: hidden;
  border: 0;
  background: #000000;
}

.player-cover-button img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.72;
}

.player-cover-button.hidden {
  display: none;
}

.player-play {
  position: absolute;
  display: grid;
  place-items: center;
  width: 88px;
  height: 88px;
  color: #047857;
  background: rgba(255, 255, 255, 0.94);
  border-radius: 999px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
  font-size: 34px;
  transform: scale(1);
  transition: transform 0.25s ease;
}

.player-cover-button:hover .player-play {
  transform: scale(1.08);
}

.player-message {
  position: absolute;
  left: 50%;
  bottom: 22px;
  z-index: 7;
  display: none;
  max-width: min(520px, calc(100% - 32px));
  padding: 12px 16px;
  color: #ffffff;
  background: rgba(220, 38, 38, 0.92);
  border-radius: 14px;
  transform: translateX(-50%);
}

.detail-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 28px;
  padding: 38px 0 72px;
}

.detail-main,
.detail-side,
.content-card {
  background: #ffffff;
  border: 1px solid rgba(229, 231, 235, 0.9);
  border-radius: 22px;
  box-shadow: var(--shadow-soft);
}

.detail-main {
  padding: 30px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: #6b7280;
  font-size: 14px;
}

.breadcrumb a {
  color: #047857;
  font-weight: 700;
}

.detail-main h1 {
  margin: 0 0 16px;
  font-size: clamp(30px, 5vw, 48px);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.detail-intro {
  margin: 0 0 22px;
  color: #374151;
  font-size: 18px;
}

.meta-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding-bottom: 24px;
  margin-bottom: 28px;
  border-bottom: 1px solid #e5e7eb;
}

.article-block {
  margin: 0 0 28px;
}

.article-block h2 {
  margin: 0 0 12px;
  font-size: 25px;
  line-height: 1.25;
}

.article-block p {
  margin: 0;
  color: #374151;
}

.review-box {
  padding: 22px;
  background: linear-gradient(135deg, #ecfdf5, #f0fdfa);
  border: 1px solid #bbf7d0;
  border-radius: 18px;
}

.detail-side {
  position: sticky;
  top: 96px;
  align-self: start;
  padding: 20px;
}

.detail-side h2,
.related-section h2 {
  margin: 0 0 18px;
  font-size: 22px;
}

.side-poster {
  overflow: hidden;
  margin-bottom: 16px;
  border-radius: 16px;
}

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

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

.side-list a {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid #f1f5f9;
  color: #374151;
}

.side-list strong {
  color: #111827;
}

.related-section {
  margin-top: 28px;
}

.site-footer {
  color: #d1fae5;
  background: #042f2e;
}

.footer-shell {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  padding: 42px 0 28px;
}

.footer-logo {
  color: #ffffff;
  font-size: 22px;
}

.site-footer p {
  max-width: 520px;
  margin: 12px 0 0;
  color: rgba(209, 250, 229, 0.72);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
  max-width: 430px;
}

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

.footer-copy {
  width: min(1180px, calc(100% - 32px));
  padding: 16px 0 28px;
  margin: 0 auto;
  color: rgba(209, 250, 229, 0.62);
  border-top: 1px solid rgba(209, 250, 229, 0.16);
}

@media (max-width: 1040px) {
  .grid.cards,
  .grid.three,
  .category-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

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

  .detail-side {
    position: static;
  }
}

@media (max-width: 760px) {
  .menu-toggle {
    display: block;
  }

  .nav-links {
    position: absolute;
    top: 72px;
    left: 16px;
    right: 16px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    box-shadow: var(--shadow);
  }

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

  .hero-carousel,
  .hero-content {
    min-height: 650px;
  }

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

  .hero-arrow {
    display: none;
  }

  .hero-search {
    flex-direction: column;
  }

  .hero-search button {
    width: 100%;
  }

  .section {
    padding: 48px 0;
  }

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

  .grid.cards,
  .grid.three,
  .grid.two,
  .category-strip,
  .compact-list {
    grid-template-columns: 1fr;
  }

  .movie-card.horizontal,
  .compact-card {
    grid-template-columns: 1fr;
  }

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

  .detail-main {
    padding: 22px;
  }

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

  .footer-links {
    justify-content: flex-start;
  }
}
