:root {
    color-scheme: light;
    --amber: #f59e0b;
    --amber-dark: #d97706;
    --amber-soft: #fff7ed;
    --stone-950: #0c0a09;
    --stone-900: #1c1917;
    --stone-800: #292524;
    --stone-700: #44403c;
    --stone-600: #57534e;
    --stone-500: #78716c;
    --stone-300: #d6d3d1;
    --stone-200: #e7e5e4;
    --stone-100: #f5f5f4;
    --white: #ffffff;
    --radius: 22px;
    --shadow: 0 18px 45px rgba(28, 25, 23, 0.14);
    --shadow-soft: 0 12px 30px rgba(28, 25, 23, 0.10);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: linear-gradient(180deg, #fffbeb 0%, #fafaf9 42%, #ffffff 100%);
    color: var(--stone-800);
    min-height: 100vh;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(214, 211, 209, 0.75);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber) 0%, var(--stone-700) 100%);
    box-shadow: 0 10px 24px rgba(245, 158, 11, 0.32);
}

.brand-text {
    display: grid;
    gap: 1px;
}

.brand-text strong {
    font-size: 19px;
    line-height: 1.1;
}

.brand-text small {
    color: var(--stone-600);
    font-size: 12px;
}

.brand.compact .brand-mark {
    width: 38px;
    height: 38px;
}

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

.nav-link,
.mobile-link {
    color: var(--stone-700);
    font-weight: 700;
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: var(--amber-dark);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: var(--amber-soft);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--stone-800);
    border-radius: 99px;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 12px;
    padding: 12px;
    border-radius: 18px;
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

.mobile-nav.is-open {
    display: grid;
    gap: 8px;
}

.mobile-link {
    padding: 12px 14px;
    border-radius: 12px;
}

.mobile-link:hover,
.mobile-link.is-active {
    background: var(--amber-soft);
}

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

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

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

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

.hero-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.05);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 70% 24%, rgba(245, 158, 11, 0.36), transparent 30%),
        linear-gradient(90deg, rgba(12, 10, 9, 0.96) 0%, rgba(28, 25, 23, 0.78) 46%, rgba(28, 25, 23, 0.24) 100%),
        linear-gradient(0deg, rgba(12, 10, 9, 0.85) 0%, transparent 42%);
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 610px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: end;
    gap: 48px;
    padding: 96px 0 76px;
}

.hero-copy {
    max-width: 720px;
}

.hero-chips,
.tag-row,
.detail-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-chips span,
.tag-row span,
.detail-meta span,
.card-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff7ed;
    font-size: 13px;
    font-weight: 700;
}

.hero h1,
.page-hero h1,
.detail-info h1 {
    margin: 14px 0 10px;
    font-size: clamp(36px, 6vw, 70px);
    line-height: 0.98;
    letter-spacing: -0.04em;
    color: var(--white);
}

.hero h2 {
    margin: 0 0 16px;
    color: var(--white);
    font-size: clamp(30px, 4vw, 54px);
    line-height: 1.05;
}

.hero p {
    max-width: 700px;
    margin: 0 0 28px;
    color: var(--stone-200);
    font-size: 18px;
    line-height: 1.8;
}

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

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

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

.btn.primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--amber) 0%, var(--amber-dark) 100%);
    box-shadow: 0 16px 30px rgba(245, 158, 11, 0.28);
}

.btn.ghost {
    color: var(--stone-800);
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

.btn.line {
    color: var(--white);
    border-color: rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.10);
    backdrop-filter: blur(10px);
}

.btn.block {
    width: 100%;
    margin-top: 12px;
}

.hero-poster {
    align-self: center;
    border-radius: 28px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
    transform: rotate(2deg);
    transition: transform 0.3s ease;
}

.hero-poster:hover {
    transform: translateY(-6px) rotate(0deg);
}

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

.hero-poster span {
    display: block;
    padding: 14px 16px;
    color: var(--white);
    font-weight: 800;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.9), rgba(68, 64, 60, 0.94));
}

.hero-controls {
    position: absolute;
    z-index: 5;
    left: 50%;
    bottom: 26px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(12, 10, 9, 0.42);
    backdrop-filter: blur(14px);
}

.hero-controls button {
    border: 0;
    color: var(--white);
    cursor: pointer;
    background: transparent;
}

.hero-controls > button {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    font-size: 28px;
    line-height: 1;
}

.hero-controls > button:hover {
    background: rgba(255, 255, 255, 0.14);
}

