:root {
    --night-950: #050607;
    --night-900: #0d0f12;
    --night-850: #13161b;
    --night-800: #1a1d23;
    --night-750: #21252b;
    --night-700: #2a2f37;
    --night-500: #6c757d;
    --night-400: #8b949e;
    --night-300: #adb5bd;
    --night-200: #dee2e6;
    --blood-700: #c1121f;
    --blood-600: #e63946;
    --blood-500: #ff4d4d;
    --yellow-500: #eab308;
    --white: #ffffff;
    --shadow-glow: 0 0 24px rgba(255, 77, 77, 0.28);
    --shadow-soft: 0 24px 60px rgba(0, 0, 0, 0.28);
    --radius: 16px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--night-200);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background:
        radial-gradient(circle at 18% 0%, rgba(230, 57, 70, 0.16), transparent 30%),
        radial-gradient(circle at 84% 10%, rgba(255, 77, 77, 0.1), transparent 34%),
        linear-gradient(180deg, var(--night-900), var(--night-950) 62%);
}

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

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

button,
input {
    font: inherit;
}

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

.site-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(13, 15, 18, 0.94);
    border-bottom: 1px solid var(--night-700);
    backdrop-filter: blur(10px);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--white);
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--blood-600), #7f101a);
    color: var(--white);
    box-shadow: var(--shadow-glow);
}

.brand-text {
    max-width: 320px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

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

.nav-link {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 16px;
    border-radius: 12px;
    color: var(--night-300);
    transition: color 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--white);
    background: var(--blood-600);
    box-shadow: 0 0 14px rgba(230, 57, 70, 0.22);
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: var(--night-800);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--night-200);
}

.mobile-panel {
    display: none;
    border-top: 1px solid var(--night-700);
    padding: 12px 16px 18px;
}

.hero {
    position: relative;
    height: 70vh;
    min-height: 560px;
    overflow: hidden;
    background: var(--night-900);
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(5, 6, 7, 0.96), rgba(13, 15, 18, 0.76) 42%, rgba(13, 15, 18, 0.18)),
        linear-gradient(0deg, var(--night-900), transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    max-width: 800px;
}

.hero-label {
    display: inline-flex;
    width: fit-content;
    padding: 7px 12px;
    margin-bottom: 18px;
    border-radius: 999px;
    color: var(--white);
    background: var(--blood-600);
    box-shadow: var(--shadow-glow);
}

.hero h1 {
    margin: 0 0 18px;
    color: var(--white);
    font-size: clamp(40px, 7vw, 78px);
    line-height: 1.02;
    text-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
}

.hero p {
    max-width: 760px;
    margin: 0 0 22px;
    color: var(--night-200);
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.7;
}

.hero-tags,
.detail-meta,
.tag-cloud,
.movie-tags,
.filter-row,
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-tags span,
.tag-cloud span,
.movie-tags span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(230, 57, 70, 0.16);
    color: var(--blood-500);
    padding: 6px 10px;
    font-size: 13px;
}

.hero-actions {
    align-items: center;
    margin-top: 28px;
}

.btn-primary,
.btn-ghost,
.btn-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 12px;
    font-weight: 700;
    transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.btn-primary {
    color: var(--white);
    background: var(--blood-600);
    box-shadow: var(--shadow-glow);
}

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

.btn-primary:hover {
    background: var(--blood-700);
}

.btn-ghost {
    color: var(--night-200);
    background: rgba(26, 29, 35, 0.8);
    border: 1px solid rgba(222, 226, 230, 0.12);
}

.btn-text {
    color: var(--blood-500);
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 52px;
    height: 52px;
    border: 0;
    border-radius: 50%;
    color: var(--white);
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(6px);
    cursor: pointer;
    font-size: 42px;
    line-height: 1;
    transform: translateY(-50%);
}

.hero-control:hover {
    background: rgba(193, 18, 31, 0.86);
}

.hero-control.prev {
    left: 22px;
}

.hero-control.next {
    right: 22px;
}

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

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

.hero-dot.active {
    width: 34px;
    background: var(--blood-600);
}

.page-stack {
    display: flex;
    flex-direction: column;
    gap: 72px;
    padding: 72px 0;
}

.page-main {
    padding: 72px 0;
}

