:root {
    --ancient-950: #2b2419;
    --ancient-900: #423a2c;
    --ancient-850: #4d3d2f;
    --ancient-800: #5a4d39;
    --ancient-700: #6f5f47;
    --ancient-500: #a89571;
    --ancient-400: #c4b49a;
    --ancient-300: #d9cfbd;
    --ancient-200: #e8e2d6;
    --ancient-100: #f5f2ed;
    --amber-500: #f59e0b;
    --amber-400: #fbbf24;
    --amber-300: #fcd34d;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ancient-100);
    background:
        radial-gradient(circle at 15% 0%, rgba(245, 158, 11, 0.12), transparent 36rem),
        radial-gradient(circle at 92% 18%, rgba(168, 149, 113, 0.14), transparent 30rem),
        var(--ancient-950);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(90, 77, 57, 0.8);
    background: rgba(43, 36, 25, 0.92);
    backdrop-filter: blur(18px);
}

.nav-wrap {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 72px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.logo span {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--ancient-950);
    font-weight: 800;
    background: linear-gradient(135deg, var(--amber-400), var(--amber-500));
    box-shadow: 0 10px 28px rgba(245, 158, 11, 0.28);
}

.logo strong {
    font-size: 20px;
    color: var(--amber-400);
    letter-spacing: 0.03em;
}

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

.main-nav a {
    color: var(--ancient-300);
    font-weight: 600;
    transition: color 0.2s ease;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--amber-400);
}

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

.top-search input,
.search-band input,
.filter-bar input,
.filter-bar select {
    width: 220px;
    border: 1px solid var(--ancient-700);
    border-radius: 12px;
    padding: 11px 14px;
    color: var(--ancient-100);
    outline: none;
    background: rgba(66, 58, 44, 0.5);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.top-search input:focus,
.search-band input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--amber-500);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

.top-search button,
.search-band button,
.btn {
    border: 0;
    border-radius: 12px;
    padding: 11px 18px;
    font-weight: 700;
    cursor: pointer;
}

.top-search button,
.btn.primary,
.search-band button {
    color: var(--ancient-950);
    background: linear-gradient(135deg, var(--amber-400), var(--amber-500));
}

.btn.ghost {
    color: var(--amber-300);
    border: 1px solid rgba(245, 158, 11, 0.35);
    background: rgba(66, 58, 44, 0.5);
}

.btn.small {
    padding: 9px 14px;
    white-space: nowrap;
}

.menu-toggle {
    display: none;
    margin-left: auto;
    border: 1px solid var(--ancient-700);
    border-radius: 10px;
    color: var(--ancient-100);
    background: rgba(66, 58, 44, 0.55);
    font-size: 22px;
    padding: 7px 12px;
}

.hero-carousel {
    position: relative;
    min-height: 72vh;
    overflow: hidden;
}

.hero-slide {
    min-height: 72vh;
    display: none;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
    padding: 72px max(28px, calc((100vw - 1280px) / 2)) 84px;
    background-size: cover;
    background-position: center;
}

.hero-slide.active {
    display: flex;
    animation: fadeIn 0.65s ease both;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(1.01);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.hero-content {
    width: min(720px, 100%);
}

.eyebrow {
    display: inline-flex;
    margin-bottom: 16px;
    color: var(--amber-300);
    font-weight: 800;
    letter-spacing: 0.18em;
}

.hero-content h1,
.page-hero h1,
.detail-copy h1 {
    margin: 0;
    font-family: "Noto Serif SC", "Songti SC", serif;
    font-size: clamp(34px, 5vw, 70px);
    line-height: 1.08;
    color: var(--ancient-100);
}

.hero-content h2 {
    margin: 18px 0 12px;
    font-size: clamp(26px, 3vw, 42px);
    color: var(--amber-400);
}

.hero-content p,
.page-hero p,
.detail-copy p {
    color: var(--ancient-300);
    line-height: 1.8;
    font-size: 18px;
}

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

.hero-tags span,
.tag-list span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 6px 10px;
    color: var(--amber-300);
    border: 1px solid rgba(245, 158, 11, 0.25);
    background: rgba(245, 158, 11, 0.1);
    font-size: 13px;
}

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

.hero-poster {
    width: min(300px, 30vw);
    aspect-ratio: 3 / 4;
    border-radius: 24px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--ancient-900), var(--ancient-800));
    box-shadow: var(--shadow);
    border: 1px solid rgba(245, 158, 11, 0.24);
    transform: rotate(2deg);
}

