:root {
  --toffee-primary: #c87941;
  --toffee-secondary: #e5a76b;
  --toffee-light: #f5e6d3;
  --toffee-cream: #fff8f0;
  --toffee-caramel: #b8784f;
  --toffee-brown: #8b5a3c;
  --toffee-dark: #6b4423;
  --cloud-white: #ffffff;
  --cloud-soft: #f9f9f9;
  --shadow-cloud: 0 8px 32px rgba(200, 121, 65, 0.12);
  --shadow-glow: 0 0 40px rgba(229, 167, 107, 0.3);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--toffee-dark);
  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  background:
    radial-gradient(circle at 8% 12%, rgba(229, 167, 107, 0.22), transparent 32rem),
    radial-gradient(circle at 92% 18%, rgba(200, 121, 65, 0.14), transparent 28rem),
    linear-gradient(135deg, var(--toffee-cream), #ffffff 48%, rgba(245, 230, 211, 0.35));
  min-height: 100vh;
}

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

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

.toffee-card {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(245, 230, 211, 0.78);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-cloud);
  backdrop-filter: blur(12px);
}

.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-0.5rem);
  box-shadow: 0 18px 42px rgba(107, 68, 35, 0.14);
}

.toffee-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.875rem;
  padding: 0.72rem 1.45rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 700;
  transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

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

.toffee-btn-primary {
  color: #ffffff;
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
  box-shadow: 0 12px 30px rgba(200, 121, 65, 0.28);
}

.toffee-btn-ghost {
  color: var(--toffee-dark);
  background: rgba(255, 255, 255, 0.32);
  border-color: rgba(255, 255, 255, 0.65);
}

.section-wrap,
.page-main {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
}

.section-wrap {
  margin-top: 4.5rem;
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.6rem;
}

.section-heading a {
  color: var(--toffee-primary);
  font-weight: 700;
}

.section-title {
  position: relative;
  display: inline-block;
  margin: 0;
  color: var(--toffee-dark);
  font-size: clamp(1.6rem, 3vw, 2.35rem);
  line-height: 1.15;
  font-weight: 900;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.45rem;
  width: 100%;
  height: 0.26rem;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--toffee-secondary), transparent);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(255, 248, 240, 0.82));
  border-bottom: 1px solid rgba(245, 230, 211, 0.82);
  backdrop-filter: blur(18px);
  box-shadow: 0 4px 24px rgba(107, 68, 35, 0.06);
}

.header-inner {
  width: min(1180px, calc(100% - 2rem));
  height: 4.5rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 1.32rem;
  font-weight: 900;
  letter-spacing: -0.04em;
  white-space: nowrap;
  background: linear-gradient(90deg, var(--toffee-primary), var(--toffee-secondary));
  background-clip: text;
  color: transparent;
}

.logo-mark {
  display: inline-grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  color: #ffffff;
  font-size: 0.78rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
  box-shadow: var(--shadow-glow);
  animation: float 6s ease-in-out infinite;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin-left: auto;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.4rem;
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  color: var(--toffee-brown);
  font-weight: 700;
  transition: background 0.3s ease, color 0.3s ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--toffee-primary);
  background: rgba(245, 230, 211, 0.75);
}

.header-search,
.mobile-search,
.wide-search {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--toffee-cream);
  border: 1px solid rgba(229, 167, 107, 0.38);
  border-radius: 999px;
  padding: 0.35rem;
}

.header-search input,
.mobile-search input,
.wide-search input,
.local-filter-form input {
  width: 100%;
  border: 0;
  outline: 0;
  color: var(--toffee-dark);
  background: transparent;
}

.header-search {
  width: 19rem;
}

.header-search input,
.mobile-search input {
  padding: 0.5rem 0.7rem;
}

.header-search button,
.mobile-search button,
.wide-search button {
  border: 0;
  color: #ffffff;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
}

.mobile-toggle {
  display: none;
  width: 2.6rem;
  height: 2.6rem;
  border: 0;
  border-radius: 999px;
  background: rgba(245, 230, 211, 0.72);
}

