:root {
    --bg: #fff7ed;
    --bg-soft: #fffbeb;
    --paper: #ffffff;
    --paper-warm: #fffaf0;
    --ink: #4a2608;
    --muted: #8a5a24;
    --accent: #b91c1c;
    --accent-dark: #7f1d1d;
    --gold: #d97706;
    --green: #15803d;
    --line: #f2d9b3;
    --shadow: 0 22px 45px rgba(97, 47, 8, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        radial-gradient(circle at top left, rgba(251, 191, 36, 0.24), transparent 34rem),
        linear-gradient(180deg, #fff7ed 0%, #fffbeb 38%, #fff7ed 100%);
    font-family: "Noto Sans SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

h1,
h2,
h3,
.site-logo-text,
.hero-title {
    font-family: "Noto Serif SC", "Songti SC", "SimSun", serif;
}

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(255, 247, 237, 0.92);
    border-bottom: 1px solid rgba(217, 119, 6, 0.16);
    backdrop-filter: blur(18px);
}

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

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: max-content;
}

.site-logo-mark {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), var(--gold));
    box-shadow: 0 12px 24px rgba(185, 28, 28, 0.22);
    font-weight: 900;
}

.site-logo-text {
    font-size: 1.55rem;
    font-weight: 900;
    color: var(--accent-dark);
    letter-spacing: 0.02em;
}

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

.main-nav a,
.mobile-panel a {
    padding: 10px 14px;
    border-radius: 999px;
    color: #7c3f12;
    font-weight: 700;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.main-nav a.is-active,
.mobile-panel a:hover,
.mobile-panel a.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), #dc2626);
    transform: translateY(-1px);
}

.header-search {
    position: relative;
    flex: 1;
    max-width: 270px;
}

.header-search input {
    width: 100%;
    height: 42px;
    border: 1px solid rgba(217, 119, 6, 0.26);
    border-radius: 999px;
    padding: 0 42px 0 16px;
    color: var(--ink);
    background: rgba(255, 255, 255, 0.84);
    outline: none;
}

.header-search button {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: var(--accent);
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    color: #ffffff;
    background: var(--accent);
}

.mobile-panel {
    display: none;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 14px;
    border: 1px solid rgba(217, 119, 6, 0.18);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
}

.mobile-panel.is-open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.page-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
}

.hero-section {
    padding: 34px 0 36px;
}

.hero-slider {
    position: relative;
    min-height: 560px;
    overflow: hidden;
    border-radius: 32px;
    background: #3b1705;
    box-shadow: var(--shadow);
}

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

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

.hero-media {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at top right, rgba(245, 158, 11, 0.34), transparent 34rem),
        linear-gradient(135deg, #3b1705, #7f1d1d 46%, #b45309);
}

.hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.42;
    filter: saturate(1.08) contrast(1.04);
}

.hero-media.image-muted img {
    display: none;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(33, 13, 4, 0.94) 0%, rgba(63, 24, 8, 0.76) 46%, rgba(63, 24, 8, 0.16) 100%),
        linear-gradient(0deg, rgba(0, 0, 0, 0.34), transparent 46%);
}

.hero-content {
    position: relative;
    z-index: 2;
    min-height: 560px;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) 380px;
    align-items: center;
    gap: 44px;
    padding: 54px;
    color: #ffffff;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 237, 213, 0.45);
    border-radius: 999px;
    color: #ffedd5;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    font-weight: 700;
}

.hero-title {
    margin: 0;
    max-width: 780px;
    font-size: clamp(2.45rem, 5vw, 5.4rem);
    line-height: 1.03;
    font-weight: 900;
    text-shadow: 0 20px 36px rgba(0, 0, 0, 0.34);
}

.hero-copy {
    max-width: 760px;
    margin: 22px 0 0;
    color: #ffedd5;
    font-size: 1.08rem;
    line-height: 1.9;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.meta-pill,
.tag-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #7c2d12;
    background: #ffedd5;
    font-weight: 800;
    font-size: 0.9rem;
}

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

.btn-primary,
.btn-secondary,
.btn-soft {
    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-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), #ef4444);
    box-shadow: 0 16px 30px rgba(185, 28, 28, 0.32);
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-soft:hover {
    transform: translateY(-2px);
}

.btn-secondary {
    color: #7c2d12;
    background: #ffedd5;
}

.btn-soft {
    color: var(--accent-dark);
    background: #fff7ed;
    border: 1px solid rgba(217, 119, 6, 0.18);
}

