:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.86);
    --panel-soft: rgba(30, 41, 59, 0.72);
    --line: rgba(51, 65, 85, 0.86);
    --text: #f8fafc;
    --muted: #94a3b8;
    --muted-strong: #cbd5e1;
    --cyan: #22d3ee;
    --cyan-deep: #06b6d4;
    --blue: #2563eb;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.42);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 12% 8%, rgba(34, 211, 238, 0.16), transparent 32rem),
        radial-gradient(circle at 82% 12%, rgba(37, 99, 235, 0.14), transparent 34rem),
        linear-gradient(135deg, #020617 0%, #0f172a 44%, #020617 100%);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.65;
}

body.no-scroll {
    overflow: hidden;
}

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

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

button,
input,
select {
    font: inherit;
}

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

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

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

.logo-mark {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    color: white;
    box-shadow: 0 10px 30px rgba(34, 211, 238, 0.28);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 22px;
    color: var(--muted-strong);
    font-size: 15px;
}

.nav-links a {
    transition: color 0.2s ease;
}

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

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

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

.mobile-panel {
    display: none;
    border-top: 1px solid rgba(51, 65, 85, 0.7);
    background: rgba(2, 6, 23, 0.96);
}

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

.mobile-panel a {
    display: block;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 14px 0;
    color: var(--muted-strong);
    border-bottom: 1px solid rgba(51, 65, 85, 0.34);
}

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

.hero {
    position: relative;
    margin: 28px auto 56px;
    min-height: 560px;
    border-radius: 32px;
    overflow: hidden;
    background: #0f172a;
    box-shadow: var(--shadow);
    border: 1px solid rgba(34, 211, 238, 0.22);
}

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

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

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

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.94) 0%, rgba(15, 23, 42, 0.72) 45%, rgba(2, 6, 23, 0.24) 100%),
        linear-gradient(0deg, rgba(2, 6, 23, 0.9), rgba(2, 6, 23, 0.12));
}

.hero-content {
    position: absolute;
    z-index: 2;
    left: clamp(24px, 7vw, 84px);
    bottom: clamp(32px, 7vw, 84px);
    width: min(680px, calc(100% - 48px));
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    color: white;
    background: rgba(6, 182, 212, 0.88);
    box-shadow: 0 14px 38px rgba(6, 182, 212, 0.22);
    font-size: 13px;
    font-weight: 800;
}

.hero h1,
.hero h2 {
    margin: 20px 0 14px;
    font-size: clamp(34px, 6vw, 70px);
    line-height: 1.03;
    letter-spacing: -0.06em;
    font-weight: 950;
}

.hero p {
    margin: 0;
    color: #dbeafe;
    font-size: clamp(16px, 2vw, 20px);
    max-width: 620px;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 12px 18px;
    border-radius: 999px;
    border: 1px solid rgba(34, 211, 238, 0.28);
    background: rgba(15, 23, 42, 0.82);
    color: white;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    border-color: rgba(34, 211, 238, 0.85);
    background: rgba(30, 41, 59, 0.92);
}

.btn-primary {
    border-color: transparent;
    background: linear-gradient(135deg, var(--cyan-deep), var(--blue));
    box-shadow: 0 16px 40px rgba(37, 99, 235, 0.28);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.hero-dots {
    position: absolute;
    z-index: 4;
    right: 36px;
    bottom: 36px;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 36px;
    height: 5px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.35);
    cursor: pointer;
}

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

.section {
    margin: 56px 0;
}

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

.section-title {
    margin: 0;
    font-size: clamp(26px, 4vw, 42px);
    line-height: 1.14;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.section-desc {
    margin: 8px 0 0;
    color: var(--muted);
    max-width: 760px;
}

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

.category-tile {
    min-height: 120px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.86), rgba(15, 23, 42, 0.78));
    transition: transform 0.2s ease, border-color 0.2s ease;
}

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

.category-tile strong {
    display: block;
    font-size: 18px;
}

.category-tile span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-size: 13px;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 14px;
    margin-bottom: 22px;
}

.search-panel input,
.search-panel select {
    width: 100%;
    height: 50px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    color: var(--text);
    background: rgba(15, 23, 42, 0.76);
    outline: none;
}

.search-panel input:focus,
.search-panel select:focus {
    border-color: rgba(34, 211, 238, 0.85);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(51, 65, 85, 0.82);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.78);
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(34, 211, 238, 0.82);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
}

.movie-card.hidden-by-filter {
    display: none;
}

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

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

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

.poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.86), transparent 46%);
}

.card-badges {
    position: absolute;
    left: 10px;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.badge {
    display: inline-flex;
    max-width: 100%;
    padding: 4px 8px;
    border-radius: 999px;
    color: white;
    background: rgba(6, 182, 212, 0.88);
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.badge-muted {
    background: rgba(30, 41, 59, 0.92);
    color: #cbd5e1;
}

.card-body {
    padding: 14px;
}

.card-title {
    margin: 0 0 7px;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 850;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-summary {
    margin: 0;
    min-height: 42px;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted-strong);
    font-size: 12px;
}

.feature-layout {
    display: grid;
    grid-template-columns: 1.28fr 1fr;
    gap: 20px;
}

.feature-card {
    position: relative;
    min-height: 500px;
    overflow: hidden;
    border-radius: 28px;
    border: 1px solid rgba(34, 211, 238, 0.22);
    background: #0f172a;
    box-shadow: var(--shadow);
}

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

.feature-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.95) 0%, rgba(2, 6, 23, 0.25) 70%);
}

