:root {
    --stone-950: #1c1917;
    --stone-900: #292524;
    --stone-800: #44403c;
    --stone-700: #57534e;
    --stone-600: #78716c;
    --stone-500: #a8a29e;
    --stone-300: #d6d3d1;
    --stone-200: #e7e5e4;
    --stone-100: #f5f5f4;
    --stone-50: #fafaf9;
    --amber-700: #b45309;
    --amber-600: #d97706;
    --amber-500: #f59e0b;
    --amber-300: #fcd34d;
    --white: #ffffff;
    --shadow: 0 20px 50px rgba(28, 25, 23, 0.16);
    --soft-shadow: 0 12px 28px rgba(28, 25, 23, 0.12);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans SC", Arial, sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--stone-900);
    background: linear-gradient(180deg, var(--stone-50), var(--stone-100));
    min-width: 320px;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    color: var(--white);
    background: linear-gradient(90deg, var(--stone-900), var(--stone-800), var(--stone-900));
    box-shadow: 0 10px 30px rgba(28, 25, 23, 0.26);
}

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

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 178px;
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: var(--stone-900);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    box-shadow: 0 10px 26px rgba(245, 158, 11, 0.3);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 20px;
    letter-spacing: 0.04em;
}

.brand-text em {
    margin-top: 3px;
    color: var(--stone-300);
    font-size: 12px;
    font-style: normal;
}

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

.nav-link {
    padding: 10px 14px;
    border-radius: 12px;
    color: #f5f5f4;
    white-space: nowrap;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--white);
    background: rgba(245, 158, 11, 0.18);
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    color: var(--white);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
}

.hero-carousel {
    position: relative;
    min-height: 560px;
    background: var(--stone-900);
    overflow: hidden;
}

.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-bg,
.hero-bg img,
.hero-shade {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.hero-bg img {
    object-fit: cover;
    opacity: 0.58;
    transform: scale(1.04);
}

.hero-shade {
    background:
        radial-gradient(circle at 74% 18%, rgba(245, 158, 11, 0.32), transparent 24%),
        linear-gradient(0deg, rgba(28, 25, 23, 0.96), rgba(28, 25, 23, 0.48) 52%, rgba(28, 25, 23, 0.22));
}

.hero-content {
    position: relative;
    z-index: 1;
    min-height: 560px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: end;
    gap: 54px;
    padding: 78px 0 80px;
}

.hero-copy {
    max-width: 760px;
    color: var(--white);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 7px 13px;
    border-radius: 999px;
    color: var(--white);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    background: var(--amber-600);
}

.eyebrow.dark {
    color: var(--amber-700);
    background: rgba(245, 158, 11, 0.14);
}

.hero-copy h1 {
    margin: 18px 0 16px;
    font-size: clamp(40px, 7vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-copy p {
    max-width: 720px;
    margin: 0;
    color: #f5f5f4;
    font-size: 19px;
    line-height: 1.85;
}

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

.hero-tags {
    margin-top: 22px;
}

.hero-tags span,
.tag-list span {
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    color: #fffbeb;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.tag-list span {
    color: var(--stone-700);
    background: rgba(245, 158, 11, 0.12);
    border-color: rgba(245, 158, 11, 0.12);
}

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

.primary-btn,
.ghost-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn {
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    box-shadow: 0 16px 34px rgba(245, 158, 11, 0.32);
}

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

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

.hero-poster {
    position: relative;
    align-self: center;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow);
    transform: rotate(2deg);
}

.hero-poster img {
    width: 300px;
    height: 420px;
    object-fit: cover;
}

.hero-poster span,
.score-badge,
.detail-poster span {
    position: absolute;
    right: 12px;
    top: 12px;
    padding: 7px 10px;
    border-radius: 999px;
    color: var(--stone-950);
    font-size: 13px;
    font-weight: 900;
    background: var(--amber-300);
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.42);
}

.hero-dot.is-active {
    width: 28px;
    border-radius: 999px;
    background: var(--amber-500);
}

.search-panel {
    position: relative;
    z-index: 5;
    margin-top: -34px;
}

.search-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 460px);
    align-items: center;
    gap: 24px;
    padding: 24px;
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--soft-shadow);
    backdrop-filter: blur(14px);
}

