:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.82);
    --panel-strong: rgba(15, 23, 42, 0.96);
    --muted: #94a3b8;
    --text: #f8fafc;
    --soft: #cbd5e1;
    --line: rgba(148, 163, 184, 0.18);
    --amber: #f59e0b;
    --amber-soft: #fbbf24;
    --rose: #fb7185;
    --sky: #38bdf8;
    --radius-xl: 32px;
    --radius-lg: 24px;
    --radius-md: 18px;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background:
        radial-gradient(circle at 18% 8%, rgba(245, 158, 11, 0.16), transparent 32rem),
        radial-gradient(circle at 82% 18%, rgba(56, 189, 248, 0.10), transparent 28rem),
        linear-gradient(135deg, #030712 0%, #0f172a 45%, #020617 100%);
}

body::before {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    content: "";
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
    background-size: 52px 52px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.85), transparent 86%);
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(2, 6, 23, 0.74);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(22px);
}

.header-shell,
.footer-shell,
.content-section,
.hero-section,
.page-hero,
.detail-shell {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.header-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand-mark {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    color: #111827;
    background: linear-gradient(135deg, var(--amber-soft), var(--amber));
    border-radius: 15px;
    box-shadow: 0 14px 38px rgba(245, 158, 11, 0.32);
}

.brand-text {
    font-size: 20px;
}

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

.nav-link,
.mobile-link {
    color: var(--soft);
    border: 1px solid transparent;
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.nav-link {
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 14px;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
    color: #fff7ed;
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.28);
}

.mobile-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    width: 44px;
    height: 44px;
    justify-content: center;
    align-items: center;
    color: var(--text);
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid var(--line);
    border-radius: 14px;
}

.mobile-toggle span {
    width: 20px;
    height: 2px;
    background: var(--text);
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 12px;
    background: rgba(15, 23, 42, 0.96);
    border: 1px solid var(--line);
    border-radius: 18px;
}

.mobile-nav.open {
    display: grid;
    gap: 8px;
}

.mobile-link {
    padding: 12px 14px;
    border-radius: 14px;
}

.hero-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 24px;
    padding: 34px 0 18px;
}

.hero-stage {
    position: relative;
    min-height: 560px;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: end;
    padding: clamp(28px, 6vw, 72px);
    background-position: center;
    background-size: cover;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-copy {
    max-width: 680px;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--amber-soft);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero-copy h1,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    letter-spacing: -0.04em;
    line-height: 0.98;
}

.hero-copy h1 {
    max-width: 760px;
    font-size: clamp(42px, 7vw, 86px);
}

.hero-summary,
.page-hero p,
.detail-one-line {
    color: var(--soft);
    line-height: 1.9;
}

.hero-summary {
    max-width: 660px;
    margin: 24px 0 0;
    font-size: 17px;
}

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

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

.hero-tags span,
.tag-row span,
.detail-tags a,
.rank-meta span,
.detail-stats span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 6px 10px;
    color: #fde68a;
    background: rgba(245, 158, 11, 0.12);
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.hero-actions,
.page-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.primary-btn,
.ghost-btn,
.section-link,
.rank-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.primary-btn {
    color: #111827;
    background: linear-gradient(135deg, var(--amber-soft), var(--amber));
    box-shadow: 0 18px 38px rgba(245, 158, 11, 0.28);
}

.ghost-btn,
.section-link,
.rank-action {
    color: var(--text);
    background: rgba(15, 23, 42, 0.64);
    border: 1px solid var(--line);
}

.primary-btn:hover,
.ghost-btn:hover,
.section-link:hover,
.rank-action:hover {
    transform: translateY(-2px);
}

.hero-controls {
    position: absolute;
    left: 48px;
    bottom: 26px;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 34px;
    height: 6px;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.32);
    border: 0;
    border-radius: 999px;
}

.hero-dot.active {
    background: var(--amber-soft);
}

