:root {
  --bg: #f7fbfb;
  --surface: #ffffff;
  --surface-soft: #ecfeff;
  --text: #0f172a;
  --muted: #64748b;
  --line: #dbeafe;
  --brand: #0f766e;
  --brand-strong: #0e7490;
  --brand-soft: #ccfbf1;
  --gold: #f59e0b;
  --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(15, 118, 110, 0.92);
  color: #ffffff;
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.16);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-logo,
.footer-logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  letter-spacing: 0.02em;
  font-size: 22px;
}

.logo-mark {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: linear-gradient(135deg, #14b8a6, #2563eb);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28), 0 12px 26px rgba(8, 47, 73, 0.26);
}

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

.site-nav a {
  padding: 10px 15px;
  border-radius: 999px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.88);
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  border: 0;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border-radius: 12px;
  padding: 9px 12px;
  font-size: 22px;
}

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

.hero {
  position: relative;
  overflow: hidden;
  min-height: 620px;
  color: #ffffff;
  background: #0f172a;
}

.hero-slide {
  min-height: 620px;
  display: none;
  align-items: center;
  background-image: linear-gradient(90deg, rgba(8, 47, 73, 0.96) 0%, rgba(15, 118, 110, 0.78) 48%, rgba(15, 23, 42, 0.58) 100%), var(--hero-image);
  background-size: cover;
  background-position: center;
}

.hero-slide.is-active {
  display: flex;
}

.hero-content {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 72px 0 92px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) 340px;
  align-items: center;
  gap: 48px;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(204, 251, 241, 0.18);
  border: 1px solid rgba(204, 251, 241, 0.32);
  color: #ccfbf1;
  font-weight: 800;
}

.hero h1 {
  margin: 18px 0 18px;
  max-width: 780px;
  font-size: clamp(40px, 7vw, 82px);
  line-height: 0.98;
  letter-spacing: -0.05em;
  font-weight: 950;
}

.hero p {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.86);
  font-size: 19px;
  line-height: 1.85;
}

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

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

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

.btn-primary {
  color: #0f172a;
  background: #ffffff;
  box-shadow: 0 16px 32px rgba(255, 255, 255, 0.2);
}

.btn-ghost {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.12);
}

.hero-card {
  overflow: hidden;
  border-radius: 28px;
  background: rgba(15, 23, 42, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.34);
}

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

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

.hero-card-body strong {
  display: block;
  font-size: 21px;
}

.hero-card-body span {
  display: block;
  margin-top: 6px;
  color: #ccfbf1;
}

.hero-dots {
  position: absolute;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.hero-dots button {
  width: 42px;
  height: 6px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.4);
}

.hero-dots button.is-active {
  background: #ffffff;
}

.hero-search {
  margin-top: 26px;
  display: flex;
  max-width: 680px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.24);
}

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

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

.hero-search button {
  border: 0;
  border-radius: 999px;
  background: #ffffff;
  color: #0f766e;
  padding: 12px 22px;
  font-weight: 900;
}

.section {
  padding: 64px 0 0;
}

.section-head,
.page-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.section-title,
.page-title h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.12;
  font-weight: 950;
  letter-spacing: -0.035em;
}

.section-desc,
.page-title p {
  color: var(--muted);
  line-height: 1.8;
  margin: 10px 0 0;
}

.more-link {
  color: var(--brand);
  font-weight: 900;
}

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

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

.movie-card {
  overflow: hidden;
  border-radius: 22px;
  background: var(--surface);
  border: 1px solid rgba(14, 116, 144, 0.12);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.poster {
  position: relative;
  display: block;
  background: linear-gradient(135deg, #ccfbf1, #dbeafe);
}

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

.poster-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(15, 23, 42, 0.74));
}

.year-badge,
.rank-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(15, 118, 110, 0.92);
  color: #ffffff;
  font-size: 12px;
  font-weight: 900;
}

.rank-badge {
  left: auto;
  right: 12px;
  background: rgba(245, 158, 11, 0.95);
}

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

.card-meta,
.detail-meta,
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.card-meta span,
.detail-meta span,
.breadcrumb a,
.breadcrumb span {
  padding: 5px 9px;
  border-radius: 999px;
  background: #f1f5f9;
}

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

.movie-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  font-size: 14px;
}

.mini-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 12px;
}

.mini-tags span,
.tag-list span {
  color: #0f766e;
  background: #ccfbf1;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 12px;
  font-weight: 800;
}

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

