:root {
  --site-emerald: #10b981;
  --site-emerald-dark: #059669;
  --site-teal: #0d9488;
  --site-slate: #0f172a;
  --site-muted: #64748b;
  --site-line: #e2e8f0;
  --site-card: #ffffff;
  --site-bg: #f8fafc;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--site-bg);
  color: #0f172a;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  backdrop-filter: blur(18px);
}

.header-inner {
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: 0 1rem;
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo-link {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0f172a;
}

.logo-mark {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  display: inline-grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--site-emerald), var(--site-teal));
  box-shadow: 0 18px 35px rgba(16, 185, 129, 0.28);
}

.logo-text {
  font-size: 1.25rem;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  font-weight: 700;
  color: #334155;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--site-emerald-dark);
}

.menu-toggle {
  display: none;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: #ecfdf5;
  color: #047857;
  font-size: 1.3rem;
}

.mobile-panel {
  display: none;
  border-top: 1px solid var(--site-line);
  background: #fff;
}

.mobile-panel a {
  display: block;
  padding: 0.8rem 1rem;
  font-weight: 700;
  color: #334155;
}

.hero-slider {
  position: relative;
  height: 560px;
  overflow: hidden;
  background: #020617;
}

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

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

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.02);
}

.hero-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.55), rgba(2, 6, 23, 0.08));
}

.hero-content {
  position: absolute;
  left: 50%;
  bottom: 0;
  z-index: 2;
  width: min(100%, 1280px);
  transform: translateX(-50%);
  padding: 3.2rem 1rem 4.2rem;
  color: #fff;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.22);
  color: #d1fae5;
  font-weight: 800;
  margin-bottom: 1rem;
}

.hero-content h1 {
  max-width: 760px;
  font-size: clamp(2.2rem, 5vw, 4.5rem);
  line-height: 1.04;
  font-weight: 900;
  letter-spacing: -0.04em;
  margin: 0 0 1rem;
}

.hero-content p {
  max-width: 760px;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1rem, 2vw, 1.2rem);
  margin: 0 0 1.25rem;
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.hero-meta span,
.tag-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 0.35rem 0.72rem;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9rem;
  font-weight: 700;
  backdrop-filter: blur(12px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
}

.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border-radius: 0.8rem;
  padding: 0.78rem 1.15rem;
  font-weight: 800;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-btn {
  color: #fff;
  background: linear-gradient(135deg, var(--site-emerald), var(--site-teal));
  box-shadow: 0 18px 35px rgba(16, 185, 129, 0.24);
}

.secondary-btn {
  color: #fff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(12px);
}

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

.hero-dots {
  position: absolute;
  right: max(1rem, calc((100vw - 1280px) / 2 + 1rem));
  bottom: 2rem;
  z-index: 4;
  display: flex;
  gap: 0.55rem;
}

.hero-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
  width: 2rem;
  background: var(--site-emerald);
}

.hero-search {
  width: min(100%, 1280px);
  margin: -2.1rem auto 0;
  position: relative;
  z-index: 5;
  padding: 0 1rem;
}

.hero-search-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.8rem;
  align-items: center;
  padding: 0.85rem;
  border-radius: 1.3rem;
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 26px 60px rgba(15, 23, 42, 0.16);
  backdrop-filter: blur(18px);
}

.search-input,
.sort-select {
  width: 100%;
  height: 3rem;
  border: 1px solid var(--site-line);
  border-radius: 0.95rem;
  padding: 0 1rem;
  outline: none;
  background: #fff;
  color: #0f172a;
}

