:root {
    color-scheme: light;
    --stone-50: #fafaf9;
    --stone-100: #f5f5f4;
    --stone-200: #e7e5e4;
    --stone-500: #78716c;
    --stone-600: #57534e;
    --stone-700: #44403c;
    --stone-800: #292524;
    --stone-900: #1c1917;
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-400: #fbbf24;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --amber-800: #92400e;
    --amber-900: #78350f;
    --radius: 18px;
    --shadow-sm: 0 1px 3px rgba(28, 25, 23, 0.08);
    --shadow-md: 0 10px 25px rgba(28, 25, 23, 0.12);
    --shadow-lg: 0 24px 60px rgba(28, 25, 23, 0.18);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--stone-50);
    color: var(--stone-800);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(120, 53, 15, 0.98);
    color: var(--amber-50);
    border-bottom: 1px solid rgba(253, 230, 138, 0.16);
    transition: background 0.25s ease, box-shadow 0.25s ease, backdrop-filter 0.25s ease;
}

.site-header.is-scrolled {
    background: rgba(120, 53, 15, 0.94);
    box-shadow: 0 12px 28px rgba(41, 37, 36, 0.22);
    backdrop-filter: blur(14px);
}

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

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

.brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(253, 230, 138, 0.18);
    color: var(--amber-100);
    box-shadow: 0 0 24px rgba(251, 191, 36, 0.28);
    font-size: 13px;
}

.brand-name {
    font-size: 20px;
    color: var(--amber-50);
}

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

.nav-link,
.mobile-nav-link {
    border-radius: 12px;
    color: var(--amber-100);
    font-size: 14px;
    font-weight: 650;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link {
    padding: 9px 13px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-nav-link:hover,
.mobile-nav-link.is-active {
    background: rgba(146, 64, 14, 0.72);
    color: var(--amber-50);
}

.mobile-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: rgba(146, 64, 14, 0.7);
    padding: 10px;
}

.mobile-menu-button span {
    display: block;
    height: 2px;
    margin: 5px 0;
    border-radius: 99px;
    background: var(--amber-100);
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 12px;
    padding: 10px;
    border-radius: 16px;
    background: rgba(146, 64, 14, 0.82);
}

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

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

.page-main {
    min-height: 70vh;
    padding-top: 64px;
}

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

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

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

.hero-slide img {
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.04);
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.42) 48%, rgba(0, 0, 0, 0.24));
}

.hero-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 18px;
    text-align: center;
    color: white;
}

.hero-panel {
    width: min(850px, 100%);
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border-radius: 999px;
    padding: 8px 16px;
    margin-bottom: 18px;
    background: rgba(217, 119, 6, 0.92);
    color: var(--amber-50);
    box-shadow: var(--shadow-md);
    backdrop-filter: blur(10px);
    font-size: 14px;
    font-weight: 700;
}

.hero-title {
    margin: 0;
    color: white;
    font-size: clamp(34px, 6vw, 62px);
    line-height: 1.08;
    font-weight: 900;
    letter-spacing: -0.03em;
    text-shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

.hero-description {
    width: min(760px, 100%);
    margin: 18px auto 28px;
    color: rgba(255, 255, 255, 0.9);
    font-size: clamp(16px, 2.2vw, 21px);
    text-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.hero-actions,
.hero-search,
.hero-categories {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.hero-search {
    width: min(680px, 100%);
    margin: 20px auto 0;
    padding: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(14px);
}

.hero-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: none;
    border-radius: 999px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.92);
    color: var(--stone-800);
}

.hero-categories {
    margin-top: 18px;
}

.hero-categories a,
.chip {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 7px 13px;
    background: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 13px;
    font-weight: 650;
}

.primary-button,
.secondary-button,
.section-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    padding: 12px 22px;
    background: var(--amber-600);
    color: white;
    box-shadow: 0 12px 25px rgba(180, 83, 9, 0.28);
}

.primary-button:hover,
.secondary-button:hover,
.section-link:hover {
    transform: translateY(-1px);
}