.hero-dots {
    display: flex;
    gap: 7px;
}

.hero-dots button {
    width: 9px;
    height: 9px;
    padding: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.38);
}

.hero-dots button.is-active {
    width: 28px;
    background: var(--amber);
}

.panel-band {
    padding: 38px 0;
    background: rgba(255, 251, 235, 0.9);
    border-bottom: 1px solid rgba(214, 211, 209, 0.7);
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 520px);
    align-items: center;
    gap: 26px;
}

.kicker {
    display: inline-flex;
    color: var(--amber-dark);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.search-panel h2,
.section-head h2,
.rank-copy-block h2,
.text-block h2 {
    margin: 8px 0 8px;
    color: var(--stone-800);
    font-size: clamp(26px, 3vw, 42px);
    line-height: 1.12;
    letter-spacing: -0.03em;
}

.search-panel p,
.section-head p,
.rank-copy-block p,
.page-hero p,
.text-block p,
.category-copy p,
.footer-brand p {
    color: var(--stone-600);
    line-height: 1.75;
}

.search-box,
.filter-panel {
    display: flex;
    gap: 10px;
}

.search-box input,
.filter-panel input,
.filter-panel select {
    min-height: 48px;
    width: 100%;
    border: 1px solid var(--stone-200);
    outline: 0;
    border-radius: 15px;
    padding: 0 16px;
    background: var(--white);
    color: var(--stone-800);
    box-shadow: 0 8px 22px rgba(28, 25, 23, 0.05);
}

.filter-panel select {
    max-width: 180px;
}

.section {
    padding: 70px 0;
}

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

.section-more {
    color: var(--amber-dark);
    font-weight: 900;
}

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

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

.category-card a {
    display: grid;
    min-height: 100%;
    overflow: hidden;
    border: 1px solid rgba(214, 211, 209, 0.8);
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow-soft);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.category-card a:hover {
    transform: translateY(-5px);
    border-color: rgba(245, 158, 11, 0.72);
    box-shadow: var(--shadow);
}

.category-covers {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    height: 148px;
    background: var(--stone-100);
}

.category-covers img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-copy {
    padding: 20px;
}

.category-copy span {
    color: var(--amber-dark);
    font-size: 13px;
    font-weight: 900;
}

.category-copy h3 {
    margin: 6px 0 8px;
    font-size: 22px;
}

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

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

.movie-card {
    display: grid;
    overflow: hidden;
    border: 1px solid rgba(214, 211, 209, 0.78);
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow-soft);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(245, 158, 11, 0.7);
    box-shadow: var(--shadow);
}

.movie-card.is-hidden,
.rank-item.is-hidden {
    display: none;
}

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

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

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

.poster-glow {
    position: absolute;
    inset: auto 0 0;
    height: 50%;
    background: linear-gradient(0deg, rgba(12, 10, 9, 0.7), transparent);
}

.watch-pill {
    position: absolute;
    left: 14px;
    bottom: 14px;
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    color: var(--white);
    font-size: 13px;
    font-weight: 900;
    background: rgba(245, 158, 11, 0.95);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.22);
}

.card-body {
    padding: 18px;
}

.card-meta {
    margin-bottom: 10px;
}

.card-meta span,
.detail-meta span,
.tag-row span {
    color: var(--stone-700);
    background: var(--amber-soft);
}

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

.movie-card h3 a:hover {
    color: var(--amber-dark);
}

.movie-card p {
    margin: 0 0 14px;
    color: var(--stone-600);
    line-height: 1.62;
}

.compact-card .card-body {
    padding: 14px;
}

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

.compact-card p {
    display: none;
}

.tag-row.big {
    margin-top: 18px;
}

.rank-band {
    padding: 74px 0;
    background:
        radial-gradient(circle at top left, rgba(245, 158, 11, 0.26), transparent 30%),
        linear-gradient(135deg, var(--stone-950) 0%, var(--stone-800) 100%);
}

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

.rank-copy-block h2,
.rank-copy-block p {
    color: var(--white);
}

.rank-copy-block p {
    color: var(--stone-200);
}

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

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

.rank-item {
    display: grid;
    grid-template-columns: 48px 60px minmax(0, 1fr) 52px;
    align-items: center;
    gap: 14px;
    min-height: 82px;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.12);
    transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
    transform: translateY(-3px);
    background: var(--white);
}

.rank-num,
.rank-dot {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber), var(--stone-700));
}

