:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-soft: #eff6ff;
    --secondary: #ea580c;
    --secondary-soft: #fff7ed;
    --accent: #ca8a04;
    --success: #16a34a;
    --dark: #0f172a;
    --dark-2: #1e293b;
    --dark-3: #334155;
    --muted: #64748b;
    --line: #e5e7eb;
    --surface: #ffffff;
    --bg: #f8fafc;
    --shadow-soft: 0 2px 15px 0 rgba(0, 0, 0, 0.05);
    --shadow-medium: 0 4px 20px 0 rgba(0, 0, 0, 0.10);
    --shadow-hard: 0 10px 40px 0 rgba(0, 0, 0, 0.15);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--dark);
    background: var(--bg);
    line-height: 1.6;
}

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(14px);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    white-space: nowrap;
}

.brand-icon {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    box-shadow: var(--shadow-soft);
}

.brand-text {
    font-size: 24px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

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

.nav-link {
    color: var(--dark-3);
    font-weight: 600;
    transition: color 0.2s ease;
}

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

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: #f1f5f9;
    cursor: pointer;
}

.menu-button span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--dark-3);
}

.mobile-nav {
    display: none;
    padding: 8px 16px 18px;
    border-top: 1px solid var(--line);
    background: #fff;
}

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

.mobile-nav a {
    padding: 10px 12px;
    border-radius: 10px;
}

.mobile-nav a:hover {
    background: #f8fafc;
}

.hero {
    position: relative;
    height: 560px;
    min-height: 560px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(180deg, var(--dark), var(--dark-2));
}

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

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

.hero-bg,
.detail-backdrop {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    transform: scale(1.03);
}

.hero-bg::after,
.detail-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 30%, rgba(37, 99, 235, 0.32), transparent 34%),
        linear-gradient(90deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.60), rgba(15, 23, 42, 0.20)),
        linear-gradient(0deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.20));
}

.hero-content {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.hero-copy {
    width: min(720px, 100%);
    padding-top: 24px;
}

.hero-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    border-radius: 999px;
    color: #fff;
    background: var(--secondary);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.hero h1,
.hero h2 {
    margin: 20px 0 16px;
    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero p {
    max-width: 680px;
    margin: 0;
    color: #e5e7eb;
    font-size: clamp(18px, 2vw, 22px);
}

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

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

.hero-tags span,
.tag-row span,
.detail-meta span {
    padding: 6px 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 24px;
    border-radius: 12px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    color: #fff;
    background: var(--primary);
    box-shadow: var(--shadow-medium);
}

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

.btn-ghost {
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: rgba(0, 0, 0, 0.48);
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.70);
}

.hero-prev {
    left: 18px;
}

.hero-next {
    right: 18px;
}

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

.hero-dot {
    width: 18px;
    height: 5px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    cursor: pointer;
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
    width: 34px;
    background: #fff;
}

.content-section {
    padding-top: 64px;
    padding-bottom: 64px;
}

.section-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 28px;
}

.section-heading h2 {
    margin: 0;
    color: var(--dark);
    font-size: 32px;
    line-height: 1.2;
}

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

.section-icon {
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--primary);
    background: var(--primary-soft);
    font-weight: 900;
}

.movie-grid {
    display: grid;
    gap: 24px;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-medium);
}

.movie-card-link {
    display: block;
    height: 100%;
}

.poster-wrap {
    position: relative;
    height: 220px;
    overflow: hidden;
    background-position: center;
    background-size: cover;
    background-color: var(--dark-2);
}

.card-small .poster-wrap {
    height: 170px;
}

.card-large .poster-wrap {
    height: 270px;
}

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

.badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    top: 12px;
    padding: 5px 9px;
    border-radius: 7px;
    color: #fff;
    font-size: 12px;
    font-weight: 800;
}

.badge-left {
    left: 12px;
    background: var(--primary);
}

.badge-right {
    right: 12px;
    background: var(--secondary);
}

.rank-badge {
    left: 12px;
    bottom: 12px;
    top: auto;
    background: rgba(0, 0, 0, 0.66);
}

