:root {
    --sky-50: #f0f9ff;
    --sky-100: #e0f2fe;
    --sky-500: #0ea5e9;
    --sky-600: #0284c7;
    --sky-700: #0369a1;
    --blue-50: #eff6ff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --white: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --soft-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 14px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

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: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid rgba(186, 230, 253, 0.9);
    backdrop-filter: blur(18px);
}

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

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

.brand-mark,
.footer-brand span {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, var(--sky-500), var(--sky-700));
    box-shadow: 0 10px 25px rgba(14, 165, 233, 0.35);
}

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

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

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

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 26px;
    color: var(--gray-700);
    font-weight: 650;
}

.desktop-nav a,
.mobile-nav a,
.footer-links a {
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active,
.footer-links a:hover {
    color: var(--sky-600);
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: var(--gray-700);
    background: var(--sky-50);
    cursor: pointer;
}

.mobile-nav {
    display: none;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px 16px;
}

.mobile-nav a {
    display: block;
    padding: 12px 14px;
    border-radius: 12px;
    color: var(--gray-700);
}

.mobile-nav a:hover,
.mobile-nav a.active {
    background: var(--sky-100);
}

.page-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 32px 24px 0;
}

.inner-page {
    padding-top: 38px;
}

.hero-carousel {
    position: relative;
    height: 520px;
    overflow: hidden;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    background: var(--gray-900);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 64px;
    background-position: center;
    background-size: cover;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 1.2s ease;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-layer {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.42) 58%, rgba(2, 132, 199, 0.12));
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(680px, 100%);
    color: var(--white);
}

.hero-kicker,
.detail-kicker,
.page-hero span {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 7px 14px;
    border-radius: 999px;
    color: var(--white);
    background: var(--sky-500);
    font-size: 14px;
    font-weight: 700;
}

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

.hero-content p {
    max-width: 620px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.8;
}

.hero-tags,
.detail-meta-grid,
.movie-meta,
.tag-list,
.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-tags span,
.tag-list span {
    padding: 7px 12px;
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.92);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

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

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

.primary-button {
    color: var(--white);
    background: linear-gradient(135deg, var(--sky-500), var(--sky-700));
    box-shadow: 0 16px 30px rgba(14, 165, 233, 0.34);
}

.primary-button:hover,
.ghost-button:hover,
.movie-card:hover,
.category-card:hover,
.category-hero-card:hover,
.mini-card:hover {
    transform: translateY(-3px);
}

.ghost-button {
    color: var(--sky-700);
    background: rgba(255, 255, 255, 0.92);
}

.hero-dots {
    position: absolute;
    right: 32px;
    bottom: 30px;
    z-index: 5;
    display: flex;
    gap: 9px;
}

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

.hero-dot.active {
    width: 30px;
    background: var(--white);
}

.search-band,
.filter-panel,
.content-card,
.side-column,
.soft-block {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(224, 242, 254, 0.95);
    box-shadow: var(--soft-shadow);
}

.search-band {
    margin: 30px 0 56px;
    padding: 28px;
    display: grid;
    grid-template-columns: 1fr minmax(280px, 420px);
    gap: 24px;
    align-items: center;
    border-radius: var(--radius-xl);
}

.search-band h2,
.section-heading h2,
.page-hero h1,
.detail-info h1,
.content-card h2,
.side-column h2 {
    margin: 0;
    color: var(--gray-800);
}

.search-band p,
.page-hero p,
.content-card p,
.detail-one-line,
.movie-info p,
.category-card small,
.category-hero-card small,
.footer-inner p {
    color: var(--gray-600);
    line-height: 1.75;
}

.home-search,
.filter-search {
    display: flex;
    gap: 10px;
}

.home-search input,
.filter-search input {
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    border: 1px solid var(--gray-200);
    border-radius: 14px;
    color: var(--gray-800);
    background: var(--white);
    outline: none;
}

.home-search input:focus,
.filter-search input:focus {
    border-color: var(--sky-500);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.16);
}

.home-search button,
.filter-search button,
.filter-button {
    border: 0;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 750;
}

.home-search button,
.filter-search button {
    min-width: 82px;
    color: var(--white);
    background: var(--sky-600);
}

.section-block {
    margin-bottom: 64px;
}

.highlight-block {
    padding: 30px;
    border-radius: var(--radius-xl);
    background: linear-gradient(120deg, var(--sky-100), var(--blue-50));
    box-shadow: var(--soft-shadow);
}

.soft-block {
    padding: 30px;
    border-radius: var(--radius-xl);
}

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