.rank-dot {
    width: 12px;
    height: 12px;
}

.rank-item img {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    object-fit: cover;
}

.rank-copy {
    display: grid;
    min-width: 0;
}

.rank-copy strong {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: var(--stone-800);
}

.rank-copy em {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: var(--stone-500);
    font-size: 13px;
    font-style: normal;
}

.rank-item b {
    color: var(--amber-dark);
    font-size: 18px;
}

.page-hero {
    position: relative;
    padding: 78px 0;
    color: var(--white);
    background:
        radial-gradient(circle at 80% 20%, rgba(245, 158, 11, 0.42), transparent 28%),
        linear-gradient(135deg, var(--stone-950), var(--stone-700));
    overflow: hidden;
}

.page-hero.slim {
    padding: 76px 0 58px;
}

.page-hero h1 {
    max-width: 760px;
}

.page-hero p {
    max-width: 720px;
    color: var(--stone-200);
    font-size: 18px;
}

.category-search {
    max-width: 560px;
    margin-top: 24px;
}

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

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

.filter-panel {
    max-width: 760px;
    margin-top: 24px;
}

.detail-top {
    padding: 46px 0 58px;
    color: var(--white);
    background:
        radial-gradient(circle at 78% 18%, rgba(245, 158, 11, 0.34), transparent 32%),
        linear-gradient(135deg, var(--stone-950), var(--stone-800));
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
    gap: 32px;
    align-items: center;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #000;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.36);
    aspect-ratio: 16 / 9;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    padding: 0;
    cursor: pointer;
    color: var(--white);
    background: #000;
    overflow: hidden;
    z-index: 2;
}

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

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.68;
    filter: brightness(0.76);
    transition: transform 0.35s ease;
}

.player-cover:hover img {
    transform: scale(1.04);
}

.play-circle {
    position: relative;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 999px;
    padding-left: 5px;
    color: var(--white);
    font-size: 36px;
    background: linear-gradient(135deg, var(--amber), var(--amber-dark));
    box-shadow: 0 16px 38px rgba(245, 158, 11, 0.38);
}

.player-cover strong {
    position: relative;
    z-index: 3;
    margin-top: 112px;
    padding: 8px 15px;
    border-radius: 999px;
    background: rgba(12, 10, 9, 0.55);
    backdrop-filter: blur(10px);
}

.detail-info h1 {
    font-size: clamp(30px, 4vw, 52px);
}

.detail-line {
    color: var(--stone-200);
    font-size: 18px;
    line-height: 1.7;
}

.detail-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 32px;
    align-items: start;
}

.content-main {
    display: grid;
    gap: 22px;
}

.text-block {
    padding: 28px;
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(214, 211, 209, 0.75);
}

.text-block h2 {
    font-size: 28px;
}

.text-block p {
    margin: 0;
    font-size: 17px;
}

.content-side {
    position: sticky;
    top: 96px;
}

.side-poster {
    display: block;
    overflow: hidden;
    border-radius: 24px;
    box-shadow: var(--shadow);
    background: var(--stone-100);
}

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

.site-footer {
    padding-top: 54px;
    color: var(--stone-300);
    background: var(--stone-950);
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(260px, 420px) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
}

.footer-brand p {
    color: var(--stone-400);
}

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

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

.footer-bottom {
    margin-top: 42px;
    padding: 18px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--stone-500);
}

@media (max-width: 1024px) {
    .main-nav {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        align-items: end;
    }

    .hero-poster {
        display: none;
    }

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

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

    .rank-list.full {
        grid-template-columns: 1fr;
    }

    .content-side {
        position: static;
        max-width: 320px;
    }
}

@media (max-width: 720px) {
    .header-inner {
        height: 66px;
    }

    .brand-text small {
        display: none;
    }

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

    .hero-inner {
        padding: 72px 0 72px;
    }

    .hero p {
        font-size: 16px;
    }

    .search-panel,
    .section-head,
    .filter-panel,
    .search-box {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .filter-panel select {
        max-width: none;
    }

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

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

    .rank-item b {
        display: none;
    }

    .card-body {
        padding: 14px;
    }

    .movie-card p,
    .tag-row {
        display: none;
    }

    .detail-top {
        padding-top: 28px;
    }

    .player-shell {
        border-radius: 18px;
    }

    .play-circle {
        width: 68px;
        height: 68px;
        font-size: 28px;
    }
}

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

    .hero-actions .btn {
        width: 100%;
    }
}
