:root {
    color-scheme: dark;
    --bg: #020617;
    --bg-soft: #0f172a;
    --bg-card: rgba(15, 23, 42, 0.82);
    --bg-card-strong: rgba(15, 23, 42, 0.96);
    --line: rgba(148, 163, 184, 0.18);
    --text: #f8fafc;
    --muted: #94a3b8;
    --soft: #cbd5e1;
    --accent: #10b981;
    --accent-strong: #34d399;
    --accent-dark: #064e3b;
    --gold: #f59e0b;
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    --shadow: 0 24px 80px rgba(2, 6, 23, 0.55);
    --header-height: 72px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 12% 0%, rgba(16, 185, 129, 0.18), transparent 28rem),
        radial-gradient(circle at 88% 8%, rgba(14, 165, 233, 0.16), transparent 25rem),
        var(--bg);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "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: 60;
    border-bottom: 1px solid var(--line);
    background: rgba(2, 6, 23, 0.82);
    backdrop-filter: blur(18px);
}

.header-inner {
    max-width: 1440px;
    height: var(--header-height);
    margin: 0 auto;
    padding: 0 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.32rem;
    font-weight: 900;
    letter-spacing: 0.03em;
}

.logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 13px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #052e2b;
    background: linear-gradient(135deg, #34d399, #eab308);
    box-shadow: 0 12px 32px rgba(16, 185, 129, 0.28);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    color: var(--soft);
    font-size: 0.96rem;
}

.desktop-nav a,
.mobile-nav a,
.footer-links a,
.category-samples a {
    transition: color 0.22s ease, transform 0.22s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover,
.category-samples a:hover {
    color: var(--accent-strong);
}

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

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

.mobile-nav {
    display: none;
    padding: 12px 28px 22px;
    border-top: 1px solid var(--line);
    background: rgba(2, 6, 23, 0.94);
}

.mobile-nav a {
    display: block;
    padding: 12px 0;
    color: var(--soft);
}

main {
    max-width: 1440px;
    margin: 0 auto;
    padding: 24px 28px 64px;
}

.hero-carousel {
    position: relative;
    min-height: min(720px, calc(100vh - var(--header-height) - 32px));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: #020617;
    box-shadow: var(--shadow);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 0.9s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.62;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.76) 43%, rgba(2, 6, 23, 0.18)),
        linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.08) 50%, rgba(2, 6, 23, 0.24));
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(720px, 62%);
    padding: clamp(36px, 6vw, 88px);
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--accent-strong);
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
}

.hero-content h1,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    color: var(--text);
    font-size: clamp(2.2rem, 5vw, 5rem);
    line-height: 1.05;
    letter-spacing: -0.06em;
}

.hero-content h2 {
    margin: 24px 0 0;
    color: var(--accent-strong);
    font-size: clamp(1.4rem, 2.4vw, 2.4rem);
    line-height: 1.15;
}

.hero-desc {
    max-width: 660px;
    margin: 18px 0 0;
    color: var(--soft);
    font-size: 1.05rem;
}

.hero-meta,
.detail-meta,
.movie-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

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

.hero-meta span,
.detail-meta span,
.movie-meta span {
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--soft);
    background: rgba(15, 23, 42, 0.55);
}

