
:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.72);
    --panel-strong: rgba(15, 23, 42, 0.92);
    --line: rgba(148, 163, 184, 0.18);
    --text: #f8fafc;
    --muted: #94a3b8;
    --soft: #cbd5e1;
    --blue: #3b82f6;
    --cyan: #22d3ee;
    --red: #fb7185;
    --green: #34d399;
    --radius: 22px;
    --shadow: 0 24px 90px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 18% 8%, rgba(59, 130, 246, 0.18), transparent 26rem),
        radial-gradient(circle at 82% 18%, rgba(34, 211, 238, 0.14), transparent 28rem),
        linear-gradient(135deg, #020617 0%, #0f172a 48%, #020617 100%);
}

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

img {
    display: block;
    max-width: 100%;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.8), rgba(15, 23, 42, 0.95));
}

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: background 0.28s ease, box-shadow 0.28s ease, backdrop-filter 0.28s ease;
}

.site-header.is-scrolled,
.site-header.menu-open {
    background: rgba(2, 6, 23, 0.94);
    box-shadow: 0 16px 45px rgba(2, 6, 23, 0.45);
    backdrop-filter: blur(18px);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.02em;
    background: linear-gradient(90deg, #60a5fa, #22d3ee);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 12px;
    color: white;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    box-shadow: 0 14px 32px rgba(59, 130, 246, 0.35);
    font-size: 14px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 26px;
}

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

.nav-link:hover,
.nav-link.active {
    color: white;
}

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

.mobile-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: white;
    border-radius: 999px;
}

main {
    min-height: 70vh;
}

.hero {
    position: relative;
    height: 72vh;
    min-height: 560px;
    overflow: hidden;
}

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

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

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

.hero-shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.86) 45%, rgba(2, 6, 23, 0.34) 100%),
        linear-gradient(0deg, rgba(2, 6, 23, 0.9) 0%, rgba(2, 6, 23, 0.12) 48%, rgba(2, 6, 23, 0.52) 100%);
}

.hero-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    padding-top: 76px;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 12px;
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.16);
    border: 1px solid rgba(96, 165, 250, 0.26);
    border-radius: 999px;
    font-size: 13px;
}

.hero h1,
.hero h2,
.page-hero h1,
.detail-title h1 {
    margin: 0;
    font-weight: 850;
    line-height: 1.08;
    letter-spacing: -0.04em;
}

.hero h1,
.hero h2 {
    font-size: clamp(40px, 7vw, 72px);
}

.hero p {
    max-width: 620px;
    margin: 22px 0 26px;
    color: #cbd5e1;
    font-size: clamp(16px, 2.2vw, 20px);
    line-height: 1.75;
}

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

.hero-meta span,
.movie-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 9px;
    color: #cbd5e1;
    background: rgba(15, 23, 42, 0.68);
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 999px;
    font-size: 12px;
}

.hero-actions,
.section-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 14px;
    color: white;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    box-shadow: 0 16px 38px rgba(59, 130, 246, 0.28);
    font-weight: 700;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 45px rgba(34, 211, 238, 0.3);
}

.btn-muted {
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: none;
}

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

.hero-dots button {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.48);
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
    width: 34px;
    background: white;
}

.quick-search {
    display: flex;
    width: min(520px, 100%);
    min-height: 52px;
    margin-top: 28px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(18px);
}

.quick-search input {
    flex: 1;
    min-width: 0;
    padding: 0 18px;
    border: 0;
    outline: 0;
    color: white;
    background: transparent;
}

.quick-search button {
    padding: 0 18px;
    border: 0;
    color: white;
    background: rgba(59, 130, 246, 0.92);
    cursor: pointer;
}

.section {
    padding: 76px 0;
}

.section-soft {
    background: rgba(15, 23, 42, 0.38);
    border-top: 1px solid rgba(148, 163, 184, 0.08);
    border-bottom: 1px solid rgba(148, 163, 184, 0.08);
}

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

