:root {
  color-scheme: dark;
  --bg-deep: #020617;
  --bg-main: #0f172a;
  --bg-soft: #1e293b;
  --bg-card: #182235;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-soft: #cbd5e1;
  --accent: #10b981;
  --accent-deep: #059669;
  --accent-soft: rgba(16, 185, 129, 0.18);
  --border: rgba(148, 163, 184, 0.18);
  --shadow: 0 22px 70px rgba(0, 0, 0, 0.38);
  --radius-lg: 22px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", Arial, sans-serif;
  background:
    radial-gradient(circle at 15% -10%, rgba(16, 185, 129, 0.18), transparent 32rem),
    linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
  color: var(--text-main);
  line-height: 1.65;
}

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

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

button,
input,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

.container {
  width: min(var(--container), calc(100% - 32px));
  margin: 0 auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.94), rgba(15, 23, 42, 0.96));
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  gap: 22px;
}

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

.brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #14b8a6);
  color: white;
  box-shadow: 0 10px 26px rgba(16, 185, 129, 0.28);
  font-size: 14px;
}

.brand-text {
  display: grid;
  line-height: 1.1;
}

.brand-text strong,
.footer-brand strong {
  font-size: 1.18rem;
  letter-spacing: 0.02em;
}

.brand-text small {
  margin-top: 4px;
  color: var(--accent);
  font-size: 0.74rem;
}

.desktop-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  color: var(--text-soft);
}

.nav-link {
  position: relative;
  font-weight: 600;
  transition: color 0.25s ease;
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 2px;
  transform: scaleX(0);
  transform-origin: center;
  background: var(--accent);
  transition: transform 0.25s ease;
}

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

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
}

.header-search {
  position: relative;
  display: flex;
  align-items: center;
  width: 270px;
}

.header-search input,
.mobile-search input,
.big-search input,
.search-page-form input,
.filter-toolbar input,
.filter-toolbar select {
  width: 100%;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.75);
  color: var(--text-main);
  outline: none;
  transition: border 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.header-search input {
  padding: 10px 42px 10px 14px;
}

.header-search input:focus,
.mobile-search input:focus,
.big-search input:focus,
.search-page-form input:focus,
.filter-toolbar input:focus,
.filter-toolbar select:focus {
  border-color: rgba(16, 185, 129, 0.75);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.14);
  background: rgba(15, 23, 42, 0.95);
}

.header-search button {
  position: absolute;
  right: 5px;
  top: 5px;
  bottom: 5px;
  width: 34px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: white;
}

.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  border-radius: 99px;
  background: white;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--border);
  padding: 14px 16px 20px;
}

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

.mobile-nav {
  display: grid;
  gap: 10px;
  margin-bottom: 14px;
}

.mobile-nav a {
  padding: 10px 0;
  color: var(--text-soft);
}

.mobile-search {
  display: flex;
  gap: 10px;
}

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

.mobile-search button {
  border: 0;
  border-radius: 12px;
  padding: 0 16px;
  background: var(--accent);
  color: white;
}

.hero-carousel {
  position: relative;
  height: min(70vh, 760px);
  min-height: 520px;
  overflow: hidden;
  background: #020617;
}

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

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

.hero-image,
.detail-bg,
.page-hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.56), rgba(2, 6, 23, 0.12)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.84), transparent 55%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  height: 100%;
}

.hero-copy {
  width: min(680px, 100%);
  animation: floatUp 0.9s ease both;
}

.hero-tags,
.chip-row,
.movie-meta-line,
.rank-meta,
.detail-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.hero-tags span,
.chip-row span,
.detail-tag-cloud a {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 10px;
  background: rgba(15, 23, 42, 0.72);
  color: var(--text-soft);
  font-size: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-tags span:first-child {
  background: var(--accent);
  color: white;
  border-color: transparent;
}

.hero-copy h1 {
  margin: 18px 0 14px;
  font-size: clamp(2.7rem, 7vw, 5.8rem);
  line-height: 1;
  letter-spacing: -0.06em;
  text-shadow: 0 14px 45px rgba(0, 0, 0, 0.48);
}

.hero-copy p {
  max-width: 640px;
  margin: 0 0 28px;
  color: #e2e8f0;
  font-size: clamp(1rem, 2vw, 1.24rem);
}

.hero-actions,
.center-actions,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.primary-btn,
.ghost-btn,
.panel-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border-radius: 13px;
  padding: 0 22px;
  font-weight: 700;
  transition: transform 0.25s ease, background 0.25s ease, border 0.25s ease;
}

