:root {
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.86);
    --panel-strong: #0f172a;
    --line: #1e293b;
    --muted: #94a3b8;
    --text: #f8fafc;
    --soft: #cbd5e1;
    --teal: #14b8a6;
    --cyan: #06b6d4;
    --orange: #f97316;
    --pink: #ec4899;
    --radius: 18px;
    --shadow: 0 18px 45px rgba(0, 0, 0, 0.34);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(20, 184, 166, 0.18), transparent 35rem),
        radial-gradient(circle at 80% 8%, rgba(236, 72, 153, 0.12), transparent 34rem),
        var(--bg);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(15, 23, 42, 0.94);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

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

.brand-icon {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    font-weight: 900;
    box-shadow: 0 10px 28px rgba(6, 182, 212, 0.32);
}

.brand-text strong,
.brand-text em {
    display: block;
}

.brand-text strong {
    font-size: 20px;
    letter-spacing: 0.02em;
}

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

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

.desktop-nav a,
.nav-dropdown button,
.mobile-nav a {
    color: var(--soft);
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: color 0.2s ease, background 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.nav-dropdown button:hover,
.mobile-nav a:hover,
.mobile-nav a.active {
    color: #fff;
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    right: 0;
    top: 34px;
    display: none;
    width: 180px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.96);
    box-shadow: var(--shadow);
}

.nav-dropdown:hover .nav-dropdown-menu {
    display: grid;
    gap: 8px;
}

.nav-dropdown-menu a {
    padding: 8px 10px;
    border-radius: 10px;
}

.nav-dropdown-menu a:hover {
    background: rgba(20, 184, 166, 0.14);
}

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

.mobile-nav {
    display: none;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 0 16px 16px;
}

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

.mobile-nav a {
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.55);
}

.hero-carousel {
    position: relative;
    height: 620px;
    overflow: hidden;
    background: #020617;
}

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

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

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
    filter: saturate(1.08);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.68), rgba(2, 6, 23, 0.22)),
        linear-gradient(0deg, #020617, rgba(2, 6, 23, 0.16) 45%, rgba(2, 6, 23, 0.32));
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) 340px;
    align-items: end;
    gap: 50px;
    height: 100%;
    padding: 96px 0 116px;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: #5eead4;
    font-weight: 800;
    letter-spacing: 0.08em;
}

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

.hero-copy p,
.page-hero p,
.detail-one-line {
    margin: 0;
    color: var(--soft);
    font-size: 18px;
}

.hero-meta,
.detail-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    color: var(--soft);
}

.hero-meta span,
.detail-meta span,
.card-meta span {
    padding: 4px 10px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.62);
    font-size: 13px;
}

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

.tag-row span {
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.14);
    color: #99f6e4;
    font-size: 12px;
}

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

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

.primary-button {
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    color: #fff;
    box-shadow: 0 16px 36px rgba(6, 182, 212, 0.25);
}

.ghost-button {
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(15, 23, 42, 0.58);
    color: #fff;
}

.primary-button:hover,
.ghost-button:hover {
    transform: translateY(-2px);
}

.hero-poster {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 26px;
    background: rgba(15, 23, 42, 0.7);
    box-shadow: var(--shadow);
}

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

.hero-control-layer {
    position: relative;
    z-index: 3;
    margin-top: -96px;
    padding-bottom: 24px;
}

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

.hero-dot {
    width: 34px;
    height: 4px;
    border: 0;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.38);
}

.hero-dot.active {
    background: linear-gradient(90deg, var(--teal), var(--cyan));
}

.hero-thumbs {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
}

.hero-thumb {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 10px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.72);
    color: var(--soft);
    cursor: pointer;
    backdrop-filter: blur(12px);
}

.hero-thumb.active {
    border-color: rgba(20, 184, 166, 0.7);
    background: rgba(20, 184, 166, 0.13);
    color: #fff;
}

.hero-thumb img {
    width: 44px;
    height: 58px;
    border-radius: 10px;
    object-fit: cover;
}

.hero-thumb span {
    overflow: hidden;
    text-align: left;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.stats-strip {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 14px;
    margin-top: 36px;
}

.stats-strip a {
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.7);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.2);
}

.stats-strip strong,
.stats-strip span {
    display: block;
}

.stats-strip strong {
    color: #fff;
    font-size: 30px;
}