.hero-side-card {
    padding: 24px;
    border: 1px solid rgba(255, 237, 213, 0.34);
    border-radius: 28px;
    background: rgba(255, 247, 237, 0.13);
    backdrop-filter: blur(20px);
    box-shadow: 0 24px 50px rgba(0, 0, 0, 0.2);
}

.hero-side-card .poster-shell {
    aspect-ratio: 3 / 4;
    border-radius: 24px;
}

.hero-side-card h2 {
    margin: 18px 0 8px;
    color: #ffffff;
    font-size: 1.55rem;
}

.hero-side-card p {
    margin: 0;
    color: #ffedd5;
    line-height: 1.7;
}

.hero-controls {
    position: absolute;
    z-index: 4;
    right: 30px;
    bottom: 28px;
    display: flex;
    gap: 10px;
}

.hero-control {
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 237, 213, 0.5);
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(12px);
}

.hero-dots {
    position: absolute;
    z-index: 4;
    left: 54px;
    bottom: 34px;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 36px;
    height: 5px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 237, 213, 0.36);
}

.hero-dot.is-active {
    background: #ffffff;
}

.section-block {
    margin: 42px 0;
}

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

.section-title {
    margin: 0;
    font-size: clamp(1.8rem, 3vw, 2.8rem);
    line-height: 1.15;
    color: #7f1d1d;
    font-weight: 900;
}

