:root {
    color-scheme: dark;
    --bg: #0b1120;
    --bg-soft: #111827;
    --panel: rgba(31, 41, 55, 0.78);
    --panel-strong: rgba(17, 24, 39, 0.94);
    --line: rgba(148, 163, 184, 0.16);
    --text: #f9fafb;
    --muted: #a7b0c0;
    --muted-2: #6b7280;
    --amber: #f59e0b;
    --orange: #ea580c;
    --red: #ef4444;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 20% 0%, rgba(245, 158, 11, 0.16), transparent 32rem),
        radial-gradient(circle at 90% 12%, rgba(234, 88, 12, 0.12), transparent 28rem),
        var(--bg);
    color: var(--text);
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(148, 163, 184, 0.14);
    background: rgba(17, 24, 39, 0.92);
    backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    letter-spacing: 0.02em;
}

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

.brand-text,
.footer-brand {
    background: linear-gradient(90deg, var(--amber), var(--orange));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 1.35rem;
}

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

.nav-link {
    color: #d1d5db;
    font-weight: 700;
    transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--amber);
    transform: translateY(-1px);
}

.mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(31, 41, 55, 0.72);
    color: var(--text);
}

.mobile-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    border-radius: 999px;
    background: currentColor;
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    padding: 10px 16px 18px;
    background: rgba(17, 24, 39, 0.96);
}

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

.mobile-link {
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(31, 41, 55, 0.68);
    color: #d1d5db;
    font-weight: 700;
}

.hero {
    position: relative;
    width: min(1240px, calc(100% - 28px));
    margin: 28px auto 0;
}

.hero-shell {
    position: relative;
    overflow: hidden;
    min-height: 620px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 34px;
    background: var(--panel-strong);
    box-shadow: var(--shadow);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(260px, 0.58fr);
    align-items: center;
    gap: 44px;
    padding: 68px;
    background-position: center;
    background-size: cover;
    opacity: 0;
    visibility: hidden;
    transform: scale(1.015);
    transition: opacity 0.5s ease, visibility 0.5s ease, transform 0.65s ease;
}

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

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: var(--amber);
    font-size: 0.84rem;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
    margin: 0;
    font-size: clamp(2.3rem, 5vw, 4.8rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.hero p,
.page-hero p,
.detail-copy p {
    margin: 22px 0 0;
    color: #d1d5db;
    font-size: 1.08rem;
    line-height: 1.85;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 6px 12px;
    border: 1px solid rgba(245, 158, 11, 0.24);
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    color: #fde68a;
    font-size: 0.86rem;
    font-weight: 700;
}

.hero-actions,
.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 30px;
}

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

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

.btn.primary {
    background: linear-gradient(90deg, var(--amber), var(--orange));
    color: #111827;
    box-shadow: 0 16px 34px rgba(245, 158, 11, 0.26);
}

.btn.ghost {
    border: 1px solid rgba(245, 158, 11, 0.32);
    background: rgba(17, 24, 39, 0.42);
    color: #fde68a;
}

.btn.small {
    min-height: 38px;
    padding: 0 16px;
    font-size: 0.9rem;
}

.hero-poster {
    position: relative;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 30px;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55);
    transform: rotate(2deg);
}

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: inherit;
}

.hero-controls {
    position: absolute;
    left: 68px;
    right: 68px;
    bottom: 34px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
}

.hero-arrow,
.hero-dot {
    pointer-events: auto;
}

.hero-arrow {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 16px;
    background: rgba(17, 24, 39, 0.74);
    color: var(--text);
    font-size: 2rem;
}

.hero-dots {
    display: flex;
    gap: 8px;
}

.hero-dot {
    width: 28px;
    height: 6px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.28);
}

.hero-dot.is-active {
    width: 48px;
    background: linear-gradient(90deg, var(--amber), var(--orange));
}

.hero-search {
    position: relative;
    z-index: 2;
    width: min(920px, calc(100% - 28px));
    margin: -34px auto 0;
    padding: 18px;
    border: 1px solid rgba(245, 158, 11, 0.16);
    border-radius: 24px;
    background: rgba(17, 24, 39, 0.9);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.32);
    backdrop-filter: blur(16px);
}

