* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: #111827;
  background: #f8fafc;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input {
  font: inherit;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  color: #064e3b;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: #ffffff;
  border-radius: 14px;
  background: linear-gradient(135deg, #059669, #0f766e, #0891b2);
  box-shadow: 0 12px 24px rgba(5, 150, 105, 0.25);
}

.brand-text {
  font-size: 20px;
  letter-spacing: 0.02em;
}

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

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

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

.menu-toggle {
  display: none;
  border: 0;
  border-radius: 999px;
  padding: 8px 14px;
  color: #047857;
  background: #ecfdf5;
  font-weight: 700;
}

.hero {
  position: relative;
  min-height: 500px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: #ffffff;
  background: linear-gradient(135deg, #059669, #0f766e, #0891b2);
}

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  mix-blend-mode: overlay;
  opacity: 0.84;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 82% 16%, rgba(255, 255, 255, 0.16), transparent 26%),
    linear-gradient(90deg, rgba(6, 78, 59, 0.94), rgba(15, 118, 110, 0.72), rgba(8, 145, 178, 0.48));
}

.hero-content {
  position: relative;
  padding: 72px 0;
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 7px 16px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(12px);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.hero-badge.dark {
  color: #047857;
  background: #ecfdf5;
}

.hero h1,
.page-hero h1,
.detail-hero h1 {
  margin: 18px 0 16px;
  font-size: clamp(38px, 6vw, 68px);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -0.04em;
}

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

.page-hero p {
  color: #4b5563;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

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

.btn:hover {
  transform: translateY(-2px);
}

.btn-light {
  color: #047857;
  background: #ffffff;
  box-shadow: 0 18px 36px rgba(15, 23, 42, 0.18);
}

.btn-glass {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-search,
.page-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  width: min(680px, 100%);
  padding: 8px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.18);
  backdrop-filter: blur(14px);
}

.page-search {
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.hero-search input,
.page-search input,
.filter-panel input {
  width: 100%;
  border: 0;
  outline: 0;
  border-radius: 12px;
  padding: 13px 16px;
  color: #111827;
  background: #ffffff;
}

.hero-search button,
.page-search button {
  border: 0;
  border-radius: 12px;
  padding: 0 20px;
  color: #ffffff;
  background: #059669;
  font-weight: 800;
}

.search-results {
  display: none;
  width: min(760px, 100%);
  margin-top: 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  color: #111827;
  box-shadow: 0 22px 45px rgba(15, 23, 42, 0.16);
  overflow: hidden;
}

.search-results.is-visible {
  display: grid;
}

.search-hit {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  padding: 12px;
  border-bottom: 1px solid #e5e7eb;
}

.search-hit:last-child {
  border-bottom: 0;
}

.search-hit img {
  width: 64px;
  height: 82px;
  border-radius: 12px;
  object-fit: cover;
  background: linear-gradient(135deg, #0f766e, #0891b2);
}

.search-hit strong {
  display: block;
  color: #111827;
  font-size: 15px;
}

.search-hit span {
  color: #6b7280;
  font-size: 13px;
}

.section {
  padding: 64px 0;
}

.section-title {
  margin-bottom: 28px;
  text-align: center;
}

.section-title h2 {
  margin: 0 0 8px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.15;
  font-weight: 900;
  color: #111827;
}

.section-title p {
  margin: 0;
  color: #6b7280;
}

.featured-grid,
.movie-grid,
.category-grid,
.overview-grid {
  display: grid;
  gap: 24px;
}

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

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

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 22px 48px rgba(15, 23, 42, 0.14);
}

.poster {
  position: relative;
  display: block;
  height: 230px;
  overflow: hidden;
  background: linear-gradient(135deg, #064e3b, #0891b2);
}

.movie-card.is-wide .poster {
  height: 280px;
}

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

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(0, 0, 0, 0.62));
}

.poster-play {
  position: absolute;
  right: 14px;
  bottom: 14px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #047857;
  background: #ffffff;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.18);
}

.card-body {
  padding: 18px;
}

.card-meta {
  margin-bottom: 8px;
  color: #059669;
  font-size: 13px;
  font-weight: 800;
}

.movie-card h3,
.rank-content h3 {
  margin: 0 0 8px;
  color: #111827;
  font-size: 19px;
  line-height: 1.3;
  font-weight: 900;
}

.movie-card p,
.rank-content p,
.side-panel p,
.overview-card p {
  margin: 0;
  color: #6b7280;
  font-size: 14px;
}

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

.tag-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  color: #047857;
  background: #ecfdf5;
  font-size: 12px;
  font-weight: 700;
}

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

.category-card,
.overview-card {
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-radius: 24px;
  padding: 24px;
  color: #ffffff;
  background: linear-gradient(135deg, #059669, #0f766e 55%, #0891b2);
  box-shadow: 0 18px 36px rgba(5, 150, 105, 0.22);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.overview-card {
  min-height: 180px;
}

.category-card:hover,
.overview-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 48px rgba(5, 150, 105, 0.28);
}

.category-card span,
.overview-card span {
  font-size: 22px;
  font-weight: 900;
}

.category-card strong {
  font-weight: 600;
  color: rgba(255, 255, 255, 0.86);
}

.overview-card p {
  color: rgba(255, 255, 255, 0.88);
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 28px;
  align-items: start;
}

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

.rank-item {
  position: relative;
  display: grid;
  grid-template-columns: 96px 52px 1fr;
  gap: 16px;
  align-items: center;
  border-radius: 22px;
  padding: 14px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.07);
}

