:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.86);
    --panel-soft: rgba(30, 41, 59, 0.72);
    --line: rgba(148, 163, 184, 0.18);
    --text: #e2e8f0;
    --muted: #94a3b8;
    --cyan: #22d3ee;
    --blue: #3b82f6;
    --shadow: 0 24px 80px rgba(8, 145, 178, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background:
        radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 34rem),
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.15), transparent 32rem),
        var(--bg);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

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

.header-inner {
    width: min(1220px, calc(100% - 32px));
    height: 76px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 22px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #fff;
    font-weight: 900;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 12px 28px rgba(34, 211, 238, 0.28);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-copy strong {
    font-size: 21px;
    letter-spacing: 0.02em;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-copy small {
    margin-top: 5px;
    color: var(--muted);
    font-size: 12px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-left: auto;
}

.nav-link {
    color: #cbd5e1;
    font-size: 15px;
    font-weight: 700;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--cyan);
}

.header-search,
.mobile-search,
.big-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-search input,
.mobile-search input,
.big-search input {
    width: 220px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 11px 15px;
    color: var(--text);
    background: rgba(15, 23, 42, 0.75);
    outline: none;
}

.header-search input:focus,
.mobile-search input:focus,
.big-search input:focus {
    border-color: rgba(34, 211, 238, 0.65);
    box-shadow: 0 0 0 4px rgba(34, 211, 238, 0.12);
}

.header-search button,
.mobile-search button,
.big-search button,
.primary-btn {
    border: 0;
    border-radius: 999px;
    padding: 11px 18px;
    color: #fff;
    font-weight: 800;
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    cursor: pointer;
    box-shadow: 0 16px 36px rgba(37, 99, 235, 0.24);
}

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--panel-soft);
}

.menu-button span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: var(--text);
    border-radius: 99px;
}

.mobile-panel {
    display: none;
    width: min(1220px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.95);
}

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

.mobile-panel nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 14px;
}

.mobile-search input {
    width: 100%;
}

.hero {
    position: relative;
    min-height: 680px;
    overflow: hidden;
    border-bottom: 1px solid var(--line);
}

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

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

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.78) 45%, rgba(2, 6, 23, 0.55) 100%),
        linear-gradient(0deg, #020617 0%, transparent 38%);
}

.hero-content {
    position: relative;
    width: min(1220px, calc(100% - 32px));
    min-height: 680px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: center;
    gap: 56px;
    padding: 72px 0;
}

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

.hero-badge,
.page-hero span,
.section-heading span {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border: 1px solid rgba(34, 211, 238, 0.28);
    border-radius: 999px;
    padding: 8px 13px;
    color: #67e8f9;
    font-size: 13px;
    font-weight: 800;
    background: rgba(8, 145, 178, 0.14);
}

.hero h1,
.page-hero h1 {
    margin: 24px 0 18px;
    font-size: clamp(38px, 7vw, 78px);
    line-height: 1.02;
    letter-spacing: -0.05em;
}

.hero p,
.page-hero p {
    max-width: 760px;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.85;
}

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

.pill {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 999px;
    padding: 5px 10px;
    color: #cbd5e1;
    font-size: 12px;
    background: rgba(15, 23, 42, 0.64);
}

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

.ghost-btn,
.section-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 999px;
    padding: 10px 18px;
    color: #dbeafe;
    font-weight: 800;
    background: rgba(15, 23, 42, 0.68);
}

.hero-poster {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(34, 211, 238, 0.22);
    border-radius: 30px;
    background: rgba(15, 23, 42, 0.76);
    box-shadow: var(--shadow);
}

