:root {
    --bg: #f8fafc;
    --ink: #0f172a;
    --muted: #64748b;
    --soft: #e2e8f0;
    --panel: #ffffff;
    --dark: #020617;
    --dark-2: #0f172a;
    --cyan: #06b6d4;
    --cyan-2: #0891b2;
    --cyan-3: #22d3ee;
    --shadow: 0 20px 55px rgba(15, 23, 42, 0.12);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: var(--bg);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #fff;
    background: linear-gradient(90deg, #020617, #1e293b, #020617);
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 12px 35px rgba(2, 6, 23, 0.25);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--cyan-3), var(--cyan-2));
    box-shadow: 0 12px 24px rgba(6, 182, 212, 0.28);
}

.brand-text {
    display: grid;
    gap: 2px;
}

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

.brand-text em {
    color: #94a3b8;
    font-size: 12px;
    font-style: normal;
}

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

.desktop-nav a,
.mobile-nav a {
    padding: 10px 16px;
    border-radius: 12px;
    color: #cbd5e1;
    transition: 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-nav a:hover {
    color: #fff;
    background: rgba(51, 65, 85, 0.75);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: rgba(51, 65, 85, 0.75);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: #e2e8f0;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.mobile-nav.is-open {
    display: grid;
}

.hero {
    position: relative;
    height: min(820px, 80vh);
    min-height: 560px;
    overflow: hidden;
    background: var(--dark);
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-layer {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.95), rgba(15, 23, 42, 0.55), rgba(2, 6, 23, 0.1));
}

.hero-content {
    position: absolute;
    left: 50%;
    bottom: 86px;
    width: min(1280px, calc(100% - 32px));
    transform: translateX(-50%);
    color: #fff;
}

.hero-kicker,
.page-hero span,
.section-heading span {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    gap: 6px;
    color: #fff;
    background: var(--cyan);
    border-radius: 999px;
    padding: 7px 16px;
    font-size: 14px;
    font-weight: 700;
}

.hero h1,
.hero h2 {
    width: min(760px, 100%);
    margin: 18px 0 12px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero .hero-movie-title {
    margin-top: 0;
    color: var(--cyan-3);
    font-size: clamp(28px, 4vw, 52px);
}

.hero p {
    width: min(720px, 100%);
    margin: 0 0 28px;
    color: #dbeafe;
    font-size: 20px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 14px;
    font-weight: 800;
    transition: 0.2s ease;
}

.btn.primary {
    color: #fff;
    background: var(--cyan);
    box-shadow: 0 16px 30px rgba(6, 182, 212, 0.28);
}

.btn.primary:hover {
    background: var(--cyan-2);
    transform: translateY(-1px);
}

.btn.ghost {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(15, 23, 42, 0.52);
    backdrop-filter: blur(8px);
}

.btn.plain {
    color: #cffafe;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    transition: 0.2s ease;
}

.hero-dot.is-active {
    width: 36px;
    background: var(--cyan);
}

.search-band,
.content-section,
.split-section,
.footer-grid,
.page-wrap,
.detail-wrap {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
}

.search-band {
    margin-top: -34px;
    position: relative;
    z-index: 8;
    padding: 24px;
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--shadow);
}

.filter-bar {
    display: grid;
    grid-template-columns: 1fr 190px 190px 190px;
    gap: 12px;
    margin-top: 18px;
}

.filter-bar input,
.filter-bar select {
    min-width: 0;
    height: 48px;
    padding: 0 16px;
    border: 1px solid var(--soft);
    border-radius: 14px;
    outline: none;
    background: #fff;
    color: var(--ink);
}

.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.filter-bar.panel {
    padding: 16px;
    background: #fff;
    border: 1px solid rgba(226, 232, 240, 0.88);
    border-radius: 22px;
    box-shadow: 0 16px 45px rgba(15, 23, 42, 0.08);
}

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

.section-heading.compact,
.section-heading.inline {
    display: block;
    margin-bottom: 0;
}

.section-heading span {
    color: var(--cyan-2);
    background: rgba(6, 182, 212, 0.12);
}

