:root {
    color-scheme: light;
    --amber: #d97706;
    --amber-dark: #b45309;
    --amber-soft: #fff7ed;
    --orange: #ea580c;
    --slate: #0f172a;
    --slate-soft: #1e293b;
    --text: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --card: #ffffff;
    --bg: #f8fafc;
    --radius: 22px;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.header-hero {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.64), rgba(15, 23, 42, 0));
}

.header-solid,
.site-header.is-scrolled {
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(18px);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.1);
}

.nav-wrap {
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 22px;
    min-height: 74px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.brand-mark,
.footer-brand span {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-grid;
    place-items: center;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    color: #ffffff;
    box-shadow: 0 10px 24px rgba(217, 119, 6, 0.34);
}

.brand-text {
    font-size: 1.36rem;
    color: #ffffff;
    transition: color 0.25s ease;
}

.header-solid .brand-text,
.site-header.is-scrolled .brand-text {
    color: var(--text);
}

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

.main-nav a {
    padding: 10px 14px;
    border-radius: 13px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 700;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.header-solid .main-nav a,
.site-header.is-scrolled .main-nav a {
    color: #374151;
}

.main-nav a:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    transform: translateY(-1px);
}

.header-solid .main-nav a:hover,
.site-header.is-scrolled .main-nav a:hover {
    color: var(--amber-dark);
    background: var(--amber-soft);
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.16);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: #ffffff;
}

.header-solid .nav-toggle,
.site-header.is-scrolled .nav-toggle {
    background: var(--amber-soft);
}

.header-solid .nav-toggle span,
.site-header.is-scrolled .nav-toggle span {
    background: var(--text);
}

.section-wrap {
    max-width: 1180px;
    margin: 0 auto;
    padding-left: 22px;
    padding-right: 22px;
}

.hero-carousel {
    position: relative;
    min-height: 760px;
    overflow: hidden;
    background: var(--slate);
}

.hero-slides {
    min-height: 760px;
}

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

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

.hero-bg {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.24)), var(--cover-image);
    background-size: cover;
    background-position: center;
    transform: scale(1.04);
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: auto 0 0 0;
    height: 180px;
    background: linear-gradient(0deg, var(--bg), rgba(248, 250, 252, 0));
}

.hero-content {
    position: relative;
    z-index: 1;
    min-height: 760px;
    max-width: 1180px;
    margin: 0 auto;
    padding: 145px 22px 120px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: center;
    gap: 54px;
}

.eyebrow,
.card-meta,
.rank-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.eyebrow span,
.card-meta span,
.rank-meta span,
.tag-list span,
.mini-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(217, 119, 6, 0.12);
    color: #92400e;
    font-size: 0.78rem;
    font-weight: 800;
}

.hero-copy .eyebrow span,
.hero-tags span {
    background: rgba(255, 255, 255, 0.14);
    color: #fde68a;
    backdrop-filter: blur(12px);
}

.hero-copy h1 {
    max-width: 740px;
    margin: 20px 0 12px;
    color: #ffffff;
    font-size: clamp(2.4rem, 5.2vw, 5.1rem);
    line-height: 1.04;
    letter-spacing: -0.055em;
}

.hero-copy h2 {
    margin: 0 0 18px;
    color: #fbbf24;
    font-size: clamp(1.55rem, 3.1vw, 2.7rem);
    line-height: 1.18;
}

.hero-copy p {
    max-width: 700px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 1.08rem;
}

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

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

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

.btn.primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 16px 30px rgba(217, 119, 6, 0.28);
}

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

.btn.ghost.light {
    color: var(--amber-dark);
    background: #ffffff;
}

.btn.text {
    color: #fde68a;
    padding-left: 4px;
    padding-right: 4px;
}

.hero-poster {
    position: relative;
    display: block;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.36);
    transform: rotate(2deg);
}

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

.hero-poster span,
.poster-play {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.92);
    color: var(--amber-dark);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.24);
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 54px;
    z-index: 2;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 14px;
}

.hero-controls button {
    border: 0;
    cursor: pointer;
}

.hero-controls > button {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    font-size: 1.6rem;
    backdrop-filter: blur(14px);
}

.hero-dots {
    display: flex;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(16px);
}

.hero-dot {
    width: 9px;
    height: 9px;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.44);
}

.hero-dot.is-active {
    width: 26px;
    border-radius: 999px;
    background: #f59e0b;
}