.hero-meta span,
.detail-meta span {
    padding: 7px 12px;
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

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

.hero-tags span,
.tag-row span {
    border-radius: 999px;
    color: #bbf7d0;
    background: rgba(6, 78, 59, 0.72);
}

.hero-tags span {
    padding: 7px 12px;
}

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

.primary-btn,
.ghost-btn,
.section-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.primary-btn {
    min-height: 46px;
    padding: 0 22px;
    color: #052e2b;
    background: linear-gradient(135deg, #34d399, #fbbf24);
    box-shadow: 0 16px 36px rgba(16, 185, 129, 0.26);
}

.ghost-btn,
.section-link {
    min-height: 46px;
    padding: 0 20px;
    border: 1px solid var(--line);
    color: var(--text);
    background: rgba(15, 23, 42, 0.72);
}

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

.ghost-btn:hover,
.section-link:hover {
    border-color: rgba(52, 211, 153, 0.7);
}

.hero-poster {
    position: absolute;
    right: clamp(28px, 5vw, 72px);
    bottom: clamp(28px, 5vw, 72px);
    z-index: 2;
    width: min(28vw, 360px);
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 30px;
    background: var(--bg-card);
    box-shadow: 0 36px 120px rgba(0, 0, 0, 0.48);
}

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

.hero-poster span {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #052e2b;
    background: rgba(52, 211, 153, 0.94);
    transform: translate(-50%, -50%);
}

.hero-dots {
    position: absolute;
    left: clamp(36px, 6vw, 88px);
    bottom: 28px;
    z-index: 3;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 34px;
    height: 7px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.32);
    cursor: pointer;
}

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

.intro-strip,
.filter-panel,
.page-hero,
.detail-hero,
.player-section,
.detail-content article,
.content-section,
.site-footer {
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: var(--bg-card);
    box-shadow: 0 22px 60px rgba(2, 6, 23, 0.22);
}

.intro-strip {
    margin-top: 28px;
    padding: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}

.intro-strip h2,
.section-heading h2,
.content-section h2,
.detail-content h2,
.site-footer h2,
.category-overview-card h2 {
    margin: 0;
    color: var(--text);
}

.intro-strip p:last-child {
    max-width: 820px;
    margin: 8px 0 0;
    color: var(--soft);
}

.filter-panel {
    margin-top: 28px;
    padding: 18px;
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px 180px auto;
    gap: 14px;
    align-items: end;
}

.filter-panel label {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-size: 0.86rem;
    font-weight: 800;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0 14px;
    color: var(--text);
    outline: none;
    background: rgba(2, 6, 23, 0.68);
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: rgba(52, 211, 153, 0.72);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12);
}

.filter-empty {
    color: var(--gold);
    font-weight: 800;
}

.content-section {
    margin-top: 28px;
    padding: 28px;
}

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

.section-heading h2 {
    font-size: clamp(1.5rem, 2.6vw, 2.25rem);
    letter-spacing: -0.04em;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: rgba(15, 23, 42, 0.72);
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    border-color: rgba(52, 211, 153, 0.58);
    box-shadow: 0 22px 60px rgba(2, 6, 23, 0.34);
    transform: translateY(-6px);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: rgba(15, 23, 42, 0.86);
}

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

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

.poster-shade {
    position: absolute;
    inset: auto 0 0;
    height: 54%;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), transparent);
}

.play-badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.play-badge {
    left: 50%;
    top: 50%;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    color: #052e2b;
    background: rgba(52, 211, 153, 0.92);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.86);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.rank-badge {
    left: 12px;
    top: 12px;
    min-width: 42px;
    height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    color: #111827;
    background: linear-gradient(135deg, #fbbf24, #34d399);
}

.movie-card-body {
    padding: 16px;
}

.movie-card-title {
    display: block;
    color: var(--text);
    font-weight: 900;
    font-size: 1.05rem;
    line-height: 1.35;
}

.movie-card-title:hover {
    color: var(--accent-strong);
}

.movie-meta {
    margin-top: 10px;
}

.movie-meta span {
    padding: 4px 8px;
    font-size: 0.78rem;
}

.movie-card-body p {
    margin: 12px 0 0;
    min-height: 3.1em;
    color: var(--muted);
    font-size: 0.92rem;
}

.tag-row {
    margin-top: 14px;
}

.tag-row span {
    padding: 4px 8px;
    font-size: 0.75rem;
}

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

.category-tile,
.category-overview-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: rgba(2, 6, 23, 0.46);
}

.category-tile {
    padding: 20px;
}

.category-tile > a {
    display: block;
}

.category-icon {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    color: #052e2b;
    font-weight: 900;
    background: linear-gradient(135deg, #34d399, #fbbf24);
}

.category-tile h3 {
    margin: 16px 0 8px;
    color: var(--text);
    font-size: 1.2rem;
}

.category-tile p,
.category-overview-card p,
.page-hero p,
.detail-lead,
.detail-content p,
.site-footer p {
    color: var(--soft);
}

.category-samples {
    display: grid;
    gap: 8px;
    margin-top: 18px;
    color: var(--muted);
    font-size: 0.9rem;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: rgba(2, 6, 23, 0.46);
}

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

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

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

.page-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(32px, 5vw, 64px);
}

.small-hero {
    background:
        linear-gradient(135deg, rgba(6, 78, 59, 0.74), rgba(15, 23, 42, 0.9)),
        var(--bg-card);
}

.page-hero p {
    max-width: 820px;
    margin: 16px 0 0;
    font-size: 1.05rem;
}

.category-hero {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
}

.category-hero img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.36);
}

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

.category-overview-card {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 20px;
    padding: 18px;
}

