:root {
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-600: #2563eb;
    --blue-700: #1d4ed8;
    --blue-900: #1e3a8a;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-500: #64748b;
    --slate-700: #334155;
    --slate-900: #0f172a;
    --white: #ffffff;
    --shadow: 0 24px 60px rgba(15, 23, 42, 0.14);
    --soft-shadow: 0 16px 35px rgba(15, 23, 42, 0.08);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
}

body {
    min-height: 100vh;
    background: var(--slate-50);
    color: var(--slate-900);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    backdrop-filter: blur(18px);
}

.header-inner {
    width: min(1240px, calc(100% - 32px));
    min-height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 22px;
}

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--slate-900);
    white-space: nowrap;
}

.logo-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-600), var(--blue-900));
    box-shadow: 0 10px 28px rgba(37, 99, 235, 0.35);
}

.logo-text {
    font-size: 20px;
    letter-spacing: -0.02em;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    color: var(--slate-700);
    font-size: 15px;
    transition: all 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--blue-700);
    background: var(--blue-50);
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px;
    border: 1px solid var(--slate-200);
    border-radius: 999px;
    background: var(--white);
}

.header-search input,
.page-filter input {
    border: 0;
    outline: 0;
    color: var(--slate-900);
    background: transparent;
}

.header-search input {
    width: 150px;
    padding: 0 8px;
}

.header-search button,
.primary-button,
.secondary-button,
.wide-link,
.small-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 700;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search button,
.primary-button,
.wide-link {
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-600), var(--blue-900));
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
}

.header-search button {
    height: 34px;
    padding: 0 14px;
}

.primary-button,
.secondary-button {
    min-height: 46px;
    padding: 0 22px;
}

.primary-button:hover,
.secondary-button:hover,
.wide-link:hover,
.header-search button:hover {
    transform: translateY(-2px);
}

.secondary-button {
    color: var(--white);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.32);
}

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

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--blue-50);
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 4px auto;
    background: var(--blue-700);
}

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

.hero {
    position: relative;
    overflow: hidden;
    color: var(--white);
    background: radial-gradient(circle at top left, rgba(96, 165, 250, 0.6), transparent 35%), linear-gradient(135deg, #2563eb 0%, #1d4ed8 48%, #172554 100%);
}

.hero-grid-bg {
    position: absolute;
    inset: 0;
    opacity: 0.16;
    background-image: linear-gradient(rgba(255, 255, 255, 0.18) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.18) 1px, transparent 1px);
    background-size: 32px 32px;
}

.hero-inner {
    position: relative;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 36px;
    padding: 86px 0 72px;
}

.hero-slider {
    position: relative;
    min-height: 560px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 42px;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(18px);
    transition: opacity 0.45s ease, transform 0.45s ease, visibility 0.45s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    margin-bottom: 14px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #bfdbfe;
    background: rgba(255, 255, 255, 0.12);
    font-size: 14px;
    font-weight: 700;
}

.hero h1,
.sub-hero h1,
.detail-info h1 {
    font-size: clamp(34px, 5vw, 64px);
    line-height: 1.06;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 640px;
    margin-top: 22px;
    color: #dbeafe;
    font-size: 19px;
    line-height: 1.85;
}

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

.hero-tags {
    margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.detail-tags span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.hero-tags span,
.detail-tags span {
    padding: 7px 11px;
    color: #dbeafe;
    background: rgba(255, 255, 255, 0.14);
}

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

.hero-poster {
    position: relative;
    height: 480px;
    overflow: hidden;
    border: 10px solid rgba(255, 255, 255, 0.14);
    border-radius: 34px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.35);
}

.hero-poster span {
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 16px;
    padding: 11px 14px;
    border-radius: 16px;
    color: var(--white);
    background: rgba(15, 23, 42, 0.72);
    backdrop-filter: blur(12px);
    font-weight: 800;
}

.hero-controls {
    position: absolute;
    left: 0;
    bottom: 0;
    display: inline-flex;
    align-items: center;
    gap: 14px;
}

.hero-prev,
.hero-next,
.hero-dot {
    color: var(--white);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.24);
}

.hero-prev,
.hero-next {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    font-size: 30px;
    line-height: 1;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    opacity: 0.65;
}

.hero-dot.is-active {
    width: 32px;
    opacity: 1;
    background: var(--white);
}

.hero-side {
    display: grid;
    align-content: center;
    gap: 16px;
}

.hero-stat-card,
.hero-mini-card {
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.18);
    backdrop-filter: blur(12px);
}

.hero-stat-card {
    padding: 22px;
}