.search-wrap h2 {
    margin: 10px 0 0;
    font-size: 24px;
}

.search-box {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 52px;
    padding: 0 16px;
    border-radius: 16px;
    border: 1px solid var(--stone-200);
    background: var(--white);
}

.search-box span {
    color: var(--amber-600);
    font-size: 22px;
}

.search-box input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
}

.search-results {
    display: none;
    margin-top: 12px;
    padding: 18px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.search-results.active {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}

.search-result-item {
    padding: 14px;
    border-radius: 14px;
    background: var(--stone-50);
    border: 1px solid var(--stone-200);
}

.search-result-item strong {
    display: block;
    margin-bottom: 6px;
}

.search-result-item span {
    color: var(--stone-600);
    font-size: 13px;
}

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

.section-block.alt {
    background: linear-gradient(180deg, rgba(231, 229, 228, 0.55), rgba(250, 250, 249, 0));
}

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

.section-head.inline {
    width: 100%;
}

.section-head h2 {
    margin: 10px 0 0;
    font-size: clamp(26px, 4vw, 38px);
    letter-spacing: -0.03em;
}

.more-link {
    color: var(--amber-700);
    font-weight: 800;
}

.category-grid,
.category-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 16px;
}

.category-tile,
.category-overview-card a {
    display: flex;
    flex-direction: column;
    min-height: 150px;
    padding: 22px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--stone-900), var(--stone-800));
    color: var(--white);
    box-shadow: var(--soft-shadow);
    overflow: hidden;
    position: relative;
}

.category-tile::after,
.category-overview-card a::after {
    content: "";
    position: absolute;
    width: 120px;
    height: 120px;
    right: -42px;
    bottom: -44px;
    border-radius: 50%;
    background: rgba(245, 158, 11, 0.28);
}

.category-tile span,
.category-overview-card span {
    font-size: 20px;
    font-weight: 900;
}

.category-tile strong,
.category-overview-card strong {
    margin-top: auto;
    font-size: 30px;
    color: var(--amber-300);
}

.category-tile em,
.category-overview-card p {
    margin: 10px 0 0;
    color: var(--stone-300);
    font-style: normal;
    line-height: 1.7;
}

.movie-grid,
.compact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.compact-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 16px;
}

.movie-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: var(--white);
    box-shadow: var(--soft-shadow);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.poster-link {
    display: block;
    position: relative;
    background: var(--stone-200);
    overflow: hidden;
}

.poster-link img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

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

.meta-row,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--stone-600);
    font-size: 12px;
}

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

.movie-card p {
    min-height: 48px;
    margin: 0 0 14px;
    color: var(--stone-600);
    font-size: 13px;
    line-height: 1.65;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr);
    gap: 34px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 42px 58px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 16px;
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.rank-num {
    color: var(--amber-600);
    font-size: 20px;
    font-weight: 900;
    text-align: center;
}

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

.rank-info {
    min-width: 0;
}

.rank-info strong,
.rank-info em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-info em {
    margin-top: 6px;
    color: var(--stone-600);
    font-size: 13px;
    font-style: normal;
}

.rank-heat {
    color: var(--amber-700);
    font-weight: 900;
}

.inner-hero,
.detail-hero {
    position: relative;
    color: var(--white);
    background: var(--stone-900);
    overflow: hidden;
}

.inner-hero::before,
.detail-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: var(--hero-image);
    background-size: cover;
    background-position: center;
    opacity: 0.35;
    transform: scale(1.06);
}

.inner-hero::after,
.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 72% 18%, rgba(245, 158, 11, 0.28), transparent 22%),
        linear-gradient(0deg, rgba(28, 25, 23, 0.94), rgba(28, 25, 23, 0.5));
}

