:root {
    --bg: #0f172a;
    --bg-soft: #111827;
    --panel: #ffffff;
    --panel-dark: rgba(15, 23, 42, 0.88);
    --text: #0f172a;
    --muted: #64748b;
    --line: rgba(148, 163, 184, 0.24);
    --orange: #f97316;
    --orange-dark: #ea580c;
    --orange-soft: #ffedd5;
    --slate: #1e293b;
    --shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background: #f8fafc;
}

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

img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, #1e293b, #0f172a 48%, #7c2d12);
}

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, #0f172a, #1e293b 52%, #0f172a);
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.24);
}

.nav-wrap {
    max-width: 1280px;
    height: 72px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, #fb923c, #ea580c);
    box-shadow: 0 12px 28px rgba(249, 115, 22, 0.32);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 22px;
    letter-spacing: 0.04em;
}

.brand-text em {
    margin-top: 2px;
    font-size: 12px;
    color: #94a3b8;
    font-style: normal;
}

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

.nav-link,
.mobile-link {
    color: #cbd5e1;
    border-radius: 12px;
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.nav-link {
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 700;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover,
.mobile-link.active {
    color: #fff;
    background: #f97316;
}

.menu-button {
    display: none;
    width: 44px;
    height: 44px;
    padding: 10px;
    border: 0;
    border-radius: 12px;
    background: rgba(148, 163, 184, 0.14);
}

.menu-button span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: #fff;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    padding: 0 24px 18px;
    background: #0f172a;
}

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

.mobile-link {
    padding: 12px 16px;
    font-weight: 700;
}

.hero {
    position: relative;
    min-height: 640px;
    overflow: hidden;
    color: #fff;
    background: #0f172a;
}

.hero-rail,
.hero-slide,
.hero-backdrop {
    position: absolute;
    inset: 0;
}

.hero-slide {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease;
}

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

.hero-backdrop {
    background-image:
        linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(15, 23, 42, 0.82) 46%, rgba(15, 23, 42, 0.35) 100%),
        radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.32), transparent 32%),
        var(--hero-image);
    background-size: cover;
    background-position: center;
    transform: scale(1.05);
    filter: saturate(1.1);
}

.hero-content {
    position: relative;
    max-width: 1280px;
    min-height: 640px;
    margin: 0 auto;
    padding: 96px 24px 160px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: center;
    gap: 48px;
}

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

.hero-kicker,
.section-kicker,
.tile-kicker {
    display: inline-flex;
    align-items: center;
    width: max-content;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.13);
    color: #fed7aa;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.hero h1 {
    margin: 20px 0 18px;
    font-size: clamp(40px, 7vw, 78px);
    line-height: 0.96;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 680px;
    margin: 0 0 28px;
    color: #dbeafe;
    font-size: 19px;
    line-height: 1.8;
}

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

.hero-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.hero-tags span {
    color: #fff7ed;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-actions,
.center-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 32px;
}

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

.primary-button {
    color: #fff;
    background: linear-gradient(135deg, #fb923c, #ea580c);
    box-shadow: 0 18px 36px rgba(249, 115, 22, 0.34);
}

.ghost-button {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.ghost-button.light {
    color: #0f172a;
    background: #fff;
    border-color: #e2e8f0;
}

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

.hero-poster {
    position: relative;
    height: 500px;
    border-radius: 34px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.28), transparent 42%);
}

.hero-search-card {
    position: absolute;
    left: 50%;
    bottom: 82px;
    transform: translateX(-50%);
    width: min(760px, calc(100% - 48px));
    padding: 18px;
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(18px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.26);
}

.hero-search-card strong {
    display: block;
    margin-bottom: 10px;
    color: #fff;
}

.hero-search {
    display: flex;
    gap: 10px;
}

.hero-search input,
.search-box input,
.filter-panel select {
    min-height: 48px;
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 0 16px;
    outline: none;
    color: #0f172a;
    background: #fff;
}

.hero-search button {
    min-width: 100px;
    border: 0;
    border-radius: 14px;
    color: #fff;
    font-weight: 900;
    background: #f97316;
}

.hero-mini-links {
    display: flex;
    gap: 14px;
    margin-top: 12px;
    color: #cbd5e1;
    font-size: 13px;
}

.hero-thumbs {
    position: absolute;
    right: 32px;
    bottom: 28px;
    display: flex;
    gap: 12px;
}

