:root {
    --bg: #fff7ed;
    --text: #111827;
    --muted: #6b7280;
    --line: #fed7aa;
    --card: #ffffff;
    --dark: #0f172a;
    --orange: #ea580c;
    --amber: #f59e0b;
    --rose: #e11d48;
    --shadow: 0 20px 45px rgba(15, 23, 42, .10);
    --soft-shadow: 0 10px 30px rgba(15, 23, 42, .08);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 44%, #fff7ed 100%);
    line-height: 1.6;
}

body.menu-open {
    overflow: hidden;
}

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, rgba(255, 251, 235, .96), rgba(255, 237, 213, .96));
    box-shadow: 0 12px 30px rgba(146, 64, 14, .10);
    backdrop-filter: blur(16px);
}

.nav-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 900;
    color: #92400e;
    letter-spacing: -.04em;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    color: #fff;
    font-size: 16px;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    box-shadow: 0 12px 25px rgba(234, 88, 12, .30);
}

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

.desktop-nav a,
.mobile-nav a {
    font-weight: 700;
    color: #4b5563;
    transition: color .2s ease, transform .2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
    color: var(--orange);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: #fff7ed;
}

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

.mobile-nav {
    display: none;
    padding: 14px 24px 24px;
    background: rgba(255, 251, 235, .98);
    border-top: 1px solid var(--line);
}

.mobile-nav a {
    display: block;
    padding: 12px 0;
}

.hero {
    position: relative;
    min-height: 650px;
    overflow: hidden;
    background: var(--dark);
}

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

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

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

.hero-content {
    position: relative;
    z-index: 2;
    width: min(760px, calc(100% - 32px));
    margin-left: max(24px, calc((100vw - 1180px) / 2));
    padding-top: 56px;
    color: #fff;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 999px;
    color: #fff;
    background: rgba(255, 255, 255, .14);
    backdrop-filter: blur(12px);
    font-size: 14px;
    font-weight: 800;
}

.hero h1,
.inner-hero h1,
.detail-info h1 {
    margin: 0;
    font-size: clamp(42px, 7vw, 78px);
    line-height: .98;
    letter-spacing: -.06em;
    text-shadow: 0 20px 45px rgba(0, 0, 0, .28);
}

.hero p,
.inner-hero p,
.detail-line {
    max-width: 720px;
    margin: 24px 0 0;
    color: rgba(255, 255, 255, .90);
    font-size: clamp(17px, 2vw, 22px);
}

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

.primary-button,
.ghost-button,
.search-tools button,
.hero-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 24px;
    border: 0;
    border-radius: 999px;
    font-weight: 900;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.primary-button,
.search-tools button,
.hero-search button {
    color: #fff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    box-shadow: 0 18px 35px rgba(234, 88, 12, .30);
}

.ghost-button {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(255, 255, 255, .14);
    backdrop-filter: blur(12px);
}

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

.hero-search-panel {
    position: absolute;
    left: 50%;
    bottom: 38px;
    z-index: 3;
    display: grid;
    gap: 18px;
    width: min(920px, calc(100% - 32px));
    transform: translateX(-50%);
}

.hero-search,
.search-tools,
.inline-filter {
    display: flex;
    gap: 12px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, .32);
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.hero-search input,
.search-tools input,
.search-tools select,
.inline-filter input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 0 18px;
    color: var(--text);
    background: transparent;
}

.hero-dots {
    display: flex;
    justify-content: center;
    gap: 9px;
}

.hero-dot {
    width: 34px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .42);
    transition: width .2s ease, background .2s ease;
}

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

.stats-strip {
    background: #fff;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    padding: 34px 0;
}

