:root {
  color-scheme: light;
  --bg-start: #fffbeb;
  --bg-mid: #fff7ed;
  --bg-end: #fef3c7;
  --text: #1f2937;
  --muted: #6b7280;
  --soft: #f9fafb;
  --white: #ffffff;
  --amber: #d97706;
  --amber-dark: #92400e;
  --amber-soft: #fef3c7;
  --blue: #2563eb;
  --red: #ef4444;
  --border: #fde68a;
  --shadow: 0 20px 45px rgba(146, 64, 14, 0.12);
  --shadow-strong: 0 26px 70px rgba(31, 41, 55, 0.24);
  --radius: 24px;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: linear-gradient(135deg, var(--bg-start), var(--bg-mid) 52%, var(--bg-end));
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

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

.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;
}

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

.brand-text {
  font-size: clamp(21px, 2.6vw, 28px);
  letter-spacing: -0.04em;
}

.brand-icon {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: white;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
  border-radius: 12px;
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.24);
}

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

.nav-link,
.mobile-link {
  font-weight: 700;
  color: #374151;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

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

.menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: var(--amber-soft);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  width: 22px;
  height: 2px;
  background: var(--amber-dark);
  border-radius: 999px;
}

.mobile-nav {
  display: none;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 0 0 14px;
}

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

.mobile-link {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(254, 243, 199, 0.55);
}

main {
  min-height: 60vh;
}

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

.hero {
  position: relative;
  padding: 30px 0 48px;
}

.hero-stage {
  position: relative;
  min-height: 560px;
  overflow: hidden;
  border-radius: 36px;
  background: #111827;
  box-shadow: var(--shadow-strong);
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(300px, 0.76fr);
  align-items: center;
  gap: 36px;
  padding: clamp(28px, 5vw, 70px);
  opacity: 0;
  pointer-events: none;
  transform: scale(1.03);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.28;
  filter: saturate(1.05) contrast(1.08);
}

.hero-slide::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 78% 30%, rgba(245, 158, 11, 0.35), transparent 36%),
    linear-gradient(100deg, rgba(17, 24, 39, 0.92), rgba(120, 53, 15, 0.74) 52%, rgba(17, 24, 39, 0.72));
}

.hero-copy,
.hero-art {
  position: relative;
  z-index: 2;
}

.hero-kicker,
.page-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  color: #fde68a;
  border: 1px solid rgba(253, 230, 138, 0.42);
  background: rgba(255, 255, 255, 0.1);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 800;
  backdrop-filter: blur(12px);
}

.hero h1 {
  margin: 22px 0 18px;
  max-width: 760px;
  color: #fff7ed;
  font-size: clamp(42px, 7vw, 76px);
  line-height: 0.96;
  letter-spacing: -0.065em;
}

.hero-lead {
  max-width: 700px;
  color: #ffedd5;
  font-size: clamp(17px, 2.3vw, 22px);
  line-height: 1.75;
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0;
}

.hero-tags span,
.tag-list span,
.card-badges span,
.detail-chip,
.poster-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 12px;
}

.hero-tags span {
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 26px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border-radius: 999px;
  border: 0;
  font-weight: 900;
  box-shadow: 0 12px 22px rgba(146, 64, 14, 0.16);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 28px rgba(146, 64, 14, 0.22);
}

.btn.primary {
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #ea580c);
}

.btn.light {
  color: #fff7ed;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.12);
}

.btn.ghost {
  color: var(--amber-dark);
  background: #fff7ed;
}

.hero-art-card {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
}

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

.hero-art-caption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  padding: 16px;
  color: #fff7ed;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.2), rgba(17, 24, 39, 0.82));
  border-radius: 20px;
}

.hero-art-caption strong {
  display: block;
  font-size: 20px;
}

.hero-search {
  position: absolute;
  left: clamp(24px, 5vw, 70px);
  right: clamp(24px, 5vw, 70px);
  bottom: 28px;
  z-index: 3;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  backdrop-filter: blur(16px);
}

.hero-search input {
  width: 100%;
  border: 0;
  outline: 0;
  color: #fff;
  background: transparent;
  padding: 0 16px;
}

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

.hero-controls {
  position: absolute;
  right: 24px;
  top: 24px;
  z-index: 5;
  display: flex;
  gap: 8px;
}

.hero-control,
.hero-dot {
  border: 0;
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px);
}

