:root {
    --bg: #020617;
    --bg-soft: #0f172a;
    --panel: rgba(15, 23, 42, 0.82);
    --panel-strong: rgba(15, 23, 42, 0.96);
    --panel-light: rgba(30, 41, 59, 0.72);
    --line: rgba(148, 163, 184, 0.18);
    --line-strong: rgba(245, 158, 11, 0.24);
    --text: #f8fafc;
    --muted: #cbd5e1;
    --weak: #94a3b8;
    --accent: #f59e0b;
    --accent-dark: #d97706;
    --accent-soft: rgba(245, 158, 11, 0.16);
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at 15% 0%, rgba(245, 158, 11, 0.12), transparent 30rem),
        radial-gradient(circle at 90% 10%, rgba(59, 130, 246, 0.14), transparent 34rem),
        linear-gradient(180deg, #020617 0%, #0f172a 42%, #020617 100%);
    color: var(--text);
}

body.menu-open {
    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;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.96), rgba(15, 23, 42, 0.96));
    border-bottom: 1px solid rgba(51, 65, 85, 0.9);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(18px);
}

.nav-wrap {
    width: min(1200px, calc(100% - 32px));
    height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 24px;
}

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

.brand {
    font-size: 21px;
    min-width: max-content;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: linear-gradient(135deg, var(--accent), #facc15);
    color: #111827;
    box-shadow: 0 10px 28px rgba(245, 158, 11, 0.35);
}

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

.nav-link {
    color: #cbd5e1;
    font-weight: 650;
    transition: color 0.2s ease;
}

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

.header-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(51, 65, 85, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.16);
}

.header-search input,
.mobile-search input,
.filter-bar input,
.filter-bar select {
    border: 0;
    color: var(--text);
    background: rgba(15, 23, 42, 0.76);
    outline: none;
}

.header-search input {
    width: 240px;
    padding: 11px 14px;
}

.header-search button,
.mobile-search button,
.filter-bar button {
    border: 0;
    cursor: pointer;
    color: #111827;
    background: var(--accent);
    font-weight: 800;
    padding: 11px 16px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.filter-bar button:hover,
.primary-btn:hover {
    background: #fbbf24;
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: rgba(51, 65, 85, 0.86);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--text);
    border-radius: 999px;
}

.mobile-panel {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
}

.mobile-nav,
.mobile-search {
    display: grid;
    gap: 10px;
}

.mobile-nav a {
    color: var(--muted);
    padding: 10px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.12);
}

.mobile-search {
    grid-template-columns: 1fr auto;
    margin-top: 12px;
}

.mobile-search input {
    padding: 12px 14px;
    border-radius: 12px 0 0 12px;
}

.mobile-search button {
    border-radius: 0 12px 12px 0;
}

main {
    overflow: hidden;
}

.hero {
    position: relative;
    min-height: 650px;
    background: #020617;
}

.hero-viewport {
    position: relative;
    min-height: 650px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 48px;
    align-items: center;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    opacity: 0;
    transform: translateY(16px);
    pointer-events: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

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

.hero-bg {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    z-index: 0;
    width: 100vw;
    overflow: hidden;
    opacity: 0.28;
    filter: blur(6px) saturate(1.1);
    transform: translateX(-50%);
}

.hero-content,
.hero-poster {
    position: relative;
    z-index: 2;
}

.hero-bg::after,
.detail-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.96)),
        linear-gradient(180deg, rgba(2, 6, 23, 0.3), #020617);
}

.hero-bg img,
.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-content {
    max-width: 720px;
    padding: 96px 0 72px;
}

.eyebrow,
.section-title p,
.page-hero p,
.detail-copy .breadcrumb,
.category-tile strong {
    color: var(--accent);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
    margin: 14px 0;
    line-height: 1.04;
    font-size: clamp(40px, 6vw, 76px);
    letter-spacing: -0.05em;
}

.hero h2 {
    margin: 0 0 16px;
    color: #fde68a;
    font-size: clamp(24px, 3vw, 40px);
}

.hero p,
.lead-text,
.page-hero span,
.detail-one-line {
    max-width: 760px;
    color: var(--muted);
    font-size: 18px;
    line-height: 1.85;
}

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

.hero-tags {
    margin: 26px 0;
}

.hero-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--accent-soft);
    color: #fcd34d;
    font-size: 13px;
    font-weight: 700;
}

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