.stats-grid div {
    padding: 26px 20px;
    text-align: center;
    border-radius: 22px;
    background: linear-gradient(135deg, #fff7ed, #fffbeb);
    box-shadow: var(--soft-shadow);
}

.stats-grid strong {
    display: block;
    color: #9a3412;
    font-size: 34px;
    line-height: 1;
}

.stats-grid span {
    display: block;
    margin-top: 8px;
    color: var(--muted);
    font-weight: 700;
}

.section-block {
    padding: 72px 0;
}

.warm-bg {
    background: linear-gradient(180deg, #fff7ed, #fff);
}

.dark-section {
    color: #fff;
    background: linear-gradient(135deg, #111827, #0f172a 52%, #431407);
}

.section-title {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 28px;
}

.section-title span {
    display: block;
    color: var(--orange);
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.section-title h2 {
    margin: 4px 0 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.1;
    letter-spacing: -.04em;
}

.section-title a,
.text-link {
    color: var(--orange);
    font-weight: 900;
}

.light-title h2,
.light-title a {
    color: #fff;
}

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

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

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

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

.category-visual {
    display: flex;
    align-items: flex-end;
    min-height: 210px;
    padding: 22px;
    color: #fff;
    background-size: cover;
    background-position: center;
}

.category-visual span {
    font-size: 28px;
    font-weight: 900;
    letter-spacing: -.04em;
}

.category-body {
    padding: 24px;
}

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

.category-body p {
    margin: 0;
    color: var(--muted);
}

.category-links {
    display: grid;
    gap: 8px;
    margin: 18px 0;
}

.category-links a {
    color: #7c2d12;
    font-weight: 700;
}

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

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

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

.movie-card {
    display: block;
    overflow: hidden;
    border: 1px solid rgba(254, 215, 170, .85);
    border-radius: 22px;
    background: var(--card);
    box-shadow: var(--soft-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}

.movie-poster {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fed7aa, #fde68a);
}

.movie-poster img,
.detail-poster img,
.ranking-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .45s ease;
}

.movie-card:hover img {
    transform: scale(1.08);
}

.poster-badge,
.card-rank {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    font-weight: 900;
    box-shadow: 0 12px 25px rgba(15, 23, 42, .20);
}

.poster-badge {
    top: 12px;
    right: 12px;
    padding: 6px 10px;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    font-size: 12px;
}

.card-rank {
    top: 12px;
    left: 12px;
    width: 42px;
    height: 42px;
    background: rgba(15, 23, 42, .84);
}

.movie-info {
    padding: 18px;
}

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

.movie-meta span,
.detail-meta span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #fff7ed;
}

.movie-info h3 {
    min-height: 2.6em;
    margin: 12px 0 8px;
    font-size: 19px;
    line-height: 1.3;
    letter-spacing: -.02em;
}

.movie-info p {
    display: -webkit-box;
    min-height: 4.8em;
    margin: 0 0 14px;
    overflow: hidden;
    color: var(--muted);
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

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

.tag-row span,
.chip-row button {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0 10px;
    border: 1px solid #fed7aa;
    border-radius: 999px;
    color: #9a3412;
    background: #fff7ed;
    font-size: 12px;
    font-weight: 800;
}

.split-layout {
    display: grid;
    grid-template-columns: .9fr 1.1fr;
    gap: 36px;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 54px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, .10);
    border-radius: 18px;
    background: rgba(255, 255, 255, .08);
    backdrop-filter: blur(12px);
}

.rank-row span {
    color: #fbbf24;
    font-size: 22px;
    font-weight: 900;
}

.rank-row em {
    color: rgba(255, 255, 255, .68);
    font-style: normal;
}

.inner-hero,
.detail-hero {
    display: flex;
    align-items: center;
    min-height: 380px;
    color: #fff;
    background-size: cover;
    background-position: center;
}

.inner-hero .container,
.detail-hero .container {
    padding: 60px 0;
}

.inline-filter {
    max-width: 560px;
    margin-top: 28px;
}

.inline-filter input {
    min-height: 46px;
}

.search-tools {
    max-width: 860px;
    margin-top: 28px;
}

.search-tools select {
    max-width: 210px;
    border: 0;
    outline: 0;
    color: var(--text);
    background: transparent;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-width: 980px;
    margin-top: 20px;
}

.chip-row button {
    border-color: rgba(255, 255, 255, .26);
    color: #fff;
    background: rgba(255, 255, 255, .16);
    backdrop-filter: blur(12px);
}

.chip-row button.is-active {
    color: #9a3412;
    background: #fff;
}

.empty-state {
    display: none;
    margin: 38px auto 0;
    padding: 34px;
    text-align: center;
    color: var(--muted);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--soft-shadow);
}

.empty-state.is-visible {
    display: block;
}

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

.ranking-card {
    display: grid;
    grid-template-columns: 74px 120px 1fr;
    gap: 22px;
    align-items: center;
    padding: 18px;
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--soft-shadow);
    transition: transform .2s ease, box-shadow .2s ease;
}

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

.ranking-number {
    color: var(--orange);
    font-size: 28px;
    font-weight: 900;
}

.ranking-card img {
    aspect-ratio: 3 / 4;
    border-radius: 16px;
}

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

.ranking-card p {
    margin: 0 0 12px;
    color: var(--muted);
}

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

.breadcrumb em {
    color: #fff;
    font-style: normal;
}

.detail-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 44px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    aspect-ratio: 3 / 4;
    border: 6px solid rgba(255, 255, 255, .18);
    border-radius: 28px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, .35);
}