.search-input:focus,
.sort-select:focus {
  border-color: var(--site-emerald);
  box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.page-shell {
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: 3rem 1rem;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
  margin-bottom: 1.35rem;
}

.section-head h2,
.page-title h1 {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  letter-spacing: -0.035em;
}

.section-head h2 {
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
}

.section-head p,
.page-title p {
  margin: 0.35rem 0 0;
  color: var(--site-muted);
}

.page-title {
  padding: 3rem 1rem 1rem;
  width: min(100%, 1280px);
  margin: 0 auto;
}

.page-title h1 {
  font-size: clamp(2rem, 4vw, 3.35rem);
}

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

.movie-card {
  background: var(--site-card);
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
  transform: translateY(-5px);
  border-color: rgba(16, 185, 129, 0.45);
  box-shadow: 0 22px 50px rgba(15, 23, 42, 0.13);
}

.poster-wrap {
  position: relative;
  aspect-ratio: 2 / 3;
  background: linear-gradient(135deg, #e2e8f0, #f8fafc);
  overflow: hidden;
}

.poster-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

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

.poster-badge {
  position: absolute;
  left: 0.65rem;
  top: 0.65rem;
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.75);
  color: #fff;
  font-weight: 800;
  font-size: 0.75rem;
}

.play-badge {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  background: rgba(2, 6, 23, 0.2);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.movie-card:hover .play-badge {
  opacity: 1;
}

.play-circle {
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(16, 185, 129, 0.95);
  box-shadow: 0 18px 40px rgba(16, 185, 129, 0.35);
}

.card-body {
  padding: 0.9rem;
}

.card-body h3,
.card-body h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.35;
  font-weight: 850;
  color: #0f172a;
}

.card-body p {
  color: var(--site-muted);
  font-size: 0.88rem;
  line-height: 1.55;
  margin: 0.45rem 0 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.65rem;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 700;
}

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

.category-card {
  position: relative;
  overflow: hidden;
  border-radius: 1.2rem;
  padding: 1.2rem;
  min-height: 190px;
  background: linear-gradient(135deg, #ffffff, #ecfdf5);
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 14px 38px rgba(15, 23, 42, 0.07);
}

.category-card::after {
  content: "";
  position: absolute;
  width: 9rem;
  height: 9rem;
  right: -3rem;
  bottom: -3rem;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.14);
}

.category-card h2,
.category-card h3 {
  margin: 0 0 0.45rem;
  font-size: 1.25rem;
  font-weight: 900;
  color: #0f172a;
}

.category-card p {
  color: #475569;
  line-height: 1.65;
  margin: 0 0 0.8rem;
}

.category-card ul {
  margin: 0 0 1rem;
  padding-left: 1.1rem;
  color: #64748b;
}

.rank-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.rank-item {
  display: grid;
  grid-template-columns: auto 6.8rem 1fr;
  gap: 0.9rem;
  align-items: center;
  background: #fff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 1rem;
  padding: 0.75rem;
  box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
}

.rank-num {
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 0.8rem;
  display: grid;
  place-items: center;
  font-weight: 900;
  color: #fff;
  background: linear-gradient(135deg, var(--site-emerald), var(--site-teal));
}

.rank-cover {
  aspect-ratio: 16 / 10;
  border-radius: 0.8rem;
  overflow: hidden;
  background: #e2e8f0;
}

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

.rank-copy h2,
.rank-copy h3 {
  margin: 0;
  font-weight: 900;
  color: #0f172a;
  font-size: 1rem;
}

.rank-copy p {
  margin: 0.35rem 0 0;
  color: #64748b;
  line-height: 1.55;
  font-size: 0.9rem;
}

.filter-panel {
  display: grid;
  grid-template-columns: 1fr 190px;
  gap: 0.8rem;
  margin-bottom: 1.4rem;
  background: #fff;
  border-radius: 1.2rem;
  padding: 0.9rem;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
  color: #64748b;
  font-size: 0.92rem;
  margin-bottom: 1rem;
}

.breadcrumb a {
  color: #059669;
  font-weight: 800;
}

.video-page {
  background: #020617;
  color: #e2e8f0;
}

.video-page .site-header {
  background: rgba(2, 6, 23, 0.9);
  border-bottom-color: rgba(30, 41, 59, 0.92);
}

.video-page .logo-link,
.video-page .nav-links a {
  color: #e2e8f0;
}

.video-page .mobile-panel {
  background: #0f172a;
  border-top-color: #1e293b;
}

.video-page .mobile-panel a {
  color: #e2e8f0;
}

.video-shell {
  width: min(100%, 1280px);
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

.player-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 1.4rem;
  align-items: start;
}

.player-box {
  position: relative;
  overflow: hidden;
  border-radius: 1.2rem;
  background: #000;
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.45);
}

.player-box video {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
  background: #000;
}

.player-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(to top, rgba(2, 6, 23, 0.35), rgba(2, 6, 23, 0.08));
  color: #fff;
  cursor: pointer;
}

.player-box.is-playing .player-overlay {
  display: none;
}

.player-overlay span {
  width: 5rem;
  height: 5rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(16, 185, 129, 0.92);
  font-size: 2rem;
  box-shadow: 0 24px 60px rgba(16, 185, 129, 0.32);
}