.rank-cover img {
  width: 96px;
  height: 126px;
  border-radius: 16px;
  object-fit: cover;
  background: linear-gradient(135deg, #0f766e, #0891b2);
}

.rank-number {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  color: #ffffff;
  background: #059669;
  font-weight: 900;
}

.text-link {
  display: inline-flex;
  margin-top: 10px;
  color: #047857;
  font-weight: 800;
}

.side-panel,
.content-card,
.info-card,
.filter-panel {
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.side-panel {
  position: sticky;
  top: 96px;
  padding: 24px;
}

.side-panel h2 {
  margin: 0 0 10px;
  font-size: 26px;
}

.compact-list {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.compact-card {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  align-items: center;
  border-radius: 18px;
  padding: 10px;
  background: #f8fafc;
}

.compact-card img {
  width: 72px;
  height: 92px;
  border-radius: 14px;
  object-fit: cover;
  background: linear-gradient(135deg, #0f766e, #0891b2);
}

.compact-card strong,
.compact-card em {
  display: block;
}

.compact-card strong {
  color: #111827;
  font-size: 15px;
}

.compact-card em {
  color: #6b7280;
  font-size: 12px;
  font-style: normal;
}

.page-hero {
  padding: 74px 0;
  background: radial-gradient(circle at 16% 20%, #d1fae5, transparent 28%), #ffffff;
}

.compact-hero {
  padding: 64px 0 48px;
}

.filter-panel {
  margin-bottom: 28px;
  padding: 14px;
}

.filter-hints {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.filter-hints span {
  border-radius: 999px;
  padding: 6px 12px;
  color: #047857;
  background: #ecfdf5;
  font-size: 13px;
  font-weight: 700;
}

.detail-hero {
  position: relative;
  color: #ffffff;
  background-size: cover;
  background-position: center;
}

.detail-hero-inner {
  min-height: 440px;
  display: flex;
  align-items: center;
  padding: 72px 0;
}

.detail-copy {
  max-width: 820px;
}

.breadcrumb {
  display: inline-flex;
  margin-bottom: 16px;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 700;
}

.detail-section {
  padding-top: 42px;
}

.player-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: 0 28px 56px rgba(2, 6, 23, 0.28);
  aspect-ratio: 16 / 9;
}

.movie-player {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #020617;
}

.play-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  color: #ffffff;
  background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.66));
  font-weight: 900;
  font-size: 18px;
}

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

.play-circle {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  color: #047857;
  background: #ffffff;
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.28);
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 28px;
  margin-top: 32px;
}

.content-card,
.info-card {
  padding: 26px;
}

.prose-card h2 {
  margin: 0 0 12px;
  font-size: 26px;
  color: #111827;
}

.prose-card p {
  margin: 0 0 24px;
  color: #374151;
  font-size: 17px;
}

.info-card img {
  width: 100%;
  border-radius: 20px;
  object-fit: cover;
  background: linear-gradient(135deg, #0f766e, #0891b2);
}

.info-card dl {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  margin: 22px 0 0;
}

.info-card dt {
  color: #6b7280;
  font-weight: 700;
}

.info-card dd {
  margin: 0;
  color: #111827;
  font-weight: 800;
}

.site-footer {
  margin-top: 36px;
  padding: 48px 0 28px;
  color: #cbd5e1;
  background: #0f172a;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 32px;
}

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

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

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

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

.footer-bottom {
  margin-top: 34px;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding-top: 22px;
  color: #94a3b8;
  font-size: 14px;
}

[data-filter-item].is-hidden {
  display: none;
}

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

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

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

  .side-panel {
    position: static;
  }
}

@media (max-width: 820px) {
  .header-inner {
    flex-wrap: wrap;
    min-height: 64px;
    padding: 10px 0;
  }

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

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

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

  .nav-link {
    border-radius: 14px;
  }

  .hero {
    min-height: 560px;
  }

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

  .featured-grid,
  .movie-grid,
  .large-grid,
  .category-grid,
  .overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .rank-item {
    grid-template-columns: 78px 42px 1fr;
  }

  .rank-cover img {
    width: 78px;
    height: 104px;
  }

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

@media (max-width: 560px) {
  .container {
    width: min(100% - 22px, 1280px);
  }

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

  .hero h1,
  .page-hero h1,
  .detail-hero h1 {
    font-size: 36px;
  }

  .hero-content,
  .detail-hero-inner {
    padding: 48px 0;
  }

  .section {
    padding: 44px 0;
  }

  .featured-grid,
  .movie-grid,
  .large-grid,
  .category-grid,
  .overview-grid {
    grid-template-columns: 1fr;
  }

  .poster,
  .movie-card.is-wide .poster {
    height: 240px;
  }

  .rank-item {
    grid-template-columns: 72px 1fr;
  }

  .rank-number {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }

  .info-card dl {
    grid-template-columns: 1fr;
  }
}