.section-heading h2,
.section-heading h1,
.block-title {
    margin: 0;
    font-size: clamp(26px, 3vw, 38px);
    font-weight: 820;
    letter-spacing: -0.03em;
}

.section-heading p,
.page-hero p,
.detail-title p {
    max-width: 760px;
    margin: 10px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.62);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.18);
    transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    border-color: rgba(96, 165, 250, 0.35);
    background: rgba(30, 41, 59, 0.82);
}

.poster-link,
.poster-frame {
    display: block;
}

.poster-frame {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
}

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

.movie-card:hover .poster-frame img,
.wide-card:hover img,
.rank-card:hover img,
.related-card:hover img {
    transform: scale(1.08);
}

.poster-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.82), transparent 58%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.poster-play {
    position: absolute;
    right: 14px;
    bottom: 14px;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    color: white;
    background: rgba(59, 130, 246, 0.96);
    transform: translateY(10px);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .poster-mask,
.movie-card:hover .poster-play {
    opacity: 1;
    transform: translateY(0);
}

.card-body {
    padding: 16px;
}

.card-body h2,
.wide-card h2,
.rank-card h2,
.related-card h2 {
    margin: 10px 0 8px;
    color: white;
    font-size: 17px;
    line-height: 1.35;
}

.card-body p,
.wide-card p,
.rank-card p,
.related-card p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}

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

.tag-row span {
    padding: 4px 8px;
    border-radius: 999px;
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.12);
    border: 1px solid rgba(96, 165, 250, 0.18);
    font-size: 12px;
}

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

.wide-card {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    min-height: 200px;
}

.wide-card-cover {
    overflow: hidden;
}

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

.wide-card-body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 18px;
}

.home-split {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(320px, 0.9fr);
    gap: 34px;
}

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

.category-card {
    position: relative;
    min-height: 190px;
    padding: 24px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 22px;
    background:
        radial-gradient(circle at 86% 18%, rgba(34, 211, 238, 0.14), transparent 11rem),
        rgba(15, 23, 42, 0.72);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(96, 165, 250, 0.36);
}

.category-card h2,
.category-card h3 {
    margin: 0 0 12px;
    font-size: 23px;
}

.category-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.75;
}

.rank-panel {
    padding: 22px;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.72);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 42px 72px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    padding: 12px;
    border-radius: 16px;
    transition: background 0.2s ease;
}

.rank-item:hover {
    background: rgba(51, 65, 85, 0.58);
}

.rank-no {
    color: rgba(148, 163, 184, 0.45);
    font-size: 28px;
    font-weight: 850;
}

.rank-thumb {
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 12px;
}

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

.rank-item h3 {
    margin: 0 0 7px;
    font-size: 15px;
}

.rank-item p {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
}

.page-hero {
    padding: 136px 0 54px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
    background:
        radial-gradient(circle at 20% 10%, rgba(59, 130, 246, 0.18), transparent 24rem),
        radial-gradient(circle at 84% 20%, rgba(34, 211, 238, 0.11), transparent 26rem);
}

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

.breadcrumb a {
    color: #bfdbfe;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 190px 170px 190px;
    gap: 14px;
    margin: 28px 0 12px;
    padding: 18px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.66);
}

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

.filter-search {
    grid-column: span 1;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 46px;
    padding: 0 13px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 14px;
    color: white;
    background: rgba(2, 6, 23, 0.76);
    outline: 0;
}

.filter-status {
    min-height: 22px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 14px;
}

.empty-state {
    display: none;
    padding: 28px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: 18px;
    color: var(--muted);
    background: rgba(15, 23, 42, 0.58);
}

.empty-state.is-visible {
    display: block;
}

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

.rank-card {
    position: relative;
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
}

.rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: grid;
    place-items: center;
    min-width: 36px;
    height: 36px;
    padding: 0 9px;
    border-radius: 12px;
    color: white;
    background: rgba(2, 6, 23, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.16);
    font-weight: 850;
}