.player-loading,
.player-error {
  position: absolute;
  left: 1rem;
  top: 1rem;
  border-radius: 999px;
  padding: 0.45rem 0.75rem;
  background: rgba(15, 23, 42, 0.78);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 800;
}

.player-error {
  background: rgba(220, 38, 38, 0.88);
}

.player-box.is-ready .player-loading {
  display: none;
}

.player-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.78), transparent);
}

.player-controls button {
  border-radius: 999px;
  padding: 0.5rem 0.8rem;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  font-weight: 800;
}

.progress-track {
  flex: 1;
  height: 0.35rem;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.25);
}

.progress-bar {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: var(--site-emerald);
}

.detail-side {
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid rgba(51, 65, 85, 0.9);
  border-radius: 1.2rem;
  padding: 1rem;
}

.detail-side img {
  width: 100%;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  border-radius: 0.95rem;
  background: #1e293b;
}

.detail-side dl {
  display: grid;
  grid-template-columns: 4rem 1fr;
  gap: 0.55rem 0.75rem;
  margin: 1rem 0 0;
  font-size: 0.92rem;
}

.detail-side dt {
  color: #94a3b8;
}

.detail-side dd {
  margin: 0;
  color: #e2e8f0;
  font-weight: 750;
}

.detail-content {
  margin-top: 1.5rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 1.4rem;
}

.detail-article,
.related-panel {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(51, 65, 85, 0.9);
  border-radius: 1.2rem;
  padding: 1.25rem;
}

.detail-article h1 {
  margin: 0 0 0.8rem;
  color: #fff;
  font-size: clamp(1.8rem, 3vw, 3rem);
  font-weight: 950;
  letter-spacing: -0.04em;
}

.detail-article h2,
.related-panel h2 {
  color: #fff;
  font-size: 1.35rem;
  margin: 1.2rem 0 0.65rem;
  font-weight: 900;
}

.detail-article p {
  color: #cbd5e1;
  line-height: 1.9;
  margin: 0.6rem 0;
}

.detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0.9rem 0 1rem;
}

.detail-tags span {
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  color: #d1fae5;
  background: rgba(16, 185, 129, 0.16);
  font-size: 0.85rem;
  font-weight: 800;
}

.related-list {
  display: grid;
  gap: 0.85rem;
}

.related-item {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.7rem;
  align-items: center;
  color: #e2e8f0;
}

.related-item img {
  width: 5rem;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 0.7rem;
  background: #1e293b;
}

.related-item h3 {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 900;
}

.related-item p {
  margin: 0.25rem 0 0;
  font-size: 0.8rem;
  color: #94a3b8;
}

.empty-state {
  display: none;
  padding: 2rem;
  text-align: center;
  color: #64748b;
  background: #fff;
  border: 1px solid var(--site-line);
  border-radius: 1rem;
}

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

.site-footer {
  background: #0f172a;
  color: #cbd5e1;
  margin-top: 3rem;
}

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

.footer-inner h2,
.footer-inner h3 {
  color: #fff;
  margin: 0 0 0.8rem;
  font-weight: 900;
}

.footer-inner p,
.footer-inner li {
  color: #94a3b8;
  line-height: 1.75;
}

.footer-inner ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.45rem;
}

.footer-inner a:hover {
  color: #34d399;
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 1.2rem;
  margin-top: 1.4rem;
  color: #94a3b8;
  font-size: 0.9rem;
}

.content-card {
  background: #fff;
  border-radius: 1.2rem;
  border: 1px solid rgba(226, 232, 240, 0.9);
  box-shadow: 0 12px 35px rgba(15, 23, 42, 0.06);
  padding: 1.4rem;
  color: #334155;
  line-height: 1.85;
}

.content-card h2 {
  color: #0f172a;
  font-weight: 900;
  margin: 1.2rem 0 0.5rem;
}

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

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

  .player-layout,
  .detail-content {
    grid-template-columns: 1fr;
  }

  .detail-side {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 1rem;
  }
}

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

  .menu-toggle {
    display: inline-grid;
    place-items: center;
  }

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

  .hero-slider {
    height: 520px;
  }

  .hero-content {
    padding-bottom: 4.7rem;
  }

  .hero-dots {
    left: 1rem;
    right: auto;
  }

  .hero-search-box,
  .filter-panel {
    grid-template-columns: 1fr;
  }

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

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

  .rank-cover {
    display: none;
  }

  .detail-side {
    grid-template-columns: 1fr;
  }

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

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

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

  .primary-btn,
  .secondary-btn {
    width: 100%;
  }
}