.hero-stat-card strong {
    display: block;
    font-size: 34px;
    line-height: 1;
}

.hero-stat-card span {
    display: block;
    margin-top: 8px;
    color: #bfdbfe;
}

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

.hero-mini-card {
    display: grid;
    grid-template-columns: 68px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    color: var(--white);
}

.hero-mini-card img {
    height: 76px;
    border-radius: 16px;
}

.hero-mini-card span {
    font-weight: 800;
    line-height: 1.35;
}

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

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

.section-heading h2,
.detail-content h2,
.ranking-panel h2 {
    color: var(--slate-900);
    font-size: clamp(26px, 3vw, 38px);
    font-weight: 900;
    letter-spacing: -0.04em;
}

.section-heading p,
.sub-hero p,
.detail-content p,
.category-overview-body p,
.ranking-info p {
    margin-top: 8px;
    color: var(--slate-500);
    line-height: 1.8;
}

.section-more {
    color: var(--blue-700);
    font-weight: 800;
}

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

.category-card {
    position: relative;
    min-height: 220px;
    overflow: hidden;
    display: flex;
    align-items: end;
    padding: 22px;
    border-radius: var(--radius-lg);
    color: var(--white);
    box-shadow: var(--soft-shadow);
}

.category-card::after,
.category-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.05), rgba(15, 23, 42, 0.82));
}

.category-card img,
.category-cover img {
    position: absolute;
    inset: 0;
    transition: transform 0.35s ease;
}

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

.category-card div {
    position: relative;
    z-index: 1;
}

.category-card h3 {
    font-size: 22px;
    font-weight: 900;
}

.category-card p {
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.84);
    line-height: 1.7;
}

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

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

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

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.card-cover {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, var(--blue-100), var(--blue-50));
}

.card-cover img,
.ranking-cover img,
.detail-cover img,
.hero-poster img,
.hero-mini-card img {
    transition: transform 0.35s ease;
}

.card-badge,
.card-year {
    position: absolute;
    top: 12px;
    padding: 6px 9px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(15, 23, 42, 0.74);
    font-size: 12px;
    font-weight: 800;
    backdrop-filter: blur(8px);
}

.card-badge {
    left: 12px;
}

.card-year {
    right: 12px;
}

.card-body {
    padding: 16px;
}

.card-body h3 {
    overflow: hidden;
    display: -webkit-box;
    min-height: 48px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 17px;
    font-weight: 900;
    line-height: 1.38;
}

.card-body p {
    overflow: hidden;
    display: -webkit-box;
    min-height: 48px;
    margin-top: 10px;
    color: var(--slate-500);
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 14px;
    line-height: 1.7;
}

.card-meta {
    margin-top: 12px;
    color: var(--blue-700);
    font-size: 13px;
    font-weight: 800;
}

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

.tag-row span {
    padding: 5px 8px;
    color: var(--slate-700);
    background: var(--slate-100);
}

.ranking-panel {
    position: sticky;
    top: 92px;
    padding: 24px;
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.rank-list,
.mini-rank-list {
    display: grid;
    gap: 12px;
    margin-top: 20px;
}

.rank-item {
    display: grid;
    grid-template-columns: 34px 52px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 16px;
    background: var(--slate-50);
}

.rank-number {
    color: var(--blue-700);
    font-weight: 900;
}

.rank-item img {
    width: 52px;
    height: 68px;
    border-radius: 12px;
}

.rank-title {
    font-weight: 900;
}

.rank-meta {
    grid-column: 3;
    color: var(--slate-500);
    font-size: 12px;
}

.wide-link {
    width: 100%;
    height: 46px;
    margin-top: 20px;
}

.sub-hero {
    padding: 72px max(16px, calc((100% - 1240px) / 2)) 64px;
    color: var(--white);
    background: radial-gradient(circle at top right, rgba(59, 130, 246, 0.45), transparent 34%), linear-gradient(135deg, var(--blue-700), #172554);
}

.sub-hero h1 {
    max-width: 850px;
}

.sub-hero p {
    max-width: 760px;
    color: #dbeafe;
    font-size: 18px;
}

.page-filter {
    width: min(680px, 100%);
    margin-top: 28px;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
}

.page-filter input {
    width: 100%;
    height: 48px;
    padding: 0 18px;
    color: var(--white);
}

.page-filter input::placeholder {
    color: #bfdbfe;
}

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

.category-overview-card {
    display: grid;
    grid-template-columns: 220px 1fr;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.category-cover {
    position: relative;
    min-height: 320px;
    overflow: hidden;
}

.category-overview-body {
    padding: 28px;
}

.category-overview-body h2 {
    font-size: 28px;
    font-weight: 900;
}

.category-overview-body .rank-item {
    grid-template-columns: 48px 1fr;
}

.category-overview-body .rank-item img {
    grid-row: span 2;
}

.category-overview-body .rank-meta {
    grid-column: 2;
}

.breadcrumb {
    width: min(1240px, calc(100% - 32px));
    margin: 28px auto 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    color: var(--slate-500);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--blue-700);
    font-weight: 800;
}

.detail-hero {
    width: min(1240px, calc(100% - 32px));
    margin: 26px auto 0;
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 40px;
    align-items: center;
    padding: 34px;
    border-radius: 34px;
    color: var(--white);
    background: radial-gradient(circle at top right, rgba(96, 165, 250, 0.55), transparent 32%), linear-gradient(135deg, #1d4ed8, #172554);
    box-shadow: var(--shadow);
}

.detail-cover {
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 26px;
    border: 8px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.36);
}

.detail-info .lead-text {
    max-width: 780px;
    margin-top: 18px;
    color: #dbeafe;
    font-size: 20px;
    line-height: 1.85;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 22px;
}

.detail-meta span {
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.13);
    color: #dbeafe;
    font-weight: 700;
}

.player-section {
    padding-top: 40px;
}

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

.movie-video {
    width: 100%;
    height: 100%;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 16px;
    color: var(--white);
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.24), rgba(2, 6, 23, 0.78));
    text-align: center;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
    width: 88px;
    height: 88px;
    display: grid;
    place-items: center;
    padding-left: 5px;
    border-radius: 999px;
    color: var(--blue-700);
    background: var(--white);
    font-size: 34px;
    box-shadow: 0 18px 42px rgba(255, 255, 255, 0.18);
}

