:root {
    color-scheme: light;
    --bg: #f8fafc;
    --paper: #ffffff;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --amber: #d97706;
    --amber-dark: #92400e;
    --amber-soft: #fef3c7;
    --slate: #1e293b;
    --slate-dark: #020617;
    --blue: #2563eb;
    --shadow: 0 20px 50px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--ink);
    background: linear-gradient(180deg, #fff7ed 0%, #f8fafc 28%, #f1f5f9 100%);
}

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.9);
    color: #ffffff;
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
    width: min(1180px, calc(100% - 32px));
    min-height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.03em;
}

.logo-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #451a03;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    box-shadow: 0 12px 24px rgba(217, 119, 6, 0.35);
}

.logo-text {
    font-size: 1.2rem;
}

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

.nav-link,
.mobile-link {
    color: rgba(255, 255, 255, 0.82);
    padding: 10px 16px;
    border-radius: 999px;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: #ffffff;
    background: rgba(217, 119, 6, 0.22);
}

.nav-link:hover {
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    background: #ffffff;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.08);
}

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

.hero-carousel {
    position: relative;
    min-height: 720px;
    overflow: hidden;
    color: #ffffff;
    background: #020617;
}

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

.hero-slide {
    display: flex;
    align-items: center;
    background-position: center;
    background-size: cover;
    opacity: 0;
    transform: scale(1.04);
    transition: opacity 0.8s ease, transform 1.2s ease;
}

.hero-slide.is-active {
    opacity: 1;
    transform: scale(1);
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 18% 22%, rgba(251, 191, 36, 0.2), transparent 28%), linear-gradient(180deg, transparent 58%, rgba(15, 23, 42, 0.96) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 98px 0 180px;
    max-width: 900px;
}

.hero-kicker,
.page-hero span,
.section-heading span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fbbf24;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-content h1 {
    max-width: 860px;
    margin: 18px 0 20px;
    font-size: clamp(2.6rem, 7vw, 6.8rem);
    line-height: 0.95;
    letter-spacing: -0.05em;
}

.hero-content p {
    max-width: 720px;
    margin: 0;
    color: #fde68a;
    font-size: clamp(1.05rem, 2vw, 1.35rem);
    line-height: 1.85;
}

.hero-tags,
.detail-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
}

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

.hero-tags span,
.hero-tags strong,
.detail-meta span,
.card-meta span {
    border-radius: 999px;
    padding: 7px 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-tags strong {
    color: #451a03;
    background: #fbbf24;
}

.hero-actions,
.inline-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 24px;
    border-radius: 14px;
    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: #451a03;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    box-shadow: 0 18px 28px rgba(217, 119, 6, 0.28);
}

.btn.ghost {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.24);
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 118px;
    z-index: 4;
    width: min(1180px, calc(100% - 32px));
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-prev,
.hero-next,
.hero-dot {
    border: 0;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(12px);
}

.hero-prev,
.hero-next {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 2rem;
    line-height: 1;
}

.hero-dots {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hero-dot {
    width: 12px;
    height: 12px;
    padding: 0;
    border-radius: 999px;
    transition: width 0.2s ease, background 0.2s ease;
}

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

.hero-search {
    position: absolute;
    left: 50%;
    bottom: 28px;
    z-index: 5;
    width: min(760px, calc(100% - 32px));
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    padding: 12px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.16);
    transform: translateX(-50%);
}

.hero-search input,
.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0 15px;
    color: var(--ink);
    background: #ffffff;
    outline: none;
}

.hero-search button {
    min-height: 48px;
    padding: 0 22px;
    border: 0;
    border-radius: 14px;
    color: #451a03;
    font-weight: 800;
    background: linear-gradient(135deg, #fbbf24, #f97316);
}

.section-wrap {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 72px 0;
}

.top-tight {
    padding-top: 28px;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 22px;
    margin-bottom: 30px;
}

.section-heading h2 {
    margin: 8px 0 0;
    font-size: clamp(2rem, 4vw, 3.6rem);
    line-height: 1;
    letter-spacing: -0.04em;
}

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

.section-heading.light,
.section-heading.light a {
    color: #ffffff;
}

.intro-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 20px;
}

.intro-card {
    min-height: 260px;
    padding: 28px;
    border-radius: var(--radius);
    background: var(--paper);
    box-shadow: var(--shadow);
}