.stat-strip {
    margin-top: -42px;
    position: relative;
    z-index: 4;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.stat-strip article,
.card-panel,
.movie-card,
.category-tile,
.category-overview-card,
.rank-item {
    background: var(--card);
    border: 1px solid rgba(226, 232, 240, 0.86);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.stat-strip article {
    padding: 22px;
    border-radius: 20px;
}

.stat-strip strong {
    display: block;
    color: var(--text);
    font-size: 1.25rem;
}

.stat-strip span {
    color: var(--muted);
    font-size: 0.94rem;
}

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

.section-head p {
    margin: 0 0 4px;
    color: var(--amber);
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-head h2 {
    margin: 0;
    font-size: clamp(1.8rem, 3vw, 2.7rem);
    line-height: 1.12;
}

.section-head a {
    color: var(--amber-dark);
    font-weight: 900;
}

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

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

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

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

.movie-card {
    border-radius: var(--radius);
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    background: #111827;
    overflow: hidden;
}

.poster-link img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.poster-link::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0), rgba(15, 23, 42, 0.55));
}

.poster-year {
    position: absolute;
    left: 14px;
    top: 14px;
    z-index: 2;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.7);
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 900;
    backdrop-filter: blur(10px);
}

.poster-play {
    z-index: 3;
    width: 48px;
    height: 48px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.movie-card:hover .poster-play {
    opacity: 1;
}

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

.movie-card-body h3 {
    margin: 12px 0 8px;
    font-size: 1.15rem;
    line-height: 1.32;
}

.movie-card-body h3 a:hover,
.rank-copy h3 a:hover {
    color: var(--amber-dark);
}

.movie-card-body p {
    margin: 0 0 14px;
    color: var(--muted);
    min-height: 3.1em;
}

.tag-list,
.mini-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.movie-card-large {
    display: grid;
    grid-template-columns: 46% 1fr;
    min-height: 360px;
}

.movie-card-large .poster-link img {
    height: 100%;
    aspect-ratio: auto;
}

.movie-card-large .movie-card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 34px;
}

.warm-panel {
    margin-top: 70px;
    padding: 1px 0 72px;
    background: linear-gradient(135deg, #fff7ed, #fffbeb);
}

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

.category-tile,
.category-overview-card {
    display: block;
    padding: 24px;
    border-radius: 22px;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-tile span,
.category-overview-main span {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 1.25rem;
    font-weight: 900;
}

.category-tile p,
.category-overview-main p {
    color: var(--muted);
    margin: 0 0 16px;
}

.category-tile div,
.category-overview-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-tile div a,
.category-overview-links a {
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--amber-soft);
    color: var(--amber-dark);
    font-size: 0.84rem;
    font-weight: 800;
}

.rank-panel {
    margin-top: 80px;
    padding: 1px 0 82px;
    background: linear-gradient(135deg, #0f172a, #1e293b);
}

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

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

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

.rank-item {
    position: relative;
    display: grid;
    grid-template-columns: 86px 42px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
}

.rank-thumb {
    border-radius: 14px;
    overflow: hidden;
    background: #111827;
}

.rank-thumb img {
    width: 86px;
    aspect-ratio: 1 / 1.15;
    object-fit: cover;
}

.rank-number {
    color: var(--amber);
    font-size: 1.3rem;
    font-weight: 1000;
}

.rank-copy h3 {
    margin: 0 0 4px;
    font-size: 1rem;
    line-height: 1.3;
}

.rank-copy p {
    margin: 0 0 8px;
    color: var(--muted);
    font-size: 0.9rem;
}

.page-main {
    padding-top: 74px;
}

.page-hero {
    padding-top: 74px;
    padding-bottom: 48px;
}

.page-hero p {
    margin: 0 0 8px;
    color: var(--amber);
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(2.2rem, 5vw, 4.6rem);
    line-height: 1.04;
    letter-spacing: -0.045em;
}

.page-hero-text {
    max-width: 780px;
    color: var(--muted);
    font-size: 1.06rem;
}

.category-hero,
.rank-hero {
    border-radius: 0 0 38px 38px;
}

.small-actions {
    margin-top: 22px;
}

.filter-bar {
    display: flex;
    align-items: end;
    gap: 14px;
    margin-bottom: 24px;
}

.search-box,
.select-box {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-weight: 800;
}

.search-box {
    flex: 1;
}

.search-box input,
.select-box select {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: #ffffff;
    padding: 0 15px;
    color: var(--text);
    outline: none;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.search-box input:focus,
.select-box select:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.detail-main {
    padding-top: 0;
}

.detail-hero {
    position: relative;
    padding-top: 74px;
    min-height: 460px;
    background: var(--slate);
    overflow: hidden;
}

.detail-hero-bg {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(90deg, rgba(15, 23, 42, 0.97), rgba(15, 23, 42, 0.78), rgba(15, 23, 42, 0.28)), var(--cover-image);
    background-size: cover;
    background-position: center;
    filter: saturate(1.05);
}

.detail-hero-bg::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 130px;
    background: linear-gradient(0deg, var(--bg), rgba(248, 250, 252, 0));
}

.detail-hero-content {
    position: relative;
    z-index: 2;
    padding-top: 78px;
    padding-bottom: 72px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 700;
}

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

.detail-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
    margin-top: 46px;
}

.detail-heading p {
    margin: 0 0 10px;
    color: #fbbf24;
    font-weight: 900;
}

.detail-heading h1 {
    max-width: 820px;
    margin: 0 0 18px;
    color: #ffffff;
    font-size: clamp(2.1rem, 5vw, 4.8rem);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 24px;
    margin-top: -70px;
    position: relative;
    z-index: 4;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    background: #000000;
    box-shadow: 0 28px 60px rgba(15, 23, 42, 0.26);
}

.watch-player {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    cursor: pointer;
    color: var(--amber-dark);
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.08), rgba(15, 23, 42, 0.42));
}