.primary-button:hover {
    background: var(--amber-700);
    box-shadow: 0 18px 36px rgba(180, 83, 9, 0.34);
}

.secondary-button {
    padding: 11px 20px;
    background: rgba(255, 255, 255, 0.16);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(10px);
}

.hero-arrow {
    position: absolute;
    z-index: 4;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.5);
    color: white;
    font-size: 28px;
    line-height: 1;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.72);
}

.hero-arrow.prev {
    left: 20px;
}

.hero-arrow.next {
    right: 20px;
}

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

.hero-dot {
    width: 9px;
    height: 9px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.54);
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
    width: 34px;
    background: white;
}

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

.content-section.tight {
    padding-top: 34px;
}

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

.section-heading h1,
.section-heading h2 {
    margin: 0;
    color: var(--stone-800);
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.15;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.section-heading p {
    margin: 8px 0 0;
    color: var(--stone-600);
}

.section-link {
    flex: 0 0 auto;
    padding: 10px 16px;
    background: var(--amber-100);
    color: var(--amber-800);
}

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

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

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

.movie-card {
    background: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(231, 229, 228, 0.8);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: rgba(217, 119, 6, 0.28);
}

.movie-card-link {
    display: block;
    height: 100%;
}

.movie-thumb {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--stone-900);
}

.movie-thumb img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.movie-year {
    position: absolute;
    right: 10px;
    bottom: 10px;
    border-radius: 999px;
    padding: 4px 9px;
    background: rgba(0, 0, 0, 0.72);
    color: white;
    font-size: 12px;
    font-weight: 800;
}

.play-hover {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(217, 119, 6, 0.92);
    color: white;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.86);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

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

.movie-card-body h3 {
    margin: 8px 0 8px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 850;
    color: var(--stone-800);
}

.movie-card-body p {
    margin: 0;
    color: var(--stone-600);
    font-size: 14px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.movie-tags span {
    border-radius: 999px;
    padding: 3px 8px;
    background: var(--amber-100);
    color: var(--amber-800);
    font-size: 12px;
    font-weight: 760;
}

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    color: var(--stone-500);
    font-size: 13px;
}

.movie-meta span {
    border-radius: 999px;
    padding: 3px 8px;
    background: var(--stone-100);
}

.movie-card-horizontal .movie-card-link {
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 0;
}

.horizontal-thumb {
    aspect-ratio: auto;
    height: 112px;
}

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

.category-card {
    min-height: 185px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-radius: 24px;
    padding: 24px;
    background: linear-gradient(135deg, var(--amber-900), var(--amber-700));
    color: var(--amber-50);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    position: relative;
}

.category-card::after {
    content: "";
    position: absolute;
    width: 120px;
    height: 120px;
    border-radius: 999px;
    right: -30px;
    top: -30px;
    background: rgba(255, 255, 255, 0.12);
}

.category-card h2,
.category-card h3 {
    margin: 0 0 10px;
    font-size: 23px;
    font-weight: 900;
}

.category-card p {
    margin: 0;
    color: rgba(255, 251, 235, 0.82);
}

.category-card span {
    margin-top: 20px;
    font-weight: 800;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 54px 92px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: white;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(231, 229, 228, 0.86);
}

.rank-number {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: var(--amber-100);
    color: var(--amber-800);
    font-weight: 900;
}

.rank-cover {
    height: 72px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--stone-900);
}

.rank-cover img {
    height: 100%;
    object-fit: cover;
}

.rank-title {
    margin: 0 0 5px;
    font-size: 18px;
    font-weight: 850;
}

.rank-desc {
    margin: 0;
    color: var(--stone-600);
    font-size: 14px;
}

.rank-action {
    border-radius: 999px;
    padding: 9px 14px;
    background: var(--amber-600);
    color: white;
    font-weight: 800;
}

.page-hero {
    background: linear-gradient(135deg, var(--amber-900), var(--amber-800));
    color: white;
    padding: 58px 0;
}

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