.player-overlay strong {
    max-width: 90%;
    font-size: clamp(20px, 3vw, 34px);
    font-weight: 900;
}

.detail-content {
    display: grid;
    gap: 18px;
    padding: 34px;
    border-radius: 28px;
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.detail-content p {
    color: var(--slate-700);
    font-size: 17px;
}

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

.ranking-card {
    display: grid;
    grid-template-columns: 150px 1fr;
    overflow: hidden;
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--soft-shadow);
}

.ranking-cover {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3 / 4;
}

.ranking-cover span {
    position: absolute;
    z-index: 1;
    left: 12px;
    top: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(37, 99, 235, 0.92);
    font-weight: 900;
}

.ranking-info {
    padding: 22px;
}

.ranking-info h2 {
    font-size: 22px;
    font-weight: 900;
}

.site-footer {
    margin-top: 40px;
    color: #cbd5e1;
    background: #0f172a;
}

.footer-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-logo {
    color: var(--white);
}

.footer-links {
    display: flex;
    gap: 16px;
}

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

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

@media (max-width: 1100px) {
    .hero-inner,
    .hero-slide,
    .two-column-layout,
    .detail-hero {
        grid-template-columns: 1fr;
    }

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

    .hero-thumb-list {
        grid-column: 1 / -1;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .hero-slider {
        min-height: 960px;
    }

    .hero-poster {
        width: min(420px, 100%);
    }

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

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

    .ranking-panel {
        position: static;
    }
}

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

    .menu-toggle {
        display: block;
        margin-left: auto;
    }

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

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

    .hero-slider {
        min-height: 900px;
    }

    .hero-slide {
        gap: 26px;
    }

    .hero-poster {
        height: 420px;
    }

    .hero-side,
    .hero-thumb-list,
    .category-overview-grid,
    .ranking-grid,
    .footer-inner,
    .category-overview-card,
    .ranking-card {
        grid-template-columns: 1fr;
    }

    .footer-inner {
        align-items: flex-start;
    }

    .category-cover {
        min-height: 260px;
    }

    .detail-hero {
        padding: 22px;
    }

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

@media (max-width: 620px) {
    .content-section {
        padding: 38px 0;
    }

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

    .card-body {
        padding: 12px;
    }

    .card-body h3 {
        font-size: 15px;
    }

    .hero h1,
    .sub-hero h1,
    .detail-info h1 {
        font-size: 34px;
    }

    .hero-slider {
        min-height: 830px;
    }

    .hero-poster {
        height: 360px;
        border-radius: 24px;
    }

    .hero-controls {
        bottom: -6px;
    }

    .section-heading {
        display: block;
    }

    .section-more {
        display: inline-flex;
        margin-top: 12px;
    }

    .rank-item {
        grid-template-columns: 30px 46px 1fr;
    }

    .rank-item img {
        width: 46px;
        height: 62px;
    }

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