.rank-cover {
    overflow: hidden;
}

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

.rank-body {
    padding: 16px;
}

.detail-hero {
    padding: 126px 0 58px;
    background:
        radial-gradient(circle at 20% 10%, rgba(59, 130, 246, 0.18), transparent 24rem),
        linear-gradient(180deg, rgba(15, 23, 42, 0.62), rgba(2, 6, 23, 0));
}

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

.detail-poster {
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 24px;
    box-shadow: var(--shadow);
}

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

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

.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin: 26px 0;
}

.content-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(300px, 0.8fr);
    gap: 34px;
    align-items: start;
}

.content-block {
    padding: 28px;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.66);
}

.content-block + .content-block {
    margin-top: 24px;
}

.content-block h2 {
    margin: 0 0 18px;
    font-size: 26px;
}

.content-block p {
    margin: 0;
    color: var(--soft);
    line-height: 1.95;
}

.info-table {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 12px 18px;
    color: var(--soft);
}

.info-table dt {
    color: var(--muted);
}

.info-table dd {
    margin: 0;
}

.player-box {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid rgba(96, 165, 250, 0.18);
    border-radius: 26px;
    background: #000;
    box-shadow: var(--shadow);
}

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

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    gap: 12px;
    width: 100%;
    border: 0;
    color: white;
    background:
        linear-gradient(0deg, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.32)),
        var(--player-cover);
    background-size: cover;
    background-position: center;
    cursor: pointer;
}

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

.play-ring {
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    box-shadow: 0 24px 54px rgba(59, 130, 246, 0.36);
    font-size: 32px;
}

.player-cover strong {
    font-size: 26px;
}

.player-cover em {
    color: #bfdbfe;
    font-style: normal;
}

.related-list {
    display: grid;
    gap: 16px;
}

.related-card {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 14px;
    padding: 12px;
    border: 1px solid rgba(148, 163, 184, 0.12);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.56);
    transition: background 0.2s ease;
}

.related-card:hover {
    background: rgba(30, 41, 59, 0.72);
}

.related-card figure {
    margin: 0;
    overflow: hidden;
    border-radius: 12px;
}

.related-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.related-card h2 {
    font-size: 15px;
}

.site-footer {
    margin-top: 70px;
    padding: 52px 0 22px;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    background: rgba(2, 6, 23, 0.74);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 36px;
}

.site-footer p {
    color: var(--muted);
    line-height: 1.75;
}

.site-footer h2 {
    margin: 0 0 16px;
    font-size: 18px;
}

.footer-links {
    display: grid;
    gap: 10px;
}

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

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 34px auto 0;
    padding-top: 22px;
    border-top: 1px solid rgba(148, 163, 184, 0.1);
    color: rgba(148, 163, 184, 0.72);
    text-align: center;
}

@media (max-width: 980px) {
    .mobile-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 76px;
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 14px;
        border: 1px solid rgba(148, 163, 184, 0.14);
        border-radius: 18px;
        background: rgba(2, 6, 23, 0.96);
        box-shadow: var(--shadow);
    }

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

    .nav-link {
        padding: 12px 8px;
    }

    .hero {
        min-height: 680px;
    }

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

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

    .detail-poster {
        max-width: 320px;
    }

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

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

    .brand {
        font-size: 20px;
    }

    .hero {
        height: auto;
        min-height: 700px;
    }

    .hero-content {
        align-items: end;
        padding-bottom: 92px;
    }

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

    .section {
        padding: 54px 0;
    }

    .section-heading {
        display: block;
    }

    .movie-grid,
    .wide-grid,
    .ranking-grid,
    .category-preview {
        grid-template-columns: 1fr;
    }

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

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

    .content-block {
        padding: 20px;
    }

    .player-cover strong {
        font-size: 20px;
    }
}