.hero-search label,
.filter-bar label span {
    display: block;
    margin-bottom: 8px;
    color: var(--amber);
    font-size: 0.82rem;
    font-weight: 900;
}

.search-box {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
}

.search-box input,
.filter-bar input,
.filter-bar select {
    width: 100%;
    min-height: 48px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 16px;
    outline: none;
    background: rgba(31, 41, 55, 0.72);
    color: var(--text);
    padding: 0 16px;
}

.search-box input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: rgba(245, 158, 11, 0.7);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.12);
}

.search-box a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    border-radius: 16px;
    background: rgba(245, 158, 11, 0.12);
    color: #fde68a;
    font-weight: 900;
}

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

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

.section-head.slim {
    margin-bottom: 18px;
}

.section-head h2 {
    margin: 0;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    letter-spacing: -0.03em;
}

.section-head p {
    margin: 8px 0 0;
    max-width: 720px;
    color: var(--muted);
    line-height: 1.8;
}

.section-head a,
.panel-title a {
    color: var(--amber);
    font-weight: 900;
}

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

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

.movie-card {
    position: relative;
    display: block;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 22px;
    background: rgba(31, 41, 55, 0.54);
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

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

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

.poster-frame img {
    transition: transform 0.35s ease, filter 0.35s ease;
}

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

.poster-shade {
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), transparent);
}

.card-info {
    display: grid;
    gap: 8px;
    padding: 14px;
}

.card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.card-meta em,
.card-meta i {
    font-style: normal;
    font-size: 0.75rem;
}

.card-meta em {
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    color: #fbbf24;
    font-weight: 900;
}

.card-meta i {
    color: var(--muted-2);
    font-weight: 700;
}

.card-info strong {
    min-height: 42px;
    color: var(--text);
    font-size: 0.98rem;
    line-height: 1.45;
}

.card-info small {
    min-height: 38px;
    color: var(--muted);
    font-size: 0.8rem;
    line-height: 1.55;
}

.rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: grid;
    min-width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    color: #111827;
    font-size: 0.9rem;
    box-shadow: 0 10px 22px rgba(245, 158, 11, 0.28);
}

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

.ranking-panel {
    position: sticky;
    top: 100px;
    padding: 22px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 24px;
    background: rgba(17, 24, 39, 0.82);
    box-shadow: var(--shadow);
}

.panel-title {
    display: flex;
    justify-content: space-between;
    margin-bottom: 16px;
    font-weight: 900;
}

.ranking-list {
    display: grid;
    gap: 10px;
}

.ranking-row {
    display: grid;
    grid-template-columns: 38px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 12px;
    border-radius: 16px;
    background: rgba(31, 41, 55, 0.56);
}

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

.ranking-row span {
    color: var(--amber);
    font-weight: 900;
}

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

.ranking-row em {
    color: var(--muted-2);
    font-style: normal;
    font-size: 0.82rem;
}

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

.channel-card,
.category-overview-card {
    display: grid;
    gap: 14px;
    padding: 22px;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 24px;
    background: rgba(31, 41, 55, 0.58);
}

.channel-main {
    display: grid;
    gap: 8px;
}

.channel-main span,
.category-title {
    color: var(--amber);
    font-size: 1.14rem;
    font-weight: 900;
}

.channel-main strong,
.category-overview-card p {
    color: #d1d5db;
    font-size: 0.94rem;
    line-height: 1.7;
}

.channel-links,
.category-sample,
.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.channel-links a,
.category-sample a,
.footer-links a {
    display: inline-flex;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(17, 24, 39, 0.56);
    color: var(--muted);
    font-size: 0.82rem;
}

.channel-links a:hover,
.category-sample a:hover,
.footer-links a:hover {
    color: #fde68a;
    background: rgba(245, 158, 11, 0.13);
}

.page-main {
    padding-top: 34px;
}

.page-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 280px;
    padding: 42px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 30px;
    background:
        linear-gradient(135deg, rgba(245, 158, 11, 0.14), transparent 36%),
        linear-gradient(115deg, rgba(17, 24, 39, 0.96), rgba(31, 41, 55, 0.78));
    box-shadow: var(--shadow);
}

