* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  color: #3b2508;
  background: linear-gradient(180deg, #fff7ed 0%, #fffbeb 42%, #fff7ed 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
}

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, 251, 235, 0.95);
  border-bottom: 1px solid rgba(245, 158, 11, 0.22);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 30px rgba(146, 64, 14, 0.08);
}

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

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.brand-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  color: #ffffff;
  background: linear-gradient(135deg, #d97706, #f59e0b 58%, #fb923c);
  border-radius: 14px;
  box-shadow: 0 12px 24px rgba(217, 119, 6, 0.26);
  font-weight: 800;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-name {
  color: #78350f;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.brand-subtitle {
  margin-top: 4px;
  color: #b45309;
  font-size: 12px;
  white-space: nowrap;
}

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

.nav-link {
  color: #78350f;
  font-size: 15px;
  font-weight: 700;
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: #d97706;
}

.header-search {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 300px;
  padding: 4px;
  background: #ffffff;
  border: 1px solid #fcd34d;
  border-radius: 999px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.header-search input,
.mobile-search input {
  min-width: 0;
  width: 100%;
  color: #78350f;
  background: transparent;
  border: 0;
  outline: 0;
}

.header-search input {
  padding: 8px 6px 8px 14px;
}

.header-search button,
.mobile-search button {
  color: #ffffff;
  background: #d97706;
  border: 0;
  border-radius: 999px;
  transition: background 0.2s ease, transform 0.2s ease;
}

.header-search button {
  padding: 8px 15px;
}

.header-search button:hover,
.mobile-search button:hover {
  background: #b45309;
  transform: translateY(-1px);
}

.menu-toggle {
  display: none;
  padding: 8px 13px;
  color: #78350f;
  background: #fff7ed;
  border: 1px solid #fcd34d;
  border-radius: 999px;
}

.mobile-panel {
  display: none;
  padding: 0 20px 18px;
  border-top: 1px solid #fde68a;
}

.mobile-panel.is-open {
  display: block;
}

.mobile-search {
  display: flex;
  gap: 8px;
  margin: 14px auto;
  width: min(100%, 520px);
  padding: 5px;
  background: #ffffff;
  border: 1px solid #fcd34d;
  border-radius: 16px;
}

.mobile-search input {
  padding: 10px 12px;
}

.mobile-search button {
  padding: 8px 15px;
}

.mobile-link {
  display: block;
  width: min(100%, 520px);
  margin: 4px auto;
  padding: 10px 12px;
  color: #78350f;
  border-radius: 12px;
}

.mobile-link:hover,
.mobile-link.is-active {
  color: #b45309;
  background: #ffedd5;
}

.hero {
  position: relative;
  min-height: 600px;
  overflow: hidden;
  background: #1c1004;
}

.hero-track,
.hero-slide,
.hero-media,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-slide {
  opacity: 0;
  transition: opacity 0.65s ease;
}

.hero-slide.is-active {
  opacity: 1;
}

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

.hero-shade {
  background:
    radial-gradient(circle at 78% 26%, rgba(251, 191, 36, 0.25), transparent 32%),
    linear-gradient(90deg, rgba(92, 38, 8, 0.94) 0%, rgba(120, 53, 15, 0.74) 42%, rgba(120, 53, 15, 0.18) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  min-height: 600px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.hero-copy {
  width: min(680px, 100%);
  color: #ffffff;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  padding: 8px 14px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(253, 230, 138, 0.34);
  border-radius: 999px;
  backdrop-filter: blur(8px);
}

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

.hero p {
  margin: 0 0 30px;
  max-width: 620px;
  color: #ffedd5;
  font-size: clamp(17px, 2.2vw, 22px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 26px;
}

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

.btn-primary {
  color: #ffffff;
  background: #d97706;
  box-shadow: 0 18px 36px rgba(217, 119, 6, 0.32);
}

.btn-secondary {
  color: #fffbeb;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(253, 230, 138, 0.36);
}

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

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-tags a,
.hero-tags span {
  display: inline-flex;
  padding: 7px 12px;
  color: #fde68a;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(253, 230, 138, 0.22);
  border-radius: 999px;
  font-size: 14px;
}

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

.hero-dot {
  width: 12px;
  height: 12px;
  padding: 0;
  background: rgba(255, 255, 255, 0.48);
  border: 0;
  border-radius: 999px;
}

.hero-dot.is-active {
  width: 34px;
  background: #fbbf24;
}

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

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

.section-title {
  margin: 0;
  color: #78350f;
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.2;
}

.section-desc {
  margin: 8px 0 0;
  color: #92400e;
}

.section-more {
  color: #b45309;
  font-weight: 800;
}

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

.category-tile {
  position: relative;
  display: block;
  min-height: 176px;
  overflow: hidden;
  background: #78350f;
  border-radius: 22px;
  box-shadow: 0 18px 35px rgba(146, 64, 14, 0.12);
}

.category-tile img {
  width: 100%;
  height: 100%;
  min-height: 176px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.category-tile:hover img {
  transform: scale(1.08);
}

.tile-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(92, 38, 8, 0.88));
}

.tile-text {
  position: absolute;
  right: 18px;
  bottom: 18px;
  left: 18px;
  color: #ffffff;
}

.tile-text strong {
  display: block;
  margin-bottom: 5px;
  font-size: 21px;
}

.tile-text em {
  color: #fde68a;
  font-size: 13px;
  font-style: normal;
}

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

.movie-card {
  overflow: hidden;
  background: #ffffff;
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 20px;
  box-shadow: 0 14px 36px rgba(146, 64, 14, 0.09);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card-cover {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #fef3c7;
}

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

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

.card-duration,
.card-score {
  position: absolute;
  right: 12px;
  display: inline-flex;
  padding: 4px 8px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 700;
}

.card-duration {
  bottom: 10px;
}

.card-score {
  top: 10px;
  color: #451a03;
  background: #fbbf24;
}

.card-body {
  padding: 17px;
}

.card-category {
  display: inline-flex;
  margin-bottom: 10px;
  padding: 4px 9px;
  color: #b45309;
  background: #ffedd5;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.card-body h3 {
  display: -webkit-box;
  min-height: 48px;
  margin: 0 0 8px;
  overflow: hidden;
  color: #78350f;
  font-size: 17px;
  line-height: 1.4;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-body h3 a:hover {
  color: #d97706;
}

.card-body p {
  display: -webkit-box;
  min-height: 44px;
  margin: 0 0 14px;
  overflow: hidden;
  color: #92400e;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  color: #b45309;
  font-size: 12px;
}

.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.card-tags span {
  padding: 3px 7px;
  color: #92400e;
  background: #fef3c7;
  border-radius: 999px;
  font-size: 11px;
}

.ranking-layout {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: 28px;
}

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

.rank-item {
  display: grid;
  grid-template-columns: 58px 132px 1fr;
  gap: 16px;
  align-items: center;
  padding: 14px;
  background: #ffffff;
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 18px;
  box-shadow: 0 12px 30px rgba(146, 64, 14, 0.07);
}

.rank-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: #ffffff;
  background: linear-gradient(135deg, #d97706, #fbbf24);
  border-radius: 14px;
  font-weight: 900;
}

.rank-poster {
  overflow: hidden;
  border-radius: 14px;
}

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

.rank-info h3 {
  margin: 0 0 6px;
  color: #78350f;
  font-size: 18px;
}

.rank-info p {
  margin: 0 0 8px;
  color: #92400e;
}

.rank-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: #b45309;
  font-size: 13px;
}

.compact-panel {
  position: sticky;
  top: 94px;
  align-self: start;
  padding: 22px;
  background: linear-gradient(180deg, #ffffff, #fff7ed);
  border: 1px solid rgba(245, 158, 11, 0.18);
  border-radius: 22px;
  box-shadow: 0 16px 36px rgba(146, 64, 14, 0.1);
}

.compact-panel h2 {
  margin: 0 0 16px;
  color: #78350f;
}

.compact-card {
  display: grid;
  grid-template-columns: 92px 1fr;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.compact-card img {
  width: 92px;
  height: 58px;
  object-fit: cover;
  border-radius: 12px;
}

.compact-card strong {
  display: -webkit-box;
  overflow: hidden;
  color: #78350f;
  font-size: 14px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.compact-card em {
  display: block;
  margin-top: 4px;
  color: #b45309;
  font-size: 12px;
  font-style: normal;
}

.page-hero {
  background:
    radial-gradient(circle at 75% 25%, rgba(251, 191, 36, 0.28), transparent 32%),
    linear-gradient(135deg, #fef3c7 0%, #ffedd5 52%, #fde68a 100%);
  border-bottom: 1px solid rgba(245, 158, 11, 0.2);
}

.page-hero-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 62px 0;
}

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

.page-hero h1,
.detail-title h1 {
  margin: 0;
  color: #78350f;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.12;
}

.page-hero p {
  max-width: 720px;
  margin: 16px 0 0;
  color: #92400e;
  font-size: 18px;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 24px;
  padding: 16px;
  background: #ffffff;
  border: 1px solid rgba(245, 158, 11, 0.17);
  border-radius: 18px;
  box-shadow: 0 12px 28px rgba(146, 64, 14, 0.07);
}

.filter-input {
  flex: 1 1 260px;
  min-width: 0;
  padding: 12px 15px;
  color: #78350f;
  background: #fffbeb;
  border: 1px solid #fcd34d;
  border-radius: 14px;
  outline: 0;
}

.sort-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sort-buttons button {
  padding: 10px 13px;
  color: #92400e;
  background: #fff7ed;
  border: 1px solid #fcd34d;
  border-radius: 999px;
}

.sort-buttons button.is-active {
  color: #ffffff;
  background: #d97706;
}

.detail-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 28px;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 36px 0 56px;
}

.detail-main,
.detail-side {
  min-width: 0;
}

.player-shell {
  position: relative;
  overflow: hidden;
  background: #000000;
  border-radius: 24px;
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.28);
}

.player-shell video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000000;
}

.player-center-button {
  position: absolute;
  inset: 50% auto auto 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  color: #ffffff;
  background: rgba(217, 119, 6, 0.92);
  border: 0;
  border-radius: 999px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
  transform: translate(-50%, -50%);
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.player-center-button span {
  margin-left: 4px;
  font-size: 30px;
}

.player-shell.is-playing .player-center-button {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -50%) scale(0.92);
}

.player-controls {
  position: absolute;
  right: 18px;
  bottom: 18px;
  left: 18px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.74), rgba(0, 0, 0, 0.38));
  border-radius: 16px;
  opacity: 1;
}

.player-control-group {
  display: flex;
  gap: 10px;
}

.player-controls button {
  padding: 8px 12px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
}

.detail-card,
.side-card {
  margin-top: 24px;
  padding: 24px;
  background: #ffffff;
  border: 1px solid rgba(245, 158, 11, 0.16);
  border-radius: 24px;
  box-shadow: 0 16px 38px rgba(146, 64, 14, 0.09);
}

.detail-card h2,
.side-card h2 {
  margin: 0 0 16px;
  color: #78350f;
  font-size: 24px;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.detail-meta span,
.detail-tags a {
  display: inline-flex;
  padding: 7px 11px;
  color: #92400e;
  background: #ffedd5;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.detail-card p {
  margin: 0 0 14px;
  color: #78350f;
}

.detail-card .lead {
  color: #92400e;
  font-size: 18px;
  font-weight: 700;
}

.search-page .movie-card.is-hidden,
.category-page .movie-card.is-hidden {
  display: none;
}

.empty-state {
  display: none;
  padding: 46px 20px;
  color: #92400e;
  text-align: center;
}

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

.site-footer {
  margin-top: 40px;
  background: linear-gradient(180deg, #fffbeb, #ffedd5);
  border-top: 1px solid rgba(245, 158, 11, 0.22);
}

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

.footer-brand p {
  max-width: 480px;
  margin: 14px 0 0;
  color: #92400e;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: #92400e;
  font-weight: 700;
}

.footer-meta {
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: #92400e;
}

@media (max-width: 1024px) {
  .desktop-nav,
  .header-search {
    display: none;
  }

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

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

  .ranking-layout,
  .detail-wrap,
  .footer-inner {
    grid-template-columns: 1fr;
  }

  .compact-panel,
  .detail-side .side-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .header-inner {
    width: min(100% - 24px, 1180px);
    height: 64px;
  }

  .brand-name {
    font-size: 17px;
  }

  .brand-subtitle {
    display: none;
  }

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

  .hero-content,
  .section,
  .page-section,
  .page-hero-inner,
  .detail-wrap,
  .footer-inner {
    width: min(100% - 24px, 1180px);
  }

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

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

  .card-body {
    padding: 13px;
  }

  .card-body h3 {
    font-size: 15px;
  }

  .rank-item {
    grid-template-columns: 44px 96px 1fr;
    gap: 10px;
    padding: 10px;
  }

  .rank-info p {
    display: none;
  }

  .player-controls {
    right: 10px;
    bottom: 10px;
    left: 10px;
    padding: 8px;
  }

  .player-controls button {
    padding: 7px 9px;
    font-size: 13px;
  }
}

@media (max-width: 430px) {
  .category-grid,
  .movie-grid {
    grid-template-columns: 1fr;
  }

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

  .rank-poster {
    display: none;
  }
}
