:root {
    --stone-50: #faf8f3;
    --stone-100: #f2ece2;
    --stone-200: #e6dacb;
    --stone-500: #8b7a68;
    --stone-700: #4f453b;
    --earth-700: #4a3329;
    --earth-800: #3a2821;
    --earth-900: #211713;
    --bronze-300: #e8c47d;
    --bronze-400: #d6a85d;
    --bronze-500: #b77c2f;
    --ink: #231c18;
    --white: #ffffff;
    --shadow-soft: 0 20px 60px rgba(42, 28, 20, 0.12);
    --shadow-card: 0 18px 35px rgba(45, 33, 25, 0.14);
    --radius-xl: 28px;
    --radius-lg: 22px;
    --radius-md: 16px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background:
        radial-gradient(circle at 12% 5%, rgba(214, 168, 93, 0.22), transparent 28rem),
        linear-gradient(180deg, #fffaf0 0%, var(--stone-50) 38%, #f4ede2 100%);
    min-height: 100vh;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(58, 40, 33, 0.94);
    backdrop-filter: blur(18px);
    color: var(--stone-50);
    box-shadow: 0 12px 35px rgba(33, 23, 19, 0.24);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: var(--earth-900);
    background: linear-gradient(135deg, var(--bronze-300), var(--bronze-500));
    box-shadow: 0 12px 28px rgba(214, 168, 93, 0.28);
}

.brand-name {
    font-size: 1.25rem;
}

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

.nav-link {
    padding: 10px 16px;
    border-radius: 999px;
    color: rgba(250, 248, 243, 0.78);
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--earth-900);
    background: var(--bronze-300);
    transform: translateY(-1px);
}

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

.menu-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    border-radius: 999px;
    background: var(--stone-50);
}

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

.hero {
    position: relative;
    min-height: 620px;
    margin: 0 auto 54px;
    overflow: hidden;
    border-radius: 0 0 34px 34px;
    color: var(--white);
    background: var(--earth-900);
    box-shadow: 0 30px 80px rgba(33, 23, 19, 0.28);
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
    transition: transform 6s ease;
}

.hero-slide.active img {
    transform: scale(1.1);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(33, 23, 19, 0.94) 0%, rgba(58, 40, 33, 0.78) 42%, rgba(33, 23, 19, 0.18) 100%),
        linear-gradient(0deg, rgba(33, 23, 19, 0.75), transparent 48%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 620px;
    margin: 0 auto;
    display: grid;
    align-content: center;
    max-width: 700px;
    padding: 96px 0 86px;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--bronze-300);
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero h1 {
    margin: 0;
    font-size: clamp(2.4rem, 7vw, 5.8rem);
    line-height: 0.95;
    letter-spacing: -0.06em;
}

.hero p {
    max-width: 620px;
    margin: 20px 0 0;
    color: rgba(255, 255, 255, 0.84);
    font-size: 1.08rem;
    line-height: 1.8;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 999px;
    font-weight: 800;
    border: 1px solid transparent;
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    color: var(--earth-900);
    background: linear-gradient(135deg, var(--bronze-300), var(--bronze-500));
    box-shadow: 0 16px 34px rgba(214, 168, 93, 0.34);
}

.btn-ghost {
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

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

.hero-dot {
    width: 32px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.35);
    cursor: pointer;
}

.hero-dot.active {
    background: var(--bronze-300);
}

.hero-side {
    position: absolute;
    right: max(24px, calc((100vw - 1180px) / 2));
    bottom: 84px;
    z-index: 3;
    width: min(350px, 34vw);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius-xl);
    padding: 18px;
    color: var(--white);
    background: rgba(33, 23, 19, 0.52);
    backdrop-filter: blur(18px);
    box-shadow: 0 22px 65px rgba(0, 0, 0, 0.26);
}

.hero-side h3 {
    margin: 0 0 12px;
}

.hero-mini-list {
    display: grid;
    gap: 10px;
}

.hero-mini-list a {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.1);
    transition: background 0.25s ease;
}

.hero-mini-list a:hover {
    background: rgba(232, 196, 125, 0.22);
}

