:root {
    --primary-50: #eff6ff;
    --primary-100: #dbeafe;
    --primary-500: #3b82f6;
    --primary-600: #1e40af;
    --primary-700: #1e3a8a;
    --secondary-50: #f0fdf4;
    --secondary-100: #dcfce7;
    --secondary-600: #065f46;
    --accent-50: #fef3c7;
    --accent-100: #fde68a;
    --accent-600: #92400e;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-900: #111827;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
    --shadow-md: 0 8px 18px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 18px 40px rgba(15, 23, 42, 0.14);
    --shadow-hero: 0 28px 70px rgba(15, 23, 42, 0.35);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--gray-50);
    color: var(--gray-900);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Roboto, Arial, sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(16px);
}

.header-inner {
    max-width: 1280px;
    height: 64px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.brand-mark {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-600), var(--secondary-600));
    box-shadow: 0 10px 22px rgba(30, 64, 175, 0.22);
}

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

.brand-text strong {
    color: var(--primary-600);
    font-size: 20px;
}

.brand-text small {
    color: var(--gray-500);
    font-size: 12px;
    margin-top: 3px;
}

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

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

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

.header-search,
.mobile-search {
    display: flex;
    align-items: center;
    border: 1px solid var(--gray-300);
    border-radius: 14px;
    overflow: hidden;
    background: var(--white);
}

.header-search input,
.mobile-search input {
    width: 220px;
    border: 0;
    outline: 0;
    padding: 10px 12px;
    background: transparent;
}

.header-search button,
.mobile-search button,
.btn-primary,
.btn-light,
.btn-outline {
    border: 0;
    border-radius: 12px;
    padding: 10px 18px;
    font-weight: 700;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.header-search button,
.btn-primary {
    background: var(--primary-600);
    color: var(--white);
}

.header-search button:hover,
.btn-primary:hover {
    background: var(--primary-700);
    transform: translateY(-1px);
}

.btn-light {
    background: var(--white);
    color: var(--primary-600);
}

.btn-light:hover {
    background: var(--gray-100);
    transform: translateY(-1px);
}

.btn-outline {
    color: var(--white);
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.45);
}

.btn-outline:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    background: var(--gray-100);
    color: var(--gray-700);
    font-size: 22px;
}

.mobile-panel {
    display: none;
    border-top: 1px solid var(--gray-200);
    padding: 16px 24px 22px;
}

.mobile-panel.is-open {
    display: block;
}

.mobile-panel nav {
    display: grid;
    gap: 14px;
    margin-top: 16px;
}

.mobile-search input {
    width: 100%;
    flex: 1;
}

.page-main {
    min-height: 60vh;
}

.hero {
    position: relative;
    color: var(--white);
    background: radial-gradient(circle at 15% 15%, rgba(59, 130, 246, 0.62), transparent 32%), linear-gradient(135deg, var(--primary-600), var(--primary-700) 48%, var(--secondary-600));
    overflow: hidden;
}

.hero-inner,
.container {
    width: min(1280px, calc(100% - 48px));
    margin: 0 auto;
}

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

.hero-copy {
    text-align: center;
    max-width: 820px;
    margin: 0 auto 42px;
}

.hero-copy .eyebrow,
.detail-eyebrow {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 6px 14px;
    color: var(--primary-600);
    background: rgba(255, 255, 255, 0.92);
    font-weight: 800;
    font-size: 14px;
    margin-bottom: 16px;
}

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

.hero-copy p {
    margin: 0 auto;
    color: #dbeafe;
    font-size: 20px;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

.hero-carousel {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    box-shadow: var(--shadow-hero);
    background: #0f172a;
}

.hero-slide {
    display: none;
    position: relative;
    min-height: 500px;
}

.hero-slide.is-active {
    display: block;
}

.hero-slide img {
    width: 100%;
    height: 500px;
    object-fit: cover;
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.25) 52%, rgba(0, 0, 0, 0.06));
}

.hero-slide-content {
    position: absolute;
    z-index: 2;
    left: 42px;
    right: 42px;
    bottom: 40px;
    max-width: 720px;
}