.hero-poster img {
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.hero-poster span {
    position: absolute;
    left: 18px;
    bottom: 18px;
    border-radius: 999px;
    padding: 8px 12px;
    color: #fff;
    font-size: 13px;
    font-weight: 900;
    background: rgba(6, 182, 212, 0.88);
}

.hero-control {
    position: absolute;
    left: 50%;
    bottom: 34px;
    z-index: 5;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 16px;
}

.hero-control button {
    width: 42px;
    height: 42px;
    border: 1px solid rgba(148, 163, 184, 0.24);
    border-radius: 999px;
    color: #fff;
    font-size: 28px;
    background: rgba(15, 23, 42, 0.72);
    cursor: pointer;
}

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

.hero-dot {
    width: 10px !important;
    height: 10px !important;
    padding: 0 !important;
    border-radius: 999px;
    background: rgba(226, 232, 240, 0.34) !important;
}

.hero-dot.active {
    width: 28px !important;
    background: linear-gradient(90deg, var(--cyan), var(--blue)) !important;
}

.quick-zones,
.content-section,
.split-section,
.detail-layout,
.player-section {
    width: min(1220px, calc(100% - 32px));
    margin: 0 auto;
}

.quick-zones {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    padding: 34px 0 8px;
}

.quick-zones a {
    border: 1px solid var(--line);
    border-radius: 22px;
    padding: 22px;
    background: rgba(15, 23, 42, 0.74);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.quick-zones a:hover,
.movie-card:hover,
.category-card:hover {
    transform: translateY(-6px);
    border-color: rgba(34, 211, 238, 0.46);
}

.quick-zones strong {
    display: block;
    font-size: 20px;
    color: #fff;
}

.quick-zones span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
}

.content-section {
    padding: 64px 0 0;
}

.section-heading {
    margin-bottom: 26px;
}

.section-heading.inline-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
}

.section-heading h2 {
    margin: 14px 0 8px;
    color: #fff;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.08;
}

.section-heading p {
    max-width: 760px;
    color: var(--muted);
    line-height: 1.8;
}

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

.category-card {
    min-height: 170px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 20px;
    background:
        radial-gradient(circle at top right, rgba(34, 211, 238, 0.18), transparent 9rem),
        rgba(15, 23, 42, 0.78);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-card span {
    color: #fff;
    font-size: 22px;
    font-weight: 900;
}

.category-card strong {
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.6;
}

.category-card em {
    color: var(--cyan);
    font-style: normal;
    font-weight: 800;
}

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

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

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

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

.movie-card:hover {
    box-shadow: var(--shadow);
}

.movie-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.movie-poster {
    position: relative;
    overflow: hidden;
    background: #0f172a;
}

.movie-poster img {
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.poster-year,
.poster-type {
    position: absolute;
    top: 12px;
    border-radius: 999px;
    padding: 6px 10px;
    color: #fff;
    font-size: 12px;
    font-weight: 900;
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(12px);
}

.poster-year {
    left: 12px;
}

.poster-type {
    right: 12px;
}

.movie-info {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 16px;
}

.movie-info h3 {
    margin: 0 0 9px;
    color: #fff;
    font-size: 18px;
    line-height: 1.35;
}

.movie-info p {
    margin: 0;
    flex: 1;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
}

.movie-meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
    color: #cbd5e1;
    font-size: 12px;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: start;
    gap: 26px;
    padding-top: 28px;
}

.compact-section {
    width: auto;
    margin: 0;
    padding: 36px 0 0;
}

.ranking-panel,
.detail-side {
    position: sticky;
    top: 100px;
    border: 1px solid var(--line);
    border-radius: 26px;
    padding: 22px;
    background: rgba(15, 23, 42, 0.78);
}

.rank-list,
.wide-rank-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.rank-item a {
    display: grid;
    grid-template-columns: 46px 62px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

.rank-item:last-child a {
    border-bottom: 0;
}

.rank-number {
    color: #67e8f9;
    font-size: 18px;
    font-weight: 900;
}

.rank-item img {
    width: 62px;
    height: 82px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-copy strong,
.rank-copy small {
    display: block;
}

.rank-copy strong {
    color: #fff;
    font-size: 15px;
    line-height: 1.35;
}

.rank-copy small {
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.wide-rank-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 24px;
    border: 1px solid var(--line);
    border-radius: 26px;
    padding: 16px 24px;
    background: rgba(15, 23, 42, 0.74);
}

.page-hero,
.detail-hero {
    width: min(1220px, calc(100% - 32px));
    margin: 0 auto;
    padding: 76px 0 24px;
}

.page-hero {
    min-height: 360px;
    display: flex;
    align-items: center;
}

.slim-hero,
.search-hero,
.ranking-hero,
.category-hero {
    min-height: 300px;
}

.big-search {
    max-width: 760px;
    margin-top: 26px;
}

.big-search input {
    flex: 1;
    width: auto;
    border-radius: 20px;
    padding: 16px 18px;
}

.big-search button {
    border-radius: 20px;
    padding: 16px 24px;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 24px;
}

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

.filter-row button.active {
    color: #fff;
    border-color: rgba(34, 211, 238, 0.52);
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.8), rgba(37, 99, 235, 0.8));
}

.detail-hero {
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 38px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    border: 1px solid rgba(34, 211, 238, 0.24);
    border-radius: 28px;
    background: var(--panel-soft);
    box-shadow: var(--shadow);
}

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

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

.breadcrumb a {
    color: #67e8f9;
}

.detail-copy h1 {
    margin: 18px 0 16px;
    color: #fff;
    font-size: clamp(34px, 6vw, 64px);
    line-height: 1.05;
}

.detail-copy p {
    max-width: 820px;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.86;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.detail-meta span {
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 9px 12px;
    color: #dbeafe;
    background: rgba(15, 23, 42, 0.72);
}

.player-section {
    padding: 42px 0 0;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(34, 211, 238, 0.24);
    border-radius: 28px;
    background: #000;
    box-shadow: var(--shadow);
}

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

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.38), rgba(2, 6, 23, 0.08));
    cursor: pointer;
}