.hero-control {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 22px;
}

.hero-dots {
  position: absolute;
  left: clamp(24px, 5vw, 70px);
  bottom: 96px;
  z-index: 5;
  display: flex;
  gap: 8px;
}

.hero-dot {
  width: 34px;
  height: 8px;
  padding: 0;
  border-radius: 999px;
  opacity: 0.6;
}

.hero-dot.is-active {
  opacity: 1;
  background: #f59e0b;
}

.section {
  padding: 34px 0;
}

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

.section-title {
  margin: 0;
  font-size: clamp(26px, 4vw, 38px);
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.section-desc {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.75;
}

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

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

.movie-list {
  display: grid;
  gap: 18px;
}

.movie-card {
  overflow: hidden;
  border-radius: 24px;
  background: var(--white);
  box-shadow: var(--shadow);
  transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 48px rgba(146, 64, 14, 0.2);
}

.movie-poster,
.movie-thumb {
  position: relative;
  display: block;
  overflow: hidden;
  background: #f3f4f6;
}

.movie-poster {
  aspect-ratio: 3 / 4;
}

.movie-poster img,
.movie-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

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

.poster-pill {
  position: absolute;
  right: 12px;
  color: var(--amber-dark);
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.16);
}

.poster-pill.top {
  top: 12px;
}

.poster-pill.bottom {
  bottom: 12px;
  color: #1d4ed8;
}

.movie-body,
.movie-info {
  padding: 18px;
}

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

.movie-card h3 a:hover {
  color: var(--amber);
}

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

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

.card-meta span {
  min-width: 0;
}

.card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.card-badges span,
.tag-list span,
.detail-chip {
  color: var(--amber-dark);
  background: var(--amber-soft);
}

.movie-card.horizontal {
  display: grid;
  grid-template-columns: 148px minmax(0, 1fr);
  gap: 0;
}

.movie-card.horizontal .movie-thumb {
  height: 100%;
  min-height: 180px;
}

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

.category-card {
  min-height: 210px;
  padding: 24px;
  border-radius: 26px;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.95), rgba(254, 243, 199, 0.72));
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 48px rgba(146, 64, 14, 0.18);
}

.category-card strong {
  display: block;
  margin-bottom: 10px;
  font-size: 22px;
  color: var(--amber-dark);
}

.category-card p {
  margin: 0 0 16px;
  color: var(--muted);
  line-height: 1.65;
}

.category-card em {
  color: var(--amber);
  font-style: normal;
  font-weight: 800;
}

.rank-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
}

