:root {
  --bg: #fff7ed;
  --surface: #ffffff;
  --surface-soft: #fff1f2;
  --text: #111827;
  --muted: #6b7280;
  --line: #fed7aa;
  --primary: #e11d48;
  --primary-dark: #be123c;
  --accent: #ea580c;
  --shadow: 0 18px 45px rgba(190, 18, 60, 0.16);
  --radius: 24px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans SC", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fff7ed 0%, #ffffff 38%, #fff7ed 100%);
}

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

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

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

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

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

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 10px 28px rgba(225, 29, 72, 0.28);
}

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

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

.nav-link {
  padding: 10px 16px;
  border-radius: 999px;
  color: #4b5563;
  font-weight: 700;
  transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 10px 24px rgba(225, 29, 72, 0.18);
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 14px;
  background: #fff1f2;
}

.menu-button span {
  display: block;
  width: 22px;
  height: 2px;
  margin: 5px auto;
  background: var(--primary);
  border-radius: 999px;
}

.hero {
  position: relative;
  height: 600px;
  overflow: hidden;
  background: #111827;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
}

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

.hero-image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(190, 18, 60, 0.94) 0%, rgba(234, 88, 12, 0.82) 48%, rgba(17, 24, 39, 0.36) 100%);
}

.hero::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 140px;
  background: linear-gradient(0deg, var(--bg), rgba(255, 247, 237, 0));
  z-index: 3;
}

.hero-content {
  position: relative;
  z-index: 4;
  width: min(1180px, calc(100% - 32px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #ffffff;
  max-width: 1180px;
}

.hero-content h1 {
  margin: 0;
  max-width: 760px;
  font-size: clamp(38px, 6vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.05em;
  font-weight: 950;
}

.hero-content h1 em {
  color: #ffe4e6;
  font-style: normal;
}

.hero-content p {
  width: min(650px, 100%);
  margin: 24px 0 0;
  font-size: 20px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.9);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.26);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

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

.hero-tags {
  margin-top: 22px;
}

.hero-tags span,
.tag-row span,
.tag-cloud a {
  border-radius: 999px;
  background: #fff1f2;
  color: var(--primary);
  font-size: 12px;
  font-weight: 800;
}

.hero-tags span {
  padding: 7px 12px;
  color: #ffffff;
  background: rgba(255, 255, 255, 0.2);
}

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

.primary-button,
.ghost-button,
.search-box button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  border: 0;
  font-weight: 900;
  cursor: pointer;
  transition: 0.2s ease;
}

.primary-button {
  color: var(--primary);
  background: #ffffff;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.18);
}

.primary-button:hover,
.ghost-button:hover,
.search-box button:hover {
  transform: translateY(-2px) scale(1.02);
}

.ghost-button {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.32);
}

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

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

.hero-dot.active {
  width: 36px;
  background: #ffffff;
}

.search-panel {
  position: relative;
  z-index: 6;
  width: min(1180px, calc(100% - 32px));
  margin: -34px auto 0;
}

.search-panel-inner {
  display: grid;
  grid-template-columns: 1fr minmax(320px, 520px);
  gap: 24px;
  align-items: center;
  padding: 26px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow);
  border: 1px solid rgba(254, 215, 170, 0.86);
}

.search-panel h2,
.section-heading h2,
.page-hero h1,
.detail-card h1 {
  margin: 0;
  font-weight: 950;
  color: #111827;
}

.search-panel h2,
.section-heading h2 {
  font-size: clamp(26px, 3vw, 36px);
}

.search-panel p,
.section-heading p,
.page-hero p,
.category-card-large p,
.movie-desc,
.detail-card p {
  color: var(--muted);
}

.search-box,
.filter-bar {
  display: flex;
  gap: 12px;
}

.search-box input,
.filter-bar input,
.filter-bar select {
  width: 100%;
  min-height: 50px;
  padding: 0 18px;
  border: 1px solid #fecdd3;
  border-radius: 999px;
  background: #fff7ed;
  color: #111827;
  outline: none;
}

.search-box input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(225, 29, 72, 0.1);
}

.search-box button {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
}

.content-section,
.movie-detail-wrap {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 64px 0;
}

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

.section-heading p {
  margin: 8px 0 0;
}

.section-more,
.text-link {
  color: var(--primary);
  font-weight: 900;
}

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

.movie-card {
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
  border: 1px solid rgba(254, 215, 170, 0.72);
  transition: 0.25s ease;
}

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