.section-heading.light span {
    color: #fff;
    background: rgba(6, 182, 212, 0.9);
}

.section-heading h2 {
    margin: 10px 0 0;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
}

.section-heading a {
    color: var(--cyan-2);
    font-weight: 800;
}

.content-section,
.split-section {
    padding: 76px 0 0;
}

.content-section.flush {
    padding-top: 28px;
}

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

.listing-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    margin-top: 28px;
}

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

.movie-card {
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.14);
}

.poster-wrap {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a, #1e293b);
}

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

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

.poster-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.68), transparent 48%);
    opacity: 0.78;
}

.play-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: rgba(6, 182, 212, 0.88);
    transform: translate(-50%, -50%);
    box-shadow: 0 18px 34px rgba(6, 182, 212, 0.3);
}

.year-badge,
.rank-badge {
    position: absolute;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(8px);
    font-size: 12px;
    font-weight: 800;
}

.year-badge {
    right: 12px;
    bottom: 12px;
    padding: 5px 10px;
}

.rank-badge {
    left: 12px;
    top: 12px;
    min-width: 34px;
    height: 34px;
    background: var(--cyan);
}

.card-body {
    display: grid;
    gap: 7px;
    padding: 16px;
}

.card-body strong {
    display: -webkit-box;
    overflow: hidden;
    color: var(--ink);
    font-size: 17px;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-desc,
.card-tags,
.card-meta {
    display: -webkit-box;
    overflow: hidden;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-tags {
    color: var(--cyan-2);
}

.dark-section {
    margin-top: 76px;
    padding: 76px 0;
    color: #fff;
    background: linear-gradient(135deg, #1e293b, #020617);
}

.dark-section .section-heading,
.dark-section .rank-panel {
    width: min(1280px, calc(100% - 32px));
    margin-left: auto;
    margin-right: auto;
}

.dark-section .section-heading a {
    color: #67e8f9;
}

.rank-panel {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.rank-row {
    display: grid;
    grid-template-columns: 52px 1fr auto;
    gap: 12px;
    align-items: center;
    min-height: 58px;
    padding: 12px 16px;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.18);
}

.rank-row span {
    color: var(--cyan-3);
    font-size: 22px;
    font-weight: 900;
}

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

.rank-row em {
    color: #94a3b8;
    font-style: normal;
    font-size: 13px;
}

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

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

.category-card {
    position: relative;
    display: grid;
    min-height: 170px;
    align-content: end;
    gap: 12px;
    overflow: hidden;
    padding: 22px;
    border-radius: 20px;
    color: #fff;
    background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.45), transparent 34%), linear-gradient(135deg, #0f172a, #1e293b);
    box-shadow: var(--shadow);
}

.category-card::after {
    content: "";
    position: absolute;
    right: -34px;
    top: -34px;
    width: 120px;
    height: 120px;
    border-radius: 999px;
    background: rgba(6, 182, 212, 0.28);
}

.category-card span {
    position: relative;
    z-index: 1;
    font-size: 24px;
    font-weight: 900;
}

.category-card p,
.category-card em {
    position: relative;
    z-index: 1;
    margin: 0;
    color: #cbd5e1;
    font-size: 14px;
    font-style: normal;
}

.category-card.large {
    min-height: 210px;
}

.split-section {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 34px;
    padding-bottom: 76px;
}

.page-hero {
    margin-top: 34px;
    padding: 58px;
    color: #fff;
    border-radius: 28px;
    background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.38), transparent 30%), linear-gradient(135deg, #020617, #1e293b);
    box-shadow: var(--shadow);
}

.page-hero.slim {
    padding: 48px;
}

.page-hero h1 {
    margin: 16px 0 12px;
    font-size: clamp(36px, 5vw, 58px);
    line-height: 1.05;
}

.page-hero p {
    width: min(780px, 100%);
    margin: 0;
    color: #cbd5e1;
    font-size: 18px;
}

.detail-wrap {
    padding-top: 28px;
    padding-bottom: 80px;
}

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

.breadcrumb a {
    color: var(--cyan-2);
    font-weight: 700;
}

.player-section {
    border-radius: 24px;
    overflow: hidden;
    background: var(--dark);
    box-shadow: var(--shadow);
}

.movie-player {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: grid;
    place-items: center;
    gap: 16px;
    padding: 28px;
    color: #fff;
    border: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.78), rgba(2, 6, 23, 0.22));
}