.primary-btn {
  background: var(--accent);
  color: white;
  box-shadow: 0 16px 36px rgba(16, 185, 129, 0.25);
}

.primary-btn:hover,
.panel-link:hover {
  background: var(--accent-deep);
  transform: translateY(-2px);
}

.ghost-btn {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(15, 23, 42, 0.54);
  color: var(--text-main);
}

.ghost-btn:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.hero-arrow {
  position: absolute;
  z-index: 3;
  top: 50%;
  width: 48px;
  height: 48px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  color: white;
  font-size: 2rem;
  transition: background 0.25s ease, transform 0.25s ease;
}

.hero-arrow:hover {
  background: rgba(0, 0, 0, 0.68);
  transform: translateY(-50%) scale(1.06);
}

.hero-arrow.prev {
  left: 22px;
}

.hero-arrow.next {
  right: 22px;
}

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

.hero-dots button {
  width: 12px;
  height: 12px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
  width: 34px;
  background: var(--accent);
}

.section-block {
  padding: 58px 0;
}

.home-search-panel {
  position: relative;
  z-index: 4;
  margin-top: -42px;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.86);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.big-search,
.search-page-form {
  display: flex;
  gap: 12px;
}

.big-search input,
.search-page-form input {
  min-height: 52px;
  padding: 0 18px;
  font-size: 1rem;
}

.big-search button,
.search-page-form button {
  min-width: 126px;
  border: 0;
  border-radius: 14px;
  background: var(--accent);
  color: white;
  font-weight: 700;
}

.quick-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.quick-links a,
.side-link-grid a {
  border-radius: 999px;
  padding: 7px 13px;
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-soft);
  transition: color 0.25s ease, background 0.25s ease;
}

.quick-links a:hover,
.side-link-grid a:hover {
  background: var(--accent-soft);
  color: #d1fae5;
}

.section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--accent), #14b8a6);
  color: white;
  box-shadow: 0 14px 30px rgba(16, 185, 129, 0.22);
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2rem);
}

.section-heading p {
  margin: 2px 0 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.movie-grid {
  display: grid;
  gap: 24px;
}

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

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

.movie-card {
  min-width: 0;
}

.movie-card-link {
  display: block;
  height: 100%;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: 18px;
  background: rgba(30, 41, 59, 0.76);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.18);
  transition: transform 0.28s ease, box-shadow 0.28s ease, border 0.28s ease;
}

.movie-card-link:hover {
  transform: translateY(-7px) scale(1.015);
  border-color: rgba(16, 185, 129, 0.45);
  box-shadow: 0 26px 68px rgba(0, 0, 0, 0.34);
}

.poster-frame {
  position: relative;
  aspect-ratio: 3 / 4;
  margin: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 30% 20%, rgba(16, 185, 129, 0.26), transparent 38%),
    linear-gradient(135deg, #0f172a, #1e293b);
}

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

.poster-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease, opacity 0.25s ease;
}

.poster-frame img.image-missing,
.hero-image.image-missing,
.detail-bg.image-missing,
.page-hero img.image-missing,
.detail-poster img.image-missing,
.rank-item img.image-missing {
  opacity: 0;
}

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

.poster-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.74), rgba(0, 0, 0, 0.08));
  transition: opacity 0.25s ease;
}

.movie-card-link:hover .poster-frame::after {
  opacity: 1;
}

.year-pill {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  border-radius: 999px;
  padding: 3px 8px;
  background: rgba(0, 0, 0, 0.72);
  color: white;
  font-size: 0.78rem;
}

.hover-play {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  transform: translate(-50%, -50%) scale(0);
  background: var(--accent);
  color: white;
  box-shadow: 0 18px 46px rgba(16, 185, 129, 0.35);
  transition: transform 0.28s ease;
}

.movie-card-link:hover .hover-play {
  transform: translate(-50%, -50%) scale(1);
}

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

.movie-card.compact .movie-card-body {
  padding: 13px;
}

.movie-card-body h3 {
  overflow: hidden;
  margin: 0 0 8px;
  color: white;
  font-size: 1.08rem;
  white-space: nowrap;
  text-overflow: ellipsis;
  transition: color 0.25s ease;
}

.movie-card-link:hover h3 {
  color: var(--accent);
}