.stats-strip span {
    color: var(--muted);
}

.page-main {
    padding: 34px 0 70px;
}

.page-section {
    margin-top: 58px;
}

.section-heading {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.section-icon {
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    box-shadow: 0 12px 28px rgba(6, 182, 212, 0.18);
}

.section-heading h2 {
    margin: 0;
    font-size: 30px;
    line-height: 1.2;
}

.section-heading p {
    margin: 4px 0 0;
    color: var(--muted);
}

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

.rank-preview a {
    display: grid;
    grid-template-columns: 44px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.72);
}

.rank-preview span {
    color: #5eead4;
    font-weight: 900;
}

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

.rank-preview em {
    color: #fbbf24;
    font-style: normal;
    font-weight: 800;
}

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

.category-card,
.category-large-card,
.movie-card,
.ranking-row,
.player-box,
.detail-article,
.sitemap-group {
    border: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.72);
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.18);
}

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 230px;
    padding: 18px;
    border-radius: var(--radius);
}

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.22;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.category-card:hover img {
    transform: scale(1.08);
    opacity: 0.32;
}

.category-card h3,
.category-card p,
.category-card em,
.category-card span {
    position: relative;
}

.category-card span {
    display: inline-flex;
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(20, 184, 166, 0.18);
    color: #99f6e4;
    font-size: 12px;
}

.category-card h3 {
    margin: 52px 0 8px;
    font-size: 22px;
}

.category-card p,
.category-card em {
    color: var(--soft);
}

.category-card em {
    display: block;
    margin-top: 12px;
    font-size: 13px;
    font-style: normal;
}

.library-tools {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto auto;
    gap: 12px;
    align-items: center;
    margin-bottom: 24px;
}

.search-shell {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.7);
}

.search-shell span {
    color: #5eead4;
    font-weight: 800;
}

.search-field {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.filter-button {
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    color: var(--soft);
    cursor: pointer;
}

.filter-button.active,
.filter-button:hover {
    border-color: rgba(20, 184, 166, 0.65);
    background: rgba(20, 184, 166, 0.16);
    color: #fff;
}

.result-count {
    color: var(--muted);
    white-space: nowrap;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    transition: transform 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    border-color: rgba(20, 184, 166, 0.62);
    transform: translateY(-4px);
}

.poster-link {
    position: relative;
    display: block;
    overflow: hidden;
    background: #0f172a;
}

.poster-link img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.score-badge {
    position: absolute;
    right: 10px;
    top: 10px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.78);
    color: #fbbf24;
    font-size: 12px;
    font-weight: 900;
}

.card-body {
    padding: 14px;
}

.card-meta {
    gap: 6px;
    margin-top: 0;
}

.card-meta span {
    padding: 3px 7px;
    font-size: 11px;
}

.movie-card h3 {
    margin: 10px 0 8px;
    font-size: 17px;
    line-height: 1.3;
}

.movie-card h3 a:hover,
.rank-info h2 a:hover,
.sitemap-group a:hover {
    color: #5eead4;
}

.movie-card p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.page-hero {
    overflow: hidden;
    padding: 38px;
    border: 1px solid var(--line);
    border-radius: 28px;
    background:
        linear-gradient(135deg, rgba(20, 184, 166, 0.17), rgba(236, 72, 153, 0.08)),
        rgba(15, 23, 42, 0.72);
    box-shadow: var(--shadow);
}

.compact-hero h1,
.category-hero h1 {
    font-size: clamp(34px, 4vw, 54px);
}

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

.breadcrumb a:hover {
    color: #5eead4;
}

.category-large-grid {
    display: grid;
    gap: 18px;
    margin-top: 28px;
}

.category-large-card {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 22px;
    padding: 18px;
    border-radius: 22px;
}

.category-cover {
    overflow: hidden;
    border-radius: 18px;
}

.category-cover img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
}

.category-large-card span {
    color: #5eead4;
    font-weight: 800;
}

.category-large-card h2 {
    margin: 6px 0 8px;
}

.category-large-card p {
    margin: 0 0 12px;
    color: var(--soft);
}

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

.mini-link-list a {
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(30, 41, 59, 0.76);
    color: var(--soft);
    font-size: 13px;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 76px 92px 1fr 90px;
    align-items: center;
    gap: 16px;
    padding: 12px;
    border-radius: 18px;
}