.section-heading.compact {
    margin-bottom: 18px;
}

.section-heading h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 850;
}

.section-heading h2 span {
    width: 5px;
    height: 34px;
    border-radius: 999px;
    background: var(--sky-600);
}

.section-heading a {
    color: var(--sky-600);
    font-weight: 800;
}

.grid {
    display: grid;
    gap: 24px;
}

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

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    box-shadow: 0 22px 44px rgba(15, 23, 42, 0.15);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, var(--sky-100), var(--gray-100));
}

.movie-card.large .poster-link,
.movie-card.ranked .poster-link {
    aspect-ratio: 16 / 9;
}

.movie-card.small .poster-link {
    aspect-ratio: 1.2 / 1;
}

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

.movie-card:hover img,
.category-card:hover img,
.category-hero-card:hover img,
.mini-card:hover img,
.detail-poster:hover img {
    transform: scale(1.07);
}

.card-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.74), rgba(15, 23, 42, 0.06));
    opacity: 0;
    transition: opacity 0.2s ease;
}

.play-bubble {
    position: absolute;
    inset: 50% auto auto 50%;
    width: 58px;
    height: 58px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--sky-600);
    background: rgba(255, 255, 255, 0.94);
    transform: translate(-50%, -50%) scale(0.6);
    opacity: 0;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.movie-card:hover .card-shade,
.movie-card:hover .play-bubble {
    opacity: 1;
}

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

.rank-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, #f97316, #ef4444);
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.28);
}

.movie-info {
    padding: 16px;
}

.movie-info h3 {
    margin: 0 0 8px;
    color: var(--gray-800);
    font-size: 17px;
    line-height: 1.35;
    font-weight: 800;
}

.movie-info h3 a:hover {
    color: var(--sky-600);
}

.movie-info p {
    min-height: 48px;
    margin: 0 0 12px;
    font-size: 14px;
}

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

.movie-meta span:last-child {
    color: var(--sky-700);
    background: var(--sky-100);
    border-radius: 999px;
    padding: 2px 8px;
}

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

.category-card,
.category-hero-card {
    display: grid;
    grid-template-columns: 96px 1fr;
    gap: 16px;
    align-items: center;
    padding: 14px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--soft-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card img,
.category-hero-card img {
    width: 96px;
    height: 72px;
    border-radius: 14px;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.category-card strong,
.category-hero-card strong {
    display: block;
    margin-bottom: 7px;
    color: var(--gray-800);
    font-size: 17px;
}

.category-card small,
.category-hero-card small {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 13px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    margin-bottom: 28px;
    padding: 42px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--sky-600), var(--sky-700));
    box-shadow: var(--shadow);
    color: var(--white);
}

.page-hero.slim {
    min-height: 220px;
}

.page-hero span {
    color: var(--sky-700);
    background: rgba(255, 255, 255, 0.95);
}

.page-hero h1 {
    margin: 18px 0 12px;
    color: var(--white);
    font-size: clamp(30px, 5vw, 48px);
    font-weight: 850;
}

.page-hero p {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 17px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-bottom: 18px;
    color: var(--gray-500);
    font-size: 14px;
}

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

.filter-panel {
    margin-bottom: 30px;
    padding: 22px;
    border-radius: var(--radius-xl);
}

.filter-panel.wide {
    display: grid;
    gap: 20px;
}

.chip-group strong {
    display: block;
    margin-bottom: 10px;
    color: var(--gray-700);
}

.chip-row {
    gap: 10px;
}

.filter-button {
    padding: 9px 14px;
    color: var(--gray-700);
    background: var(--gray-100);
}

.filter-button:hover,
.filter-button.active {
    color: var(--white);
    background: var(--sky-600);
}

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

.category-overview {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--soft-shadow);
}

.category-hero-card {
    grid-template-columns: 140px 1fr;
    padding: 0;
    box-shadow: none;
}

.category-hero-card img {
    width: 140px;
    height: 100px;
}

.category-preview-list,
.mini-list {
    display: grid;
    gap: 10px;
}

.mini-card {
    position: relative;
    display: grid;
    grid-template-columns: 70px 1fr auto;
    gap: 12px;
    align-items: center;
    min-height: 78px;
    padding: 8px;
    border-radius: 16px;
    background: var(--white);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease;
}

.mini-card img {
    width: 70px;
    height: 62px;
    border-radius: 12px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.mini-body {
    min-width: 0;
}

.mini-body strong,
.mini-body small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mini-body strong {
    color: var(--gray-800);
}

.mini-body small {
    margin-top: 6px;
    color: var(--gray-500);
    font-size: 12px;
}

.mini-rank {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--white);
    background: var(--sky-600);
    font-size: 12px;
    font-weight: 800;
}

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

