:root {
    --bg: #fff7ed;
    --bg-soft: #fffbeb;
    --text: #1f2937;
    --muted: #6b7280;
    --line: rgba(148, 163, 184, 0.28);
    --card: rgba(255, 255, 255, 0.92);
    --amber: #d97706;
    --orange: #ea580c;
    --dark: #111827;
    --shadow: 0 20px 60px rgba(146, 64, 14, 0.12);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--text);
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 38%, #fff7ed 100%);
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, rgba(255, 251, 235, 0.96), rgba(255, 237, 213, 0.96));
    border-bottom: 1px solid rgba(217, 119, 6, 0.14);
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 30px rgba(146, 64, 14, 0.08);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 900;
    white-space: nowrap;
    background: linear-gradient(90deg, var(--amber), var(--orange));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 10px 24px rgba(217, 119, 6, 0.24);
}

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

.main-nav a {
    padding: 10px 14px;
    border-radius: 999px;
    color: #4b5563;
    font-weight: 700;
    transition: 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 12px 26px rgba(217, 119, 6, 0.18);
}

.top-search,
.mobile-panel form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.top-search input,
.mobile-panel input,
.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid rgba(217, 119, 6, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.82);
    padding: 12px 16px;
    color: var(--text);
    outline: none;
    transition: 0.2s ease;
}

.top-search input {
    width: 220px;
}

.top-search input:focus,
.mobile-panel input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
    border-color: rgba(217, 119, 6, 0.7);
    box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.12);
}

button,
.btn-primary,
.btn-secondary,
.section-head a,
.category-overview-top a {
    cursor: pointer;
    border: 0;
    border-radius: 999px;
    font-weight: 800;
}

.top-search button,
.mobile-panel button,
.filter-panel button,
.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    padding: 12px 18px;
    box-shadow: 0 14px 28px rgba(217, 119, 6, 0.22);
}

.btn-secondary {
    color: #ffffff;
    padding: 12px 18px;
    background: rgba(17, 24, 39, 0.56);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(10px);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(217, 119, 6, 0.18);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    width: 20px;
    height: 2px;
    background: var(--amber);
    border-radius: 999px;
}

.mobile-panel {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
}

.mobile-panel a {
    display: block;
    padding: 12px 8px;
    color: #374151;
    font-weight: 800;
}

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

.hero-shell {
    position: relative;
    min-height: 680px;
    overflow: hidden;
    background: radial-gradient(circle at top left, rgba(251, 191, 36, 0.32), transparent 34%), linear-gradient(135deg, #111827, #7c2d12 58%, #f97316);
}

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

.hero-slide {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.72s ease, visibility 0.72s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
}

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.05) contrast(1.08);
    transform: scale(1.05);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(17, 24, 39, 0.92), rgba(17, 24, 39, 0.55), rgba(124, 45, 18, 0.34)), linear-gradient(0deg, rgba(17, 24, 39, 0.55), transparent 40%);
}

.hero-inner {
    position: relative;
    z-index: 2;
    min-height: 680px;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 58px;
    align-items: center;
    padding: 86px 0 72px;
}

.hero-copy {
    color: #ffffff;
}

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

.hero-copy h1 {
    margin: 18px 0;
    font-size: clamp(42px, 7vw, 86px);
    line-height: 0.95;
    letter-spacing: -0.06em;
    max-width: 780px;
}

.hero-copy p {
    max-width: 680px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.84);
    font-size: 18px;
    line-height: 1.85;
}

.hero-tags,
.detail-tags,
.genre-list,
.movie-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.detail-tags span,
.genre-list span,
.movie-tags span {
    display: inline-flex;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 13px;
    font-weight: 800;
}

.movie-tags span {
    color: #92400e;
    background: #fffbeb;
    border-color: rgba(217, 119, 6, 0.14);
}

.hero-actions,
.detail-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 28px;
}

.hero-poster {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 30px;
    min-height: 480px;
    background: rgba(255, 255, 255, 0.14);
    box-shadow: 0 34px 100px rgba(0, 0, 0, 0.38);
    border: 1px solid rgba(255, 255, 255, 0.24);
    transform: rotate(1deg);
}

.hero-poster img {
    width: 100%;
    height: 480px;
    object-fit: cover;
}

.hero-poster strong {
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 20px;
    color: #ffffff;
    font-size: 24px;
    text-shadow: 0 10px 24px rgba(0, 0, 0, 0.58);
}