.category-card {
  position: relative;
  min-height: 160px;
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(135deg, #0f766e, #2563eb);
  color: #ffffff;
  box-shadow: var(--shadow);
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.36;
}

.category-card div {
  position: relative;
  z-index: 1;
  padding: 24px;
}

.category-card h3 {
  margin: 0;
  font-size: 24px;
  font-weight: 950;
}

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

.rank-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.rank-box {
  border-radius: 24px;
  background: var(--surface);
  border: 1px solid rgba(14, 116, 144, 0.12);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  padding: 20px;
}

.rank-box h3 {
  margin: 0 0 14px;
  font-size: 22px;
  font-weight: 950;
}

.rank-row {
  display: grid;
  grid-template-columns: 48px 1fr 52px;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-top: 1px solid #eef2f7;
}

.rank-row:first-of-type {
  border-top: 0;
}

.rank-row strong {
  color: var(--brand);
}

.rank-row span {
  font-weight: 800;
}

.rank-row em {
  color: var(--gold);
  font-style: normal;
  font-weight: 950;
  text-align: right;
}

.page-hero {
  padding: 56px 0 28px;
  background: linear-gradient(135deg, rgba(204, 251, 241, 0.9), rgba(219, 234, 254, 0.72));
}

.filter-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px 190px;
  gap: 12px;
  margin: 28px 0 28px;
  padding: 14px;
  border-radius: 22px;
  background: var(--surface);
  border: 1px solid rgba(14, 116, 144, 0.14);
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.filter-panel input,
.filter-panel select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #dbeafe;
  border-radius: 16px;
  outline: 0;
  padding: 0 14px;
  color: var(--text);
  background: #ffffff;
}

.detail-hero {
  padding: 42px 0 20px;
}

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) 360px;
  gap: 32px;
  align-items: start;
}

.player-shell {
  overflow: hidden;
  border-radius: 28px;
  background: #020617;
  box-shadow: var(--shadow);
}

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

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

.player-cover {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: linear-gradient(135deg, rgba(2, 6, 23, 0.72), rgba(15, 118, 110, 0.45)), var(--poster);
  background-size: cover;
  background-position: center;
  cursor: pointer;
  z-index: 2;
}

.player-shell.is-playing .player-cover {
  opacity: 0;
  pointer-events: none;
}

.play-button {
  width: 92px;
  height: 92px;
  border: 0;
  border-radius: 999px;
  color: #0f766e;
  background: rgba(255, 255, 255, 0.92);
  font-size: 36px;
  box-shadow: 0 22px 56px rgba(0, 0, 0, 0.32);
}

.player-caption {
  padding: 18px 20px 20px;
  color: #ffffff;
}

.player-caption h1 {
  margin: 0;
  font-size: clamp(28px, 5vw, 46px);
  line-height: 1.12;
  font-weight: 950;
}

.player-caption p {
  margin: 12px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.8;
}

.detail-side {
  border-radius: 28px;
  background: var(--surface);
  border: 1px solid rgba(14, 116, 144, 0.12);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

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

.detail-side-body {
  padding: 20px;
}

.detail-section {
  margin-top: 32px;
  padding: 28px;
  border-radius: 28px;
  background: var(--surface);
  border: 1px solid rgba(14, 116, 144, 0.12);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.detail-section h2 {
  margin: 0 0 14px;
  font-size: 26px;
  font-weight: 950;
}

.detail-section p {
  color: #334155;
  line-height: 1.95;
  font-size: 17px;
}

.site-footer {
  margin-top: 72px;
  padding: 42px 0 26px;
  color: #d1fae5;
  background: #0f172a;
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 32px;
}

.footer-inner p {
  color: #94a3b8;
  line-height: 1.8;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

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

.copyright {
  width: min(1180px, calc(100% - 32px));
  margin: 24px auto 0;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #94a3b8;
  text-align: center;
}

.empty-state {
  display: none;
  padding: 36px;
  border-radius: 24px;
  background: #ffffff;
  color: var(--muted);
  text-align: center;
  border: 1px solid #dbeafe;
}

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

@media (max-width: 980px) {
  .hero-content,
  .detail-layout,
  .footer-inner,
  .rank-panel {
    grid-template-columns: 1fr;
  }

  .hero-card {
    max-width: 360px;
  }

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

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

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

@media (max-width: 720px) {
  .header-inner {
    min-height: 64px;
  }

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

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 14px;
    border-radius: 18px;
    background: rgba(15, 118, 110, 0.98);
  }

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

  .site-nav a {
    display: block;
  }

  .hero,
  .hero-slide {
    min-height: 720px;
  }

  .hero-content {
    padding: 44px 0 84px;
  }

  .hero-search {
    border-radius: 24px;
    flex-direction: column;
  }

  .hero-search input {
    min-height: 46px;
  }

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

  .section-head,
  .page-title-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .detail-section {
    padding: 22px;
  }
}