.intro-panel,
.section-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 32px;
    border: 1px solid rgba(222, 226, 230, 0.08);
    border-radius: 24px;
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.1), rgba(26, 29, 35, 0.86));
    box-shadow: var(--shadow-soft);
}

.intro-panel h2,
.section-head h2,
.page-title h1,
.article-section h2 {
    margin: 0;
    color: var(--white);
}

.intro-panel p,
.section-head p,
.page-title p,
.article-section p,
.category-tile p,
.category-card p,
.site-footer p {
    color: var(--night-400);
    line-height: 1.8;
}

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

.section-head h2 {
    font-size: clamp(26px, 4vw, 38px);
}

.section-head a {
    color: var(--blood-500);
    font-weight: 700;
}

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(222, 226, 230, 0.07);
    border-radius: var(--radius);
    background: var(--night-800);
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.22);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    border-color: rgba(230, 57, 70, 0.34);
    box-shadow: var(--shadow-glow), 0 28px 60px rgba(0, 0, 0, 0.36);
}

.movie-card.horizontal {
    display: grid;
    grid-template-columns: 280px 1fr;
    min-height: 220px;
}

.poster-wrap {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--night-850);
}

.movie-card.horizontal .poster-wrap {
    aspect-ratio: auto;
    min-height: 220px;
}

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

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

.poster-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), transparent 54%);
}

.quality-badge,
.rating-badge,
.rank-num {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 9px;
    border-radius: 8px;
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
    background: rgba(0, 0, 0, 0.58);
    backdrop-filter: blur(5px);
}

.quality-badge {
    left: 10px;
    bottom: 10px;
    background: var(--blood-600);
}

.rating-badge {
    right: 10px;
    top: 10px;
    color: var(--yellow-500);
}

.rank-num {
    left: 10px;
    top: 10px;
    width: 34px;
    justify-content: center;
    background: var(--blood-600);
}

.play-hover {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    color: var(--white);
    background: var(--blood-600);
    box-shadow: var(--shadow-glow);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.movie-info {
    display: flex;
    flex-direction: column;
    min-height: 210px;
    padding: 16px;
}

.movie-card.horizontal .movie-info {
    min-height: auto;
    justify-content: center;
    padding: 24px;
}

.movie-info h3 {
    margin: 12px 0 8px;
    color: var(--white);
    font-size: 18px;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    transition: color 0.25s ease;
}

.movie-card:hover .movie-info h3 {
    color: var(--blood-500);
}

.movie-info p {
    flex: 1;
    margin: 0 0 14px;
    color: var(--night-400);
    font-size: 14px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.movie-meta,
.detail-meta {
    color: var(--night-500);
    font-size: 13px;
}

.movie-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

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

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

.category-tile,
.category-card {
    position: relative;
    overflow: hidden;
    min-height: 160px;
    padding: 24px;
    border: 1px solid rgba(222, 226, 230, 0.08);
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.14), rgba(26, 29, 35, 0.92));
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, border-color 0.25s ease;
}

.category-tile:hover,
.category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(230, 57, 70, 0.34);
}

.category-tile span,
.category-card span {
    position: relative;
    z-index: 2;
    display: block;
    margin-bottom: 10px;
    color: var(--white);
    font-size: 22px;
    font-weight: 800;
}

.category-tile p,
.category-card p {
    position: relative;
    z-index: 2;
    margin: 0;
}

.category-card.large {
    min-height: 260px;
}

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.22;
}

.featured-list {
    display: grid;
    gap: 22px;
}

.tool-bar,
.simple-search {
    margin-bottom: 24px;
}

.tool-bar {
    display: grid;
    gap: 16px;
    padding: 20px;
    border: 1px solid rgba(222, 226, 230, 0.08);
    border-radius: 18px;
    background: rgba(26, 29, 35, 0.76);
}

.search-box {
    display: grid;
    gap: 8px;
    color: var(--night-300);
    font-weight: 700;
}

.search-box input {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--night-700);
    border-radius: 12px;
    padding: 0 16px;
    color: var(--white);
    background: var(--night-900);
    outline: none;
}

.search-box input:focus {
    border-color: var(--blood-600);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.18);
}

