:root {
    color-scheme: dark;
    --bg: #020617;
    --bg-soft: #0f172a;
    --panel: rgba(15, 23, 42, 0.84);
    --panel-strong: rgba(15, 23, 42, 0.96);
    --line: rgba(148, 163, 184, 0.18);
    --text: #f8fafc;
    --muted: #94a3b8;
    --muted-strong: #cbd5e1;
    --cyan: #22d3ee;
    --cyan-dark: #0891b2;
    --blue: #2563eb;
    --orange: #fb923c;
    --green: #34d399;
    --radius: 18px;
    --shadow: 0 24px 80px rgba(2, 6, 23, 0.38);
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background: var(--bg);
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(34, 211, 238, 0.16), transparent 34rem),
        radial-gradient(circle at top right, rgba(37, 99, 235, 0.18), transparent 30rem),
        linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
}

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

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

button,
input,
select {
    font: inherit;
}

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

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

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

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 22px;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.site-logo span,
.footer-logo::first-letter {
    display: inline-flex;
}

.site-logo span {
    padding: 6px 9px;
    border-radius: 12px;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), #67e8f9);
    box-shadow: 0 12px 30px rgba(34, 211, 238, 0.32);
}

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

.nav-link {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--muted-strong);
    transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text);
    background: rgba(34, 211, 238, 0.12);
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 14px;
    color: var(--text);
    background: rgba(15, 23, 42, 0.78);
}

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

.hero-section {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    isolation: isolate;
}

.hero-backdrop {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0;
    opacity: 0.72;
}

.hero-image {
    position: relative;
    min-width: 0;
    overflow: hidden;
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.94), rgba(8, 47, 73, 0.82));
}

.hero-image img {
    width: 100%;
    height: 100%;
    min-height: 600px;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.04);
    transform: scale(1.02);
}

.hero-image span {
    position: absolute;
    right: 18px;
    bottom: 18px;
    max-width: calc(100% - 36px);
    padding: 8px 12px;
    border-radius: 999px;
    color: var(--text);
    background: rgba(2, 6, 23, 0.62);
    backdrop-filter: blur(14px);
    font-size: 13px;
}

.hero-shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(90deg, #020617 0%, rgba(2, 6, 23, 0.9) 34%, rgba(2, 6, 23, 0.28) 100%),
        linear-gradient(0deg, #020617 0%, transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    min-height: 600px;
    display: flex;
    align-items: center;
}

.hero-copy {
    width: min(680px, 100%);
    padding: 84px 0;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    color: var(--cyan);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.eyebrow.orange {
    color: var(--orange);
}

.eyebrow.green {
    color: var(--green);
}

.hero-copy h1,
.page-hero h1,
.detail-title-row h1 {
    margin: 0;
    font-size: clamp(36px, 6vw, 66px);
    line-height: 1.04;
    letter-spacing: -0.06em;
}

.hero-copy p,
.page-hero p {
    max-width: 720px;
    margin: 22px 0 0;
    color: var(--muted-strong);
    font-size: 18px;
    line-height: 1.85;
}

.hero-search {
    display: flex;
    align-items: stretch;
    width: min(560px, 100%);
    margin-top: 30px;
    padding: 6px;
    border: 1px solid rgba(34, 211, 238, 0.26);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.78);
    box-shadow: 0 16px 60px rgba(2, 6, 23, 0.3);
    backdrop-filter: blur(16px);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 0 16px;
    color: var(--text);
    background: transparent;
}

.hero-search button,
.primary-btn,
.ghost-btn,
.inline-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border: 0;
    border-radius: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.hero-search button,
.primary-btn {
    padding: 0 24px;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), #67e8f9);
    box-shadow: 0 16px 32px rgba(34, 211, 238, 0.22);
}

.ghost-btn {
    padding: 0 22px;
    border: 1px solid var(--line);
    color: var(--text);
    background: rgba(15, 23, 42, 0.82);
}

.hero-search button:hover,
.primary-btn:hover,
.ghost-btn:hover,
.inline-link:hover {
    transform: translateY(-2px);
}

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

.section-block,
.category-panel,
.split-layout,
.overview-grid {
    padding: 68px 0;
}

.section-block.no-margin {
    padding: 0;
}

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

.section-heading h2 {
    margin: 0;
    font-size: clamp(26px, 4vw, 36px);
    letter-spacing: -0.04em;
}

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

.movie-grid {
    display: grid;
    gap: 22px;
}

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: 0 18px 60px rgba(2, 6, 23, 0.18);
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(34, 211, 238, 0.38);
    background: rgba(15, 23, 42, 0.96);
}

.card-cover {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(145deg, #0f172a, #164e63);
}

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

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

.card-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 36%, rgba(2, 6, 23, 0.76) 100%);
}