.hero-slide-content .pill,
.pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 6px 12px;
    background: var(--primary-500);
    color: var(--white);
    font-size: 14px;
    font-weight: 800;
    margin-bottom: 14px;
}

.hero-slide-content h2 {
    margin: 0 0 14px;
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.1;
}

.hero-slide-content p {
    margin: 0 0 20px;
    color: var(--gray-200);
    font-size: 18px;
}

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

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

.carousel-arrow.prev {
    left: 18px;
}

.carousel-arrow.next {
    right: 18px;
}

.carousel-dots {
    position: absolute;
    z-index: 4;
    left: 50%;
    bottom: 20px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 8px;
}

.carousel-dots button {
    width: 9px;
    height: 9px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    transition: width 0.2s ease, background 0.2s ease;
}

.carousel-dots button.is-active {
    width: 34px;
    background: var(--white);
}

.section {
    padding: 64px 0;
}

.section-soft {
    background: linear-gradient(135deg, var(--secondary-50), var(--primary-50));
}

.section-warm {
    background: linear-gradient(135deg, var(--accent-50), var(--secondary-50));
}

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

.section-heading h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 36px);
    line-height: 1.18;
}

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

.section-link {
    color: var(--primary-600);
    font-weight: 800;
    white-space: nowrap;
}

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

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

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

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

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--gray-200);
}

.poster-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.52), transparent 62%);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.movie-card:hover .poster-shade {
    opacity: 1;
}

.play-dot {
    position: absolute;
    right: 14px;
    bottom: 14px;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.92);
    color: var(--primary-600);
    font-size: 16px;
    font-weight: 900;
    opacity: 0;
    transform: scale(0.9);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-dot {
    opacity: 1;
    transform: scale(1);
}

.card-body {
    padding: 16px;
}

.card-meta {
    color: var(--gray-500);
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 7px;
}

.card-body h3 {
    margin: 0 0 8px;
    font-size: 17px;
    line-height: 1.28;
}

.card-body h3 a:hover {
    color: var(--primary-600);
}

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

.tag-row {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.tag-row span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 4px 9px;
    color: var(--primary-600);
    background: var(--primary-50);
    font-size: 12px;
    font-weight: 700;
}

.compact-card {
    border-radius: 18px;
}

.compact-link {
    display: grid;
    grid-template-columns: 92px 1fr;
    gap: 14px;
    padding: 12px;
}

.compact-link img {
    width: 92px;
    height: 120px;
    border-radius: 14px;
    object-fit: cover;
}

.compact-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.compact-info strong {
    font-size: 18px;
    line-height: 1.28;
}

.compact-info em {
    margin: 8px 0;
    color: var(--gray-500);
    font-size: 13px;
    font-style: normal;
    font-weight: 700;
}

.compact-info small {
    color: var(--gray-600);
    font-size: 14px;
}

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

.category-card {
    min-height: 210px;
    padding: 26px;
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--shadow-md);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.category-card strong {
    display: block;
    font-size: 24px;
    margin-bottom: 10px;
}

.category-card p {
    margin: 0 0 22px;
    color: var(--gray-600);
}

.category-card span {
    color: var(--primary-600);
    font-weight: 800;
}

.page-hero {
    padding: 58px 0;
    color: var(--white);
    background: linear-gradient(135deg, var(--primary-600), var(--secondary-600));
}

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(32px, 5vw, 52px);
    line-height: 1.1;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: #dbeafe;
    font-size: 18px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 180px 180px;
    gap: 14px;
    padding: 20px;
    margin: -30px auto 40px;
    border-radius: 22px;
    background: var(--white);
    box-shadow: var(--shadow-lg);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid var(--gray-300);
    border-radius: 14px;
    outline: none;
    padding: 12px 14px;
    background: var(--white);
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--primary-500);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 58px 110px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 14px;
    border-radius: 20px;
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.rank-number {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, var(--accent-600), var(--primary-600));
    font-weight: 900;
}

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

.rank-info h3 {
    margin: 0 0 6px;
    font-size: 20px;
}

.rank-info p {
    margin: 0;
    color: var(--gray-600);
}

.rank-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 12px;
    color: var(--primary-600);
    background: var(--primary-50);
    font-weight: 800;
}

