:root {
    --site-primary: #0284c7;
    --site-primary-dark: #0369a1;
    --site-ink: #0f172a;
    --site-muted: #64748b;
    --site-soft: #f8fafc;
    --site-line: #e2e8f0;
    --site-card: #ffffff;
    --site-radius: 22px;
    --site-shadow: 0 20px 55px rgba(15, 23, 42, .12);
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    color: var(--site-ink);
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 42%, #f8fafc 100%);
    font-family: Inter, "Noto Sans SC", "Microsoft YaHei", Arial, sans-serif;
}

body.nav-open {
    overflow: hidden;
}

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

.site-header.scrolled,
.site-header.open {
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 10px 30px rgba(15, 23, 42, .08);
    backdrop-filter: blur(16px);
}

.nav-wrap {
    width: min(1180px, calc(100% - 32px));
    height: 76px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -.03em;
}

.site-header.scrolled .brand,
.site-header.open .brand {
    color: var(--site-ink);
}

.brand-icon {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--site-primary), #38bdf8);
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(2, 132, 199, .32);
    font-size: 16px;
}

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

.main-nav a {
    color: rgba(255, 255, 255, .92);
    font-weight: 700;
    font-size: 15px;
    transition: color .2s ease;
}

.site-header.scrolled .main-nav a,
.site-header.open .main-nav a {
    color: #334155;
}

.main-nav a:hover,
.main-nav a.active,
.site-header.scrolled .main-nav a:hover,
.site-header.scrolled .main-nav a.active {
    color: var(--site-primary);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
}

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

.site-header.scrolled .nav-toggle,
.site-header.open .nav-toggle {
    color: var(--site-ink);
}

.hero {
    position: relative;
    height: 78vh;
    min-height: 620px;
    overflow: hidden;
    background: #020617;
}

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

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

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

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(2, 6, 23, .15), rgba(2, 6, 23, .72)), linear-gradient(90deg, rgba(2, 6, 23, .88), rgba(2, 6, 23, .12));
}

.hero-content {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
}

.hero-content,
.home-search,
.category-overview-block,
.rank-block,
.hot-section,
.page-main,
.detail-wrap {
    width: min(1180px, calc(100% - 32px));
    margin-left: auto;
    margin-right: auto;
}

.hero-copy {
    width: min(720px, 100%);
    color: #ffffff;
    padding-top: 64px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(2, 132, 199, .13);
    color: #0284c7;
    font-weight: 800;
    font-size: 13px;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hero .eyebrow,
.detail-hero .eyebrow {
    background: rgba(14, 165, 233, .95);
    color: #ffffff;
}

.hero h1 {
    margin-top: 18px;
    font-size: clamp(42px, 7vw, 76px);
    line-height: 1.02;
    font-weight: 950;
    letter-spacing: -.055em;
}

.hero p {
    margin-top: 22px;
    width: min(660px, 100%);
    font-size: clamp(17px, 2vw, 22px);
    color: rgba(255, 255, 255, .9);
    line-height: 1.75;
}

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

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

.hero-tags span,
.tag-row span,
.tag-cloud span {
    border-radius: 999px;
    background: rgba(255, 255, 255, .16);
    color: #ffffff;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 700;
    backdrop-filter: blur(8px);
}

.tag-row span,
.tag-cloud span {
    background: #eff6ff;
    color: #0369a1;
}

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

.primary-btn,
.ghost-btn,
.search-box a,
.section-head a,
.category-card span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 14px;
    font-weight: 850;
    transition: transform .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}

.primary-btn {
    background: var(--site-primary);
    color: #ffffff;
    box-shadow: 0 18px 35px rgba(2, 132, 199, .35);
}

.primary-btn:hover,
.search-box a:hover {
    background: var(--site-primary-dark);
    transform: translateY(-2px);
}

.ghost-btn {
    border: 1px solid rgba(255, 255, 255, .35);
    color: #ffffff;
    background: rgba(255, 255, 255, .1);
    backdrop-filter: blur(10px);
}

.ghost-btn:hover {
    background: rgba(255, 255, 255, .18);
    transform: translateY(-2px);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 8;
    width: 52px;
    height: 52px;
    border-radius: 999px;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, .18);
    color: #ffffff;
    font-size: 38px;
    line-height: 1;
    backdrop-filter: blur(12px);
    transition: background .2s ease, transform .2s ease;
}