.filter-btn {
    min-height: 38px;
    border: 1px solid rgba(222, 226, 230, 0.1);
    border-radius: 999px;
    padding: 0 14px;
    color: var(--night-300);
    background: var(--night-850);
    cursor: pointer;
}

.filter-btn:hover,
.filter-btn.active {
    color: var(--white);
    background: var(--blood-600);
    border-color: var(--blood-600);
}

.page-title {
    max-width: 860px;
    margin-bottom: 42px;
}

.page-title span {
    display: inline-flex;
    margin-bottom: 12px;
    color: var(--blood-500);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.16em;
}

.page-title h1 {
    font-size: clamp(40px, 7vw, 72px);
    line-height: 1.05;
}

.detail-hero {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    background: var(--night-900);
}

.detail-bg {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    filter: blur(12px);
    transform: scale(1.06);
    opacity: 0.28;
}

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, var(--night-950), rgba(5, 6, 7, 0.76) 46%, rgba(5, 6, 7, 0.32));
}

.detail-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 330px 1fr;
    gap: 42px;
    align-items: center;
    min-height: 620px;
    padding: 64px 0;
}

.detail-poster {
    overflow: hidden;
    border-radius: 24px;
    background: var(--night-800);
    box-shadow: var(--shadow-soft), var(--shadow-glow);
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--night-400);
    margin-bottom: 18px;
}

.breadcrumb a {
    color: var(--blood-500);
}

.detail-content h1 {
    margin: 0 0 18px;
    color: var(--white);
    font-size: clamp(42px, 7vw, 76px);
    line-height: 1.05;
}

.lead {
    max-width: 840px;
    margin: 0 0 22px;
    color: var(--night-200);
    font-size: 20px;
    line-height: 1.8;
}

.detail-meta {
    margin-bottom: 18px;
}

.tag-cloud {
    margin-bottom: 28px;
}

.player-section {
    padding: 72px 0 24px;
}

.video-frame {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid rgba(222, 226, 230, 0.08);
    border-radius: 22px;
    background: #000;
    box-shadow: var(--shadow-soft);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: var(--white);
    background: rgba(0, 0, 0, 0.36);
    cursor: pointer;
}

.player-overlay.hidden {
    display: none;
}

.play-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: var(--blood-600);
    box-shadow: var(--shadow-glow);
    font-size: 34px;
}

.article-section {
    display: grid;
    gap: 18px;
    padding: 42px 0 18px;
}

.article-section h2 {
    font-size: 28px;
}

.article-section p {
    margin: 0 0 12px;
    font-size: 17px;
}

.related-section {
    padding-top: 42px;
}

.site-footer {
    border-top: 1px solid var(--night-800);
    background: rgba(5, 6, 7, 0.94);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 38px;
    padding: 48px 0;
}

.site-footer h3 {
    margin: 0 0 16px;
    color: var(--white);
}

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

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

.footer-links a:hover {
    color: var(--blood-500);
}

.footer-bottom {
    border-top: 1px solid var(--night-800);
    padding: 22px 16px;
    text-align: center;
    color: var(--night-500);
}

[data-card].hidden {
    display: none;
}

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

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

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

    .nav-toggle {
        display: block;
    }

    .mobile-panel.open {
        display: grid;
        gap: 8px;
    }

    .mobile-panel .nav-link {
        justify-content: center;
    }

    .hero {
        height: 78vh;
        min-height: 620px;
    }

    .hero-overlay {
        background:
            linear-gradient(0deg, var(--night-900), rgba(13, 15, 18, 0.58) 64%, rgba(13, 15, 18, 0.38)),
            rgba(0, 0, 0, 0.28);
    }

    .hero-control {
        display: none;
    }

    .intro-panel,
    .section-head,
    .section-panel {
        align-items: start;
        flex-direction: column;
    }

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

    .movie-card.horizontal,
    .detail-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .detail-grid {
        gap: 26px;
    }

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

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

    .brand-text {
        max-width: 210px;
    }

    .hero h1,
    .detail-content h1,
    .page-title h1 {
        font-size: 38px;
    }

    .hero p,
    .lead {
        font-size: 16px;
    }

    .movie-grid,
    .compact-grid,
    .category-grid,
    .category-grid.big {
        grid-template-columns: 1fr;
    }

    .page-stack,
    .page-main {
        padding: 42px 0;
    }

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