.hover-play {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 34px;
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.movie-card-body {
    padding: 18px;
}

.movie-card h3 {
    display: -webkit-box;
    min-height: 52px;
    margin: 0 0 10px;
    overflow: hidden;
    color: var(--dark-2);
    font-size: 18px;
    line-height: 1.45;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    transition: color 0.2s ease;
}

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

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

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

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

.tag-row span {
    background: var(--primary-soft);
    color: var(--primary-dark);
}

.gradient-band {
    background: linear-gradient(180deg, var(--secondary-soft), #fff);
}

.section-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.scroll-buttons {
    display: flex;
    gap: 10px;
}

.scroll-buttons button {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 999px;
    color: var(--dark-3);
    background: #fff;
    box-shadow: var(--shadow-soft);
    cursor: pointer;
}

.card-scroller {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    padding: 4px 0 18px;
    scroll-behavior: smooth;
    scrollbar-width: none;
}

.card-scroller::-webkit-scrollbar {
    display: none;
}

.scroller-item {
    width: 320px;
    flex: 0 0 320px;
}

.tab-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
}

.tab-button {
    border: 0;
    border-radius: 12px;
    padding: 12px 22px;
    color: var(--dark-3);
    background: #fff;
    box-shadow: var(--shadow-soft);
    font-weight: 800;
    cursor: pointer;
}

.tab-button.active {
    color: #fff;
    background: var(--primary);
}

.category-panel {
    display: none;
}

.category-panel.active {
    display: block;
}

.section-more {
    margin-top: 28px;
    text-align: center;
}

.ranking-split {
    background: linear-gradient(180deg, var(--primary-soft), #fff);
}

.split-grid {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 32px;
    align-items: start;
}

.ranking-card,
.side-card,
.story-card,
.player-card {
    border-radius: 20px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.ranking-card {
    position: sticky;
    top: 88px;
    padding: 22px;
}

.ranking-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.ranking-head h2 {
    margin: 0;
    font-size: 24px;
}

.ranking-head a {
    color: var(--primary);
    font-weight: 800;
}

.rank-row {
    display: grid;
    grid-template-columns: 38px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
}

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

.rank-num {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    color: #fff;
    background: var(--secondary);
    font-weight: 900;
}

.rank-title {
    overflow: hidden;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-year {
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.page-hero {
    position: relative;
    color: #fff;
    background:
        radial-gradient(circle at 20% 30%, rgba(37, 99, 235, 0.40), transparent 28%),
        linear-gradient(135deg, var(--dark), var(--dark-2));
}

.compact-hero {
    padding: 74px 0;
}

.page-hero h1 {
    margin: 14px 0 12px;
    font-size: clamp(38px, 6vw, 58px);
    line-height: 1.1;
}

.page-hero p {
    max-width: 760px;
    margin: 0;
    color: #e5e7eb;
    font-size: 18px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
    font-weight: 700;
}

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

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

.category-card {
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
}

.category-cover {
    height: 190px;
    background-color: var(--dark-2);
    background-position: center;
    background-size: cover;
}

.category-card-body {
    padding: 22px;
}

.category-card-body h2 {
    margin: 0 0 10px;
    font-size: 24px;
}

.category-card-body p {
    min-height: 78px;
    margin: 0 0 16px;
    color: var(--muted);
}

.category-card-body span {
    color: var(--primary);
    font-weight: 900;
}

.filter-bar {
    display: grid;
    grid-template-columns: 1fr 170px 170px;
    gap: 14px;
    margin-bottom: 28px;
    padding: 18px;
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.expanded-filter {
    grid-template-columns: 1fr 190px 170px 170px;
}

.filter-bar input,
.filter-bar select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 0 14px;
    color: var(--dark-3);
    background: #fff;
    outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.ranking-list-page {
    display: grid;
    gap: 16px;
}

.ranking-item {
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ranking-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-medium);
}

.ranking-item a {
    display: grid;
    grid-template-columns: 64px 120px 1fr auto;
    gap: 18px;
    align-items: center;
    padding: 16px;
}

.ranking-number {
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    font-size: 18px;
    font-weight: 900;
}

.ranking-poster {
    height: 76px;
    border-radius: 12px;
    background-color: var(--dark-2);
    background-position: center;
    background-size: cover;
}

.ranking-info h2 {
    margin: 0 0 8px;
    font-size: 20px;
}

.ranking-info p {
    display: -webkit-box;
    margin: 0 0 8px;
    overflow: hidden;
    color: var(--muted);
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
}

.ranking-play {
    color: var(--primary);
    font-weight: 900;
}

.detail-hero {
    position: relative;
    min-height: 520px;
    overflow: hidden;
    color: #fff;
    background: var(--dark);
}

.detail-hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 36px;
    align-items: center;
    min-height: 520px;
    padding-top: 46px;
    padding-bottom: 46px;
}

.detail-cover {
    height: 420px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 24px;
    background-color: var(--dark-2);
    background-position: center;
    background-size: cover;
    box-shadow: var(--shadow-hard);
}

.detail-copy h1 {
    margin: 16px 0 14px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.08;
}

.detail-copy p {
    max-width: 820px;
    margin: 0 0 18px;
    color: #e5e7eb;
    font-size: 19px;
}

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

.detail-tags span {
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
}

.detail-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 28px;
    align-items: start;
}

.detail-main {
    display: grid;
    gap: 24px;
}

.player-card {
    padding: 14px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: #000;
    box-shadow: var(--shadow-hard);
}

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

.player-trigger {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    color: #fff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.10));
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-trigger span {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--primary);
    box-shadow: var(--shadow-hard);
    font-size: 34px;
    transform: translateX(3px);
}

.player-trigger.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.story-card {
    padding: 28px;
}

.story-card h2,
.side-card h2 {
    margin: 0 0 14px;
    font-size: 24px;
}

.story-card p {
    margin: 0;
    color: var(--dark-3);
    font-size: 17px;
}

.detail-side {
    position: sticky;
    top: 88px;
    display: grid;
    gap: 18px;
}

.side-card {
    padding: 22px;
}

.side-card dl {
    display: grid;
    grid-template-columns: 70px 1fr;
    gap: 10px 12px;
    margin: 0;
}

.side-card dt {
    color: var(--muted);
    font-weight: 800;
}

.side-card dd {
    margin: 0;
    color: var(--dark-2);
    font-weight: 700;
}

.side-link {
    display: block;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    color: var(--primary);
    font-weight: 800;
}

.side-link:last-child {
    border-bottom: 0;
}

.site-footer {
    color: #cbd5e1;
    background: var(--dark);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.6fr;
    gap: 32px;
    padding: 48px 0;
}

.footer-logo .brand-text {
    color: #fff;
    background: none;
    -webkit-text-fill-color: #fff;
}

.footer-brand p {
    max-width: 440px;
    margin: 16px 0 0;
    color: #94a3b8;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: #fff;
    font-size: 18px;
}

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

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

.footer-links a:hover {
    color: #fff;
}

.footer-bottom {
    padding: 18px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.10);
    text-align: center;
    color: #94a3b8;
}

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

@media (max-width: 1100px) {
    .desktop-nav {
        gap: 16px;
    }

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

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

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

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

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

    .menu-button {
        display: block;
    }

    .brand-text {
        font-size: 20px;
    }

    .hero {
        height: 620px;
    }

    .hero-copy {
        padding-right: 28px;
    }

    .hero-arrow {
        display: none;
    }

    .hero h1,
    .hero h2 {
        font-size: 42px;
    }

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

    .detail-hero-grid {
        grid-template-columns: 1fr;
        gap: 24px;
        padding-top: 34px;
    }

    .detail-cover {
        width: min(300px, 100%);
        height: 410px;
    }

    .ranking-item a {
        grid-template-columns: 48px 88px 1fr;
    }

    .ranking-play {
        display: none;
    }

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

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

    .hero {
        min-height: 600px;
    }

    .hero-copy {
        padding-right: 0;
    }

    .hero h1,
    .hero h2,
    .page-hero h1,
    .detail-copy h1 {
        font-size: 34px;
    }

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

    .content-section {
        padding-top: 42px;
        padding-bottom: 42px;
    }

    .three-col,
    .four-col,
    .category-grid {
        grid-template-columns: 1fr;
    }

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

    .scroller-item {
        width: 280px;
        flex-basis: 280px;
    }

    .poster-wrap,
    .card-small .poster-wrap,
    .card-large .poster-wrap {
        height: 230px;
    }

    .ranking-item a {
        grid-template-columns: 42px 1fr;
    }

    .ranking-poster {
        display: none;
    }

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