.hero-arrow:hover {
    background: rgba(255, 255, 255, .28);
    transform: translateY(-50%) scale(1.04);
}

.hero-arrow.prev {
    left: 24px;
}

.hero-arrow.next {
    right: 24px;
}

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

.hero-dots button {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .55);
    transition: width .25s ease, background .25s ease;
}

.hero-dots button.active {
    width: 34px;
    background: #ffffff;
}

.home-search,
.category-overview-block,
.rank-block {
    padding: 72px 0;
}

.search-panel,
.page-hero,
.content-card,
.side-card,
.category-card a,
.text-page article,
.list-tools {
    background: rgba(255, 255, 255, .92);
    border: 1px solid var(--site-line);
    border-radius: var(--site-radius);
    box-shadow: var(--site-shadow);
}

.search-panel {
    padding: clamp(26px, 5vw, 46px);
    margin-bottom: 24px;
    background: linear-gradient(135deg, #ffffff, #f0f9ff);
}

.search-panel h2,
.section-head h2,
.page-hero h1,
.content-card h2,
.side-card h2,
.text-page h2 {
    font-weight: 950;
    color: var(--site-ink);
    letter-spacing: -.035em;
}

.search-panel h2 {
    font-size: clamp(28px, 4vw, 46px);
}

.search-panel p,
.section-head p,
.page-hero p,
.movie-card p,
.content-card p,
.text-page p {
    color: var(--site-muted);
    line-height: 1.78;
}

.search-panel p {
    margin-top: 10px;
    max-width: 700px;
}

.search-box {
    margin-top: 26px;
    display: flex;
    gap: 12px;
}

.search-box input {
    flex: 1;
    min-width: 0;
    height: 54px;
    border-radius: 16px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    padding: 0 18px;
    color: var(--site-ink);
    outline: none;
    box-shadow: inset 0 1px 0 rgba(15, 23, 42, .03);
}

.search-box input:focus {
    border-color: var(--site-primary);
    box-shadow: 0 0 0 4px rgba(2, 132, 199, .12);
}

.search-box a {
    background: var(--site-primary);
    color: #ffffff;
    white-space: nowrap;
}

.search-box.wide {
    margin: 0;
    flex: 1;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 22px 0 28px;
}

.filter-row button {
    border-radius: 999px;
    border: 1px solid #cbd5e1;
    background: #ffffff;
    color: #334155;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 800;
    transition: background .2s ease, color .2s ease, border-color .2s ease;
}

.filter-row button.active,
.filter-row button:hover {
    background: var(--site-primary);
    border-color: var(--site-primary);
    color: #ffffff;
}

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

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

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

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

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(2, 132, 199, .45);
    box-shadow: 0 22px 48px rgba(15, 23, 42, .14);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #0f172a;
}

.movie-card.compact .poster-link {
    aspect-ratio: 16 / 9;
}

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

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

.play-chip {
    position: absolute;
    right: 12px;
    bottom: 12px;
    border-radius: 999px;
    background: rgba(2, 132, 199, .94);
    color: #ffffff;
    padding: 7px 12px;
    font-size: 12px;
    font-weight: 850;
}

.rank-mark {
    position: absolute;
    left: 12px;
    top: 12px;
    min-width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: rgba(15, 23, 42, .82);
    color: #ffffff;
    font-weight: 950;
    box-shadow: 0 10px 22px rgba(0, 0, 0, .22);
}

.card-body {
    padding: 18px;
}

.meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--site-primary-dark);
    font-size: 12px;
    font-weight: 850;
}

.meta-row span:not(:last-child)::after {
    content: "·";
    margin-left: 8px;
    color: #94a3b8;
}

.movie-card h3 {
    font-size: 20px;
    line-height: 1.35;
    font-weight: 950;
    color: var(--site-ink);
    margin-bottom: 9px;
}

.movie-card h3 a:hover {
    color: var(--site-primary);
}

.movie-card p {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    font-size: 14px;
}

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

.tag-row span {
    font-size: 12px;
    padding: 6px 9px;
}