.movie-poster {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(135deg, #fecdd3, #fed7aa);
}

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

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

.play-chip,
.rank-badge {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  font-weight: 900;
}

.play-chip {
  right: 12px;
  bottom: 12px;
  padding: 8px 12px;
  color: #ffffff;
  background: rgba(225, 29, 72, 0.92);
  backdrop-filter: blur(10px);
}

.rank-badge {
  left: 12px;
  top: 12px;
  min-width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 10px 20px rgba(225, 29, 72, 0.22);
}

.movie-info {
  padding: 18px;
}

.movie-title {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 18px;
  font-weight: 950;
}

.movie-title:hover {
  color: var(--primary);
}

.movie-meta {
  margin: 8px 0 0;
  color: var(--primary);
  font-size: 13px;
  font-weight: 800;
}

.movie-desc {
  display: -webkit-box;
  min-height: 66px;
  margin: 10px 0 0;
  overflow: hidden;
  line-height: 1.65;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.tag-row {
  margin-top: 14px;
}

.tag-row span,
.tag-cloud a {
  padding: 6px 10px;
}

.two-column-section {
  display: grid;
  grid-template-columns: 1.55fr 0.85fr;
  gap: 28px;
  align-items: start;
}

.category-grid,
.category-large-grid {
  display: grid;
  gap: 18px;
}

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

.category-tile,
.category-card-large,
.side-card,
.detail-card,
.ranking-box {
  background: #ffffff;
  border: 1px solid rgba(254, 215, 170, 0.82);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

.category-tile {
  min-height: 122px;
  padding: 22px;
  transition: 0.2s ease;
}

.category-tile:hover {
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  transform: translateY(-4px);
}

.category-tile span {
  display: block;
  font-size: 20px;
  font-weight: 950;
}

.category-tile small {
  display: block;
  margin-top: 8px;
  color: var(--muted);
  line-height: 1.55;
}

.category-tile:hover small {
  color: rgba(255, 255, 255, 0.86);
}

.ranking-box {
  padding: 24px;
}

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

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

.compact-card:hover {
  background: #ffe4e6;
}

.compact-card img {
  width: 56px;
  height: 74px;
  object-fit: cover;
  border-radius: 14px;
}

.compact-card span:not(.mini-rank) {
  font-weight: 900;
}

.compact-card small {
  grid-column: 3;
  color: var(--muted);
}

.mini-rank {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #ffffff;
  background: var(--primary);
  font-weight: 900;
}

.page-hero {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 36px auto 0;
  overflow: hidden;
  border-radius: 34px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: var(--shadow);
}

.small-hero {
  padding: 64px;
}

.page-hero h1 {
  color: #ffffff;
  font-size: clamp(36px, 5vw, 58px);
}

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

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

.category-card-large {
  overflow: hidden;
}

.category-cover-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 3px;
  height: 180px;
  overflow: hidden;
  background: #fff1f2;
}

.category-cover-strip img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.category-card-large div {
  padding: 24px;
}

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

.filter-bar {
  margin-bottom: 28px;
}

.filter-bar select {
  flex: 0 0 180px;
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
  color: var(--muted);
  font-weight: 700;
}

.breadcrumb a:hover {
  color: var(--primary);
}

.detail-main {
  display: grid;
  gap: 24px;
}

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

.movie-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  background: #000000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  cursor: pointer;
  background-size: cover;
  background-position: center;
  transition: opacity 0.24s ease, visibility 0.24s ease;
}

.player-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.player-button {
  width: 86px;
  height: 86px;
  border: 0;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #ffffff;
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.24);
}

.play-triangle {
  width: 0;
  height: 0;
  margin-left: 7px;
  border-top: 16px solid transparent;
  border-bottom: 16px solid transparent;
  border-left: 24px solid var(--primary);
}

.detail-card,
.side-card {
  padding: 26px;
}

.detail-title-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.detail-title-row strong {
  flex: 0 0 auto;
  height: 54px;
  min-width: 72px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  font-size: 22px;
}

.detail-pill {
  display: inline-block;
  margin-bottom: 12px;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--primary);
  background: #fff1f2;
  font-weight: 900;
}

.detail-card h1 {
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.18;
}

.detail-one-line {
  margin-top: 16px;
  font-size: 18px;
  line-height: 1.8;
}

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

.detail-meta span {
  padding: 8px 12px;
  border-radius: 999px;
  background: #fff7ed;
  color: #9a3412;
  font-weight: 800;
}

.detail-card h2,
.side-card h2 {
  margin: 26px 0 12px;
  font-size: 24px;
  font-weight: 950;
}

.detail-card p {
  line-height: 1.9;
  font-size: 16px;
}

.detail-cover {
  width: 100%;
  border-radius: 28px;
  box-shadow: var(--shadow);
  aspect-ratio: 3 / 4;
  object-fit: cover;
}

.detail-side {
  display: grid;
  gap: 20px;
  position: sticky;
  top: 96px;
}

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

.side-card dt {
  color: var(--muted);
  font-weight: 800;
}

.side-card dd {
  margin: 0;
  font-weight: 900;
}

.related-section {
  padding-top: 0;
}

.movie-card.is-hidden {
  display: none;
}

.site-footer {
  margin-top: 32px;
  padding: 48px 0 22px;
  background: #111827;
  color: rgba(255, 255, 255, 0.72);
}

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

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

.footer-inner p {
  max-width: 520px;
  line-height: 1.8;
}

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

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

.footer-bottom {
  width: min(1180px, calc(100% - 32px));
  margin: 28px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  text-align: center;
}

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

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

  .detail-side {
    position: static;
  }
}

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

  .menu-button {
    display: block;
  }

  .site-nav {
    position: absolute;
    left: 16px;
    right: 16px;
    top: 72px;
    display: none;
    flex-direction: column;
    padding: 14px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow);
  }

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

  .nav-link {
    width: 100%;
    text-align: center;
  }

  .hero {
    height: 620px;
  }

  .hero-content {
    justify-content: flex-end;
    padding-bottom: 120px;
  }

  .hero-content p {
    font-size: 16px;
  }

  .search-panel-inner,
  .search-box,
  .filter-bar {
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .content-section,
  .movie-detail-wrap {
    padding: 42px 0;
  }

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

  .movie-info {
    padding: 14px;
  }

  .movie-desc {
    display: none;
  }

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

  .small-hero {
    padding: 42px 24px;
  }

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

  .filter-bar select {
    flex: auto;
  }

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

@media (max-width: 460px) {
  .brand-text {
    font-size: 18px;
  }

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

  .hero-actions,
  .search-box {
    align-items: stretch;
  }

  .primary-button,
  .ghost-button,
  .search-box button {
    width: 100%;
  }
}