.mobile-toggle span {
  display: block;
  width: 1.2rem;
  height: 2px;
  margin: 0.26rem auto;
  border-radius: 999px;
  background: var(--toffee-primary);
}

.mobile-panel {
  display: none;
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 0 0 1rem;
}

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

.mobile-nav,
.mobile-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.mobile-categories a {
  padding: 0.4rem 0.75rem;
  color: var(--toffee-brown);
  border-radius: 999px;
  background: rgba(245, 230, 211, 0.55);
}

.hero-carousel {
  position: relative;
  min-height: clamp(34rem, 76vh, 46rem);
  overflow: hidden;
  border-radius: 0 0 3rem 3rem;
  background: var(--toffee-dark);
  box-shadow: 0 24px 60px rgba(107, 68, 35, 0.18);
}

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

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

.hero-bg,
.hero-layer {
  position: absolute;
  inset: 0;
}

.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.04);
  filter: blur(2px) saturate(1.08);
}

.hero-layer {
  background:
    linear-gradient(90deg, rgba(54, 30, 16, 0.86), rgba(107, 68, 35, 0.58), rgba(255, 248, 240, 0.2)),
    linear-gradient(0deg, rgba(54, 30, 16, 0.72), transparent 42%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 2rem));
  min-height: clamp(34rem, 76vh, 46rem);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(18rem, 0.62fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
  padding: 5.5rem 0 4.5rem;
}

.hero-copy {
  color: #fff7ed;
}

.eyebrow {
  margin: 0 0 0.75rem;
  color: var(--toffee-secondary);
  font-size: 0.86rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-copy h1,
.hero-copy h2 {
  margin: 0;
  max-width: 52rem;
  font-size: clamp(2.6rem, 6.4vw, 5.8rem);
  line-height: 1.02;
  letter-spacing: -0.08em;
  text-shadow: 0 16px 42px rgba(0, 0, 0, 0.25);
}

.hero-desc {
  max-width: 44rem;
  margin: 1.35rem 0 0;
  color: rgba(255, 248, 240, 0.88);
  font-size: clamp(1rem, 1.9vw, 1.28rem);
}

.hero-tags,
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.52rem;
}

.hero-tags {
  margin-top: 1.4rem;
}

.hero-tags span,
.tag-list span {
  display: inline-flex;
  align-items: center;
  min-height: 1.8rem;
  padding: 0.25rem 0.72rem;
  border-radius: 999px;
  color: var(--toffee-dark);
  font-size: 0.82rem;
  font-weight: 800;
  background: rgba(245, 230, 211, 0.78);
}

.hero-tags span {
  color: #fff7ed;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.26);
  backdrop-filter: blur(10px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2rem;
}

.hero-poster {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 2rem;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.28);
  transform: rotate(1.5deg);
  transition: transform 0.35s ease;
}

.hero-poster:hover {
  transform: rotate(0deg) translateY(-0.45rem);
}

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

.hero-poster span {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  color: #ffffff;
  font-weight: 900;
  text-shadow: 0 3px 12px rgba(0, 0, 0, 0.35);
}

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

.hero-dot {
  width: 0.65rem;
  height: 0.65rem;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.48);
  transition: width 0.3s ease, background 0.3s ease;
}

.hero-dot.is-active {
  width: 2.35rem;
  background: #ffffff;
}

.search-panel {
  width: min(1180px, calc(100% - 2rem));
  margin: -2.4rem auto 0;
  position: relative;
  z-index: 4;
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 1.5rem;
  align-items: center;
  padding: 1.4rem;
}

.search-panel h2,
.search-panel p {
  margin: 0;
}

.search-panel h2 {
  font-size: 1.45rem;
}

.search-panel p {
  color: var(--toffee-brown);
}

.wide-search {
  width: 100%;
  padding: 0.5rem;
}

.wide-search input {
  padding: 0.68rem 0.9rem;
}

.wide-search button {
  padding: 0.72rem 1.45rem;
}

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

.movie-card {
  overflow: hidden;
}

.poster-link {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 1.35rem 1.35rem 0 0;
  background: rgba(107, 68, 35, 0.08);
}