.hot-section {
    width: 100%;
    max-width: none;
    padding: 68px max(16px, calc((100% - 1180px) / 2));
    background: linear-gradient(135deg, #0284c7, #0369a1);
}

.hot-scroll {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(270px, 1fr);
    gap: 18px;
    overflow-x: auto;
    padding: 8px 4px 18px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
}

.hot-scroll::-webkit-scrollbar {
    display: none;
}

.hot-scroll .movie-card {
    min-width: 270px;
    scroll-snap-align: start;
}

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

.section-head.left {
    align-items: center;
}

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

.section-head p {
    margin-top: 8px;
}

.section-head a {
    background: #e0f2fe;
    color: #0369a1;
    min-height: 42px;
}

.section-head a:hover,
.category-card a:hover span {
    background: var(--site-primary);
    color: #ffffff;
}

.section-head.dark h2,
.section-head.dark p,
.section-head.dark a {
    color: #ffffff;
}

.section-head.dark a {
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .25);
}

.category-strip {
    margin-top: 42px;
}

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

.page-main {
    padding-top: 112px;
    padding-bottom: 78px;
}

.page-hero {
    padding: clamp(34px, 5vw, 56px);
    margin-bottom: 32px;
    background: linear-gradient(135deg, #ffffff, #eef9ff);
}

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

.page-hero h1 {
    margin-top: 15px;
    font-size: clamp(36px, 5vw, 58px);
}

.page-hero p {
    margin-top: 14px;
    max-width: 820px;
    font-size: 17px;
}

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

.category-card a {
    display: grid;
    grid-template-columns: 210px 1fr;
    gap: 22px;
    padding: 18px;
    color: inherit;
}

.category-thumbs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.category-thumbs img {
    width: 100%;
    aspect-ratio: 1 / .78;
    object-fit: cover;
    border-radius: 13px;
    background: #0f172a;
}

.category-card h2 {
    font-size: 25px;
    font-weight: 950;
    margin: 8px 0 10px;
}

.category-card p {
    color: var(--site-muted);
    line-height: 1.72;
}

.category-card span {
    margin-top: 20px;
    background: #e0f2fe;
    color: #0369a1;
}

.list-tools {
    margin-bottom: 30px;
    padding: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
    justify-content: space-between;
}

.list-tools .filter-row {
    margin: 0;
}

.sticky-tools {
    position: sticky;
    top: 90px;
    z-index: 10;
    backdrop-filter: blur(16px);
}

.empty-state {
    margin-top: 24px;
    padding: 30px;
    text-align: center;
    border-radius: 18px;
    border: 1px dashed #93c5fd;
    color: #0369a1;
    background: #eff6ff;
    font-weight: 800;
}

.detail-main {
    background: #f8fafc;
    padding-bottom: 78px;
}

.detail-hero {
    min-height: 640px;
    padding-top: 108px;
    padding-bottom: 60px;
    background-size: cover;
    background-position: center;
    color: #ffffff;
}

.detail-wrap {
    width: min(1180px, calc(100% - 32px));
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
    color: rgba(255, 255, 255, .82);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #ffffff;
}

.detail-intro {
    display: grid;
    grid-template-columns: minmax(240px, 360px) 1fr;
    gap: clamp(26px, 5vw, 54px);
    align-items: center;
}

.detail-cover {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 26px;
    box-shadow: 0 32px 80px rgba(0, 0, 0, .34);
    background: #0f172a;
}

.detail-copy h1 {
    margin-top: 18px;
    font-size: clamp(36px, 5.4vw, 68px);
    font-weight: 950;
    letter-spacing: -.05em;
    line-height: 1.08;
}

.detail-copy .lead {
    margin-top: 20px;
    font-size: 19px;
    line-height: 1.78;
    color: rgba(255, 255, 255, .9);
    max-width: 760px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    margin-top: -80px;
    align-items: start;
}

.detail-content {
    display: grid;
    gap: 22px;
}

.player-section {
    border-radius: 26px;
    overflow: hidden;
    box-shadow: 0 32px 70px rgba(15, 23, 42, .28);
    background: #020617;
}

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

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle, rgba(2, 132, 199, .16), rgba(2, 6, 23, .2));
    transition: opacity .25s ease, visibility .25s ease;
}

