:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: #0f172a;
    --panel-soft: #111827;
    --panel-light: #1e293b;
    --text: #ffffff;
    --muted: #94a3b8;
    --muted-strong: #cbd5e1;
    --line: rgba(148, 163, 184, 0.18);
    --accent: #f59e0b;
    --accent-dark: #d97706;
    --radius: 18px;
    --shadow: 0 22px 60px rgba(0, 0, 0, 0.42);
}

* {
    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.12), transparent 28rem),
        radial-gradient(circle at 95% 12%, rgba(37, 99, 235, 0.14), transparent 30rem),
        var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.94);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

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

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

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent), #ef4444);
    color: #fff;
    box-shadow: 0 12px 30px rgba(245, 158, 11, 0.25);
}

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

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

.nav-link {
    color: var(--muted-strong);
    font-size: 15px;
    font-weight: 650;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--accent);
}

.menu-toggle {
    display: none;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.86);
    color: var(--text);
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    padding: 10px 16px 14px;
    background: #0f172a;
}

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

.mobile-link {
    display: block;
    padding: 10px 12px;
    border-radius: 12px;
    color: var(--muted-strong);
}

.mobile-link:hover,
.mobile-link.is-active {
    background: rgba(245, 158, 11, 0.12);
    color: var(--accent);
}

.hero {
    padding-top: 64px;
}

.hero-stage {
    position: relative;
    height: 70vh;
    min-height: 560px;
    overflow: hidden;
    background: #020617;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.85s ease;
    background: linear-gradient(135deg, var(--poster-a), var(--poster-b));
}

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

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

.hero-slide img.image-hidden {
    opacity: 0;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.86) 38%, rgba(2, 6, 23, 0.22) 100%),
        linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0) 32%);
}

.hero-copy {
    position: absolute;
    z-index: 2;
    left: max(24px, calc((100% - 1180px) / 2));
    bottom: 96px;
    width: min(660px, calc(100% - 48px));
}

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

.hero-copy h1,
.hero-copy h2 {
    margin: 0 0 18px;
    font-size: clamp(42px, 7vw, 72px);
    line-height: 1.04;
    letter-spacing: -0.04em;
}

.hero-copy p:not(.eyebrow) {
    margin: 0 0 28px;
    color: var(--muted-strong);
    font-size: 18px;
    max-width: 640px;
}

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

.hero-tags span,
.tag-row span,
.detail-meta span,
.ranking-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.18);
    color: var(--muted-strong);
    font-size: 13px;
}

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

.primary-button,
.ghost-button,
.inline-search button,
.filter-grid button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 12px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.primary-button,
.inline-search button,
.filter-grid button {
    border: 0;
    background: var(--accent);
    color: #fff;
}

.primary-button:hover,
.inline-search button:hover,
.filter-grid button:hover {
    background: var(--accent-dark);
    transform: translateY(-1px);
}

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

.ghost-button:hover {
    border-color: var(--accent);
    transform: translateY(-1px);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 40px;
    line-height: 1;
    transform: translateY(-50%);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

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

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

.page-top {
    padding-top: 104px;
}

.search-strip {
    margin-top: -46px;
    position: relative;
    z-index: 5;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 24px;
    align-items: center;
    padding: 24px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.92);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.search-strip h2,
.section-head h2,
.page-title-block h1,
.related-panel h2,
.detail-card h1,
.detail-card h2,
.text-panel h2 {
    margin: 0;
}

.search-strip p,
.page-title-block p,
.text-panel p,
.detail-card p,
.card-copy p,
.ranking-copy p {
    color: var(--muted);
}

.inline-search,
.filter-grid {
    display: flex;
    gap: 12px;
}

.inline-search input,
.filter-grid input,
.filter-grid select {
    width: 100%;
    min-height: 44px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 12px;
    background: rgba(2, 6, 23, 0.72);
    color: var(--text);
    padding: 0 14px;
    outline: none;
}

.inline-search input:focus,
.filter-grid input:focus,
.filter-grid select:focus {
    border-color: rgba(245, 158, 11, 0.75);
}

.content-section {
    margin: 64px 0;
}

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

.section-head h2 {
    font-size: clamp(26px, 4vw, 36px);
    letter-spacing: -0.03em;
}

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

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

.movie-card {
    min-width: 0;
}

.poster {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.24), transparent 8rem),
        linear-gradient(135deg, var(--poster-a), var(--poster-b));
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.34);
    transform: translateZ(0);
}