.play-overlay span {
    width: 92px;
    height: 92px;
    border-radius: 999px;
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    box-shadow: 0 18px 48px rgba(34, 211, 238, 0.35);
    position: relative;
}

.play-overlay span::after {
    content: "";
    position: absolute;
    left: 38px;
    top: 30px;
    width: 0;
    height: 0;
    border-top: 16px solid transparent;
    border-bottom: 16px solid transparent;
    border-left: 23px solid #fff;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
    padding-top: 42px;
}

.detail-article {
    border: 1px solid var(--line);
    border-radius: 26px;
    padding: 30px;
    background: rgba(15, 23, 42, 0.76);
}

.detail-article h2,
.detail-side h2 {
    margin: 0 0 16px;
    color: #fff;
    font-size: 28px;
}

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

.detail-article p {
    margin: 0;
    color: #cbd5e1;
    line-height: 1.95;
    font-size: 17px;
}

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

.footer-inner {
    width: min(1220px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 420px;
    gap: 30px;
    padding: 42px 0;
}

.footer-brand p {
    max-width: 640px;
    margin: 18px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

.footer-links strong {
    display: block;
    margin-bottom: 14px;
    color: #fff;
}

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

.footer-links a {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 8px 12px;
    color: #cbd5e1;
    background: rgba(15, 23, 42, 0.68);
}

.footer-bottom {
    width: min(1220px, calc(100% - 32px));
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 0;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 14px;
}

.empty-state {
    grid-column: 1 / -1;
    border: 1px solid var(--line);
    border-radius: 24px;
    padding: 42px;
    color: var(--muted);
    text-align: center;
    background: rgba(15, 23, 42, 0.74);
}

@media (max-width: 1180px) {
    .desktop-nav,
    .header-search {
        display: none;
    }

    .menu-button {
        display: block;
        margin-left: auto;
    }

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

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

    .ranking-panel,
    .detail-side {
        position: static;
    }

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

@media (max-width: 760px) {
    .header-inner {
        height: 66px;
    }

    .brand-copy strong {
        font-size: 18px;
    }

    .brand-copy small {
        display: none;
    }

    .hero,
    .hero-content {
        min-height: 620px;
    }

    .hero-content {
        padding: 42px 0 86px;
        gap: 26px;
    }

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

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

    .quick-zones,
    .category-grid,
    .category-movie-grid,
    .movie-grid,
    .small-grid,
    .related-grid,
    .wide-rank-list {
        grid-template-columns: 1fr;
    }

    .section-heading.inline-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .big-search,
    .mobile-search {
        align-items: stretch;
        flex-direction: column;
    }

    .footer-bottom {
        flex-direction: column;
    }
}