.small-hero h1,
.category-hero h1,
.ranking-hero h1 {
    font-size: clamp(2rem, 4vw, 3.5rem);
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 16px;
    margin-top: 26px;
    padding: 18px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 22px;
    background: rgba(17, 24, 39, 0.78);
}

.empty-state {
    display: none;
    padding: 34px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 22px;
    background: rgba(31, 41, 55, 0.54);
    color: var(--muted);
    text-align: center;
}

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

.movie-card.is-hidden {
    display: none;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin-bottom: 22px;
    color: var(--muted);
}

.breadcrumb a {
    color: #fde68a;
}

.detail-top {
    display: grid;
    grid-template-columns: 310px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
    padding: 34px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 30px;
    background:
        radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.18), transparent 26rem),
        rgba(17, 24, 39, 0.84);
    box-shadow: var(--shadow);
}

.detail-poster {
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 26px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
}

.player-section,
.story-section {
    margin-top: 42px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 28px;
    background: #000;
    box-shadow: var(--shadow);
}

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

.play-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    border: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
    color: var(--text);
}

.play-overlay.is-hidden {
    display: none;
}

.play-circle {
    display: grid;
    width: 76px;
    height: 76px;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    color: #111827;
    font-size: 2rem;
    box-shadow: 0 18px 44px rgba(245, 158, 11, 0.32);
}

.story-section {
    display: grid;
    grid-template-columns: 1fr;
    gap: 18px;
}

.story-section article {
    padding: 28px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 24px;
    background: rgba(31, 41, 55, 0.54);
}

.story-section h2 {
    margin: 0 0 12px;
    font-size: 1.35rem;
}

.story-section p {
    margin: 0;
    color: #d1d5db;
    line-height: 1.95;
}

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

.info-list div {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 10px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(17, 24, 39, 0.48);
}

.info-list dt {
    color: var(--amber);
    font-weight: 900;
}

.info-list dd {
    margin: 0;
    color: #d1d5db;
}

.site-footer {
    margin-top: 86px;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    background: rgba(17, 24, 39, 0.84);
}

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

.footer-grid h2 {
    margin: 0 0 14px;
    font-size: 1rem;
}

.footer-grid p {
    max-width: 520px;
    color: var(--muted);
    line-height: 1.8;
}

.footer-bottom {
    padding: 18px;
    border-top: 1px solid rgba(148, 163, 184, 0.1);
    color: var(--muted-2);
    text-align: center;
}

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

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

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

    .ranking-panel {
        position: static;
    }
}

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

    .mobile-toggle {
        display: block;
    }

    .hero-shell {
        min-height: 720px;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        padding: 38px 26px 82px;
    }

    .hero-poster {
        max-width: 240px;
        margin: 0 auto;
    }

    .hero-controls {
        left: 26px;
        right: 26px;
    }

    .search-box,
    .filter-bar,
    .detail-top,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .page-hero {
        align-items: flex-start;
        flex-direction: column;
        padding: 30px;
    }

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

@media (max-width: 640px) {
    .layout {
        width: min(100% - 22px, 1180px);
    }

    .header-inner {
        min-height: 66px;
    }

    .brand-text {
        font-size: 1.12rem;
    }

    .hero {
        width: min(100% - 18px, 1240px);
        margin-top: 16px;
    }

    .hero-shell {
        min-height: 660px;
        border-radius: 24px;
    }

    .hero h1,
    .detail-copy h1 {
        font-size: 2.15rem;
    }

    .hero p,
    .page-hero p,
    .detail-copy p {
        font-size: 0.98rem;
    }

    .hero-search {
        width: min(100% - 18px, 920px);
        margin-top: 14px;
    }

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

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

    .content-section {
        padding-top: 48px;
    }

    .section-head {
        display: grid;
    }

    .detail-top,
    .story-section article {
        padding: 22px;
        border-radius: 22px;
    }

    .player-shell {
        border-radius: 20px;
    }

    .info-list {
        grid-template-columns: 1fr;
    }

    .ranking-row {
        grid-template-columns: 34px 1fr;
    }

    .ranking-row em {
        display: none;
    }
}