.poster-vertical {
    aspect-ratio: 2 / 3;
}

.poster img,
.wide-media img,
.ranking-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease, opacity 0.2s ease;
}

.poster img.image-hidden,
.wide-media img.image-hidden,
.ranking-media img.image-hidden {
    opacity: 0;
}

.poster:hover img,
.wide-card:hover img,
.ranking-card:hover img {
    transform: scale(1.08);
}

.poster-layer {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.84));
}

.poster-play {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.92);
    color: #fff;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.86);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.poster:hover .poster-play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.poster-label {
    position: absolute;
    right: 10px;
    top: 10px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.58);
    color: #fff;
    font-size: 12px;
}

.poster-caption {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
}

.poster-caption strong,
.poster-caption em {
    display: block;
}

.poster-caption strong {
    font-size: 15px;
    line-height: 1.35;
}

.poster-caption em {
    margin-top: 4px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 12px;
    font-style: normal;
}

.card-copy h2 {
    margin: 12px 0 4px;
    font-size: 16px;
    line-height: 1.35;
}

.card-copy h2 a:hover {
    color: var(--accent);
}

.card-copy p {
    margin: 0 0 10px;
    display: -webkit-box;
    min-height: 44px;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 13px;
}

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

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

.category-tile,
.category-overview-card {
    display: grid;
    gap: 8px;
    min-height: 132px;
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.72));
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile:hover,
.category-overview-card:hover {
    transform: translateY(-2px);
    border-color: rgba(245, 158, 11, 0.55);
}

.category-tile strong,
.category-overview-card strong {
    font-size: 18px;
}

.category-tile span,
.category-overview-card span {
    color: var(--muted);
    font-size: 13px;
}

.rank-panel,
.related-panel,
.detail-card,
.text-panel,
.filter-panel,
.player-panel {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.82);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.rank-panel {
    padding: 22px;
}

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

.compact-head a {
    color: var(--accent);
    font-weight: 800;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) 44px;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.48);
}

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

.rank-row span {
    color: var(--accent);
    font-weight: 900;
}

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

.rank-row em {
    color: var(--muted-strong);
    font-style: normal;
    text-align: right;
}

.center-more {
    text-align: center;
}

.page-title-block {
    margin: 0 0 34px;
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.66));
}

.page-title-block.centered {
    text-align: center;
}

.page-title-block h1 {
    font-size: clamp(34px, 5vw, 56px);
    letter-spacing: -0.04em;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin: 42px 0 12px;
}

.pager-link,
.pager-gap {
    min-width: 42px;
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.72);
    color: var(--muted-strong);
    padding: 0 12px;
}

.pager-link:hover,
.pager-link.is-current {
    background: var(--accent);
    color: #fff;
}

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

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

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

.player-panel {
    padding: 12px;
    margin-bottom: 24px;
}

.video-shell {
    position: relative;
    overflow: hidden;
    border-radius: 14px;
    background: #000;
}