.detail-info h1 {
    font-size: clamp(40px, 6vw, 70px);
}

.detail-meta {
    margin: 24px 0;
}

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

.large-tags {
    margin-bottom: 28px;
}

.large-tags span {
    border-color: rgba(255, 255, 255, .22);
    color: #fff;
    background: rgba(255, 255, 255, .14);
}

.watch-section {
    padding: 72px 0 0;
    background: #fff;
}

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

.video-player {
    width: 100%;
    height: 100%;
    background: #020617;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 10px;
    border: 0;
    color: #fff;
    background: radial-gradient(circle at center, rgba(249, 115, 22, .30), rgba(15, 23, 42, .76));
    transition: opacity .25s ease, visibility .25s ease;
}

.player-shell.is-playing .player-cover {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.play-circle {
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 50%;
    color: var(--orange);
    background: #fff;
    box-shadow: 0 20px 45px rgba(0, 0, 0, .28);
    font-size: 30px;
}

.player-cover strong {
    font-size: 24px;
}

.player-cover em {
    font-style: normal;
    color: rgba(255, 255, 255, .78);
}

.content-layout {
    display: grid;
    grid-template-columns: 1.2fr .8fr;
    gap: 24px;
}

.story-card {
    padding: 34px;
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--soft-shadow);
}

.story-card h2 {
    margin: 0 0 18px;
    font-size: 28px;
}

.story-card p {
    margin: 0;
    color: #374151;
    font-size: 17px;
    line-height: 1.9;
}

.accent-card {
    background: linear-gradient(135deg, #fff7ed, #fffbeb);
}

.site-footer {
    color: #d1d5db;
    background: linear-gradient(180deg, #111827, #030712);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 42px;
    padding: 54px 0;
}

.footer-brand {
    color: #fbbf24;
}

.site-footer p {
    max-width: 420px;
    color: #9ca3af;
}

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

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

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

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

.is-hidden {
    display: none !important;
}

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

    .category-grid,
    .category-grid.wide,
    .split-layout,
    .content-layout {
        grid-template-columns: 1fr;
    }
}

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

    .menu-toggle {
        display: block;
    }

    .mobile-nav.is-open {
        display: block;
    }

    .hero {
        min-height: 720px;
    }

    .hero-content {
        margin: 0 auto;
        padding-top: 80px;
    }

    .hero-search,
    .search-tools,
    .inline-filter {
        flex-direction: column;
        align-items: stretch;
        border-radius: 24px;
    }

    .hero-search input,
    .search-tools input,
    .search-tools select,
    .inline-filter input {
        min-height: 48px;
    }

    .stats-grid,
    .movie-grid,
    .mini-grid,
    .footer-grid,
    .detail-layout {
        grid-template-columns: 1fr;
    }

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

    .ranking-card {
        grid-template-columns: 48px 86px 1fr;
        gap: 14px;
    }

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

    .rank-row {
        grid-template-columns: 44px 1fr;
    }

    .rank-row em {
        grid-column: 2;
    }
}

@media (max-width: 520px) {
    .container {
        width: min(100% - 24px, 1180px);
    }

    .brand {
        font-size: 21px;
    }

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

    .category-visual {
        min-height: 180px;
    }

    .movie-grid {
        gap: 16px;
    }

    .story-card {
        padding: 24px;
    }
}