.category-cover {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    aspect-ratio: 2 / 3;
}

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

.category-cover span {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
    padding: 8px 10px;
    border-radius: 999px;
    color: #052e2b;
    font-weight: 900;
    text-align: center;
    background: rgba(52, 211, 153, 0.92);
}

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

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

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

.detail-hero {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 34px;
    padding: 28px;
}

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    background: rgba(2, 6, 23, 0.64);
    box-shadow: 0 22px 70px rgba(0, 0, 0, 0.35);
}

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

.detail-info {
    display: flex;
    min-width: 0;
    flex-direction: column;
    justify-content: center;
}

.detail-info h1 {
    font-size: clamp(2rem, 4vw, 4rem);
}

.detail-lead {
    margin: 18px 0 0;
    font-size: 1.12rem;
}

.detail-meta {
    margin-top: 22px;
}

.detail-tags {
    margin: 20px 0 28px;
}

.player-section {
    margin-top: 28px;
    padding: 18px;
}

.video-shell {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: 24px;
    background: #000;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    color: var(--text);
    cursor: pointer;
    background:
        radial-gradient(circle at center, rgba(16, 185, 129, 0.18), transparent 22rem),
        linear-gradient(0deg, rgba(2, 6, 23, 0.78), rgba(2, 6, 23, 0.56));
}

.player-cover.is-hidden {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.player-pulse {
    width: 86px;
    height: 86px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #052e2b;
    font-size: 2rem;
    background: linear-gradient(135deg, #34d399, #fbbf24);
    box-shadow: 0 0 0 18px rgba(16, 185, 129, 0.14);
}

.player-cover strong {
    font-size: clamp(1.4rem, 3vw, 2.4rem);
}

.player-cover em {
    color: var(--accent-strong);
    font-style: normal;
    font-weight: 800;
}

.detail-content {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin-top: 28px;
}

.detail-content article {
    padding: 26px;
}

.detail-content h2 {
    margin-bottom: 12px;
}

.detail-content p {
    margin: 0;
    font-size: 1.02rem;
}

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

.info-list div {
    display: grid;
    grid-template-columns: 90px minmax(0, 1fr);
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

.info-list dt {
    color: var(--muted);
    font-weight: 800;
}

.info-list dd {
    margin: 0;
    color: var(--text);
}

.site-footer {
    max-width: 1440px;
    margin: 0 auto 28px;
    padding: 30px 28px;
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 30px;
}

.footer-logo {
    margin-bottom: 12px;
}

.footer-links {
    display: grid;
    gap: 9px;
    margin-top: 12px;
    color: var(--muted);
}

.footer-bottom {
    margin-top: 28px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 0.92rem;
}

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

@media (max-width: 1180px) {
    .movie-grid,
    .dense-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

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

    .hero-content {
        width: 68%;
    }
}

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

    .mobile-toggle {
        display: block;
    }

    .mobile-nav.is-open {
        display: block;
    }

    main {
        padding: 18px 16px 46px;
    }

    .hero-carousel {
        min-height: 780px;
    }

    .hero-content {
        width: 100%;
        padding: 34px 24px;
    }

    .hero-poster {
        left: 24px;
        right: 24px;
        bottom: 58px;
        width: auto;
        height: 300px;
        aspect-ratio: auto;
    }

    .hero-dots {
        left: 24px;
    }

    .intro-strip,
    .section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

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

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

    .category-hero img,
    .detail-poster,
    .category-cover {
        max-width: 320px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 620px) {
    .header-inner {
        padding: 0 16px;
    }

    .site-logo {
        font-size: 1.12rem;
    }

    .logo-mark {
        width: 34px;
        height: 34px;
    }

    .hero-carousel {
        min-height: 720px;
        border-radius: 22px;
    }

    .hero-content h1,
    .page-hero h1,
    .detail-info h1 {
        font-size: 2.05rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .movie-grid,
    .dense-grid,
    .category-grid,
    .ranking-list,
    .filter-panel,
    .info-list {
        grid-template-columns: 1fr;
    }

    .content-section,
    .intro-strip,
    .filter-panel,
    .page-hero,
    .detail-hero,
    .player-section,
    .detail-content article,
    .site-footer {
        padding: 18px;
        border-radius: 20px;
    }

    .ranking-row {
        grid-template-columns: 42px minmax(0, 1fr);
    }

    .ranking-row em {
        grid-column: 2;
    }

    .player-pulse {
        width: 70px;
        height: 70px;
    }
}