.movie-player {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.floating-play {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 74px;
    height: 74px;
    border: 0;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.92);
    color: #fff;
    font-size: 30px;
    transform: translate(-50%, -50%);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.floating-play.is-hidden {
    opacity: 0;
    pointer-events: none;
    transform: translate(-50%, -50%) scale(0.8);
}

.detail-card {
    padding: 28px;
}

.detail-card h1 {
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.detail-meta {
    margin: 18px 0;
}

.detail-meta strong,
.ranking-meta strong {
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.16);
    color: var(--accent);
}

.lead-text {
    padding: 18px;
    border-radius: 16px;
    background: rgba(30, 41, 59, 0.52);
    color: var(--muted-strong) !important;
}

.detail-card section {
    margin-top: 28px;
}

.detail-card h2 {
    margin-bottom: 12px;
    font-size: 22px;
}

.large-tags span {
    border-radius: 10px;
}

.related-panel {
    position: sticky;
    top: 84px;
    padding: 22px;
}

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

.wide-card {
    display: grid;
    grid-template-columns: 122px minmax(0, 1fr);
    gap: 12px;
    padding: 10px;
    border-radius: 14px;
    background: rgba(30, 41, 59, 0.42);
}

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

.wide-media {
    display: block;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--poster-a), var(--poster-b));
}

.wide-copy {
    min-width: 0;
}

.wide-copy strong,
.wide-copy em,
.wide-copy small {
    display: block;
}

.wide-copy strong {
    line-height: 1.35;
}

.wide-copy em {
    margin: 4px 0;
    color: var(--muted-strong);
    font-size: 12px;
    font-style: normal;
}

.wide-copy small {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    color: var(--muted);
}

.filter-panel {
    padding: 22px;
    margin-bottom: 28px;
}

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

.filter-grid label {
    display: grid;
    gap: 8px;
    color: var(--muted-strong);
    font-weight: 700;
}

.ranking-grid {
    display: grid;
    gap: 14px;
}

.ranking-card {
    display: grid;
    grid-template-columns: 148px minmax(0, 1fr);
    gap: 18px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.78);
}

.ranking-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--poster-a), var(--poster-b));
}

.ranking-media span {
    position: absolute;
    left: 10px;
    top: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-weight: 900;
}

.ranking-copy h2 {
    margin: 0 0 10px;
    font-size: 24px;
}

.ranking-copy h2 a:hover {
    color: var(--accent);
}

.narrow-page {
    max-width: 860px;
}

.text-panel {
    padding: 30px;
}

.text-panel h2 {
    margin-top: 24px;
    margin-bottom: 10px;
}

.text-panel h2:first-child {
    margin-top: 0;
}

.site-footer {
    margin-top: 86px;
    border-top: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.86);
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 44px 0;
    display: grid;
    grid-template-columns: minmax(0, 2fr) 1fr 1fr;
    gap: 36px;
}

.footer-brand p,
.footer-inner a,
.footer-bottom p {
    color: var(--muted);
}

.footer-inner h2 {
    margin: 0 0 14px;
    font-size: 17px;
}

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

.footer-inner a:hover {
    color: var(--accent);
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 20px 0 34px;
    border-top: 1px solid var(--line);
    text-align: center;
    font-size: 13px;
}

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

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

    .related-panel {
        position: static;
    }

    .filter-grid,
    .search-strip {
        grid-template-columns: 1fr;
    }
}

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

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

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

    .hero-stage {
        min-height: 620px;
        height: 78vh;
    }

    .hero-copy {
        bottom: 92px;
    }

    .hero-arrow {
        display: none;
    }

    .search-strip {
        margin-top: 20px;
    }

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

    .ranking-card,
    .wide-card {
        grid-template-columns: 100px minmax(0, 1fr);
    }

    .detail-card,
    .page-title-block,
    .text-panel {
        padding: 22px;
    }
}

@media (max-width: 460px) {
    .movie-grid,
    .large-grid,
    .category-grid,
    .category-overview-grid {
        gap: 12px;
    }

    .card-copy p,
    .tag-row {
        display: none;
    }

    .hero-copy h1,
    .hero-copy h2 {
        font-size: 38px;
    }

    .inline-search {
        flex-direction: column;
    }
}