.search-panel {
    margin: -32px auto 52px;
    width: min(980px, calc(100% - 32px));
    position: relative;
    z-index: 5;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding: 14px;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(18px);
}

.search-panel input,
.filter-bar input,
.filter-bar select {
    width: 100%;
    height: 52px;
    border: 1px solid var(--stone-200);
    border-radius: 18px;
    padding: 0 18px;
    color: var(--ink);
    background: var(--white);
    outline: none;
    font-size: 1rem;
}

.search-panel input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--bronze-400);
    box-shadow: 0 0 0 4px rgba(214, 168, 93, 0.18);
}

.section {
    margin: 0 0 58px;
}

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

.section-head h2 {
    margin: 0;
    font-size: clamp(1.7rem, 4vw, 2.7rem);
    letter-spacing: -0.04em;
}

.section-head p:not(.eyebrow) {
    margin: 8px 0 0;
    color: var(--stone-500);
    line-height: 1.8;
}

.section-link {
    flex: 0 0 auto;
    color: var(--earth-700);
    font-weight: 800;
    padding: 12px 18px;
    border-radius: 999px;
    background: var(--stone-100);
}

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

.category-tile {
    min-height: 178px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
    border-radius: var(--radius-lg);
    color: var(--white);
    background:
        radial-gradient(circle at 20% 12%, rgba(232, 196, 125, 0.34), transparent 10rem),
        linear-gradient(135deg, var(--earth-800), #6d4b35);
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
    transform: translateY(-5px);
    box-shadow: 0 28px 60px rgba(45, 33, 25, 0.22);
}

.category-tile strong {
    font-size: 1.22rem;
}

.category-tile span,
.category-tile p {
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.7;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(230, 218, 203, 0.72);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 28px 60px rgba(45, 33, 25, 0.2);
}

.poster {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, var(--earth-800), var(--bronze-500));
}

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

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

.year-badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    top: 12px;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 0.78rem;
    font-weight: 800;
}

.year-badge {
    right: 12px;
    color: var(--earth-900);
    background: var(--bronze-300);
}

.rank-badge {
    left: 12px;
    color: var(--white);
    background: rgba(33, 23, 19, 0.78);
}

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

.movie-card-title {
    display: -webkit-box;
    overflow: hidden;
    min-height: 3em;
    color: var(--ink);
    font-size: 1.08rem;
    font-weight: 900;
    line-height: 1.5;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-meta {
    margin: 10px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--stone-500);
    font-size: 0.9rem;
}

.movie-meta span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.movie-meta span + span::before {
    content: "";
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--bronze-400);
}

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

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

.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    color: var(--earth-700);
    background: var(--stone-100);
    font-size: 0.82rem;
    font-weight: 700;
}

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

.rank-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 14px;
    align-items: center;
    padding: 16px;
    border: 1px solid rgba(230, 218, 203, 0.78);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 12px 28px rgba(45, 33, 25, 0.08);
}

.rank-num {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 13px;
    color: var(--earth-900);
    background: var(--bronze-300);
    font-weight: 900;
}

.rank-title {
    display: grid;
    gap: 4px;
}

.rank-title strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-title span,
.rank-score {
    color: var(--stone-500);
    font-size: 0.9rem;
}

.page-hero {
    margin-bottom: 34px;
    padding: 34px;
    border-radius: var(--radius-xl);
    color: var(--white);
    background:
        radial-gradient(circle at 8% 12%, rgba(232, 196, 125, 0.28), transparent 18rem),
        linear-gradient(135deg, var(--earth-800), var(--earth-900));
    box-shadow: var(--shadow-card);
}

.page-hero h1 {
    margin: 0;
    font-size: clamp(2rem, 5vw, 4rem);
    letter-spacing: -0.05em;
}

.page-hero p {
    max-width: 760px;
    margin: 14px 0 0;
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.8;
}

.breadcrumb {
    margin-bottom: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.92rem;
}

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

.breadcrumb .sep {
    color: rgba(255, 255, 255, 0.38);
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 180px;
    gap: 12px;
    margin-bottom: 26px;
    padding: 14px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--shadow-soft);
}

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