.player-overlay span {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 22px 50px rgba(0, 0, 0, 0.32);
    font-size: 2rem;
}

.player-shell.is-playing .player-overlay {
    display: none;
}

.card-panel {
    border-radius: 24px;
    padding: 24px;
}

.detail-copy {
    margin-top: 22px;
}

.detail-copy h2,
.side-info h2 {
    margin: 0 0 12px;
    font-size: 1.35rem;
}

.detail-copy p {
    margin: 0 0 20px;
    color: #374151;
}

.detail-side {
    display: grid;
    gap: 18px;
    align-content: start;
}

.detail-cover {
    width: 100%;
    border-radius: 24px;
    aspect-ratio: 3 / 4.15;
    object-fit: cover;
    box-shadow: var(--shadow);
}

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

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

.side-info dd {
    margin: 0;
    color: var(--text);
    font-weight: 700;
}

.related-section {
    margin-bottom: 70px;
}

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

.site-footer {
    margin-top: 80px;
    background: linear-gradient(135deg, #0f172a, #1e293b);
    color: #ffffff;
}

.footer-grid {
    max-width: 1180px;
    margin: 0 auto;
    padding: 54px 22px 32px;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 32px;
}

.footer-grid p {
    color: rgba(255, 255, 255, 0.64);
}

.footer-grid h2 {
    margin: 0 0 12px;
    color: #fbbf24;
    font-size: 1rem;
}

.footer-grid a:not(.footer-brand) {
    display: block;
    margin: 8px 0;
    color: rgba(255, 255, 255, 0.68);
}

.footer-grid a:hover {
    color: #ffffff;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 18px 22px;
    text-align: center;
    color: rgba(255, 255, 255, 0.62);
}

.back-top {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 30;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    display: none;
    cursor: pointer;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 14px 28px rgba(217, 119, 6, 0.3);
}

.back-top.is-visible {
    display: grid;
    place-items: center;
}

.movie-item.is-hidden {
    display: none;
}

@media (max-width: 980px) {
    .hero-content {
        grid-template-columns: 1fr;
        padding-top: 120px;
        gap: 28px;
    }

    .hero-poster {
        max-width: 260px;
        transform: none;
    }

    .stat-strip,
    .movie-grid,
    .movie-grid.four,
    .category-grid,
    .category-overview-grid,
    .home-rank,
    .full-rank,
    .related-grid,
    .footer-grid,
    .detail-layout {
        grid-template-columns: 1fr 1fr;
    }

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

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

    .brand-text {
        font-size: 1.05rem;
    }

    .nav-toggle {
        display: block;
    }

    .main-nav {
        position: fixed;
        top: 64px;
        left: 14px;
        right: 14px;
        display: none;
        padding: 14px;
        border-radius: 18px;
        background: rgba(255, 255, 255, 0.97);
        box-shadow: var(--shadow);
        flex-direction: column;
        align-items: stretch;
    }

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

    .main-nav a,
    .header-solid .main-nav a,
    .site-header.is-scrolled .main-nav a {
        color: var(--text);
    }

    .hero-carousel,
    .hero-slides,
    .hero-content {
        min-height: 700px;
    }

    .hero-copy h1 {
        font-size: 2.45rem;
    }

    .hero-poster {
        display: none;
    }

    .hero-controls {
        bottom: 24px;
    }

    .stat-strip,
    .movie-grid,
    .movie-grid.four,
    .category-grid,
    .category-overview-grid,
    .home-rank,
    .full-rank,
    .related-grid,
    .footer-grid,
    .detail-layout {
        grid-template-columns: 1fr;
    }

    .movie-card-large {
        grid-template-columns: 1fr;
    }

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

    .filter-bar {
        align-items: stretch;
        flex-direction: column;
    }

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

    .rank-thumb img {
        width: 74px;
    }

    .detail-heading {
        align-items: start;
        flex-direction: column;
    }

    .detail-hero {
        min-height: 520px;
    }
}