.movie-card-body p {
  display: -webkit-box;
  min-height: 3.15em;
  margin: 0 0 12px;
  overflow: hidden;
  color: var(--text-muted);
  font-size: 0.92rem;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.movie-meta-line {
  justify-content: space-between;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.movie-meta-line span {
  overflow: hidden;
  max-width: 50%;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.chip-row {
  margin-top: 10px;
}

.region-section {
  display: grid;
  gap: 36px;
}

.mini-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.mini-title span {
  width: 4px;
  height: 26px;
  border-radius: 999px;
  background: var(--accent);
}

.mini-title h3 {
  flex: 1;
  margin: 0;
  font-size: 1.25rem;
}

.mini-title a {
  color: var(--accent);
  font-weight: 700;
}

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

.side-card,
.detail-main-card,
.detail-side-card,
.player-card,
.category-panel,
.internal-links,
.search-shell,
.filter-toolbar {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: rgba(15, 23, 42, 0.66);
  box-shadow: 0 18px 58px rgba(0, 0, 0, 0.18);
}

.side-card {
  position: sticky;
  top: 92px;
  padding: 26px;
}

.side-card h2,
.internal-links h2 {
  margin-top: 0;
}

.side-card p {
  color: var(--text-muted);
}

.side-link-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

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

.rank-list.compact-rank {
  gap: 12px;
}

.rank-item a {
  display: grid;
  grid-template-columns: 54px 74px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 17px;
  background: rgba(30, 41, 59, 0.68);
  transition: transform 0.25s ease, border 0.25s ease;
}

.rank-item a:hover {
  transform: translateX(6px);
  border-color: rgba(16, 185, 129, 0.45);
}

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

.rank-item img {
  width: 74px;
  height: 98px;
  border-radius: 12px;
  object-fit: cover;
  background: var(--bg-card);
}

.rank-item h3 {
  margin: 0 0 6px;
}

.rank-item p {
  display: -webkit-box;
  margin: 0 0 8px;
  overflow: hidden;
  color: var(--text-muted);
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.rank-meta {
  color: var(--text-muted);
  font-size: 0.83rem;
}

.page-hero,
.detail-hero {
  position: relative;
  overflow: hidden;
  background: #020617;
}

.small-hero {
  min-height: 360px;
}

.page-hero-overlay,
.detail-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.55)),
    linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.1));
}

.page-hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 360px;
  padding: 70px 0;
}

.eyebrow {
  width: max-content;
  border-radius: 999px;
  padding: 6px 12px;
  background: var(--accent-soft);
  color: #a7f3d0;
  font-weight: 700;
}

.page-hero h1,
.detail-info h1 {
  margin: 16px 0 10px;
  font-size: clamp(2.3rem, 6vw, 4.4rem);
  line-height: 1.05;
  letter-spacing: -0.045em;
}

.page-hero p,
.detail-info p {
  max-width: 760px;
  margin: 0 0 24px;
  color: var(--text-soft);
  font-size: 1.1rem;
}

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

.stats-grid div {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(30, 41, 59, 0.58);
}

.stats-grid strong {
  display: block;
  font-size: 2rem;
  line-height: 1;
  color: var(--accent);
}

.stats-grid span {
  color: var(--text-muted);
}

.category-listing {
  display: grid;
  gap: 32px;
}

.category-panel {
  padding: 26px;
}

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

.category-panel h2 {
  margin: 0;
}

.category-panel p {
  margin: 4px 0 0;
  color: var(--text-muted);
}

.panel-link {
  min-width: max-content;
  background: var(--accent);
  color: white;
}

.filter-toolbar {
  display: grid;
  grid-template-columns: minmax(180px, 1fr) repeat(4, minmax(130px, 180px));
  gap: 14px;
  align-items: end;
  margin-bottom: 26px;
  padding: 18px;
}

.filter-toolbar strong {
  display: block;
  font-size: 1.2rem;
}

.filter-toolbar [data-filter-count] {
  display: block;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.filter-toolbar label span {
  display: block;
  margin-bottom: 6px;
  color: var(--text-muted);
  font-size: 0.82rem;
}

.filter-toolbar input,
.filter-toolbar select {
  min-height: 42px;
  padding: 0 12px;
}

.filter-results .movie-card.is-hidden,
.rank-item.is-hidden {
  display: none;
}

.search-shell {
  padding: 24px;
}

.search-page-form {
  margin-bottom: 14px;
}

.search-summary {
  margin-bottom: 22px;
  color: var(--text-muted);
}

.empty-state {
  padding: 46px;
  text-align: center;
  border: 1px dashed rgba(148, 163, 184, 0.34);
  border-radius: 18px;
}

.detail-hero {
  min-height: 620px;
}

.detail-hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 42px;
  align-items: center;
  min-height: 620px;
  padding: 70px 0;
}