.player-overlay span {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--cyan);
    box-shadow: 0 20px 42px rgba(6, 182, 212, 0.32);
    font-size: 28px;
}

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

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

.detail-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
    margin-top: 28px;
}

.detail-card {
    padding: 28px;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
}

.main-copy h1 {
    margin: 14px 0 14px;
    font-size: clamp(32px, 4vw, 48px);
    line-height: 1.12;
}

.main-copy h2,
.detail-card h2 {
    margin: 28px 0 12px;
    font-size: 22px;
}

.main-copy h2:first-child,
.detail-card h2:first-child {
    margin-top: 0;
}

.lead {
    color: var(--ink);
    font-size: 19px;
    font-weight: 700;
}

.meta-line,
.tag-row,
.tag-list,
.inline-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0;
}

.tag-row span,
.tag-list span,
.inline-links a {
    display: inline-flex;
    padding: 7px 12px;
    border-radius: 999px;
    color: #0e7490;
    background: rgba(6, 182, 212, 0.12);
    font-size: 14px;
    font-weight: 700;
}

.meta-line span {
    color: var(--muted);
}

.main-copy p {
    color: #334155;
    white-space: pre-line;
}

.side-poster {
    overflow: hidden;
    border-radius: 22px;
    background: #0f172a;
    box-shadow: var(--shadow);
}

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

.detail-side {
    display: grid;
    gap: 20px;
    align-content: start;
}

.detail-card dl {
    display: grid;
    grid-template-columns: 74px 1fr;
    gap: 12px 14px;
    margin: 0;
}

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

.detail-card dd {
    margin: 0;
    color: var(--ink);
    font-weight: 700;
}

.side-grid {
    gap: 14px;
}

.side-grid .card-body {
    padding: 12px;
}

.side-grid .card-desc,
.side-grid .card-tags {
    display: none;
}

.site-footer {
    margin-top: 80px;
    padding: 56px 0 0;
    color: #cbd5e1;
    background: linear-gradient(180deg, #0f172a, #020617);
    border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 36px;
}

.footer-brand {
    color: #fff;
    font-size: 20px;
    font-weight: 900;
}

.site-footer h2 {
    margin: 0 0 14px;
    color: #fff;
    font-size: 18px;
}

.site-footer p {
    color: #94a3b8;
}

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

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

.footer-bottom {
    width: min(1280px, calc(100% - 32px));
    margin: 34px auto 0;
    padding: 22px 0;
    color: #64748b;
    border-top: 1px solid rgba(148, 163, 184, 0.16);
    font-size: 14px;
}

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

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

    .menu-toggle {
        display: inline-flex;
    }

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

    .category-grid.overview,
    .split-section,
    .detail-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

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

    .related-box {
        grid-column: 1 / -1;
    }
}

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

    .brand-text em {
        display: none;
    }

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

    .hero {
        height: 72vh;
        min-height: 520px;
    }

    .hero-content {
        bottom: 70px;
    }

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

    .search-band,
    .page-hero,
    .page-hero.slim,
    .detail-card {
        padding: 22px;
    }

    .filter-bar {
        grid-template-columns: 1fr;
    }

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

    .section-heading {
        display: block;
    }

    .section-heading a {
        display: inline-flex;
        margin-top: 10px;
    }

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

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

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

@media (max-width: 500px) {
    .movie-grid,
    .listing-grid,
    .category-grid,
    .category-grid.overview,
    .small-grid,
    .side-grid {
        grid-template-columns: 1fr;
    }

    .hero-actions {
        display: grid;
    }

    .btn {
        width: 100%;
    }
}