.rank-panel,
.side-panel,
.filter-panel,
.info-panel,
.player-panel,
.story-panel {
  border-radius: 28px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.rank-panel,
.side-panel,
.info-panel,
.story-panel {
  padding: 24px;
}

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

.compact-item {
  display: grid;
  grid-template-columns: auto 64px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 10px;
  border-radius: 18px;
  background: #fffaf0;
  transition: background 0.2s ease, transform 0.2s ease;
}

.compact-item:hover {
  background: #ffedd5;
  transform: translateX(3px);
}

.compact-item img {
  width: 64px;
  height: 84px;
  object-fit: cover;
  border-radius: 12px;
}

.compact-item strong,
.compact-item em {
  display: block;
  min-width: 0;
}

.compact-item strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-item em {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.rank-no {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: linear-gradient(135deg, #f59e0b, #ef4444);
  border-radius: 10px;
  font-weight: 900;
}

.page-hero {
  padding: 46px 0 28px;
}

.page-hero-inner {
  overflow: hidden;
  border-radius: 34px;
  padding: clamp(28px, 5vw, 58px);
  color: #fff7ed;
  background:
    radial-gradient(circle at 82% 22%, rgba(253, 186, 116, 0.36), transparent 34%),
    linear-gradient(135deg, #78350f, #111827);
  box-shadow: var(--shadow-strong);
}

.page-kicker {
  color: #fde68a;
}

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

.page-hero p {
  max-width: 780px;
  margin: 0;
  color: #ffedd5;
  font-size: 18px;
  line-height: 1.75;
}

.filter-panel {
  display: grid;
  gap: 14px;
  padding: 16px;
  margin-bottom: 24px;
}

.search-box {
  display: grid;
  gap: 8px;
  color: var(--amber-dark);
  font-weight: 900;
}

.search-box input,
.filter-select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #fed7aa;
  border-radius: 14px;
  outline: 0;
  background: #fff;
  padding: 0 14px;
}

.search-box input:focus,
.filter-select:focus {
  border-color: #f59e0b;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

.filter-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.filter-count {
  margin: 0;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb a {
  color: var(--amber-dark);
}

.detail-shell {
  padding: 32px 0 54px;
}

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

.player-panel {
  overflow: hidden;
  padding: 0;
}

.player-box {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #050505;
  border-radius: 28px 28px 0 0;
}

.player-box video {
  width: 100%;
  height: 100%;
  background: #050505;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 0;
  color: #fff;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0.64));
}

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

.play-ring {
  width: 86px;
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 255, 255, 0.76);
  border-radius: 50%;
  background: rgba(245, 158, 11, 0.82);
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.3);
}

.play-triangle {
  width: 0;
  height: 0;
  margin-left: 6px;
  border-top: 16px solid transparent;
  border-bottom: 16px solid transparent;
  border-left: 24px solid #fff;
}

.player-title {
  font-size: 18px;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.player-caption {
  padding: 24px;
}

.player-caption h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.player-caption p {
  margin: 0;
  color: var(--muted);
  line-height: 1.75;
}

.detail-title {
  position: sticky;
  top: 94px;
}

.info-panel {
  margin-bottom: 20px;
}

.detail-poster {
  overflow: hidden;
  border-radius: 22px;
  margin-bottom: 18px;
}

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

.detail-meta {
  display: grid;
  gap: 12px;
  margin: 18px 0;
}

.detail-meta div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #fde68a;
}

.detail-meta span:first-child {
  color: var(--muted);
}

.detail-meta span:last-child {
  font-weight: 900;
  text-align: right;
}

.story-panel {
  margin-top: 22px;
}

.story-panel h2,
.story-panel h3,
.side-panel h2,
.rank-panel h2,
.info-panel h2 {
  margin: 0 0 16px;
  font-size: 24px;
  letter-spacing: -0.02em;
}

.story-panel p,
.info-panel p {
  color: #374151;
  line-height: 1.85;
}

.story-panel blockquote {
  margin: 0 0 20px;
  padding: 18px 20px;
  color: var(--amber-dark);
  border-left: 4px solid #f59e0b;
  background: #fff7ed;
  border-radius: 18px;
  line-height: 1.7;
}

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

.site-footer {
  margin-top: 40px;
  color: #fffbeb;
  background: linear-gradient(135deg, #78350f, #7c2d12 58%, #111827);
}

.footer-grid {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.3fr 0.8fr 0.9fr 1fr;
  gap: 34px;
  padding: 46px 0;
}

.footer-brand {
  color: #fffbeb;
  font-size: 20px;
}

.site-footer h2 {
  margin: 0 0 14px;
  font-size: 18px;
  color: #fde68a;
}

.site-footer p,
.site-footer li {
  color: #fed7aa;
  line-height: 1.75;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer a:hover {
  color: #fff;
}

.empty-state {
  display: none;
  padding: 32px;
  text-align: center;
  color: var(--muted);
  background: #fff;
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.empty-state.show {
  display: block;
}

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

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

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

  .detail-title {
    position: static;
  }

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

@media (max-width: 820px) {
  .desktop-nav {
    display: none;
  }

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

  .hero-stage {
    min-height: 720px;
    border-radius: 28px;
  }

  .hero-slide {
    grid-template-columns: 1fr;
    align-items: start;
    gap: 22px;
    padding: 34px 24px 150px;
  }

  .hero h1 {
    margin-top: 18px;
  }

  .hero-art-card {
    max-width: 260px;
  }

  .hero-search {
    grid-template-columns: 1fr;
    border-radius: 24px;
  }

  .hero-dots {
    bottom: 124px;
  }

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

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

  .movie-card.horizontal {
    grid-template-columns: 112px minmax(0, 1fr);
  }

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

@media (max-width: 540px) {
  .header-inner,
  .section,
  .hero,
  .page-hero,
  .detail-shell,
  .footer-grid,
  .mobile-nav {
    width: min(100% - 22px, 1180px);
  }

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

  .hero-stage {
    min-height: 760px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

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

  .movie-card.horizontal {
    grid-template-columns: 100px minmax(0, 1fr);
  }

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