.feature-copy {
    position: absolute;
    z-index: 2;
    left: 24px;
    right: 24px;
    bottom: 24px;
}

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

.side-link {
    display: grid;
    grid-template-columns: 92px 1fr;
    gap: 14px;
    align-items: center;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.78);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.side-link:hover {
    transform: translateX(5px);
    border-color: rgba(34, 211, 238, 0.78);
}

.side-link img {
    width: 92px;
    height: 124px;
    border-radius: 14px;
    object-fit: cover;
}

.side-link strong {
    display: block;
    font-size: 16px;
    line-height: 1.35;
}

.side-link span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-size: 13px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 58px 70px 1fr auto;
    gap: 14px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.75);
}

.rank-num {
    display: inline-grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.9), rgba(37, 99, 235, 0.9));
    font-weight: 950;
}

.rank-thumb {
    width: 70px;
    height: 94px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-title {
    margin: 0;
    font-size: 17px;
    font-weight: 850;
}

.rank-desc {
    margin: 4px 0 0;
    color: var(--muted);
    font-size: 13px;
}

.page-hero {
    margin: 34px 0 34px;
    padding: clamp(28px, 6vw, 58px);
    border: 1px solid rgba(34, 211, 238, 0.24);
    border-radius: 30px;
    background:
        radial-gradient(circle at 88% 18%, rgba(34, 211, 238, 0.18), transparent 22rem),
        linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.72));
    box-shadow: var(--shadow);
}

.page-hero h1 {
    margin: 14px 0 12px;
    font-size: clamp(32px, 5vw, 58px);
    line-height: 1.08;
    letter-spacing: -0.06em;
    font-weight: 950;
}

.page-hero p {
    margin: 0;
    max-width: 850px;
    color: var(--muted-strong);
    font-size: 18px;
}

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

.category-card {
    display: block;
    padding: 18px;
    border-radius: 24px;
    border: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.78);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

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

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

.category-card p {
    margin: 0 0 16px;
    color: var(--muted);
}

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

.category-preview img {
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: 12px;
    object-fit: cover;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 28px 0 18px;
    color: var(--muted);
    font-size: 14px;
}

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

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

.player-card,
.detail-card {
    border: 1px solid var(--line);
    border-radius: 28px;
    background: rgba(15, 23, 42, 0.82);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.cinema-player {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

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

.play-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, rgba(34, 211, 238, 0.18), rgba(2, 6, 23, 0.72));
    cursor: pointer;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

.cinema-player.is-playing .play-cover {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.play-button {
    width: 86px;
    height: 86px;
    border: 0;
    border-radius: 50%;
    color: white;
    background: linear-gradient(135deg, var(--cyan-deep), var(--blue));
    box-shadow: 0 24px 60px rgba(6, 182, 212, 0.32);
    cursor: pointer;
    font-size: 34px;
    display: grid;
    place-items: center;
}

.player-info {
    padding: 24px;
}

.player-info h1 {
    margin: 0 0 14px;
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.13;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 14px 0;
}

.meta-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    color: #dbeafe;
    background: rgba(30, 41, 59, 0.88);
    border: 1px solid rgba(51, 65, 85, 0.8);
    font-size: 13px;
}

.detail-card {
    padding: 24px;
}

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

.detail-card p {
    margin: 0 0 18px;
    color: var(--muted-strong);
}

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

.tag {
    padding: 5px 9px;
    border-radius: 999px;
    color: var(--cyan);
    background: rgba(34, 211, 238, 0.1);
    border: 1px solid rgba(34, 211, 238, 0.22);
    font-size: 12px;
}

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

.footer {
    margin-top: 70px;
    border-top: 1px solid rgba(51, 65, 85, 0.72);
    background: rgba(2, 6, 23, 0.74);
}

.footer-inner {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 34px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    color: var(--muted);
}

.footer strong {
    color: white;
}

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

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

    .detail-layout,
    .feature-layout {
        grid-template-columns: 1fr;
    }
}

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

    .nav-toggle {
        display: block;
    }

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

    .hero-slide::after {
        background: linear-gradient(0deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.28));
    }

    .hero-content {
        left: 22px;
        right: 22px;
        bottom: 74px;
        width: auto;
    }

    .hero-dots {
        left: 22px;
        right: auto;
        bottom: 28px;
    }

    .section-head,
    .footer-inner {
        display: block;
    }

    .search-panel {
        grid-template-columns: 1fr;
    }

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

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

    .rank-item {
        grid-template-columns: 46px 58px 1fr;
    }

    .rank-item .btn {
        grid-column: 1 / -1;
    }
}

@media (max-width: 520px) {
    .page,
    .navbar,
    .footer-inner {
        width: min(100% - 24px, 1280px);
    }

    .logo {
        font-size: 18px;
    }

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

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

    .movie-grid,
    .related-grid {
        grid-template-columns: 1fr 1fr;
    }

    .card-body {
        padding: 12px;
    }

    .card-title {
        font-size: 14px;
    }

    .card-summary {
        display: none;
    }

    .player-info,
    .detail-card {
        padding: 18px;
    }
}
