:root {
    color-scheme: dark;
    --bg: #0f172a;
    --bg-deep: #020617;
    --panel: rgba(15, 23, 42, 0.78);
    --panel-solid: #111827;
    --muted: #94a3b8;
    --text: #f8fafc;
    --soft: #cbd5e1;
    --line: rgba(148, 163, 184, 0.18);
    --amber: #f59e0b;
    --amber-2: #fbbf24;
    --red: #ef4444;
    --radius: 18px;
    --shadow: 0 24px 60px rgba(0, 0, 0, 0.36);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(245, 158, 11, 0.12), transparent 26rem),
        linear-gradient(180deg, #0f172a 0%, #1e293b 38%, #0f172a 100%);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

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

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

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.logo-mark {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #111827;
    background: linear-gradient(135deg, var(--amber), var(--amber-2));
    box-shadow: 0 12px 30px rgba(245, 158, 11, 0.3);
}

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

.nav-link {
    padding: 9px 14px;
    border-radius: 999px;
    color: var(--soft);
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--amber-2);
    background: rgba(245, 158, 11, 0.11);
}

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.8);
    color: var(--text);
}

.menu-button span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: var(--text);
    border-radius: 999px;
}

.hero {
    position: relative;
    min-height: 68vh;
    overflow: hidden;
    background: var(--bg-deep);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.85s 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-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.66) 44%, rgba(15, 23, 42, 0.18) 100%),
        linear-gradient(0deg, #0f172a 0%, rgba(15, 23, 42, 0.12) 48%, rgba(15, 23, 42, 0.3) 100%);
}

.hero-copy {
    position: absolute;
    left: max(24px, calc((100vw - 1280px) / 2));
    bottom: clamp(54px, 12vh, 120px);
    width: min(680px, calc(100% - 48px));
}

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

.hero h1,
.hero h2 {
    margin: 0;
    max-width: 880px;
    font-size: clamp(38px, 7vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-one-line {
    margin: 20px 0 0;
    max-width: 640px;
    color: var(--soft);
    font-size: clamp(16px, 2vw, 20px);
}

.hero-tags,
.detail-meta,
.detail-tags,
.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

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

.hero-tags span,
.detail-meta span,
.chip {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 10px;
    border: 1px solid rgba(245, 158, 11, 0.28);
    border-radius: 999px;
    color: #fde68a;
    background: rgba(245, 158, 11, 0.12);
    font-size: 12px;
    font-style: normal;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 28px;
}

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

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

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

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

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.5);
    color: var(--text);
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

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

.hero-dot {
    width: 30px;
    height: 5px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.38);
    cursor: pointer;
}

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

.page-main {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
}

.top-spaced {
    padding-top: 36px;
}

.section {
    padding: 44px 0;
}

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

.section-head.center {
    display: block;
    max-width: 720px;
    margin: 0 auto 28px;
    text-align: center;
}

.section-head h2,
.side-panel h2,
.text-card h2 {
    margin: 0;
    font-size: clamp(26px, 4vw, 40px);
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.section-head p,
.side-panel p,
.page-hero p,
.text-card p {
    color: var(--soft);
}

.section-link {
    color: var(--amber-2);
    font-weight: 800;
}

.filter-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin: 0 0 24px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.62);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.16);
}

.search-box {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 240px;
    padding: 0 16px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.56);
    border: 1px solid var(--line);
}

.search-box span {
    color: var(--amber-2);
    font-size: 13px;
    font-weight: 800;
}

.search-box input,
.filter-select {
    width: 100%;
    min-height: 44px;
    border: 0;
    outline: none;
    color: var(--text);
    background: transparent;
}

.filter-actions {
    display: flex;
    gap: 10px;
}

.filter-select {
    width: 150px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.56);
}

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

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

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

.movie-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.72);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.16);
    transition: transform 0.2s ease, border 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    border-color: rgba(245, 158, 11, 0.56);
    box-shadow: 0 24px 56px rgba(0, 0, 0, 0.28);
}

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

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

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

.poster-mask {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.76), rgba(2, 6, 23, 0.08));
    transition: opacity 0.25s ease;
}

.movie-card:hover .poster-mask {
    opacity: 1;
}

.play-dot,
.play-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    color: #111827;
    background: var(--amber);
    font-weight: 900;
    box-shadow: 0 14px 34px rgba(245, 158, 11, 0.32);
}

.rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    min-width: 36px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 8px;
    border-radius: 999px;
    color: #111827;
    background: var(--amber-2);
    font-size: 12px;
    font-weight: 900;
}

.card-body {
    display: block;
    padding: 14px;
}

.card-body strong {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 16px;
}

.card-line {
    display: -webkit-box;
    min-height: 42px;
    margin-top: 7px;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    color: var(--muted);
    font-size: 13px;
}

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

.card-tags {
    margin-top: 10px;
}

.card-tags .chip {
    color: #cbd5e1;
    border-color: rgba(148, 163, 184, 0.2);
    background: rgba(51, 65, 85, 0.72);
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
    align-items: start;
}