.side-column {
    position: sticky;
    top: 92px;
    padding: 22px;
    border-radius: var(--radius-xl);
}

.side-column h2 {
    margin-bottom: 18px;
    font-size: 22px;
    font-weight: 850;
}

.detail-hero {
    display: grid;
    grid-template-columns: 330px 1fr;
    gap: 34px;
    align-items: stretch;
    padding: 28px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--white), var(--sky-50));
    box-shadow: var(--shadow);
}

.detail-poster {
    overflow: hidden;
    border-radius: 22px;
    background: var(--gray-100);
}

.detail-poster img {
    width: 100%;
    height: 100%;
    min-height: 430px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.detail-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.detail-info h1 {
    margin: 18px 0 14px;
    font-size: clamp(32px, 5vw, 54px);
    line-height: 1.12;
    font-weight: 900;
}

.detail-one-line {
    max-width: 760px;
    margin: 0 0 20px;
    font-size: 18px;
}

.detail-meta-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.detail-meta-grid span {
    padding: 13px 14px;
    border-radius: 14px;
    color: var(--gray-600);
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid var(--gray-200);
}

.detail-meta-grid b {
    display: block;
    margin-bottom: 4px;
    color: var(--gray-800);
}

.detail-info .tag-list {
    margin-bottom: 26px;
}

.detail-info .tag-list span {
    color: var(--sky-700);
    background: var(--sky-100);
    border-color: transparent;
}

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

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: var(--gray-900);
    box-shadow: var(--shadow);
}

.player-box video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: var(--gray-900);
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: var(--white);
    background: radial-gradient(circle at center, rgba(14, 165, 233, 0.32), rgba(15, 23, 42, 0.76));
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.big-play {
    width: 82px;
    height: 82px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--sky-600);
    background: var(--white);
    font-size: 32px;
    box-shadow: 0 20px 50px rgba(255, 255, 255, 0.2);
}

.content-card {
    margin-bottom: 24px;
    padding: 28px;
    border-radius: var(--radius-xl);
}

.content-card h2 {
    margin-bottom: 14px;
    font-size: 26px;
    font-weight: 850;
}

.content-card p {
    margin: 0;
    font-size: 16px;
}

.empty-state {
    padding: 30px;
    border-radius: var(--radius-lg);
    color: var(--gray-500);
    text-align: center;
    background: var(--white);
}

.site-footer {
    margin-top: 80px;
    border-top: 1px solid var(--gray-200);
    background: linear-gradient(180deg, var(--gray-50), var(--gray-100));
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 42px 24px 24px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 32px;
    align-items: center;
}

.footer-brand {
    margin-bottom: 12px;
}

.footer-brand strong {
    color: var(--gray-800);
    font-size: 20px;
}

.footer-inner p {
    max-width: 760px;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 18px;
    color: var(--gray-600);
    font-weight: 700;
}

.copyright {
    max-width: 1280px;
    margin: 0 auto;
    padding: 20px 24px 34px;
    color: var(--gray-500);
    text-align: center;
    font-size: 13px;
}

@media (max-width: 1080px) {
    .cards-small {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

    .two-column-page,
    .detail-hero {
        grid-template-columns: 1fr;
    }

    .side-column {
        position: static;
    }
}

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

    .mobile-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-nav.open {
        display: block;
    }

    .header-inner,
    .page-wrap,
    .footer-inner,
    .copyright {
        padding-left: 18px;
        padding-right: 18px;
    }

    .hero-carousel {
        height: 560px;
        border-radius: 0 0 24px 24px;
        margin-left: -18px;
        margin-right: -18px;
    }

    .hero-slide {
        padding: 34px 22px 72px;
    }

    .hero-dots {
        left: 22px;
        right: auto;
    }

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

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

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

    .detail-poster img {
        min-height: 360px;
    }
}

@media (max-width: 560px) {
    .brand-text strong {
        font-size: 18px;
    }

    .brand-text small {
        display: none;
    }

    .home-search,
    .filter-search,
    .hero-actions,
    .footer-links {
        flex-direction: column;
    }

    .cards-large,
    .cards-normal,
    .cards-small,
    .category-overview-grid {
        grid-template-columns: 1fr;
    }

    .movie-card.small .poster-link,
    .poster-link {
        aspect-ratio: 16 / 10;
    }

    .page-hero,
    .detail-hero,
    .highlight-block,
    .soft-block,
    .content-card {
        padding: 22px;
    }

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