.poster-link img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.poster-gradient {
  position: absolute;
  inset: 45% 0 0;
  background: linear-gradient(0deg, rgba(39, 20, 10, 0.75), transparent);
}

.watch-chip {
  position: absolute;
  right: 0.8rem;
  bottom: 0.8rem;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 900;
  padding: 0.32rem 0.7rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.rank-badge {
  position: absolute;
  left: 0.85rem;
  top: 0.85rem;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  width: 2.1rem;
  height: 2.1rem;
  color: #ffffff;
  font-weight: 900;
  border-radius: 50%;
  background: linear-gradient(135deg, #f59e0b, var(--toffee-primary));
  box-shadow: 0 8px 20px rgba(107, 68, 35, 0.25);
}

.movie-card-body {
  padding: 1rem;
}

.movie-title {
  display: block;
  color: var(--toffee-dark);
  font-size: 1.05rem;
  font-weight: 900;
  line-height: 1.35;
}

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

.movie-desc {
  display: -webkit-box;
  min-height: 3.1rem;
  margin: 0.55rem 0 0.85rem;
  overflow: hidden;
  color: rgba(107, 68, 35, 0.78);
  font-size: 0.92rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  color: rgba(107, 68, 35, 0.65);
  font-size: 0.82rem;
  font-weight: 700;
}

.movie-meta span {
  padding: 0.16rem 0.5rem;
  border-radius: 999px;
  background: rgba(245, 230, 211, 0.58);
}

.movie-card .tag-list {
  margin-top: 0.8rem;
}

.movie-card-list {
  display: grid;
  grid-template-columns: 8.8rem minmax(0, 1fr);
  gap: 1rem;
  padding: 0.75rem;
}

.list-poster {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  background: rgba(107, 68, 35, 0.08);
}

.list-poster img {
  width: 100%;
  height: 100%;
  min-height: 12rem;
  object-fit: cover;
}

.list-body {
  align-self: center;
}

.list-body .movie-desc {
  min-height: auto;
}

.list-stack {
  display: grid;
  gap: 1rem;
}

.two-column-section {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(18rem, 0.6fr);
  gap: 1.6rem;
  align-items: start;
}

.ranking-panel {
  position: sticky;
  top: 6rem;
  padding: 1.3rem;
}

.ranking-panel h2 {
  margin: 0 0 1rem;
  font-size: 1.35rem;
}

.rank-list {
  display: grid;
  gap: 0.75rem;
}

.rank-row {
  display: grid;
  grid-template-columns: 2.4rem 3.4rem minmax(0, 1fr) auto;
  gap: 0.8rem;
  align-items: center;
  padding: 0.65rem;
  border-radius: 1rem;
  background: rgba(255, 248, 240, 0.72);
  transition: transform 0.3s ease, background 0.3s ease;
}

.rank-row:hover {
  transform: translateX(0.25rem);
  background: rgba(245, 230, 211, 0.78);
}

.rank-number {
  color: var(--toffee-primary);
  font-weight: 900;
}

.rank-row img {
  width: 3.4rem;
  height: 4.3rem;
  border-radius: 0.7rem;
  object-fit: cover;
}

.rank-info {
  display: grid;
  gap: 0.1rem;
}

.rank-info strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-info em {
  overflow: hidden;
  color: rgba(107, 68, 35, 0.64);
  font-size: 0.76rem;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-score {
  color: var(--toffee-caramel);
  font-weight: 900;
}

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

.category-card,
.category-overview-card {
  position: relative;
  overflow: hidden;
  min-height: 15rem;
  padding: 1.15rem;
}

.category-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.2;
  transform: scale(1.05);
}

.category-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(145deg, rgba(255, 248, 240, 0.9), rgba(245, 230, 211, 0.72));
}

.category-card > * {
  position: relative;
  z-index: 1;
}

.category-icon {
  display: inline-grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  margin-bottom: 1.25rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.66);
  font-size: 1.45rem;
}