.hero-thumb {
    width: 150px;
    height: 70px;
    padding: 0;
    display: grid;
    grid-template-columns: 48px 1fr;
    align-items: center;
    gap: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    color: #fff;
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(12px);
}

.hero-thumb.active {
    border-color: #f97316;
    box-shadow: 0 0 0 2px rgba(249, 115, 22, 0.22);
}

.hero-thumb img {
    height: 70px;
}

.hero-thumb span {
    padding-right: 8px;
    font-size: 12px;
    font-weight: 800;
    text-align: left;
}

.page-section {
    max-width: 1280px;
    margin: 0 auto;
    padding: 64px 24px;
}

.sub-hero {
    min-height: 330px;
    padding: 92px 24px 64px;
    display: grid;
    place-items: center;
    color: #fff;
    text-align: center;
    background:
        radial-gradient(circle at 30% 20%, rgba(249, 115, 22, 0.36), transparent 30%),
        linear-gradient(135deg, #0f172a, #1e293b 52%, #111827);
}

.sub-hero div {
    max-width: 860px;
}

.sub-hero span {
    color: #fdba74;
    font-weight: 900;
}

.sub-hero h1 {
    margin: 14px 0 16px;
    font-size: clamp(34px, 6vw, 62px);
    line-height: 1.05;
    font-weight: 900;
}

.sub-hero p {
    margin: 0;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.8;
}

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

.section-head .section-kicker {
    color: #ea580c;
    background: #ffedd5;
}

.section-head h2 {
    margin: 12px 0 0;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.section-head p {
    margin: 10px 0 0;
    color: var(--muted);
}

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

.category-tile {
    min-height: 168px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: 24px;
    color: #fff;
    background:
        linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.9)),
        radial-gradient(circle at top right, rgba(249, 115, 22, 0.34), transparent 32%);
    box-shadow: var(--shadow);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
    transform: translateY(-4px);
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.25);
}

.category-tile .tile-kicker {
    color: #ffedd5;
    background: rgba(249, 115, 22, 0.18);
}

.category-tile strong {
    margin-top: 18px;
    display: block;
    font-size: 22px;
    font-weight: 900;
}

.category-tile em {
    margin-top: 8px;
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.55;
    font-style: normal;
}

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

.movie-card {
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 56px rgba(15, 23, 42, 0.14);
}

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

.poster-link img {
    transition: transform 0.35s ease;
}

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

.year-badge,
.play-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    color: #fff;
    font-size: 12px;
    font-weight: 900;
}

.year-badge {
    top: 10px;
    left: 10px;
    padding: 5px 9px;
    background: rgba(15, 23, 42, 0.78);
}

.play-badge {
    right: 10px;
    bottom: 10px;
    padding: 6px 10px;
    background: #f97316;
}

.card-body {
    padding: 15px;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #f97316;
    font-size: 12px;
    font-weight: 900;
}

.card-body h3,
.rank-body h3 {
    margin: 10px 0 8px;
    color: #0f172a;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 900;
}

.card-body p,
.rank-body p,
.content-card p {
    margin: 0;
    color: #64748b;
    line-height: 1.65;
}

.card-body p {
    min-height: 52px;
    font-size: 13px;
}

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

.tag-row span {
    color: #9a3412;
    background: #ffedd5;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 18px;
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px 180px;
    gap: 12px;
    border-radius: 24px;
    background: #fff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

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

.rank-item {
    padding: 16px;
    display: grid;
    grid-template-columns: 62px 88px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
}

.rank-list.compact-list .rank-item:nth-child(n + 7) {
    display: none;
}

.rank-number {
    width: 52px;
    height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    color: #fff;
    font-weight: 900;
    background: linear-gradient(135deg, #fb923c, #ea580c);
}

.rank-poster {
    height: 118px;
    overflow: hidden;
    border-radius: 16px;
    background: #111827;
}

.rank-action {
    min-width: 78px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    font-weight: 900;
    background: #0f172a;
}

.empty-state {
    display: none;
    padding: 34px;
    border-radius: 22px;
    color: #64748b;
    text-align: center;
    background: #fff;
    border: 1px dashed #cbd5e1;
}

.empty-state.show {
    display: block;
}

.detail-hero {
    position: relative;
    min-height: 640px;
    overflow: hidden;
    color: #fff;
    background: #0f172a;
}

.detail-bg {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.76), rgba(15, 23, 42, 0.5)),
        var(--detail-image);
    background-size: cover;
    background-position: center;
    filter: blur(8px) saturate(1.05);
    transform: scale(1.08);
}