.intro-card.strong {
    color: #ffffff;
    background: linear-gradient(135deg, #0f172a, #92400e);
}

.intro-card span {
    color: var(--amber);
    font-weight: 800;
}

.intro-card h2 {
    margin: 14px 0 12px;
    font-size: 1.65rem;
    line-height: 1.18;
}

.intro-card p {
    margin: 0 0 24px;
    color: var(--muted);
    line-height: 1.75;
}

.intro-card.strong p {
    color: #fde68a;
}

.intro-card a {
    display: inline-flex;
    color: var(--amber-dark);
    font-weight: 800;
}

.intro-card.strong a {
    color: #fbbf24;
}

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

.category-card {
    min-height: 160px;
    padding: 22px;
    border-radius: 20px;
    color: #ffffff;
    background: linear-gradient(135deg, #1e293b, #92400e);
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:nth-child(3n) {
    background: linear-gradient(135deg, #0f766e, #164e63);
}

.category-card:nth-child(4n) {
    background: linear-gradient(135deg, #4338ca, #0f172a);
}

.category-card:hover,
.movie-card:hover,
.category-overview:hover {
    transform: translateY(-5px);
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.18);
}

.category-card span {
    font-size: 1.35rem;
    font-weight: 900;
}

.category-card p {
    margin: 14px 0 0;
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.65;
}

.dark-section {
    width: auto;
    max-width: none;
    padding: 72px max(16px, calc((100% - 1180px) / 2));
    color: #ffffff;
    background: radial-gradient(circle at 12% 10%, rgba(217, 119, 6, 0.32), transparent 28%), linear-gradient(135deg, #020617, #1e293b 45%, #78350f);
}

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

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

.movie-card:hover img {
    transform: scale(1.06);
    filter: brightness(1.05);
}

.score-badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    font-weight: 900;
}

.score-badge {
    right: 12px;
    top: 12px;
    padding: 7px 10px;
    color: #451a03;
    background: #fbbf24;
}

.rank-badge {
    left: 12px;
    top: 12px;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.84);
}

.card-body {
    padding: 18px;
}

.card-meta {
    gap: 6px;
    margin-bottom: 10px;
}

.card-meta span {
    padding: 5px 8px;
    color: var(--muted);
    background: #f1f5f9;
    border-color: #e2e8f0;
    font-size: 0.78rem;
}

.card-body h3 {
    margin: 0 0 10px;
    font-size: 1.18rem;
    line-height: 1.25;
}

.card-body p {
    min-height: 48px;
    margin: 0 0 14px;
    color: var(--muted);
    line-height: 1.65;
    font-size: 0.95rem;
}

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

.tag-row span,
.tag-row a {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--amber-dark);
    background: #fff7ed;
    font-size: 0.82rem;
    font-weight: 700;
}

.movie-card.compact .card-body {
    padding: 14px;
}

.movie-card.compact .card-body p,
.movie-card.compact .tag-row {
    display: none;
}

.page-hero {
    position: relative;
    min-height: 380px;
    display: grid;
    place-items: center;
    padding: 72px 16px;
    color: #ffffff;
    text-align: center;
    background: radial-gradient(circle at 20% 20%, rgba(251, 191, 36, 0.22), transparent 30%), linear-gradient(135deg, #020617, #78350f);
}

.small-hero {
    min-height: 330px;
}

.category-hero {
    min-height: 360px;
}

.ranking-hero {
    background: radial-gradient(circle at 70% 30%, rgba(14, 165, 233, 0.18), transparent 30%), linear-gradient(135deg, #020617, #1e293b 44%, #92400e);
}

.page-hero h1 {
    margin: 12px 0;
    font-size: clamp(2.3rem, 5vw, 5rem);
    line-height: 1;
    letter-spacing: -0.05em;
}

.page-hero p {
    max-width: 720px;
    margin: 0 auto;
    color: #fde68a;
    font-size: 1.12rem;
    line-height: 1.85;
}

.filter-panel {
    width: min(1180px, calc(100% - 32px));
    margin: -44px auto 0;
    position: relative;
    z-index: 3;
    padding: 18px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.filter-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 0.8fr 0.9fr;
    gap: 14px;
}

.filter-grid label {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-weight: 800;
}

.filter-grid span {
    font-size: 0.9rem;
}

.filter-empty {
    margin-top: 16px;
    padding: 18px;
    text-align: center;
    color: var(--muted);
    border-radius: 16px;
    background: #f8fafc;
}

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

.category-overview {
    overflow: hidden;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-covers {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    height: 170px;
    background: #0f172a;
}

.category-covers img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-overview div:last-child {
    padding: 24px;
}

.category-overview h2 {
    margin: 0 0 10px;
    font-size: 1.45rem;
}

.category-overview p {
    margin: 0 0 18px;
    color: var(--muted);
    line-height: 1.7;
}

.category-overview span {
    color: var(--amber-dark);
    font-weight: 900;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 76px 110px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 16px;
}

.rank-number {
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    color: #451a03;
    font-size: 1.35rem;
    font-weight: 900;
    background: linear-gradient(135deg, #fbbf24, #f97316);
}

.rank-cover {
    width: 96px;
    height: 128px;
    overflow: hidden;
    border-radius: 14px;
    background: #0f172a;
}

.rank-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rank-info h2 {
    margin: 0 0 10px;
    font-size: 1.35rem;
}

.rank-info p {
    margin: 0 0 12px;
    color: var(--muted);
    line-height: 1.7;
}

.rank-score {
    padding: 10px 14px;
    border-radius: 999px;
    color: #451a03;
    background: #fbbf24;
    font-weight: 900;
}

.detail-hero {
    position: relative;
    min-height: 680px;
    overflow: hidden;
    color: #ffffff;
    background: #020617;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    filter: saturate(1.08);
}

.detail-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.94));
}

.detail-inner {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 46px 0 76px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-bottom: 34px;
    color: rgba(255, 255, 255, 0.76);
}

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

.detail-grid {
    display: grid;
    grid-template-columns: 310px 1fr;
    gap: 40px;
    align-items: end;
}

.detail-poster {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

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

.detail-poster span {
    position: absolute;
    right: 16px;
    top: 16px;
    padding: 8px 12px;
    border-radius: 999px;
    color: #451a03;
    background: #fbbf24;
    font-weight: 900;
}

.detail-info h1 {
    margin: 16px 0;
    font-size: clamp(2.2rem, 5vw, 5.5rem);
    line-height: 1;
    letter-spacing: -0.05em;
}

.detail-one-line {
    max-width: 820px;
    margin: 0 0 20px;
    color: #fde68a;
    font-size: 1.18rem;
    line-height: 1.75;
}

.detail-tags {
    margin: 24px 0 30px;
}

.player-section {
    padding-bottom: 34px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    background: #000000;
    box-shadow: 0 28px 90px rgba(15, 23, 42, 0.36);
    aspect-ratio: 16 / 9;
}

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

.player-start {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 14px;
    border: 0;
    color: #ffffff;
    background: radial-gradient(circle, rgba(15, 23, 42, 0.22), rgba(15, 23, 42, 0.72));
}

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

.play-symbol {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    padding-left: 6px;
    border-radius: 50%;
    color: #451a03;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    box-shadow: 0 20px 60px rgba(217, 119, 6, 0.38);
    font-size: 2.4rem;
}

.player-start strong {
    font-size: 1.25rem;
}

.detail-content-grid {
    display: grid;
    grid-template-columns: 1fr 330px;
    gap: 24px;
    padding-top: 36px;
}

.content-card {
    padding: 30px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.content-card h2 {
    margin: 0 0 16px;
    font-size: 1.6rem;
}

.content-card h2:not(:first-child) {
    margin-top: 32px;
}

.content-card p {
    margin: 0;
    color: #334155;
    line-height: 1.95;
    font-size: 1.05rem;
}

.side-copy dl {
    display: grid;
    grid-template-columns: 76px 1fr;
    gap: 12px 14px;
    margin: 0;
}

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

.side-copy dd {
    margin: 0;
    color: var(--ink);
}

.side-copy a {
    color: var(--amber-dark);
    font-weight: 800;
}

.site-footer {
    color: rgba(255, 255, 255, 0.72);
    background: #020617;
}

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

.footer-logo {
    margin-bottom: 12px;
    color: #ffffff;
    font-size: 1.3rem;
    font-weight: 900;
}

.site-footer p {
    max-width: 360px;
    margin: 0;
    line-height: 1.75;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: #ffffff;
    font-size: 1rem;
}

.site-footer a {
    display: block;
    margin: 9px 0;
}

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

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 28px;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

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

    .category-grid,
    .category-overview-grid,
    .intro-grid,
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

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

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

    .menu-toggle {
        display: block;
    }

    .hero-carousel {
        min-height: 650px;
    }

    .hero-content {
        padding-top: 78px;
        padding-bottom: 190px;
    }

    .hero-search {
        grid-template-columns: 1fr;
    }

    .hero-controls {
        bottom: 150px;
    }

    .section-wrap {
        padding: 48px 0;
    }

    .section-heading {
        display: grid;
        align-items: start;
    }

    .movie-grid,
    .compact-grid,
    .category-grid,
    .category-overview-grid,
    .intro-grid,
    .footer-grid,
    .filter-grid {
        grid-template-columns: 1fr;
    }

    .rank-row {
        grid-template-columns: 50px 80px 1fr;
        align-items: start;
    }

    .rank-number {
        width: 42px;
        height: 42px;
        border-radius: 14px;
        font-size: 1rem;
    }

    .rank-cover {
        width: 76px;
        height: 104px;
    }

    .rank-score {
        grid-column: 3;
        justify-self: start;
    }

    .detail-grid {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .detail-poster {
        max-width: 240px;
    }

    .detail-hero {
        min-height: auto;
    }

    .content-card {
        padding: 22px;
    }

    .side-copy dl {
        grid-template-columns: 64px 1fr;
    }

    .footer-bottom {
        display: grid;
    }
}

@media (max-width: 480px) {
    .header-inner {
        min-height: 64px;
    }

    .logo-text {
        font-size: 1rem;
    }

    .hero-content h1,
    .page-hero h1,
    .detail-info h1 {
        letter-spacing: -0.03em;
    }

    .hero-tags span,
    .hero-tags strong,
    .detail-meta span {
        font-size: 0.82rem;
    }

    .btn {
        width: 100%;
    }

    .player-shell {
        border-radius: 18px;
    }
}