.hero-side-card {
    align-self: stretch;
    padding: 30px;
    background:
        linear-gradient(180deg, rgba(245, 158, 11, 0.12), rgba(15, 23, 42, 0.84)),
        rgba(15, 23, 42, 0.88);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.hero-side-card h2 {
    margin: 0;
    font-size: 32px;
    line-height: 1.18;
}

.hero-side-card p {
    color: var(--soft);
    line-height: 1.8;
}

.hero-search-card {
    display: grid;
    gap: 12px;
    margin-top: 28px;
}

.hero-search-card input,
.search-box input,
.select-box select {
    width: 100%;
    min-height: 48px;
    color: var(--text);
    background: rgba(2, 6, 23, 0.72);
    border: 1px solid var(--line);
    border-radius: 16px;
    outline: 0;
}

.hero-search-card input,
.search-box input {
    padding: 0 16px;
}

.hero-search-card a {
    display: inline-flex;
    justify-content: center;
    padding: 13px 16px;
    color: #111827;
    background: var(--amber-soft);
    border-radius: 16px;
    font-weight: 800;
}

.content-section {
    padding: 54px 0;
}

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

.section-head h2 {
    margin: 0;
    font-size: clamp(28px, 4vw, 44px);
    letter-spacing: -0.03em;
}

.compact-head h2 {
    font-size: 30px;
}

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

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

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

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

.movie-card {
    overflow: hidden;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: 0 18px 52px rgba(0, 0, 0, 0.22);
    transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(245, 158, 11, 0.42);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: #0f172a;
}

.poster-link img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease, filter 0.35s ease;
}

.movie-card:hover .poster-link img {
    transform: scale(1.06);
    filter: saturate(1.08) contrast(1.04);
}

.poster-glow {
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    background: linear-gradient(180deg, transparent, rgba(2, 6, 23, 0.86));
}

.card-score {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 6px 9px;
    color: #111827;
    background: var(--amber-soft);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
}

.card-body {
    padding: 16px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: var(--muted);
    font-size: 12px;
}

.card-title {
    margin: 10px 0 8px;
    font-size: 20px;
    line-height: 1.28;
}

.movie-card.compact .card-title {
    font-size: 17px;
}

.card-title a:hover,
.rank-content a:hover,
.sample-links a:hover,
.footer-links a:hover {
    color: var(--amber-soft);
}

.card-body p {
    margin: 0;
    color: var(--soft);
    font-size: 14px;
    line-height: 1.7;
}

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

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