.card-year,
.card-play {
    position: absolute;
    z-index: 2;
}

.card-year {
    top: 12px;
    left: 12px;
    padding: 5px 9px;
    border-radius: 999px;
    color: #001018;
    background: var(--cyan);
    font-size: 12px;
    font-weight: 900;
}

.card-play {
    right: 12px;
    bottom: 12px;
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #001018;
    background: var(--text);
    box-shadow: 0 12px 28px rgba(2, 6, 23, 0.3);
}

.card-body {
    padding: 16px;
}

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

.card-body h3 {
    margin: 0;
    color: var(--text);
    font-size: 18px;
    line-height: 1.35;
}

.card-body h3 a:hover {
    color: var(--cyan);
}

.card-body p {
    min-height: 46px;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}

.tag-row,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.tag-row span,
.detail-tags span {
    padding: 5px 8px;
    border: 1px solid rgba(34, 211, 238, 0.18);
    border-radius: 999px;
    color: var(--cyan);
    background: rgba(34, 211, 238, 0.08);
    font-size: 12px;
}

.large-card .card-cover {
    aspect-ratio: 16 / 10;
}

.compact-card .card-body p {
    display: none;
}

.wide-card,
.rank-card {
    display: grid;
    grid-template-columns: 104px 1fr;
    align-items: stretch;
}

.wide-card .card-cover,
.rank-card .card-cover {
    aspect-ratio: auto;
    min-height: 150px;
}

.rank-number {
    position: absolute;
    z-index: 3;
    top: 10px;
    left: 10px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    color: #001018;
    background: linear-gradient(135deg, var(--orange), #fde68a);
    font-weight: 900;
}

.category-panel {
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.42);
}

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

.category-tile {
    display: flex;
    min-height: 150px;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
    border: 1px solid rgba(34, 211, 238, 0.18);
    border-radius: var(--radius);
    background:
        radial-gradient(circle at top right, rgba(34, 211, 238, 0.22), transparent 9rem),
        linear-gradient(135deg, rgba(34, 211, 238, 0.13), rgba(37, 99, 235, 0.12));
    transition: transform 0.22s ease, border-color 0.22s ease;
}

.category-tile:hover {
    transform: translateY(-5px);
    border-color: rgba(34, 211, 238, 0.44);
}

.category-tile strong {
    font-size: 20px;
}

.category-tile span {
    color: var(--muted-strong);
    line-height: 1.7;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 380px;
    gap: 28px;
}

.vertical-list,
.ranking-list {
    display: grid;
    gap: 16px;
}

.ranking-panel,
.detail-main-card,
.filter-panel,
.category-overview-card {
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) + 6px);
    background: var(--panel);
    box-shadow: var(--shadow);
}

.ranking-panel {
    padding: 24px;
    align-self: start;
    position: sticky;
    top: 96px;
}

.compact-heading {
    margin-bottom: 18px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    padding: 82px 0;
    border-bottom: 1px solid var(--line);
    background:
        radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 25rem),
        linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(8, 47, 73, 0.86));
}

.small-hero h1 {
    font-size: clamp(34px, 5vw, 56px);
}

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

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

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

.category-overview-card {
    display: grid;
    grid-template-columns: 188px 1fr;
    gap: 22px;
    padding: 20px;
}

.category-thumb-stack {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.category-thumb-stack img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 14px;
    background: #0f172a;
}

.category-overview-card h2 {
    margin: 6px 0 10px;
}

.category-overview-card p {
    color: var(--muted-strong);
    line-height: 1.8;
}

.inline-link {
    width: max-content;
    min-height: 38px;
    padding: 0 14px;
    color: var(--cyan);
    background: rgba(34, 211, 238, 0.1);
}

.filter-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 26px;
    padding: 18px;
}

.filter-panel strong {
    display: block;
    margin-bottom: 6px;
    font-size: 18px;
}

.filter-panel span {
    color: var(--muted);
    font-size: 14px;
}

.filter-controls {
    display: flex;
    flex-wrap: wrap;
    justify-content: end;
    gap: 10px;
}

.filter-controls input,
.filter-controls select,
.inner-search input {
    min-height: 44px;
    border: 1px solid var(--line);
    border-radius: 12px;
    outline: 0;
    color: var(--text);
    background: rgba(2, 6, 23, 0.46);
}

.filter-controls input {
    width: min(280px, 100%);
    padding: 0 14px;
}

.filter-controls select {
    padding: 0 38px 0 12px;
}

.empty-state {
    display: none;
    margin-top: 24px;
    padding: 28px;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    color: var(--muted-strong);
    text-align: center;
}

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

.ranking-page-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.big-rank-card {
    grid-template-columns: 126px 1fr;
}

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

