:root {
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-500: #f59e0b;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --amber-800: #92400e;
    --amber-900: #78350f;
    --orange-50: #fff7ed;
    --orange-100: #ffedd5;
    --orange-600: #ea580c;
    --orange-700: #c2410c;
    --orange-950: #431407;
    --ink: #271100;
    --muted: #8a5f25;
    --white: #ffffff;
    --shadow: 0 20px 45px rgba(120, 53, 15, 0.16);
    --soft-shadow: 0 10px 24px rgba(120, 53, 15, 0.12);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    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;
    color: var(--ink);
    background: linear-gradient(180deg, var(--amber-50), var(--orange-50) 48%, var(--amber-50));
    min-height: 100vh;
}

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

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

button,
input {
    font: inherit;
}

.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 var(--amber-200);
    box-shadow: 0 10px 24px rgba(120, 53, 15, 0.08);
    backdrop-filter: blur(14px);
}

.nav-shell {
    width: min(1240px, calc(100% - 32px));
    min-height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

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

.brand-icon {
    width: 42px;
    height: 42px;
    display: inline-grid;
    place-items: center;
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(217, 119, 6, 0.25);
}

.brand-text strong {
    display: block;
    font-size: 20px;
    line-height: 1.1;
    letter-spacing: -0.02em;
    background: linear-gradient(90deg, var(--amber-700), var(--orange-700));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-text small {
    display: block;
    color: var(--amber-700);
    font-size: 12px;
    margin-top: 4px;
    white-space: nowrap;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.nav-link,
.mobile-link {
    color: var(--amber-900);
    border-radius: 12px;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link {
    padding: 10px 14px;
    font-weight: 600;
    font-size: 14px;
}

.nav-link:hover,
.nav-link.active,
.mobile-link:hover {
    background: var(--amber-100);
    color: var(--amber-800);
}

.menu-toggle {
    display: none;
    border: 0;
    padding: 10px 14px;
    border-radius: 12px;
    color: var(--amber-900);
    background: var(--amber-100);
    cursor: pointer;
}

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

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

.mobile-link {
    display: block;
    padding: 12px 14px;
}

.hero {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    background: var(--orange-950);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s ease, visibility 1s ease;
}

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.02);
}

.hero-slide.is-missing-image,
.cover-frame.is-missing-image {
    background: radial-gradient(circle at 20% 20%, rgba(245, 158, 11, 0.5), transparent 32%), linear-gradient(135deg, #2b1204, #92400e 55%, #f59e0b);
}

.hero-slide.is-missing-image img,
.cover-frame.is-missing-image img {
    display: none;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.45) 48%, rgba(0, 0, 0, 0.1));
}

.hero-copy {
    position: absolute;
    left: max(24px, calc((100% - 1240px) / 2));
    right: 24px;
    bottom: 72px;
    max-width: 820px;
    color: var(--white);
}

.hero-tags,
.tag-row,
.meta-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.tag-row span,
.meta-row span,
.eyebrow {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    line-height: 1;
}

.hero-tags span,
.eyebrow {
    padding: 8px 12px;
    background: var(--amber-600);
    color: var(--white);
    font-weight: 700;
    font-size: 13px;
}

.hero-copy h1 {
    margin: 18px 0 14px;
    font-size: clamp(36px, 6vw, 72px);
    line-height: 1.02;
    letter-spacing: -0.05em;
}

.hero-copy p {
    margin: 0 0 28px;
    color: var(--amber-100);
    font-size: clamp(16px, 2vw, 21px);
    line-height: 1.75;
    max-width: 720px;
}

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

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 12px 22px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.button.primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
    box-shadow: 0 14px 30px rgba(217, 119, 6, 0.28);
}

.button.ghost {
    color: var(--white);
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(10px);
}

.button.light {
    color: var(--amber-900);
    background: var(--amber-100);
}

.button.small {
    min-height: 36px;
    padding: 9px 16px;
    font-size: 14px;
}

.hero-control {
    position: absolute;
    top: 50%;
    width: 48px;
    height: 48px;
    transform: translateY(-50%);
    border: 0;
    border-radius: 50%;
    color: var(--white);
    background: rgba(0, 0, 0, 0.38);
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
    backdrop-filter: blur(8px);
    opacity: 0;
    transition: opacity 0.2s ease, background 0.2s ease;
}

.hero:hover .hero-control {
    opacity: 1;
}

.hero-control:hover {
    background: rgba(0, 0, 0, 0.62);
}

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

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

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

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

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

.search-band {
    width: min(1240px, calc(100% - 32px));
    margin: -38px auto 0;
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 22px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--amber-100);
    box-shadow: var(--shadow);
}

.search-band strong {
    display: block;
    font-size: 20px;
    color: var(--amber-900);
}

.search-band span {
    color: var(--muted);
}