.page-hero h1 {
    margin: 0;
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.15;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.page-hero p {
    width: min(760px, 100%);
    margin: 12px 0 0;
    color: var(--amber-100);
    font-size: 18px;
}

.filter-panel {
    border-radius: 26px;
    padding: 18px;
    margin: 0 0 30px;
    background: white;
    border: 1px solid rgba(231, 229, 228, 0.9);
    box-shadow: var(--shadow-sm);
}

.filter-form {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 170px 150px 160px auto;
    gap: 12px;
    align-items: end;
}

.filter-form label {
    display: grid;
    gap: 6px;
    color: var(--stone-600);
    font-size: 13px;
    font-weight: 800;
}

.filter-form input,
.filter-form select {
    width: 100%;
    border: 1px solid var(--stone-200);
    border-radius: 14px;
    background: var(--stone-50);
    color: var(--stone-800);
    padding: 11px 12px;
    outline: none;
}

.filter-form input:focus,
.filter-form select:focus {
    border-color: var(--amber-600);
    box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.12);
}

.filter-status {
    margin: 12px 4px 0;
    color: var(--stone-500);
    font-size: 14px;
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--amber-100);
    margin-bottom: 16px;
    font-size: 14px;
}

.detail-shell {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0 60px;
    display: grid;
    grid-template-columns: minmax(0, 2fr) 360px;
    gap: 28px;
}

.detail-card,
.side-card {
    border-radius: 24px;
    background: white;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(231, 229, 228, 0.86);
    overflow: hidden;
}

.detail-content {
    padding: 26px;
}

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: black;
}

.player-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: black;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    width: 100%;
    height: 100%;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: black;
}

.player-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.72;
}

.player-cover-shade {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(217, 119, 6, 0.18), rgba(0, 0, 0, 0.62));
}

.play-badge {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    transform: translate(-50%, -50%);
    background: rgba(217, 119, 6, 0.95);
    color: white;
    font-size: 30px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.36);
}

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

.detail-title {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.16;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.detail-lead {
    margin: 14px 0 0;
    color: var(--stone-600);
    font-size: 18px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin: 20px 0 22px;
}

.detail-meta span {
    border-radius: 999px;
    padding: 7px 11px;
    background: var(--stone-100);
    color: var(--stone-700);
    font-size: 14px;
    font-weight: 750;
}

.detail-section {
    margin-top: 26px;
}

.detail-section h2 {
    margin: 0 0 10px;
    font-size: 22px;
    font-weight: 900;
    color: var(--stone-800);
}

.detail-section p {
    margin: 0;
    color: var(--stone-700);
    font-size: 16px;
}

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

.tag-cloud span {
    border-radius: 999px;
    padding: 6px 10px;
    background: var(--amber-100);
    color: var(--amber-800);
    font-weight: 750;
    font-size: 13px;
}

.side-card {
    padding: 18px;
    position: sticky;
    top: 84px;
}

.side-card h2 {
    margin: 0 0 16px;
    font-size: 20px;
    font-weight: 900;
}

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

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

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

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

    .side-card {
        position: static;
    }
}

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

    .mobile-menu-button {
        display: block;
    }

    .hero {
        height: 620px;
    }

    .hero-arrow {
        display: none;
    }

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

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

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

    .filter-keyword {
        grid-column: 1 / -1;
    }
}

@media (max-width: 620px) {
    .header-inner {
        width: min(100% - 22px, 1180px);
    }

    .brand-name {
        font-size: 18px;
    }

    .content-section {
        width: min(100% - 24px, 1180px);
        padding: 38px 0;
    }

    .hero {
        height: 650px;
    }

    .hero-content {
        align-items: flex-end;
        padding-bottom: 70px;
    }

    .hero-search {
        border-radius: 22px;
    }

    .hero-search input,
    .hero-search .primary-button {
        width: 100%;
    }

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

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

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

    .rank-item {
        grid-template-columns: 42px 72px 1fr;
    }

    .rank-action {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .detail-shell {
        width: min(100% - 24px, 1180px);
        padding-top: 28px;
    }

    .detail-content {
        padding: 18px;
    }

    .movie-card-horizontal .movie-card-link {
        grid-template-columns: 118px 1fr;
    }

    .horizontal-thumb {
        height: 104px;
    }
}