.rank-number {
    color: #5eead4;
    font-weight: 900;
    text-align: center;
}

.rank-cover {
    overflow: hidden;
    border-radius: 12px;
}

.rank-cover img {
    width: 92px;
    height: 120px;
    object-fit: cover;
}

.rank-info h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

.rank-info p {
    margin: 0;
    color: var(--muted);
}

.rank-score {
    color: #fbbf24;
    font-size: 24px;
    text-align: center;
}

.detail-main {
    max-width: 1180px;
}

.detail-hero {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 34px;
    align-items: end;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 28px;
    background:
        linear-gradient(135deg, rgba(20, 184, 166, 0.16), rgba(6, 182, 212, 0.06)),
        rgba(15, 23, 42, 0.76);
    box-shadow: var(--shadow);
}

.detail-poster {
    overflow: hidden;
    border-radius: 24px;
    box-shadow: var(--shadow);
}

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

.detail-copy h1 {
    font-size: clamp(34px, 5vw, 64px);
}

.detail-tags {
    margin-bottom: 24px;
}

.player-section {
    margin-top: 34px;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #000;
}

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

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 12px;
    border: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.75), rgba(2, 6, 23, 0.35));
    color: #fff;
    cursor: pointer;
}

.play-overlay span {
    display: grid;
    width: 76px;
    height: 76px;
    place-items: center;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--teal), var(--cyan));
    box-shadow: 0 18px 38px rgba(6, 182, 212, 0.24);
    font-size: 28px;
}

.play-overlay strong {
    font-size: 18px;
}

.player-box.playing .play-overlay {
    display: none;
}

.detail-article {
    margin-top: 34px;
    padding: 28px;
    border-radius: 24px;
}

.detail-article h2 {
    margin: 0 0 12px;
    font-size: 26px;
}

.detail-article h2:not(:first-child) {
    margin-top: 26px;
}

.detail-article p {
    margin: 0;
    color: var(--soft);
    font-size: 17px;
}

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

.movie-card.compact h3 {
    font-size: 15px;
}

.sitemap-layout {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
    margin-top: 28px;
}

.sitemap-group {
    padding: 22px;
    border-radius: 22px;
}

.sitemap-group h2 {
    margin: 0 0 14px;
}

.sitemap-group ul {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sitemap-group li a {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: var(--soft);
    font-size: 14px;
}

.sitemap-group span {
    color: var(--muted);
}

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

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 28px 0;
    color: var(--muted);
}

.footer-inner strong {
    color: #fff;
}

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

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

.footer-links a:hover {
    color: #5eead4;
}

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

@media (max-width: 1080px) {
    .movie-grid,
    .category-grid {
        grid-template-columns: repeat(4, 1fr);
    }

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

    .rank-preview {
        grid-template-columns: repeat(2, 1fr);
    }
}

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

    .mobile-menu-button {
        display: block;
    }

    .hero-carousel {
        height: auto;
        min-height: 720px;
    }

    .hero-slide {
        position: relative;
        display: none;
        min-height: 720px;
    }

    .hero-slide.active {
        display: block;
    }

    .hero-content,
    .detail-hero,
    .category-large-card {
        grid-template-columns: 1fr;
    }

    .hero-content {
        align-items: center;
        padding: 78px 0 158px;
    }

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

    .hero-thumbs {
        display: none;
    }

    .stats-strip,
    .sitemap-layout {
        grid-template-columns: 1fr 1fr;
    }

    .library-tools {
        grid-template-columns: 1fr;
    }

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

    .rank-score {
        grid-column: 1 / -1;
        text-align: left;
        padding-left: 8px;
    }
}

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

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

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

    .hero-copy p,
    .page-hero p,
    .detail-one-line {
        font-size: 15px;
    }

    .hero-meta,
    .detail-meta {
        gap: 7px;
    }

    .stats-strip,
    .rank-preview,
    .category-grid,
    .movie-grid,
    .related-grid,
    .sitemap-layout,
    .sitemap-group ul {
        grid-template-columns: 1fr 1fr;
    }

    .category-grid,
    .movie-grid,
    .related-grid {
        gap: 12px;
    }

    .card-body {
        padding: 11px;
    }

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

    .page-hero,
    .detail-hero,
    .detail-article {
        padding: 20px;
        border-radius: 22px;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}