.detail-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    opacity: 0.32;
    filter: blur(12px);
    transform: scale(1.04);
}

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

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.82)),
        linear-gradient(0deg, #020617 0%, transparent 42%);
}

.player-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
    align-items: stretch;
}

.video-shell {
    position: relative;
    overflow: hidden;
    min-height: 420px;
    border: 1px solid rgba(34, 211, 238, 0.22);
    border-radius: 24px;
    background: #000;
    box-shadow: var(--shadow);
}

.video-player {
    width: 100%;
    height: 100%;
    min-height: 420px;
    display: block;
    background: #000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 10px;
    border: 0;
    color: var(--text);
    background:
        radial-gradient(circle at center, rgba(34, 211, 238, 0.18), transparent 18rem),
        rgba(2, 6, 23, 0.38);
    cursor: pointer;
}

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

.player-icon {
    width: 74px;
    height: 74px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), #67e8f9);
    box-shadow: 0 18px 48px rgba(34, 211, 238, 0.28);
    font-size: 28px;
}

.player-overlay strong {
    font-size: 22px;
}

.player-overlay small {
    color: var(--muted-strong);
}

.player-message {
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 5;
    display: none;
    padding: 10px 12px;
    border-radius: 12px;
    color: var(--muted-strong);
    background: rgba(2, 6, 23, 0.68);
}

.player-message.active {
    display: block;
}

.detail-side-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: var(--panel);
}

.detail-side-card img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 18px;
    background: #0f172a;
}

.full-btn {
    width: 100%;
}

.detail-content {
    padding: 44px 0 20px;
}

.detail-main-card {
    padding: clamp(22px, 4vw, 38px);
}

.detail-title-row {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 20px;
}

.detail-title-row h1 {
    font-size: clamp(30px, 5vw, 52px);
}

.lead-text {
    max-width: 900px;
    margin: 22px 0;
    color: var(--muted-strong);
    font-size: 18px;
    line-height: 1.85;
}

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

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

.detail-meta-grid span {
    display: block;
    margin-bottom: 8px;
    color: var(--muted);
    font-size: 13px;
}

.detail-meta-grid strong {
    font-size: 16px;
}

.text-section {
    margin-top: 32px;
}

.text-section h2 {
    margin: 0 0 12px;
    font-size: 24px;
}

.text-section p {
    margin: 0;
    color: var(--muted-strong);
    font-size: 16px;
    line-height: 1.95;
}

.search-result-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.search-result-head h2 {
    margin: 0;
}

.search-result-head span {
    color: var(--muted);
}

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

.footer-inner {
    display: grid;
    gap: 18px;
    padding: 36px 0;
    text-align: center;
}

.footer-inner p {
    max-width: 760px;
    margin: 0 auto;
    color: var(--muted);
    line-height: 1.8;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    color: var(--muted-strong);
}

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

@media (max-width: 1100px) {
    .featured-grid,
    .hot-grid,
    .standard-grid,
    .catalog-grid,
    .related-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

    .split-layout,
    .player-layout {
        grid-template-columns: 1fr;
    }

    .ranking-panel {
        position: static;
    }

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

@media (max-width: 820px) {
    .site-nav {
        position: fixed;
        top: 72px;
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 14px;
        border: 1px solid var(--line);
        border-radius: 18px;
        background: rgba(2, 6, 23, 0.96);
        box-shadow: var(--shadow);
    }

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

    .nav-toggle {
        display: block;
    }

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

    .hero-image:nth-child(n + 2) {
        display: none;
    }

    .hero-copy {
        padding: 60px 0;
    }

    .hero-search,
    .filter-panel,
    .detail-title-row {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-search button {
        width: 100%;
    }

    .featured-grid,
    .hot-grid,
    .standard-grid,
    .catalog-grid,
    .related-grid,
    .category-grid,
    .overview-grid,
    .ranking-page-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

    .video-shell,
    .video-player {
        min-height: 300px;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(100% - 24px, 1180px);
    }

    .site-logo {
        font-size: 18px;
    }

    .hero-section,
    .hero-content,
    .hero-image img {
        min-height: 560px;
    }

    .hero-copy h1,
    .page-hero h1 {
        font-size: 34px;
    }

    .hero-copy p,
    .page-hero p,
    .lead-text {
        font-size: 16px;
    }

    .featured-grid,
    .hot-grid,
    .standard-grid,
    .catalog-grid,
    .related-grid,
    .category-grid,
    .overview-grid,
    .ranking-page-list {
        grid-template-columns: 1fr;
    }

    .wide-card,
    .rank-card,
    .big-rank-card {
        grid-template-columns: 96px 1fr;
    }

    .card-body {
        padding: 14px;
    }

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

    .video-shell,
    .video-player {
        min-height: 236px;
        border-radius: 18px;
    }
}