.hero-poster img,
.detail-poster img,
.poster-frame img,
.rank-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-dots {
    position: absolute;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.hero-dots button {
    width: 32px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(232, 226, 214, 0.32);
    cursor: pointer;
}

.hero-dots button.active {
    background: var(--amber-400);
}

.container,
.search-band,
.page-hero,
.detail-hero-grid,
.footer-inner {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
}

.search-band {
    margin-top: -34px;
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: 1fr minmax(280px, 520px);
    gap: 24px;
    align-items: center;
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 22px;
    padding: 26px;
    background: linear-gradient(135deg, rgba(66, 58, 44, 0.92), rgba(43, 36, 25, 0.96));
    box-shadow: var(--shadow);
}

.search-band h2,
.section-title h2,
.rank-panel h2,
.article-panel h2 {
    margin: 0;
    color: var(--amber-400);
    font-family: "Noto Serif SC", "Songti SC", serif;
}

.search-band p,
.section-title p,
.movie-card p,
.rank-panel em,
.article-panel p {
    color: var(--ancient-400);
    line-height: 1.75;
}

.search-band form {
    display: flex;
    gap: 10px;
}

.search-band input {
    width: 100%;
}

.container {
    padding: 64px 0 0;
}

.section-title {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 24px;
}

.section-title span {
    width: 5px;
    height: 36px;
    margin-top: 3px;
    border-radius: 999px;
    background: var(--amber-500);
}

.section-title h2 {
    font-size: 30px;
}

.section-title p {
    margin: 6px 0 0;
}

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

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

.movie-card {
    border: 1px solid rgba(90, 77, 57, 0.75);
    border-radius: var(--radius);
    overflow: hidden;
    background: rgba(66, 58, 44, 0.34);
    transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    border-color: rgba(245, 158, 11, 0.42);
    background: rgba(66, 58, 44, 0.56);
}

.poster-frame {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    background: linear-gradient(135deg, var(--ancient-900), var(--ancient-800));
}

.poster-badge {
    position: absolute;
    right: 10px;
    top: 10px;
    border-radius: 999px;
    padding: 5px 9px;
    color: var(--ancient-950);
    background: var(--amber-400);
    font-weight: 800;
    font-size: 12px;
}

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

.movie-meta-line,
.detail-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    color: var(--ancient-500);
    font-size: 13px;
}

.movie-card h3 {
    margin: 8px 0;
    color: var(--ancient-100);
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h3 a:hover,
.rank-row h2 a:hover,
.text-links a:hover {
    color: var(--amber-400);
}

.movie-card p {
    min-height: 48px;
    margin: 0 0 12px;
    font-size: 14px;
}

.split-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 28px;
}

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

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

.category-tile {
    min-height: 150px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    gap: 8px;
    border-radius: 20px;
    padding: 22px;
    overflow: hidden;
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(245, 158, 11, 0.22);
    box-shadow: inset 0 -48px 90px rgba(0, 0, 0, 0.26);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile:hover {
    transform: translateY(-4px);
    border-color: rgba(245, 158, 11, 0.55);
}

.category-tile span {
    color: var(--amber-400);
    font-size: 22px;
    font-weight: 800;
}

.category-tile strong {
    color: var(--ancient-300);
    line-height: 1.5;
}

.rank-panel {
    position: sticky;
    top: 96px;
    align-self: start;
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 22px;
    padding: 22px;
    background: linear-gradient(180deg, rgba(66, 58, 44, 0.72), rgba(43, 36, 25, 0.95));
}

.rank-panel a {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid rgba(90, 77, 57, 0.55);
}

.rank-panel span,
.rank-num {
    color: var(--amber-400);
    font-weight: 900;
}

.more-link {
    border-bottom: 0 !important;
    color: var(--amber-300);
}

.page-main {
    padding-bottom: 72px;
}

.page-hero {
    margin-top: 36px;
    padding: 58px;
    border: 1px solid rgba(245, 158, 11, 0.22);
    border-radius: 28px;
    background:
        linear-gradient(135deg, rgba(66, 58, 44, 0.82), rgba(43, 36, 25, 0.92)),
        radial-gradient(circle at 70% 30%, rgba(245, 158, 11, 0.18), transparent 22rem);
    box-shadow: var(--shadow);
}

.page-hero.small-hero h1 {
    font-size: clamp(34px, 4vw, 56px);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-bottom: 22px;
    color: var(--ancient-400);
}

.breadcrumb a {
    color: var(--amber-300);
}

.filter-bar {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}

.filter-bar.full input {
    min-width: min(520px, 100%);
}

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

.rank-row {
    display: grid;
    grid-template-columns: 64px 86px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 14px;
}

.rank-cover {
    width: 86px;
    aspect-ratio: 3 / 4;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--ancient-900), var(--ancient-800));
}