.movie-player.is-started .player-overlay {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.big-play {
    width: 92px;
    height: 92px;
    border-radius: 999px;
    background: var(--site-primary);
    color: #ffffff;
    font-size: 34px;
    box-shadow: 0 24px 60px rgba(2, 132, 199, .45);
    transition: transform .2s ease, background .2s ease;
}

.big-play:hover {
    transform: scale(1.06);
    background: var(--site-primary-dark);
}

.content-card,
.side-card {
    padding: clamp(22px, 4vw, 34px);
}

.content-card h2,
.side-card h2 {
    font-size: 26px;
    margin-bottom: 16px;
}

.content-card p {
    font-size: 17px;
}

.tag-cloud span {
    margin-top: 0;
}

.detail-side {
    position: sticky;
    top: 100px;
}

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

.side-item {
    display: grid;
    grid-template-columns: 112px 1fr;
    gap: 14px;
    align-items: center;
    color: inherit;
}

.side-item img {
    width: 112px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 14px;
    background: #0f172a;
}

.side-item strong {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    font-size: 15px;
    line-height: 1.45;
}

.side-item em {
    display: block;
    margin-top: 6px;
    color: var(--site-muted);
    font-size: 12px;
    font-style: normal;
}

.side-item:hover strong {
    color: var(--site-primary);
}

.more-wrap {
    margin-top: 54px;
}

.text-page {
    display: grid;
    gap: 20px;
}

.text-page article {
    padding: 30px;
}

.text-page h2 {
    font-size: 26px;
    margin-bottom: 12px;
}

.site-footer {
    background: #0f172a;
    color: #cbd5e1;
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 58px 0 34px;
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 34px;
}

.footer-logo {
    display: inline-flex;
    margin-bottom: 14px;
    color: #ffffff;
    font-size: 24px;
    font-weight: 950;
}

.site-footer p {
    line-height: 1.75;
    max-width: 410px;
}

.site-footer h2 {
    color: #ffffff;
    font-size: 16px;
    font-weight: 900;
    margin-bottom: 16px;
}

.site-footer nav {
    display: grid;
    gap: 9px;
}

.site-footer a:hover {
    color: #38bdf8;
}

.footer-copy {
    border-top: 1px solid rgba(255, 255, 255, .08);
    text-align: center;
    padding: 20px 16px;
    color: #94a3b8;
    font-size: 14px;
}

@media (max-width: 1024px) {
    .movie-grid,
    .catalog-grid,
    .small-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

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

    .detail-side {
        position: static;
    }

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

@media (max-width: 768px) {
    .nav-wrap {
        height: 66px;
    }

    .brand {
        font-size: 20px;
    }

    .main-nav {
        position: fixed;
        left: 16px;
        right: 16px;
        top: 74px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 12px;
        border-radius: 20px;
        background: rgba(255, 255, 255, .98);
        box-shadow: var(--site-shadow);
    }

    body.nav-open .main-nav {
        display: flex;
    }

    .main-nav a,
    .site-header .main-nav a {
        color: #334155;
        padding: 14px 16px;
        border-radius: 13px;
    }

    .main-nav a:hover,
    .main-nav a.active {
        background: #f0f9ff;
    }

    .nav-toggle {
        display: flex;
    }

    .hero {
        height: 76vh;
        min-height: 560px;
    }

    .hero-content {
        width: calc(100% - 32px);
    }

    .hero h1 {
        font-size: clamp(34px, 12vw, 48px);
    }

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

    .hero-arrow {
        display: none;
    }

    .search-box,
    .list-tools {
        flex-direction: column;
        align-items: stretch;
    }

    .movie-grid,
    .catalog-grid,
    .small-grid,
    .rank-list {
        grid-template-columns: 1fr;
    }

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

    .detail-hero {
        padding-top: 92px;
    }

    .detail-intro {
        grid-template-columns: 1fr;
    }

    .detail-cover {
        max-width: 280px;
    }

    .detail-layout {
        margin-top: -40px;
    }

    .side-item {
        grid-template-columns: 96px 1fr;
    }

    .side-item img {
        width: 96px;
    }

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