.side-panel,
.text-card,
.page-hero,
.detail-hero,
.watch-section,
.breadcrumb {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.72);
    box-shadow: var(--shadow);
}

.side-panel {
    position: sticky;
    top: 96px;
    padding: 24px;
}

.rank-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.rank-row {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 8px;
    border-radius: 14px;
    background: rgba(2, 6, 23, 0.38);
    transition: background 0.2s ease;
}

.rank-row:hover {
    background: rgba(245, 158, 11, 0.1);
}

.rank-row img {
    width: 58px;
    height: 80px;
    border-radius: 10px;
    object-fit: cover;
}

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

.rank-row em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

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

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

.category-tile {
    position: relative;
    min-height: 230px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel-solid);
    box-shadow: 0 16px 42px rgba(0, 0, 0, 0.22);
}

.category-tile img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.category-tile:hover img {
    transform: scale(1.08);
}

.category-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.9), rgba(2, 6, 23, 0.2));
}

.category-text {
    position: absolute;
    inset: auto 0 0 0;
    display: grid;
    gap: 8px;
    padding: 22px;
}

.category-text strong {
    font-size: 24px;
}

.category-text em {
    color: var(--soft);
    font-style: normal;
}

.mini-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mini-links a,
.small-links a {
    display: inline-flex;
    padding: 5px 10px;
    border-radius: 999px;
    color: #fde68a;
    background: rgba(245, 158, 11, 0.16);
    font-size: 12px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(30px, 6vw, 56px);
}

.compact-hero {
    text-align: center;
}

.page-hero h1 {
    margin: 0;
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 760px;
    margin: 16px auto 0;
}

.channel-hero {
    min-height: 320px;
    display: flex;
    align-items: end;
    background-image:
        linear-gradient(90deg, rgba(2, 6, 23, 0.9), rgba(15, 23, 42, 0.6)),
        var(--channel-image);
    background-position: center;
    background-size: cover;
}

.channel-hero p {
    margin-left: 0;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 20px;
    padding: 14px 18px;
    color: var(--muted);
    font-size: 14px;
    box-shadow: none;
}

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

.detail-hero {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 30px;
    align-items: center;
    padding: clamp(20px, 4vw, 34px);
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: calc(var(--radius) - 4px);
    object-fit: cover;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.36);
}

.detail-copy h1 {
    margin: 0;
    font-size: clamp(34px, 6vw, 64px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.detail-one-line {
    color: var(--soft);
    font-size: 18px;
}

.detail-meta,
.detail-tags {
    margin-top: 14px;
}

.watch-section {
    margin-top: 26px;
    padding: clamp(18px, 4vw, 30px);
}

.player {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius);
    background: #000;
}

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

.play-layer {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: var(--text);
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.74), rgba(2, 6, 23, 0.24));
    cursor: pointer;
}

.play-layer span:last-child {
    max-width: 80%;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 20px;
    font-weight: 800;
}

.player.is-playing .play-layer {
    display: none;
}

.detail-text {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.text-card {
    padding: clamp(20px, 4vw, 30px);
}

.text-card p {
    margin: 16px 0 0;
    font-size: 16px;
}

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

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

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

.footer-inner {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 34px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    color: var(--muted);
}

.footer-inner strong {
    color: var(--text);
    font-size: 18px;
}

.footer-inner p {
    margin: 6px 0 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
}

.footer-links a {
    color: var(--soft);
}

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

    .split-section {
        grid-template-columns: 1fr;
    }

    .side-panel {
        position: static;
    }

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

@media (max-width: 780px) {
    .header-inner {
        min-height: 64px;
    }

    .menu-button {
        display: block;
    }

    .site-nav {
        position: absolute;
        top: 64px;
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: 16px;
        background: rgba(2, 6, 23, 0.94);
        box-shadow: var(--shadow);
    }

    .site-nav.is-open {
        display: flex;
    }

    .hero {
        min-height: 72vh;
    }

    .hero-copy {
        left: 20px;
        bottom: 70px;
        width: calc(100% - 40px);
    }

    .hero-arrow {
        display: none;
    }

    .section-head,
    .filter-panel,
    .footer-inner {
        align-items: stretch;
        flex-direction: column;
    }

    .filter-actions {
        flex-direction: column;
    }

    .filter-select {
        width: 100%;
    }

    .movie-grid,
    .compact-grid,
    .editor-grid,
    .related-grid,
    .ranking-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

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

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

    .detail-poster {
        max-width: 280px;
        margin: 0 auto;
    }

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

    .footer-links {
        justify-content: flex-start;
    }
}

@media (max-width: 460px) {
    .page-main,
    .header-inner,
    .footer-inner {
        width: min(100% - 24px, 1280px);
    }

    .movie-grid,
    .compact-grid,
    .editor-grid,
    .related-grid,
    .ranking-grid {
        grid-template-columns: 1fr;
    }

    .card-body strong {
        white-space: normal;
    }
}