.detail-card,
.player-card,
.related-card {
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(230, 218, 203, 0.72);
    box-shadow: var(--shadow-card);
}

.detail-card {
    overflow: hidden;
}

.detail-poster {
    aspect-ratio: 16 / 8;
    background: linear-gradient(135deg, var(--earth-800), var(--bronze-500));
}

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

.detail-body {
    padding: 28px;
}

.detail-body h1 {
    margin: 0 0 16px;
    font-size: clamp(2rem, 5vw, 3.4rem);
    letter-spacing: -0.06em;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin: 22px 0;
}

.info-item {
    padding: 14px;
    border-radius: 16px;
    background: var(--stone-100);
}

.info-item span {
    display: block;
    color: var(--stone-500);
    font-size: 0.84rem;
    margin-bottom: 6px;
}

.info-item strong {
    color: var(--ink);
}

.text-block {
    margin-top: 26px;
}

.text-block h2 {
    margin: 0 0 12px;
    font-size: 1.35rem;
}

.text-block p {
    margin: 0;
    color: var(--stone-700);
    line-height: 1.9;
}

.player-card {
    overflow: hidden;
    position: sticky;
    top: 98px;
}

.player-head {
    padding: 18px 20px;
    color: var(--white);
    background: linear-gradient(135deg, var(--earth-800), var(--earth-900));
}

.player-head h2 {
    margin: 0;
    font-size: 1.2rem;
}

.player-shell {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #080605;
}

.player-shell video {
    width: 100%;
    height: 100%;
    display: block;
    background: #080605;
}

.player-action {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: var(--white);
    background: radial-gradient(circle at center, rgba(214, 168, 93, 0.22), rgba(8, 6, 5, 0.7));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-action span {
    width: 82px;
    height: 82px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--earth-900);
    background: linear-gradient(135deg, var(--bronze-300), var(--bronze-500));
    box-shadow: 0 18px 45px rgba(214, 168, 93, 0.28);
    font-size: 1.6rem;
    font-weight: 900;
}

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

.related-card {
    margin-top: 18px;
    padding: 20px;
}

.related-card h2 {
    margin: 0 0 16px;
    font-size: 1.25rem;
}

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

.related-item {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    align-items: center;
}

.related-item img {
    width: 72px;
    height: 96px;
    object-fit: cover;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--earth-800), var(--bronze-500));
}

.related-item strong {
    display: -webkit-box;
    overflow: hidden;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.related-item span {
    display: block;
    margin-top: 6px;
    color: var(--stone-500);
    font-size: 0.9rem;
}

.site-footer {
    color: rgba(250, 248, 243, 0.78);
    background: var(--earth-900);
}

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

.footer-brand strong {
    color: var(--bronze-300);
    font-size: 1.25rem;
}

.footer-brand p {
    max-width: 620px;
    line-height: 1.8;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(2, auto);
    gap: 12px 24px;
}

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

.copyright {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 20px 0 28px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: rgba(250, 248, 243, 0.58);
    font-size: 0.92rem;
}

.empty-state {
    display: none;
    padding: 36px;
    border-radius: var(--radius-lg);
    color: var(--stone-500);
    background: rgba(255, 255, 255, 0.82);
    text-align: center;
}

@media (max-width: 980px) {
    .main-nav {
        position: absolute;
        top: 74px;
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 14px;
        border-radius: 22px;
        background: var(--earth-800);
        box-shadow: var(--shadow-card);
    }

    .main-nav.open {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }

    .hero-side {
        display: none;
    }

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

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

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

    .player-card {
        position: static;
    }

    .filter-bar {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .site-header-inner,
    .page-main,
    .hero-content,
    .search-panel,
    .footer-inner,
    .copyright {
        width: min(100% - 24px, 1180px);
    }

    .hero {
        border-radius: 0 0 24px 24px;
    }

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

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

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

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

    .rank-score {
        grid-column: 2;
    }

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

    .detail-body,
    .page-hero {
        padding: 22px;
    }
}