.rank-row h2 {
    margin: 0 0 8px;
    color: var(--ancient-100);
    font-size: 22px;
}

.rank-row p {
    margin: 0 0 10px;
}

.detail-hero {
    padding: 40px 0 72px;
    background-size: cover;
    background-position: center;
}

.detail-hero-grid {
    display: grid;
    grid-template-columns: 310px 1fr;
    gap: 44px;
    align-items: center;
}

.detail-poster {
    aspect-ratio: 3 / 4;
    border-radius: 24px;
    overflow: hidden;
    background: linear-gradient(135deg, var(--ancient-900), var(--ancient-800));
    box-shadow: var(--shadow);
    border: 1px solid rgba(245, 158, 11, 0.28);
}

.detail-copy h1 {
    font-size: clamp(34px, 4vw, 64px);
}

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

.detail-meta span,
.detail-meta a {
    border-radius: 999px;
    padding: 7px 12px;
    background: rgba(66, 58, 44, 0.72);
    border: 1px solid rgba(90, 77, 57, 0.86);
}

.detail-tags {
    margin-top: 12px;
}

.detail-content {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(320px, 0.82fr);
    gap: 28px;
}

.player-panel,
.article-panel {
    border: 1px solid rgba(90, 77, 57, 0.75);
    border-radius: 24px;
    padding: 18px;
    background: rgba(66, 58, 44, 0.38);
}

.video-shell {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    background: #000;
    aspect-ratio: 16 / 9;
}

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

.play-layer {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: var(--ancient-950);
    background: radial-gradient(circle, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.54));
}

.play-layer span {
    width: 78px;
    height: 78px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--amber-400);
    box-shadow: 0 18px 42px rgba(245, 158, 11, 0.35);
    font-size: 30px;
    padding-left: 5px;
}

.video-shell.playing .play-layer {
    opacity: 0;
    pointer-events: none;
}

.article-panel {
    padding: 28px;
}

.article-panel h2 {
    margin: 0 0 12px;
    font-size: 24px;
}

.article-panel p {
    margin: 0 0 24px;
    color: var(--ancient-300);
}

.text-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.text-links a {
    border: 1px solid rgba(245, 158, 11, 0.26);
    border-radius: 999px;
    padding: 8px 12px;
    color: var(--amber-300);
    background: rgba(245, 158, 11, 0.08);
}

.site-footer {
    margin-top: 80px;
    border-top: 1px solid rgba(90, 77, 57, 0.8);
    background: rgba(43, 36, 25, 0.82);
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr 1.6fr;
    gap: 28px;
    padding: 36px 0;
}

.footer-inner strong {
    color: var(--amber-400);
    font-size: 22px;
}

.footer-inner p {
    color: var(--ancient-400);
    line-height: 1.7;
}

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

.footer-links a {
    color: var(--ancient-300);
}

.footer-links a:hover {
    color: var(--amber-400);
}

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

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

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

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

    .rank-panel {
        position: static;
    }
}

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

    .menu-toggle {
        display: block;
    }

    .main-nav,
    .top-search {
        width: 100%;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding-bottom: 16px;
    }

    .site-header.open .main-nav,
    .site-header.open .top-search {
        display: flex;
    }

    .top-search input {
        width: 100%;
    }

    .hero-slide {
        min-height: auto;
        padding-top: 50px;
        padding-bottom: 74px;
        flex-direction: column;
        align-items: flex-start;
    }

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

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

    .search-band form {
        flex-direction: column;
    }

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

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

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

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

    .rank-row .btn {
        grid-column: 2 / 4;
        text-align: center;
    }

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

    .detail-poster {
        width: min(270px, 78vw);
    }

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

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

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

    .filter-bar,
    .hero-actions {
        flex-direction: column;
    }

    .filter-bar input,
    .filter-bar select,
    .btn {
        width: 100%;
    }
}