.inner-hero .container,
.detail-top {
    position: relative;
    z-index: 1;
}

.inner-hero {
    padding: 92px 0 74px;
}

.small-hero {
    --hero-image: linear-gradient(135deg, #292524, #57534e);
}

.inner-hero h1,
.detail-copy h1 {
    margin: 16px 0;
    font-size: clamp(38px, 6vw, 66px);
    line-height: 1.05;
}

.inner-hero p,
.detail-line {
    max-width: 760px;
    color: var(--stone-100);
    font-size: 18px;
    line-height: 1.8;
}

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

.page-grid {
    grid-template-columns: repeat(auto-fill, minmax(176px, 1fr));
}

.side-rank,
.detail-side {
    position: sticky;
    top: 86px;
    padding: 18px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.side-rank h2,
.detail-side h2 {
    margin: 0 0 16px;
}

.rank-list.slim .rank-item {
    grid-template-columns: 36px minmax(0, 1fr);
}

.rank-list.slim img,
.rank-list.slim .rank-heat {
    display: none;
}

.detail-hero {
    padding: 76px 0 72px;
}

.detail-top {
    display: grid;
    grid-template-columns: 270px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
}

.detail-poster {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.detail-poster img {
    width: 270px;
    height: 405px;
    object-fit: cover;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--stone-300);
    font-size: 14px;
}

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

.breadcrumb em {
    font-style: normal;
}

.detail-meta {
    margin: 18px 0;
    color: var(--stone-100);
}

.detail-meta span {
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
}

.detail-tags span {
    color: #fffbeb;
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.12);
}

.detail-main,
.text-panel,
.player-box {
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.detail-main {
    overflow: hidden;
}

.player-box {
    position: relative;
    overflow: hidden;
    background: #000000;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.player-box video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: grid;
    place-items: center;
    border: 0;
    color: var(--white);
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.18));
}

.player-overlay span {
    width: 76px;
    height: 76px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--stone-950);
    font-size: 30px;
    background: var(--amber-300);
    box-shadow: 0 16px 38px rgba(245, 158, 11, 0.36);
}

.player-overlay.is-hidden {
    display: none;
}

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

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

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

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

.rank-list.full {
    gap: 14px;
}

.compact-rank-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}

.site-footer {
    color: var(--stone-100);
    background: var(--stone-950);
}

.footer-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 34px 0;
}

.footer-grid strong {
    display: block;
    margin-bottom: 8px;
    color: var(--white);
    font-size: 20px;
}

.footer-grid p {
    margin: 0;
    color: var(--stone-300);
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

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

.copyright {
    padding: 16px;
    color: var(--stone-500);
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (max-width: 980px) {
    .hero-content,
    .split-layout,
    .page-layout,
    .detail-layout,
    .rank-page-grid {
        grid-template-columns: 1fr;
    }

    .hero-poster,
    .side-rank,
    .detail-side {
        display: none;
    }

    .detail-top {
        grid-template-columns: 190px minmax(0, 1fr);
    }

    .detail-poster img {
        width: 190px;
        height: 285px;
    }
}

@media (max-width: 760px) {
    .nav-wrap {
        height: auto;
        min-height: 64px;
        flex-wrap: wrap;
        padding: 10px 0;
    }

    .menu-toggle {
        display: grid;
        place-items: center;
    }

    .main-nav {
        display: none;
        width: 100%;
        padding: 10px 0;
        flex-direction: column;
        align-items: stretch;
    }

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

    .nav-link {
        width: 100%;
    }

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

    .hero-content {
        padding: 86px 0 82px;
    }

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

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

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

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

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

    .movie-card h3 {
        font-size: 16px;
    }

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

    .rank-heat {
        display: none;
    }

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

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

    .detail-poster img {
        width: 210px;
        height: 315px;
    }
}

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

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