.detail-inner {
    position: relative;
    max-width: 1280px;
    margin: 0 auto;
    padding: 48px 24px 72px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #cbd5e1;
    font-size: 14px;
}

.breadcrumb a {
    color: #fdba74;
    font-weight: 800;
}

.breadcrumb em {
    font-style: normal;
}

.detail-layout {
    margin-top: 48px;
    display: grid;
    grid-template-columns: 330px minmax(0, 1fr);
    align-items: center;
    gap: 46px;
}

.detail-poster {
    height: 480px;
    overflow: hidden;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
}

.detail-copy h1 {
    margin: 18px 0;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.detail-copy p {
    max-width: 820px;
    margin: 0 0 26px;
    color: #dbeafe;
    font-size: 19px;
    line-height: 1.8;
}

.detail-section {
    padding-top: 48px;
    padding-bottom: 48px;
}

.player-card,
.content-card {
    border-radius: 28px;
    background: #fff;
    border: 1px solid #e2e8f0;
    box-shadow: var(--shadow);
}

.player-card {
    padding: 16px;
}

.video-frame {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: #020617;
    aspect-ratio: 16 / 9;
}

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

.video-play-button {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 188px;
    height: 72px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, #fb923c, #ea580c);
    box-shadow: 0 18px 42px rgba(249, 115, 22, 0.36);
    font-weight: 900;
}

.video-play-button span {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
}

.video-play-button.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.video-message {
    position: absolute;
    left: 18px;
    bottom: 18px;
    max-width: calc(100% - 36px);
    padding: 10px 12px;
    display: none;
    border-radius: 12px;
    color: #fff;
    background: rgba(15, 23, 42, 0.76);
    font-size: 13px;
}

.video-message.show {
    display: block;
}

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

.content-card {
    padding: 28px;
}

.content-card .section-kicker {
    color: #ea580c;
    background: #ffedd5;
}

.content-card h2 {
    margin: 16px 0 12px;
    font-size: 28px;
    font-weight: 900;
}

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

.site-footer {
    color: #cbd5e1;
    background: #0f172a;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 36px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-brand {
    color: #fff;
    font-size: 20px;
    font-weight: 900;
}

.footer-links {
    display: flex;
    gap: 16px;
}

.footer-links a {
    color: #fdba74;
    font-weight: 800;
}

.footer-inner p {
    margin: 0;
}

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

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

    .hero-content {
        grid-template-columns: minmax(0, 1fr) 280px;
    }
}

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

    .menu-button {
        display: block;
    }

    .hero {
        min-height: 780px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        padding-top: 76px;
        padding-bottom: 260px;
    }

    .hero-poster {
        display: none;
    }

    .hero-thumbs {
        left: 24px;
        right: 24px;
        overflow-x: auto;
        padding-bottom: 4px;
    }

    .hero-thumb {
        flex: 0 0 150px;
    }

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

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

    .detail-poster {
        width: min(320px, 100%);
        height: 440px;
    }

    .two-column {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 640px) {
    .nav-wrap {
        height: 64px;
        padding: 0 16px;
    }

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

    .hero {
        min-height: 720px;
    }

    .hero-content {
        min-height: 720px;
        padding: 54px 18px 260px;
    }

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

    .hero-search-card {
        bottom: 112px;
        width: calc(100% - 28px);
    }

    .hero-search {
        flex-direction: column;
    }

    .hero-search button {
        min-height: 46px;
    }

    .page-section {
        padding: 42px 16px;
    }

    .sub-hero {
        min-height: 280px;
        padding: 74px 16px 48px;
    }

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

    .card-body {
        padding: 12px;
    }

    .card-body p {
        display: none;
    }

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

    .rank-item {
        grid-template-columns: 42px 76px minmax(0, 1fr);
        align-items: start;
        gap: 12px;
    }

    .rank-number {
        width: 38px;
        height: 38px;
        border-radius: 12px;
        font-size: 13px;
    }

    .rank-poster {
        height: 104px;
    }

    .rank-action {
        grid-column: 3;
        justify-self: start;
        margin-top: 4px;
    }

    .detail-inner {
        padding: 36px 16px 52px;
    }

    .detail-poster {
        height: 420px;
    }

    .player-card {
        padding: 8px;
        border-radius: 20px;
    }

    .video-frame {
        border-radius: 16px;
    }

    .video-play-button {
        width: 156px;
        height: 62px;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}
