:root {
    --rose-950: #4c0519;
    --rose-900: #881337;
    --rose-800: #9f1239;
    --rose-700: #be123c;
    --rose-600: #e11d48;
    --rose-100: #ffe4e6;
    --rose-50: #fff1f2;
    --amber-900: #78350f;
    --amber-800: #92400e;
    --amber-700: #b45309;
    --amber-600: #d97706;
    --amber-500: #f59e0b;
    --amber-400: #fbbf24;
    --amber-100: #fef3c7;
    --amber-50: #fffbeb;
    --gray-900: #111827;
    --gray-800: #1f2937;
    --gray-700: #374151;
    --gray-600: #4b5563;
    --gray-500: #6b7280;
    --gray-200: #e5e7eb;
    --white: #ffffff;
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.12), 0 4px 6px -4px rgba(0, 0, 0, 0.12);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.16), 0 8px 10px -6px rgba(0, 0, 0, 0.16);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 12px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--gray-800);
    background: linear-gradient(180deg, var(--rose-50), var(--amber-50) 42%, var(--white));
}

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: var(--white);
    background: linear-gradient(90deg, var(--rose-900), var(--rose-800), var(--amber-900));
    box-shadow: var(--shadow-lg);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 64px;
    gap: 22px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.logo-mark {
    display: inline-grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    background: linear-gradient(135deg, #fb7185, var(--amber-400));
    box-shadow: var(--shadow-lg);
    transition: transform 0.25s ease;
}

.site-logo:hover .logo-mark {
    transform: scale(1.08);
}

.logo-text {
    font-size: 20px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
}

.nav-link {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.92);
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: #fde68a;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select {
    border: 0;
    outline: 0;
    font: inherit;
}

.header-search input {
    width: 240px;
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--gray-800);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
}

.header-search button,
.mobile-search button {
    border: 0;
    border-radius: 999px;
    padding: 10px 16px;
    color: var(--rose-900);
    background: #fde68a;
    font-weight: 700;
    cursor: pointer;
}

.mobile-menu-button {
    display: none;
    border: 0;
    background: transparent;
    color: var(--white);
    font-size: 28px;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
}

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

.mobile-search {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
}

.mobile-search input {
    min-width: 0;
    padding: 11px 14px;
    border-radius: 999px;
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    color: var(--white);
    background: var(--gray-900);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.7s ease;
}

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

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

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.64), rgba(0, 0, 0, 0.18));
}

.hero-content {
    position: relative;
    z-index: 2;
    height: 100%;
    display: flex;
    align-items: center;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--amber-400);
    font-weight: 700;
    letter-spacing: 0.04em;
}

.hero h1 {
    margin: 14px 0 16px;
    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero p {
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 20px;
    line-height: 1.7;
}

.hero-meta,
.detail-meta,
.breadcrumbs,
.inline-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-meta span,
.detail-meta span,
.inline-tags span,
.card-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.hero-meta span:first-child,
.inline-tags span,
.card-tags span {
    color: var(--white);
    background: var(--rose-600);
}

.hero-meta span:not(:first-child),
.detail-meta span {
    color: rgba(255, 255, 255, 0.88);
    background: rgba(255, 255, 255, 0.12);
}

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

.primary-button,
.secondary-button,
.section-more,
.load-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.primary-button {
    padding: 15px 28px;
    color: var(--white);
    background: linear-gradient(90deg, var(--rose-600), var(--amber-600));
    box-shadow: var(--shadow-lg);
}

.primary-button:hover,
.secondary-button:hover,
.load-link:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: var(--shadow-xl);
}

.secondary-button {
    padding: 14px 24px;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
}

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

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

.hero-dot.is-active {
    width: 34px;
    background: var(--amber-400);
}

.page-section {
    padding: 64px 0;
}

.page-section.soft {
    background: linear-gradient(90deg, var(--rose-100), var(--amber-100));
}

.page-section.dark-cta {
    color: var(--white);
    text-align: center;
    background: linear-gradient(90deg, var(--rose-900), var(--amber-900));
}

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

.section-heading h1,
.section-heading h2 {
    margin: 6px 0 0;
    color: var(--gray-800);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
}

.dark-cta .section-heading h2,
.dark-cta .section-heading h1 {
    color: var(--white);
}

.section-more {
    padding: 10px 16px;
    color: var(--rose-700);
    background: rgba(255, 255, 255, 0.75);
}

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

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

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

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

.card-cover {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, var(--rose-100), var(--amber-100));
}

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

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

.play-pill,
.rank-badge {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--white);
    font-weight: 800;
}

.play-pill {
    left: 14px;
    bottom: 14px;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.58);
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-pill {
    opacity: 1;
    transform: translateY(0);
}