.hero-control {
    position: absolute;
    z-index: 5;
    top: 50%;
    width: 48px;
    height: 48px;
    transform: translateY(-50%);
    border-radius: 999px;
    color: #ffffff;
    background: rgba(17, 24, 39, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-size: 38px;
    line-height: 1;
    backdrop-filter: blur(12px);
}

.hero-control.prev {
    left: 28px;
}

.hero-control.next {
    right: 28px;
}

.hero-dots {
    position: absolute;
    z-index: 5;
    bottom: 34px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 9px;
}

.hero-dots button {
    width: 12px;
    height: 12px;
    padding: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.48);
    transition: 0.2s ease;
}

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

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

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

.section-head h2,
.page-hero h1,
.story-card h2,
.info-card h2 {
    margin: 8px 0 0;
    color: var(--dark);
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.section-head p,
.page-hero p {
    max-width: 720px;
    color: var(--muted);
    line-height: 1.8;
    margin: 12px 0 0;
}

.section-head a,
.category-overview-top a {
    color: var(--amber);
    background: #fffbeb;
    border: 1px solid rgba(217, 119, 6, 0.16);
    padding: 11px 16px;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--card);
    border: 1px solid rgba(217, 119, 6, 0.12);
    box-shadow: var(--shadow);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 28px 70px rgba(146, 64, 14, 0.18);
}

.movie-cover {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fef3c7, #fdba74);
}

.movie-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.42s ease;
}

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

.movie-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    color: #ffffff;
    background: rgba(17, 24, 39, 0.72);
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 900;
    backdrop-filter: blur(8px);
}

.movie-body {
    padding: 16px;
}

.movie-body h3 {
    margin: 12px 0 8px;
    font-size: 18px;
    line-height: 1.35;
}

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

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

.movie-meta,
.rank-card-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 14px;
    color: #9a3412;
    font-size: 13px;
    font-weight: 800;
}

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

.category-tile,
.category-overview-card,
.story-card,
.info-card,
.rank-panel,
.filter-panel {
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(217, 119, 6, 0.12);
    box-shadow: var(--shadow);
}

.category-tile {
    position: relative;
    min-height: 248px;
    padding: 22px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    color: #ffffff;
}

.category-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(17, 24, 39, 0.88), rgba(17, 24, 39, 0.25));
}

.category-tile img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-tile span,
.category-tile p {
    position: relative;
    z-index: 1;
}

.category-tile span {
    font-size: 24px;
    font-weight: 900;
}

.category-tile p {
    margin: 10px 0 0;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
    font-size: 14px;
}

.rank-panel {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
    padding: 18px;
}

.rank-item {
    display: grid;
    grid-template-columns: auto 54px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 18px;
    background: #fffbeb;
    border: 1px solid rgba(217, 119, 6, 0.12);
}

.rank-no {
    color: var(--orange);
    font-size: 18px;
    font-weight: 900;
}

.rank-item img {
    width: 54px;
    height: 72px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-title {
    font-weight: 900;
    line-height: 1.4;
}

.rank-item em {
    color: #92400e;
    font-style: normal;
    font-weight: 900;
}

.page-hero {
    position: relative;
    overflow: hidden;
    padding: 108px max(16px, calc((100% - 1180px) / 2)) 76px;
    background: radial-gradient(circle at 20% 0%, rgba(251, 191, 36, 0.34), transparent 34%), linear-gradient(135deg, #fff7ed, #ffedd5);
}

.page-hero::after {
    content: "";
    position: absolute;
    right: 8%;
    top: 20%;
    width: 240px;
    height: 240px;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(217, 119, 6, 0.2), rgba(249, 115, 22, 0.1));
    filter: blur(4px);
}

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

.category-overview-card {
    padding: 24px;
}

.category-overview-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.category-overview-card h2 {
    margin: 0;
}

.category-overview-card p {
    color: var(--muted);
    line-height: 1.8;
}

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

.mini-card {
    display: block;
    overflow: hidden;
    border-radius: 16px;
    background: #fffbeb;
}

.mini-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.mini-card span {
    display: block;
    padding: 10px;
    font-weight: 800;
    font-size: 13px;
    line-height: 1.35;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1fr 190px auto;
    gap: 12px;
    padding: 16px;
    margin-bottom: 24px;
}

.wide-filter {
    grid-template-columns: 1fr 180px 160px auto;
}

.empty-state {
    display: none;
    padding: 40px;
    text-align: center;
    color: var(--muted);
    background: #ffffff;
    border-radius: var(--radius);
    border: 1px solid rgba(217, 119, 6, 0.12);
}

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

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

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

.rank-card {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 18px;
    padding: 16px;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow);
    border: 1px solid rgba(217, 119, 6, 0.12);
}