.detail-poster {
  overflow: hidden;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 24px;
  background: var(--bg-card);
  box-shadow: var(--shadow);
}

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

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
  color: var(--text-muted);
}

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

.detail-tags-top {
  margin-bottom: 12px;
}

.player-card {
  padding: 18px;
}

.player-stage {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  background: #000;
  aspect-ratio: 16 / 9;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.movie-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.12));
  color: white;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-overlay span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 82px;
  height: 82px;
  border-radius: 999px;
  background: var(--accent);
  box-shadow: 0 18px 48px rgba(16, 185, 129, 0.35);
  font-size: 2rem;
}

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

.player-note {
  margin: 12px 4px 0;
  color: var(--text-muted);
}

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

.detail-main-card,
.detail-side-card,
.internal-links {
  padding: 28px;
}

.detail-main-card h2,
.detail-side-card h2 {
  margin-top: 0;
  color: #e2e8f0;
}

.detail-main-card p {
  color: var(--text-soft);
  font-size: 1.02rem;
}

.detail-side-card dl {
  display: grid;
  gap: 12px;
  margin: 0 0 22px;
}

.detail-side-card dl div {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.detail-side-card dt {
  color: var(--text-muted);
}

.detail-side-card dd {
  margin: 0;
}

.internal-links ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.internal-links a {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(30, 41, 59, 0.58);
  color: white;
}

.internal-links a:hover {
  color: var(--accent);
}

.internal-links span {
  color: var(--text-muted);
  white-space: nowrap;
}

.site-footer {
  margin-top: 58px;
  border-top: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.72);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr;
  gap: 34px;
  padding: 44px 0;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.site-footer p,
.site-footer a,
.site-footer li {
  color: var(--text-muted);
}

.site-footer a:hover {
  color: var(--accent);
}

.site-footer h2 {
  margin: 0 0 12px;
  color: #d1fae5;
  font-size: 1rem;
}

.site-footer ul {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-bottom {
  padding: 18px 0 28px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 60;
  display: none;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: white;
  font-size: 1.2rem;
  box-shadow: 0 12px 30px rgba(16, 185, 129, 0.28);
}

.back-to-top.is-visible {
  display: block;
}

@keyframes floatUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

  .menu-toggle {
    display: block;
  }

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

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

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

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

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

  .side-card {
    position: static;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(100% - 24px, var(--container));
  }

  .hero-carousel {
    min-height: 560px;
    height: 76vh;
  }

  .hero-copy h1 {
    font-size: clamp(2.2rem, 13vw, 4rem);
  }

  .hero-arrow {
    display: none;
  }

  .home-search-panel {
    margin-top: -26px;
    padding: 16px;
  }

  .big-search,
  .search-page-form,
  .mobile-search {
    flex-direction: column;
  }

  .big-search button,
  .search-page-form button,
  .mobile-search button {
    min-height: 46px;
  }

  .section-block {
    padding: 42px 0;
  }

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

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

  .movie-card-body p {
    font-size: 0.86rem;
  }

  .rank-item a {
    grid-template-columns: 44px 62px minmax(0, 1fr);
    gap: 10px;
  }

  .rank-item img {
    width: 62px;
    height: 84px;
  }

  .rank-number {
    width: 38px;
    height: 38px;
  }

  .page-hero-content,
  .small-hero {
    min-height: 320px;
  }

  .stats-grid,
  .filter-toolbar,
  .footer-grid,
  .internal-links ul {
    grid-template-columns: 1fr;
  }

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

  .detail-hero-inner {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 46px 0;
  }

  .detail-poster {
    width: min(260px, 72vw);
  }

  .detail-hero {
    min-height: auto;
  }

  .player-card,
  .detail-main-card,
  .detail-side-card,
  .internal-links,
  .category-panel,
  .search-shell {
    padding: 16px;
    border-radius: 18px;
  }
}

@media (max-width: 440px) {
  .movie-grid.four-cols,
  .movie-grid.six-cols {
    grid-template-columns: 1fr;
  }

  .brand-text strong {
    font-size: 1rem;
  }
}