.rank-badge {
    top: 12px;
    left: 12px;
    width: 38px;
    height: 38px;
    background: linear-gradient(135deg, var(--rose-600), var(--amber-500));
    box-shadow: var(--shadow-lg);
}

.card-body {
    padding: 16px;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}

.card-tags span {
    min-height: 24px;
    padding: 4px 8px;
    font-size: 12px;
    background: var(--rose-600);
}

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

.card-body h3 a:hover {
    color: var(--rose-800);
}

.card-body p {
    margin: 0 0 12px;
    color: var(--gray-600);
    font-size: 14px;
    line-height: 1.7;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--gray-500);
    font-size: 12px;
}

.card-compact .card-body p {
    display: none;
}

.feature-split {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 24px;
}

.feature-large .card-cover {
    aspect-ratio: 16 / 9;
}

.side-stack {
    display: grid;
    gap: 18px;
}

.filter-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 26px;
    padding: 16px;
    border-radius: var(--radius-lg);
    background: rgba(255, 255, 255, 0.78);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(10px);
}

.filter-input-wrap {
    flex: 1;
    display: grid;
    gap: 8px;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    padding: 13px 14px;
    border-radius: 14px;
    color: var(--gray-800);
    background: var(--rose-50);
}

.filter-selects {
    display: flex;
    gap: 12px;
}

[data-filter-count] {
    color: var(--gray-500);
    font-size: 13px;
}

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

.category-card {
    padding: 22px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-lg);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.category-card h3 {
    margin: 0 0 8px;
    color: var(--rose-800);
    font-size: 22px;
}

.category-card p {
    min-height: 48px;
    margin: 0 0 16px;
    color: var(--gray-600);
    line-height: 1.6;
}

.category-card strong {
    color: var(--amber-700);
}

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

.page-hero h1 {
    max-width: 850px;
    margin: 8px 0 14px;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.1;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
    line-height: 1.7;
}

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

.player-card,
.detail-card,
.sidebar-card {
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

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

.player-wrap video,
.player-poster {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.player-wrap video {
    z-index: 2;
}

.player-poster {
    z-index: 1;
    opacity: 0.68;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    border: 0;
    color: var(--white);
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.22));
    cursor: pointer;
}

.player-overlay span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 94px;
    height: 94px;
    border-radius: 50%;
    font-size: 42px;
    background: linear-gradient(135deg, var(--rose-600), var(--amber-500));
    box-shadow: var(--shadow-xl);
    transition: transform 0.22s ease;
}

.player-overlay:hover span {
    transform: scale(1.08);
}

.player-note {
    padding: 16px 20px;
    color: var(--gray-600);
    background: var(--amber-50);
}

.detail-card {
    padding: 26px;
}

.detail-card h2,
.sidebar-card h2 {
    margin: 0 0 14px;
    color: var(--gray-800);
}

.detail-card p {
    margin: 0 0 18px;
    color: var(--gray-700);
    line-height: 1.9;
}

.breadcrumbs {
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
}

.breadcrumbs a:hover {
    color: #fde68a;
}

.sidebar-card {
    padding: 20px;
}

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

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

.sidebar-item img {
    width: 82px;
    height: 110px;
    object-fit: cover;
    border-radius: 12px;
    background: var(--rose-100);
}

.sidebar-item h3 {
    margin: 0 0 6px;
    font-size: 15px;
    line-height: 1.45;
}

.sidebar-item p {
    margin: 0;
    color: var(--gray-500);
    font-size: 12px;
}

.site-footer {
    padding: 42px 0;
    color: rgba(255, 255, 255, 0.86);
    background: var(--gray-900);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 30px;
}

.footer-logo {
    margin-bottom: 14px;
}

.site-footer h3 {
    margin: 0 0 12px;
    color: var(--white);
}

.site-footer a {
    display: block;
    margin: 8px 0;
    color: rgba(255, 255, 255, 0.76);
}

.site-footer a:hover {
    color: #fde68a;
}

.hidden-by-filter {
    display: none !important;
}

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

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

@media (max-width: 820px) {
    .desktop-nav,
    .header-search {
        display: none;
    }

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

    .hero {
        height: 560px;
    }

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

    .hero-actions,
    .section-heading,
    .filter-panel,
    .filter-selects,
    .footer-grid,
    .feature-split {
        flex-direction: column;
        display: grid;
        align-items: stretch;
    }

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

@media (max-width: 520px) {
    .container {
        width: min(100% - 22px, 1180px);
    }

    .logo-text {
        font-size: 17px;
    }

    .hero {
        height: 620px;
    }

    .hero h1 {
        font-size: 40px;
    }

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

    .card-cover {
        aspect-ratio: 16 / 10;
    }
}