.category-card strong,
.category-overview-card h2 {
  display: block;
  margin: 0;
  color: var(--toffee-dark);
  font-size: 1.32rem;
  font-weight: 900;
}

.category-card p,
.category-overview-card p {
  margin: 0.65rem 0 0;
  color: rgba(107, 68, 35, 0.78);
}

.page-main {
  padding: 2rem 0 4.5rem;
}

.page-hero {
  padding: clamp(1.6rem, 5vw, 3rem);
  margin-bottom: 2rem;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(255, 248, 240, 0.78)),
    radial-gradient(circle at 88% 20%, rgba(229, 167, 107, 0.18), transparent 22rem);
}

.page-hero h1 {
  max-width: 48rem;
  margin: 0;
  font-size: clamp(2rem, 5.2vw, 4.8rem);
  line-height: 1.05;
  letter-spacing: -0.06em;
}

.page-hero p:last-child,
.page-hero > p:not(.eyebrow) {
  max-width: 52rem;
  color: rgba(107, 68, 35, 0.78);
  font-size: 1.04rem;
}

.category-overview-card {
  display: grid;
  grid-template-columns: 8rem minmax(0, 1fr);
  gap: 1rem;
  min-height: 12rem;
}

.category-thumb {
  position: relative;
  overflow: hidden;
  border-radius: 1.2rem;
}

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

.category-thumb span {
  position: absolute;
  right: 0.5rem;
  bottom: 0.5rem;
  display: inline-grid;
  place-items: center;
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
}

.sample-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 1rem;
}

.sample-list span {
  color: var(--toffee-primary);
  font-size: 0.78rem;
  font-weight: 800;
  padding: 0.24rem 0.6rem;
  border-radius: 999px;
  background: rgba(245, 230, 211, 0.68);
}

.local-filter-form {
  max-width: 36rem;
  margin-top: 1.4rem;
  padding: 0.4rem 1rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(229, 167, 107, 0.28);
}

.local-filter-form input {
  padding: 0.65rem 0;
}

.sort-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1rem;
}

.sort-bar button {
  border: 0;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  color: var(--toffee-dark);
  font-weight: 800;
  background: rgba(245, 230, 211, 0.72);
}

.sort-bar button.is-active {
  color: #ffffff;
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
}

.category-list-wrap {
  margin-top: 2rem;
}

.top-rank-grid .movie-card:first-child {
  transform: translateY(-0.35rem);
}

.ranking-stack .movie-card-list {
  grid-template-columns: 7.5rem minmax(0, 1fr);
}

.search-page-form {
  max-width: 42rem;
  margin-top: 1.4rem;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  margin: 0 0 1rem;
  color: rgba(107, 68, 35, 0.72);
  font-size: 0.92rem;
}

.breadcrumbs a {
  color: var(--toffee-primary);
  font-weight: 800;
}

.detail-main {
  max-width: 1180px;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(15rem, 0.38fr) minmax(0, 0.62fr);
  gap: clamp(1.2rem, 4vw, 2.4rem);
  align-items: center;
  padding: clamp(1rem, 4vw, 2rem);
}

.detail-poster {
  overflow: hidden;
  border-radius: 1.4rem;
  box-shadow: 0 22px 50px rgba(107, 68, 35, 0.18);
}

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

.detail-copy h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1.08;
  letter-spacing: -0.06em;
}

.detail-lead {
  margin: 1rem 0 1.2rem;
  color: rgba(107, 68, 35, 0.8);
  font-size: 1.08rem;
}

.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.detail-meta span {
  padding: 0.32rem 0.8rem;
  border-radius: 999px;
  color: var(--toffee-primary);
  font-weight: 800;
  background: rgba(245, 230, 211, 0.68);
}

.large-tags {
  margin-bottom: 1.5rem;
}

.watch-section {
  margin-top: 2.4rem;
}

.player-shell {
  position: relative;
  overflow: hidden;
  margin-top: 1.5rem;
  background: #130c08;
  aspect-ratio: 16 / 9;
}

.movie-video,
.player-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.movie-video {
  background: #130c08;
  object-fit: contain;
}