.primary-btn,
.ghost-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 13px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.primary-btn {
    color: #111827;
    background: var(--accent);
    box-shadow: 0 18px 44px rgba(245, 158, 11, 0.24);
}

.ghost-btn {
    color: var(--text);
    border: 1px solid rgba(245, 158, 11, 0.38);
    background: rgba(15, 23, 42, 0.64);
}

.ghost-btn:hover {
    transform: translateY(-1px);
    border-color: rgba(245, 158, 11, 0.72);
    background: rgba(245, 158, 11, 0.12);
}

.hero-poster {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    border: 1px solid rgba(245, 158, 11, 0.28);
    box-shadow: var(--shadow);
    transform: rotate(2deg);
}

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 52%, rgba(0, 0, 0, 0.62));
}

.hero-poster img {
    width: 100%;
    height: 520px;
    object-fit: cover;
}

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

.hero-dot {
    width: 36px;
    height: 6px;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    background: rgba(148, 163, 184, 0.45);
}

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

.section-block,
.category-sections {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0;
}

.intro-block {
    padding-top: 60px;
}

.section-title {
    margin-bottom: 24px;
}

.section-title p {
    margin: 0 0 8px;
    font-size: 13px;
}

.section-title h2,
.footer-grid h2 {
    margin: 0;
    color: var(--text);
    font-size: clamp(24px, 3vw, 34px);
    letter-spacing: -0.02em;
}

.section-title.with-link {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
}

.section-title.with-link a {
    color: #fcd34d;
    font-weight: 750;
}

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

.category-tile,
.category-section-card,
.side-panel,
.movie-card,
.page-hero,
.detail-section {
    background: var(--panel);
    border: 1px solid var(--line);
    box-shadow: 0 16px 50px rgba(0, 0, 0, 0.22);
    backdrop-filter: blur(16px);
}

.category-tile {
    min-height: 190px;
    padding: 20px;
    border-radius: 22px;
    transition: transform 0.24s ease, border-color 0.24s ease, background 0.24s ease;
}

.category-tile:hover,
.movie-card:hover,
.compact-card:hover,
.rank-item:hover {
    transform: translateY(-4px);
    border-color: var(--line-strong);
}

.category-tile p {
    color: var(--muted);
    line-height: 1.7;
}

.category-tile div {
    display: grid;
    gap: 6px;
    color: var(--weak);
    font-size: 13px;
}

.two-column {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 44px 60px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    min-height: 86px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.76);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.rank-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #111827;
    background: linear-gradient(135deg, var(--accent), #facc15);
    width: 36px;
    height: 36px;
    border-radius: 12px;
    font-weight: 900;
}

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

.rank-copy {
    min-width: 0;
}

.rank-copy strong,
.compact-card strong {
    display: block;
    color: var(--text);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-copy em,
.compact-card em,
.card-meta {
    display: block;
    margin-top: 6px;
    color: var(--weak);
    font-size: 13px;
    font-style: normal;
}

.rank-score {
    color: #fcd34d;
    font-weight: 900;
}

.side-panel {
    padding: 22px;
    border-radius: 24px;
    align-self: start;
}

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

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

.compact-card {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.58);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.compact-card img {
    width: 64px;
    height: 86px;
    object-fit: cover;
    border-radius: 12px;
}

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

.movie-card {
    overflow: hidden;
    border-radius: 22px;
    transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

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

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

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.76));
}

.play-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    color: white;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.84);
    transform: translate(-50%, -50%) scale(0.88);
    opacity: 0;
    transition: opacity 0.24s ease, transform 0.24s ease;
}

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

.poster-badge {
    position: absolute;
    right: 12px;
    top: 12px;
    padding: 5px 9px;
    border-radius: 999px;
    color: white;
    background: rgba(0, 0, 0, 0.62);
    font-size: 12px;
    font-weight: 800;
}

.card-body {
    padding: 16px;
}

.card-body h2 {
    margin: 10px 0 8px;
    font-size: 18px;
    line-height: 1.3;
}

.card-body h2 a:hover {
    color: var(--accent);
}

.card-body p {
    min-height: 48px;
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.page-hero {
    width: min(1200px, calc(100% - 32px));
    min-height: 300px;
    margin: 36px auto 0;
    padding: 54px;
    border-radius: 30px;
    background:
        radial-gradient(circle at 88% 10%, rgba(245, 158, 11, 0.18), transparent 24rem),
        linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.72));
}