.rank-card-cover {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 18px;
}

.rank-card-cover img {
    width: 120px;
    height: 160px;
    object-fit: cover;
}

.rank-card-cover span {
    position: absolute;
    top: 10px;
    left: 10px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    border-radius: 999px;
    padding: 6px 10px;
    font-weight: 900;
}

.rank-card-title {
    font-size: 22px;
    font-weight: 900;
}

.rank-card p {
    color: var(--muted);
    line-height: 1.7;
}

.detail-hero {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    background: #111827;
}

.detail-bg,
.detail-overlay {
    position: absolute;
    inset: 0;
}

.detail-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(8px) saturate(1.04);
    transform: scale(1.08);
}

.detail-overlay {
    background: linear-gradient(90deg, rgba(17, 24, 39, 0.94), rgba(17, 24, 39, 0.68), rgba(124, 45, 18, 0.28));
}

.detail-wrap {
    position: relative;
    z-index: 1;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 54px 0 70px;
}

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

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

.detail-grid {
    display: grid;
    grid-template-columns: 330px 1fr;
    gap: 46px;
    align-items: center;
}

.detail-poster {
    overflow: hidden;
    border-radius: 30px;
    box-shadow: 0 30px 90px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

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

.detail-info {
    color: #ffffff;
}

.detail-info h1 {
    margin: 16px 0;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1;
    letter-spacing: -0.055em;
}

.detail-info p {
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.85;
    font-size: 18px;
    max-width: 760px;
}

.player-section {
    margin-top: -86px;
    position: relative;
    z-index: 4;
}

.player-frame {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #000000;
    box-shadow: 0 34px 100px rgba(0, 0, 0, 0.24);
    border: 1px solid rgba(217, 119, 6, 0.16);
    aspect-ratio: 16 / 9;
}

.player-frame video {
    position: relative;
    z-index: 1;
    width: 100%;
    height: 100%;
    display: block;
    background: #000000;
}

.player-poster {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    transition: opacity 0.24s ease, visibility 0.24s ease;
}

.player-poster img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.62;
}

.play-cta {
    position: relative;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #ffffff;
    padding: 18px 26px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 24px 60px rgba(217, 119, 6, 0.34);
    font-size: 18px;
}

.play-cta span {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.22);
}

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

.detail-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 330px;
    gap: 22px;
}

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

.story-card p,
.info-card dd {
    color: var(--muted);
    line-height: 1.85;
}

.info-card dl {
    margin: 16px 0;
}

.info-card div {
    margin-bottom: 12px;
}

.info-card dt {
    color: #92400e;
    font-weight: 900;
    margin-bottom: 4px;
}

.info-card dd {
    margin: 0;
}

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

.site-footer {
    margin-top: 48px;
    padding: 48px 0;
    color: #d1d5db;
    background: linear-gradient(135deg, #111827, #431407);
}

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

.footer-logo {
    color: #fbbf24;
    font-size: 28px;
    font-weight: 900;
    margin-bottom: 12px;
}

.site-footer p {
    max-width: 520px;
    line-height: 1.8;
}

.site-footer h3 {
    color: #fbbf24;
    margin: 0 0 14px;
}

.site-footer a {
    display: block;
    margin: 10px 0;
    color: #e5e7eb;
}

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

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

    .menu-toggle {
        display: inline-flex;
    }

    .hero-inner,
    .detail-grid {
        grid-template-columns: 1fr;
    }

    .hero-poster {
        display: none;
    }

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

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

    .rank-panel,
    .rank-list,
    .detail-content-grid,
    .category-overview-grid {
        grid-template-columns: 1fr;
    }
}

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

    .brand {
        font-size: 20px;
    }

    .hero-shell,
    .hero-inner {
        min-height: 580px;
    }

    .hero-inner {
        padding: 64px 0 70px;
    }

    .hero-control {
        display: none;
    }

    .hero-copy h1,
    .detail-info h1 {
        font-size: 42px;
    }

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

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

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

    .rank-item {
        grid-template-columns: auto 48px 1fr;
    }

    .rank-item em {
        display: none;
    }

    .filter-panel,
    .wide-filter {
        grid-template-columns: 1fr;
    }

    .rank-card {
        grid-template-columns: 88px 1fr;
        gap: 14px;
    }

    .rank-card-cover img {
        width: 88px;
        height: 120px;
    }

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

    .player-section {
        margin-top: -42px;
    }

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

@media (max-width: 480px) {
    .movie-grid,
    .compact-grid,
    .related-grid,
    .category-grid,
    .mini-grid {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .detail-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        text-align: center;
    }
}