.player-cover {
  z-index: 2;
  display: grid;
  place-items: center;
  border: 0;
  padding: 0;
  overflow: hidden;
  color: #ffffff;
  background: transparent;
}

.player-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.76) saturate(1.05);
}

.player-shade {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(229, 167, 107, 0.16), rgba(22, 12, 6, 0.74));
}

.play-circle {
  position: relative;
  z-index: 2;
  display: inline-grid;
  place-items: center;
  width: clamp(4.6rem, 10vw, 7.2rem);
  height: clamp(4.6rem, 10vw, 7.2rem);
  padding-left: 0.25rem;
  border-radius: 50%;
  color: #ffffff;
  font-size: clamp(1.5rem, 4vw, 2.4rem);
  background: linear-gradient(135deg, var(--toffee-primary), var(--toffee-secondary));
  box-shadow: 0 18px 54px rgba(0, 0, 0, 0.35);
}

.player-cover strong {
  position: absolute;
  z-index: 2;
  bottom: clamp(1.2rem, 4vw, 2.4rem);
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  letter-spacing: 0.06em;
}

.player-cover.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.detail-content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.3rem;
  margin-top: 2rem;
}

.detail-article {
  padding: clamp(1.25rem, 3vw, 2rem);
}

.detail-article h2 {
  margin: 0 0 0.9rem;
  font-size: 1.45rem;
}

.detail-article p {
  margin: 0;
  color: rgba(107, 68, 35, 0.82);
  font-size: 1.02rem;
}

.related-wrap {
  width: 100%;
}

.site-footer {
  margin-top: 5rem;
  border-top: 1px solid rgba(245, 230, 211, 0.84);
  background: linear-gradient(135deg, rgba(245, 230, 211, 0.75), rgba(255, 248, 240, 0.92), #ffffff);
}

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

.footer-brand p {
  max-width: 28rem;
  margin: 0.8rem 0 0;
  color: rgba(107, 68, 35, 0.72);
}

.footer-links {
  display: grid;
  gap: 0.55rem;
  align-content: start;
}

.footer-links a {
  color: var(--toffee-brown);
  font-weight: 700;
}

.footer-links a:hover {
  color: var(--toffee-primary);
}

.category-links {
  grid-template-columns: repeat(2, auto);
  column-gap: 1.1rem;
}

.footer-bottom {
  padding: 0.8rem;
  color: #ffffff;
  text-align: center;
  font-weight: 800;
  background: linear-gradient(90deg, var(--toffee-secondary), var(--toffee-primary), var(--toffee-caramel));
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-0.45rem);
  }
}

@media (max-width: 1080px) {
  .header-search {
    display: none;
  }

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

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

  .ranking-panel {
    position: static;
  }
}

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

  .mobile-toggle {
    display: block;
    margin-left: auto;
  }

  .header-inner {
    height: 4.1rem;
  }

  .hero-content,
  .search-panel,
  .detail-hero,
  .detail-content-grid {
    grid-template-columns: 1fr;
  }

  .hero-content {
    min-height: 43rem;
    padding-top: 4.5rem;
  }

  .hero-poster {
    max-width: 17rem;
    margin: 0 auto;
  }

  .search-panel {
    margin-top: -1.3rem;
  }

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

  .category-overview-card {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .section-wrap,
  .page-main,
  .header-inner,
  .mobile-panel,
  .footer-inner,
  .search-panel,
  .hero-content {
    width: min(100% - 1rem, 1180px);
  }

  .logo {
    font-size: 1.05rem;
  }

  .logo-mark {
    width: 2rem;
    height: 2rem;
  }

  .hero-carousel {
    border-radius: 0 0 1.6rem 1.6rem;
  }

  .hero-copy h1,
  .hero-copy h2 {
    font-size: clamp(2.15rem, 13vw, 3.4rem);
  }

  .hero-actions,
  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .movie-card-list,
  .ranking-stack .movie-card-list {
    grid-template-columns: 6.4rem minmax(0, 1fr);
  }

  .list-poster img {
    min-height: 9.4rem;
  }

  .page-hero {
    border-radius: 1.1rem;
  }

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