.detail-hero {
    position: relative;
    color: var(--white);
    overflow: hidden;
    background: #0f172a;
}

.detail-bg {
    position: absolute;
    inset: 0;
    opacity: 0.36;
}

.detail-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(10px) saturate(1.1);
    transform: scale(1.08);
}

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.72));
}

.detail-wrap {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 36px;
    padding: 62px 0;
}

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: var(--shadow-hero);
}

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

.detail-info h1 {
    margin: 0 0 16px;
    font-size: clamp(32px, 5vw, 58px);
    line-height: 1.08;
}

.detail-info .summary-line {
    margin: 0 0 22px;
    color: var(--gray-200);
    font-size: 19px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin: 26px 0;
}

.info-item {
    padding: 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.info-item span {
    display: block;
    color: var(--gray-300);
    font-size: 13px;
}

.info-item strong {
    display: block;
    margin-top: 4px;
    color: var(--white);
}

.breadcrumb {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
    color: var(--gray-300);
    margin-bottom: 16px;
}

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

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

.content-card,
.side-card {
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--shadow-md);
    padding: 26px;
}

.content-card + .content-card {
    margin-top: 24px;
}

.content-card h2,
.side-card h2 {
    margin: 0 0 18px;
    font-size: 26px;
}

.content-card p {
    margin: 0;
    color: var(--gray-700);
    font-size: 17px;
    line-height: 1.85;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    background: #050816;
    box-shadow: var(--shadow-lg);
    aspect-ratio: 16 / 9;
}

.player-box video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #050816;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.18));
}

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

.player-play {
    width: 92px;
    height: 92px;
    border: 0;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-600);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-lg);
    font-size: 34px;
    font-weight: 900;
    transition: transform 0.2s ease, background 0.2s ease;
}

.player-play:hover {
    transform: scale(1.06);
    background: var(--white);
}

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

.side-link {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    align-items: center;
}

.side-link img {
    width: 72px;
    height: 92px;
    border-radius: 12px;
    object-fit: cover;
}

.side-link strong {
    display: block;
    line-height: 1.35;
}

.side-link span {
    display: block;
    margin-top: 4px;
    color: var(--gray-500);
    font-size: 13px;
}

.site-footer {
    margin-top: 40px;
    color: var(--gray-300);
    background: var(--gray-900);
}

.footer-inner {
    width: min(1280px, calc(100% - 48px));
    margin: 0 auto;
    padding: 44px 0;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
}

.footer-brand strong {
    display: block;
    color: var(--white);
    font-size: 22px;
}

.footer-brand p {
    margin: 8px 0 0;
    max-width: 480px;
    color: var(--gray-400);
}

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

.footer-col ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 8px;
}

.footer-col a:hover {
    color: #93c5fd;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 18px 24px;
    color: var(--gray-400);
    text-align: center;
}

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

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

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

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

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

@media (max-width: 860px) {
    .hero-inner,
    .container,
    .footer-inner {
        width: min(100% - 32px, 1280px);
    }

    .hero-inner {
        padding: 46px 0 54px;
    }

    .hero-slide,
    .hero-slide img {
        min-height: 420px;
        height: 420px;
    }

    .hero-slide-content {
        left: 24px;
        right: 24px;
        bottom: 34px;
    }

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

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

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

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

    .rank-item {
        grid-template-columns: 48px 88px 1fr;
    }

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

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

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

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

    .footer-inner {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .header-inner {
        padding: 0 16px;
    }

    .brand-text small {
        display: none;
    }

    .hero h1,
    .detail-info h1,
    .page-hero h1 {
        font-size: 32px;
    }

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

    .hero-slide,
    .hero-slide img {
        min-height: 380px;
        height: 380px;
    }

    .carousel-arrow {
        width: 38px;
        height: 38px;
    }

    .card-body {
        padding: 13px;
    }

    .card-body p {
        min-height: 0;
    }

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

    .compact-link {
        grid-template-columns: 82px 1fr;
    }

    .compact-link img {
        width: 82px;
        height: 108px;
    }

    .player-play {
        width: 74px;
        height: 74px;
        font-size: 28px;
    }
}