.section-desc {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.7;
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(217, 119, 6, 0.16);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 10px 28px rgba(97, 47, 8, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(185, 28, 28, 0.3);
    box-shadow: 0 22px 44px rgba(97, 47, 8, 0.16);
}

.poster-shell {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    background:
        radial-gradient(circle at 30% 20%, rgba(251, 191, 36, 0.48), transparent 28%),
        linear-gradient(135deg, #7f1d1d, #b45309 52%, #78350f);
}

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

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

.poster-shell.image-muted img {
    display: none;
}

.card-badge {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 2;
    padding: 5px 9px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(127, 29, 29, 0.9);
    font-size: 0.78rem;
    font-weight: 900;
}

.card-year {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    padding: 5px 9px;
    border-radius: 999px;
    color: #7c2d12;
    background: rgba(255, 237, 213, 0.92);
    font-size: 0.78rem;
    font-weight: 900;
}

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

.movie-title {
    margin: 0;
    color: #7f1d1d;
    font-size: 1.02rem;
    line-height: 1.35;
    font-weight: 900;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 9px;
    color: var(--muted);
    font-size: 0.86rem;
}

.movie-card-copy {
    margin: 10px 0 0;
    color: #7c3f12;
    font-size: 0.9rem;
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.category-card {
    min-height: 188px;
    padding: 24px;
    border-radius: 26px;
    color: #ffffff;
    background:
        radial-gradient(circle at top right, rgba(255, 237, 213, 0.26), transparent 36%),
        linear-gradient(135deg, #7f1d1d, #b45309);
    box-shadow: var(--shadow);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 26px 46px rgba(127, 29, 29, 0.2);
}

.category-card h2,
.category-card h3 {
    margin: 0;
    font-size: 1.6rem;
}

.category-card p {
    margin: 12px 0 0;
    color: #ffedd5;
    line-height: 1.8;
}

.rank-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 22px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 54px 72px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border: 1px solid rgba(217, 119, 6, 0.18);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 22px rgba(97, 47, 8, 0.08);
}

.rank-number {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), var(--gold));
    font-weight: 900;
}

.rank-thumb {
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border-radius: 12px;
    background: linear-gradient(135deg, #7f1d1d, #b45309);
}

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

.rank-title {
    margin: 0;
    color: #7f1d1d;
    font-weight: 900;
}

.rank-desc {
    margin: 6px 0 0;
    color: var(--muted);
    line-height: 1.6;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.page-hero {
    margin: 34px 0 30px;
    padding: 36px;
    border-radius: 30px;
    color: #ffffff;
    background:
        radial-gradient(circle at top right, rgba(251, 191, 36, 0.28), transparent 36%),
        linear-gradient(135deg, #7f1d1d, #b45309);
    box-shadow: var(--shadow);
}

.page-hero h1 {
    margin: 0;
    font-size: clamp(2.2rem, 5vw, 4.4rem);
    line-height: 1.1;
    font-weight: 900;
}

.page-hero p {
    max-width: 850px;
    margin: 14px 0 0;
    color: #ffedd5;
    font-size: 1.05rem;
    line-height: 1.85;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 28px 0 16px;
    color: var(--muted);
    font-weight: 700;
}

.breadcrumb a {
    color: var(--accent-dark);
}

.filter-panel,
.search-panel {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
    padding: 18px;
    border: 1px solid rgba(217, 119, 6, 0.18);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 26px rgba(97, 47, 8, 0.08);
}

.filter-panel input,
.search-panel input,
.search-panel select {
    min-height: 44px;
    border: 1px solid rgba(217, 119, 6, 0.28);
    border-radius: 999px;
    padding: 0 16px;
    color: var(--ink);
    background: #ffffff;
    outline: none;
}

.search-panel input {
    flex: 1 1 280px;
}

.search-panel select {
    flex: 0 0 150px;
}

.filter-panel input {
    flex: 1 1 260px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    align-items: start;
}

.detail-main,
.detail-side,
.text-card {
    border: 1px solid rgba(217, 119, 6, 0.16);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
}

.detail-main {
    overflow: hidden;
}

.player-box {
    position: relative;
    overflow: hidden;
    background: #140802;
}

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    background:
        radial-gradient(circle at center, rgba(185, 28, 28, 0.25), transparent 32%),
        #140802;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(20, 8, 2, 0.38);
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-button {
    width: 82px;
    height: 82px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), #f97316);
    box-shadow: 0 20px 48px rgba(0, 0, 0, 0.35);
    font-size: 2rem;
    font-weight: 900;
}

.player-status {
    position: absolute;
    left: 18px;
    bottom: 16px;
    z-index: 3;
    color: #ffedd5;
    font-weight: 700;
}

.detail-content {
    padding: 28px;
}

.detail-title {
    margin: 0;
    color: #7f1d1d;
    font-size: clamp(2rem, 4vw, 3.5rem);
    line-height: 1.12;
    font-weight: 900;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 18px;
}

.detail-intro {
    margin: 0;
    color: #7c3f12;
    font-size: 1.06rem;
    line-height: 1.85;
}

.text-card {
    padding: 24px;
    margin-top: 22px;
}

.text-card h2 {
    margin: 0 0 12px;
    color: #7f1d1d;
    font-size: 1.55rem;
}

.text-card p {
    margin: 0;
    color: #6f3b12;
    line-height: 1.9;
}

.detail-side {
    padding: 18px;
    position: sticky;
    top: 96px;
}

.detail-side .poster-shell {
    border-radius: 22px;
}

.info-list {
    display: grid;
    gap: 12px;
    margin-top: 18px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(217, 119, 6, 0.16);
    color: var(--muted);
}

.info-row strong {
    color: #7f1d1d;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

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

.site-footer {
    margin-top: 64px;
    padding: 34px 0;
    color: #ffedd5;
    background: linear-gradient(135deg, #451a03, #7f1d1d);
}

.footer-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 24px;
    align-items: center;
}

.footer-title {
    margin: 0;
    color: #ffffff;
    font-size: 1.6rem;
    font-weight: 900;
}

.footer-text {
    margin: 8px 0 0;
    line-height: 1.7;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-end;
}

.footer-links a {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
}

.empty-state {
    padding: 34px;
    border-radius: 24px;
    color: var(--muted);
    background: rgba(255, 255, 255, 0.9);
    text-align: center;
}

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

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

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

    .hero-side-card {
        display: none;
    }

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

    .detail-side {
        position: static;
    }
}

@media (max-width: 860px) {
    .main-nav,
    .header-search {
        display: none;
    }

    .mobile-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .hero-slider,
    .hero-content {
        min-height: 620px;
    }

    .hero-content {
        padding: 34px 24px;
    }

    .hero-dots {
        left: 24px;
        bottom: 24px;
    }

    .hero-controls {
        right: 24px;
        bottom: 18px;
    }

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

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

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

    .footer-links {
        justify-content: flex-start;
    }
}

@media (max-width: 560px) {
    .header-inner,
    .page-shell,
    .footer-inner,
    .mobile-panel {
        width: min(100% - 22px, 1240px);
    }

    .site-logo-text {
        font-size: 1.28rem;
    }

    .hero-section {
        padding-top: 18px;
    }

    .hero-slider {
        border-radius: 22px;
        min-height: 640px;
    }

    .hero-content {
        min-height: 640px;
        padding: 28px 18px 74px;
    }

    .hero-title {
        font-size: 2.45rem;
    }

    .hero-copy {
        font-size: 0.98rem;
    }

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

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

    .page-hero {
        padding: 26px 20px;
        border-radius: 22px;
    }

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

    .rank-item .btn-soft {
        grid-column: 1 / -1;
    }

    .detail-content,
    .text-card {
        padding: 20px;
    }
}