.category-tile,
.category-card-large {
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-tile {
    min-height: 220px;
    padding: 22px;
}

.category-tile:hover,
.category-card-large:hover {
    transform: translateY(-5px);
    border-color: rgba(245, 158, 11, 0.42);
}

.category-tile span,
.category-card-cover span {
    color: var(--amber-soft);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.12em;
}

.category-tile h2,
.category-card-body h2 {
    margin: 14px 0 10px;
}

.category-tile p,
.category-card-body p,
.footer-brand p {
    color: var(--soft);
    line-height: 1.8;
}

.category-tile strong {
    display: block;
    margin-top: 18px;
    color: #fff7ed;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(320px, 0.75fr);
    gap: 24px;
}

.spotlight-panel,
.ranking-panel {
    padding: 26px;
    background: rgba(15, 23, 42, 0.62);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 74px 50px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 14px;
    background: rgba(2, 6, 23, 0.56);
    border: 1px solid var(--line);
    border-radius: 20px;
}

.small-rank-list .rank-item {
    grid-template-columns: 58px 42px minmax(0, 1fr);
}

.small-rank-list .rank-action {
    display: none;
}

.rank-cover {
    display: block;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 14px;
}

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

.rank-index {
    color: var(--amber-soft);
    font-size: 24px;
    font-weight: 900;
}

.rank-content h2,
.rank-content h3 {
    margin: 0 0 8px;
    font-size: 18px;
}

.rank-content p {
    margin: 0 0 10px;
    color: var(--soft);
    line-height: 1.65;
}

.rank-meta span {
    color: var(--muted);
    background: rgba(148, 163, 184, 0.08);
    border-color: rgba(148, 163, 184, 0.16);
}

.page-hero {
    margin-top: 34px;
    padding: clamp(42px, 8vw, 88px);
    overflow: hidden;
    background:
        radial-gradient(circle at 20% 10%, rgba(245, 158, 11, 0.18), transparent 28rem),
        radial-gradient(circle at 86% 20%, rgba(56, 189, 248, 0.12), transparent 26rem),
        rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

.page-hero h1 {
    max-width: 820px;
    font-size: clamp(38px, 6vw, 72px);
}

.page-hero p {
    max-width: 760px;
    margin: 20px 0 0;
    font-size: 17px;
}

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

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

.category-card-cover {
    display: flex;
    align-items: end;
    min-height: 260px;
    padding: 22px;
    background-position: center;
    background-size: cover;
}

.category-card-body {
    padding: 24px;
}

.sample-links,
.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.sample-links a,
.footer-links a {
    color: var(--soft);
    font-size: 14px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 14px;
    margin-bottom: 24px;
    padding: 16px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: 22px;
}

.search-box span,
.select-box span {
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.select-box select {
    padding: 0 12px;
}

.empty-state {
    display: none;
    margin: 22px 0 0;
    padding: 20px;
    color: var(--soft);
    text-align: center;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: 18px;
}

.empty-state.show {
    display: block;
}

.detail-hero {
    position: relative;
    overflow: hidden;
    padding: 54px 0;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    z-index: -1;
    background-position: center;
    background-size: cover;
    filter: saturate(1.05);
}

.detail-shell {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 34px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
}

.detail-poster img {
    aspect-ratio: 2 / 3;
    height: auto;
    object-fit: cover;
}

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

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

.detail-info h1 {
    max-width: 850px;
    font-size: clamp(42px, 6vw, 78px);
}

.detail-one-line {
    max-width: 860px;
    margin: 22px 0 0;
    font-size: 18px;
}

.detail-tags,
.detail-stats {
    margin-top: 18px;
}

.detail-tags a {
    color: #fde68a;
}

.player-card {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: #000;
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 14px;
    cursor: pointer;
    color: var(--text);
    text-align: center;
    background: radial-gradient(circle at center, rgba(245, 158, 11, 0.22), rgba(2, 6, 23, 0.68));
    border: 0;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-icon {
    display: grid;
    width: 86px;
    height: 86px;
    place-items: center;
    padding-left: 6px;
    color: #111827;
    background: linear-gradient(135deg, var(--amber-soft), var(--amber));
    border-radius: 50%;
    box-shadow: 0 20px 58px rgba(245, 158, 11, 0.34);
    font-size: 32px;
}

.player-overlay strong {
    font-size: clamp(22px, 4vw, 38px);
}

.detail-article {
    margin-top: 30px;
    padding: 28px;
    background: rgba(15, 23, 42, 0.76);
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
}

.detail-article h2 {
    margin: 0 0 14px;
    font-size: 28px;
}

.detail-article h2:not(:first-child) {
    margin-top: 26px;
}

.detail-article p {
    margin: 0;
    color: var(--soft);
    font-size: 16px;
    line-height: 2;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-top: 26px;
}

.info-grid div {
    padding: 16px;
    background: rgba(2, 6, 23, 0.5);
    border: 1px solid var(--line);
    border-radius: 18px;
}

.info-grid span {
    display: block;
    color: var(--muted);
    font-size: 12px;
}

.info-grid strong {
    display: block;
    margin-top: 6px;
}

.next-prev {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 18px;
}

.next-prev a {
    padding: 16px;
    color: var(--soft);
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
    border-radius: 18px;
}

.next-prev a:hover {
    color: var(--amber-soft);
    border-color: rgba(245, 158, 11, 0.36);
}

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

.footer-shell {
    display: grid;
    grid-template-columns: 1.1fr 1fr 1fr;
    gap: 28px;
    padding: 44px 0 24px;
}

.footer-group h2 {
    margin: 0 0 14px;
    font-size: 18px;
}

.footer-links {
    flex-direction: column;
    align-items: flex-start;
}

.copyright {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 28px;
    color: var(--muted);
    font-size: 13px;
}

.hidden-card {
    display: none !important;
}

@media (max-width: 1100px) {
    .hero-section,
    .split-section,
    .detail-shell,
    .footer-shell {
        grid-template-columns: 1fr;
    }

    .hero-side-card {
        display: none;
    }

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

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

    .mobile-toggle {
        display: flex;
    }

    .hero-stage {
        min-height: 520px;
    }

    .hero-slide {
        padding: 32px 22px 62px;
    }

    .hero-controls {
        left: 24px;
    }

    .section-head,
    .filter-panel,
    .rank-item,
    .next-prev {
        grid-template-columns: 1fr;
    }

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

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

    .rank-action {
        width: 100%;
    }

    .detail-shell {
        align-items: start;
    }

    .detail-poster {
        max-width: 260px;
    }
}

@media (max-width: 560px) {
    .header-shell,
    .footer-shell,
    .content-section,
    .hero-section,
    .page-hero,
    .detail-shell {
        width: min(100% - 22px, 1180px);
    }

    .brand-text {
        font-size: 18px;
    }

    .hero-stage {
        min-height: 500px;
        border-radius: 22px;
    }

    .hero-copy h1,
    .page-hero h1,
    .detail-info h1 {
        line-height: 1.08;
    }

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

    .page-hero,
    .detail-article,
    .spotlight-panel,
    .ranking-panel {
        padding: 24px;
        border-radius: 22px;
    }

    .content-section {
        padding: 34px 0;
    }

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

    .rank-index {
        position: absolute;
        margin-left: 8px;
    }

    .rank-content,
    .rank-action {
        grid-column: 1 / -1;
    }
}