.search-form,
.filter-bar {
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-form input,
.filter-bar input {
    width: min(420px, 100%);
    height: 46px;
    padding: 0 16px;
    border: 1px solid var(--amber-200);
    border-radius: 999px;
    outline: none;
    color: var(--ink);
    background: var(--white);
}

.search-form input:focus,
.filter-bar input:focus {
    border-color: var(--amber-600);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.15);
}

.search-form button,
.filter-buttons button {
    height: 46px;
    border: 0;
    border-radius: 999px;
    padding: 0 18px;
    color: var(--white);
    background: var(--amber-700);
    cursor: pointer;
    font-weight: 800;
}

.page-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
}

.top-space {
    padding-top: 34px;
}

.content-section {
    margin: 70px 0;
}

.warm-panel {
    margin-left: -18px;
    margin-right: -18px;
    padding: 34px 18px 42px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--amber-100), var(--orange-100));
    box-shadow: var(--soft-shadow);
}

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

.section-head h2 {
    margin: 0 0 8px;
    color: var(--amber-900);
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.section-head p {
    margin: 0 0 12px;
    color: var(--muted);
}

.section-head span {
    display: block;
    width: 86px;
    height: 4px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--amber-600), var(--orange-600));
}

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

.movie-grid {
    display: grid;
    gap: 22px;
}

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

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

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

.cover-link,
.cover-frame {
    display: block;
}

.cover-frame {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, var(--amber-200), var(--orange-100));
}

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

.movie-card:hover .cover-frame img,
.category-tile:hover img,
.rank-item:hover img {
    transform: scale(1.08);
}

.play-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    transform: translate(-50%, -50%) scale(0.86);
    border-radius: 50%;
    color: var(--white);
    background: rgba(0, 0, 0, 0.48);
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-mark {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.rank-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    min-width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    background: var(--amber-600);
    font-weight: 900;
}

.movie-info {
    padding: 18px;
}

.meta-row {
    color: var(--amber-700);
    font-size: 12px;
    font-weight: 700;
}

.meta-row span {
    padding: 6px 9px;
    background: var(--amber-100);
}

.meta-row.large {
    gap: 10px;
    font-size: 13px;
}

.movie-info h3 {
    margin: 12px 0 8px;
    color: var(--amber-900);
    font-size: 18px;
    line-height: 1.35;
}

.movie-info h3 a:hover,
.rank-copy h2 a:hover,
.category-card-large h2 a:hover {
    color: var(--amber-700);
}

.movie-info p,
.rank-copy p,
.category-card-large p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

.tag-row {
    margin-top: 14px;
}

.tag-row span {
    padding: 6px 9px;
    color: var(--amber-800);
    background: var(--orange-100);
    font-size: 12px;
    font-weight: 700;
}

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

.category-tile {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 18px;
    border-radius: var(--radius-lg);
    color: var(--white);
    background: var(--orange-950);
    box-shadow: var(--soft-shadow);
}

.category-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.1));
}

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

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

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

.category-tile strong {
    margin: 6px 0;
}

.category-tile em {
    font-style: normal;
    color: var(--amber-100);
    font-size: 13px;
    line-height: 1.55;
}

.horizontal-row {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 4px 4px 18px;
    scroll-snap-type: x mandatory;
}

.horizontal-row .movie-card {
    width: 270px;
    flex: 0 0 270px;
    scroll-snap-align: start;
}

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

.rank-list.compact .rank-item:nth-child(n + 6) {
    display: none;
}

.rank-item {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 22px;
    padding: 16px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.rank-cover {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: var(--amber-100);
}

.rank-cover img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    transition: transform 0.45s ease;
}

.rank-number {
    position: absolute;
    z-index: 2;
    left: 10px;
    top: 10px;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    background: var(--amber-600);
    font-weight: 900;
}

.rank-copy h2 {
    margin: 12px 0 8px;
    color: var(--amber-900);
    font-size: 24px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    min-height: 310px;
    display: flex;
    align-items: flex-end;
    padding: 42px;
    border-radius: var(--radius-xl);
    color: var(--white);
    background: radial-gradient(circle at 15% 15%, rgba(245, 158, 11, 0.7), transparent 30%), linear-gradient(135deg, #271100, #92400e 60%, #f59e0b);
    box-shadow: var(--shadow);
}

.page-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: var(--hero-image);
    background-size: cover;
    background-position: center;
    opacity: 0.32;
}

.page-hero > div {
    position: relative;
    z-index: 1;
    max-width: 760px;
}

.page-hero h1 {
    margin: 14px 0;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.04;
    letter-spacing: -0.04em;
}

.page-hero p {
    color: var(--amber-100);
    font-size: 18px;
    line-height: 1.75;
}