.page-hero.slim {
    min-height: 250px;
}

.page-hero h1 {
    font-size: clamp(34px, 5vw, 58px);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    color: var(--weak);
    margin-bottom: 20px;
}

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

.filter-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 180px auto;
    gap: 12px;
    margin-bottom: 24px;
}

.filter-bar input,
.filter-bar select {
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
}

.filter-bar button {
    border-radius: 14px;
}

.filter-state {
    color: var(--weak);
    margin: -8px 0 18px;
}

.category-sections {
    display: grid;
    gap: 24px;
}

.category-section-card {
    padding: 28px;
    border-radius: 26px;
}

.category-section-card > p {
    color: var(--muted);
    line-height: 1.8;
}

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

.detail-hero {
    position: relative;
    min-height: 620px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    opacity: 0.36;
    filter: blur(4px) saturate(1.2);
}

.detail-layout {
    position: relative;
    z-index: 2;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 330px minmax(0, 1fr);
    gap: 44px;
    align-items: center;
    padding: 72px 0;
}

.detail-cover {
    overflow: hidden;
    border-radius: 28px;
    border: 1px solid rgba(245, 158, 11, 0.28);
    box-shadow: var(--shadow);
}

.detail-cover img {
    width: 100%;
    height: 470px;
    object-fit: cover;
}

.detail-copy h1 {
    max-width: 780px;
    font-size: clamp(38px, 5vw, 68px);
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 22px;
}

.detail-meta span {
    padding: 8px 12px;
    border: 1px solid rgba(245, 158, 11, 0.18);
    border-radius: 999px;
    color: #fde68a;
    background: rgba(15, 23, 42, 0.62);
    font-weight: 700;
}

.detail-tags {
    margin: 0 0 28px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    background: black;
    border: 1px solid rgba(245, 158, 11, 0.22);
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.movie-video {
    display: block;
    width: 100%;
    height: 100%;
    background: #000;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    border: 0;
    color: white;
    cursor: pointer;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.76));
}

.player-cover[hidden] {
    display: none;
}

.big-play {
    display: inline-flex;
    width: 88px;
    height: 88px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--accent);
    color: #111827;
    font-size: 32px;
    box-shadow: 0 20px 52px rgba(245, 158, 11, 0.28);
}

.player-cover strong {
    font-size: clamp(22px, 4vw, 34px);
}

.article-section {
    padding: 34px;
    border-radius: 26px;
}

.article-copy {
    color: var(--muted);
    font-size: 17px;
    line-height: 2;
}

.article-copy p {
    margin: 0 0 16px;
}

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

.site-footer {
    margin-top: 56px;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.92), #020617);
    border-top: 1px solid rgba(51, 65, 85, 0.8);
}

.footer-grid {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 32px;
}

.footer-grid p,
.footer-grid a {
    color: var(--weak);
    line-height: 1.8;
}

.footer-grid a {
    display: block;
    margin: 7px 0;
}

.footer-grid a:hover {
    color: var(--accent);
}

.footer-brand {
    margin-bottom: 14px;
    font-size: 20px;
}

.copyright {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 24px 0 36px;
    color: var(--weak);
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    text-align: center;
}

[hidden] {
    display: none !important;
}

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

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

    .hero-slide,
    .detail-layout,
    .two-column {
        grid-template-columns: 1fr;
    }

    .hero-poster {
        display: none;
    }

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

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

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

    .brand {
        font-size: 18px;
    }

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

    .hero-content {
        padding: 72px 0 90px;
    }

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

    .hero p,
    .lead-text,
    .page-hero span,
    .detail-one-line {
        font-size: 16px;
    }

    .section-title.with-link {
        align-items: start;
        flex-direction: column;
    }

    .category-grid,
    .movie-grid,
    .related-grid,
    .full-rank,
    .compact-list.four {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .page-hero {
        padding: 34px 24px;
        border-radius: 24px;
    }

    .detail-layout {
        gap: 26px;
    }

    .detail-cover img {
        height: auto;
        max-height: 520px;
    }

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

    .rank-item {
        grid-template-columns: 38px 54px minmax(0, 1fr);
    }

    .rank-score {
        grid-column: 3;
    }
}

@media (max-width: 520px) {
    .category-grid,
    .movie-grid,
    .related-grid,
    .full-rank,
    .compact-list.four {
        grid-template-columns: 1fr;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .primary-btn,
    .ghost-btn {
        width: 100%;
    }
}