.small-hero,
.search-hero,
.ranking-hero {
    min-height: 260px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 18px;
    color: var(--amber-800);
    font-weight: 700;
}

.breadcrumb span {
    color: var(--muted);
}

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

.category-card-large {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 22px;
    padding: 18px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.category-cover-stack {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    overflow: hidden;
    min-height: 160px;
    border-radius: 16px;
    background: var(--amber-100);
}

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

.category-card-large h2 {
    margin: 4px 0 10px;
    color: var(--amber-900);
    font-size: 24px;
}

.category-card-large .button {
    margin-top: 18px;
}

.filter-bar {
    justify-content: space-between;
    flex-wrap: wrap;
    padding: 18px;
    margin-bottom: 24px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.filter-bar.stacked {
    align-items: stretch;
    flex-direction: column;
}

.filter-bar.stacked input {
    width: 100%;
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-buttons button.is-active {
    background: var(--orange-700);
}

.empty-state {
    display: none;
    padding: 28px;
    text-align: center;
    color: var(--muted);
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--soft-shadow);
}

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

.detail-shell {
    max-width: 1160px;
}

.detail-hero {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 34px;
    align-items: center;
    padding: 26px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(254, 243, 199, 0.96));
    box-shadow: var(--shadow);
}

.detail-poster {
    aspect-ratio: 3 / 4;
    border-radius: 22px;
    box-shadow: var(--shadow);
}

.detail-copy h1 {
    margin: 18px 0;
    color: var(--amber-900);
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.04;
    letter-spacing: -0.05em;
}

.lead {
    color: var(--muted);
    font-size: 19px;
    line-height: 1.75;
}

.detail-tags {
    margin-bottom: 24px;
}

.player-section {
    margin: 44px 0;
}

.video-frame {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius-xl);
    background: #000000;
    box-shadow: var(--shadow);
}

.video-frame video {
    width: 100%;
    height: 100%;
    display: block;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: radial-gradient(circle, rgba(245, 158, 11, 0.24), rgba(0, 0, 0, 0.64));
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.player-overlay.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.big-play {
    border: 0;
    padding: 18px 28px;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-600), var(--orange-700));
    box-shadow: 0 18px 40px rgba(217, 119, 6, 0.38);
    font-size: 20px;
    font-weight: 900;
    cursor: pointer;
}

.detail-content {
    padding: 34px;
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.detail-content h2 {
    margin: 0 0 12px;
    color: var(--amber-900);
    font-size: 28px;
}

.detail-content h2:not(:first-child) {
    margin-top: 28px;
}

.detail-content p {
    margin: 0;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.9;
}

.site-footer {
    margin-top: 80px;
    color: var(--amber-50);
    background: linear-gradient(180deg, var(--amber-900), var(--orange-950));
}

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

.footer-grid h2 {
    margin: 0 0 12px;
    font-size: 20px;
    color: var(--amber-100);
}

.footer-grid p {
    margin: 0;
    color: var(--amber-200);
    line-height: 1.8;
}

.footer-grid a {
    display: inline-block;
    margin: 0 12px 8px 0;
    color: var(--amber-100);
    font-weight: 700;
}

.footer-bottom {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 0;
    border-top: 1px solid rgba(253, 230, 138, 0.24);
    color: var(--amber-200);
}

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

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

    .desktop-nav {
        display: none;
    }

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

@media (max-width: 820px) {
    .brand-text small {
        display: none;
    }

    .hero {
        min-height: 540px;
    }

    .hero-copy {
        left: 20px;
        right: 20px;
        bottom: 62px;
    }

    .hero-control {
        opacity: 1;
        width: 42px;
        height: 42px;
    }

    .search-band,
    .section-head,
    .search-form,
    .rank-item,
    .category-card-large,
    .detail-hero,
    .footer-grid,
    .footer-bottom {
        display: block;
    }

    .search-form input,
    .search-form button {
        width: 100%;
        margin-top: 12px;
    }

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

    .rank-cover,
    .category-cover-stack {
        display: block;
        margin-bottom: 16px;
    }

    .rank-cover img {
        height: 210px;
    }

    .detail-poster {
        max-width: 320px;
        margin: 0 auto 24px;
    }

    .footer-grid section,
    .footer-bottom span + span {
        margin-top: 20px;
    }
}

@media (max-width: 560px) {
    .nav-shell,
    .page-shell,
    .search-band,
    .footer-grid,
    .footer-bottom,
    .mobile-nav {
        width: min(100% - 22px, 1240px);
    }

    .brand {
        min-width: 0;
    }

    .brand-text strong {
        font-size: 17px;
    }

    .hero {
        min-height: 520px;
    }

    .hero-copy h1 {
        font-size: 38px;
    }

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

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

    .page-hero {
        padding: 28px;
    }

    .detail-content {
        padding: 24px;
    }
}
