:root {
    --emerald-50: #ecfdf5;
    --emerald-100: #d1fae5;
    --emerald-500: #10b981;
    --emerald-600: #059669;
    --emerald-700: #047857;
    --teal-600: #0d9488;
    --cyan-600: #0891b2;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --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 12px 30px rgba(15, 23, 42, 0.10);
    --shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.18);
    --radius-lg: 18px;
    --radius-xl: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(14px);
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 68px;
    gap: 18px;
}

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

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: var(--white);
    background: linear-gradient(135deg, var(--emerald-600), var(--teal-600));
    border-radius: 12px;
    box-shadow: 0 10px 24px rgba(5, 150, 105, 0.25);
    font-size: 14px;
}

.brand-text {
    font-size: 24px;
    letter-spacing: -0.02em;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 18px;
    flex: 1;
}

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

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

.header-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    min-width: 250px;
    border: 1px solid var(--gray-200);
    background: var(--gray-50);
    border-radius: 999px;
}

.header-search input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    padding: 10px 14px;
    color: var(--gray-700);
}

.header-search button {
    border: 0;
    background: var(--emerald-600);
    color: var(--white);
    padding: 10px 16px;
    font-weight: 700;
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: var(--gray-100);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.nav-toggle span {
    width: 20px;
    height: 2px;
    background: var(--gray-700);
    border-radius: 999px;
}

.mobile-menu {
    display: none;
    border-top: 1px solid var(--gray-200);
    background: var(--white);
    padding: 10px 16px 16px;
}

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

.mobile-link {
    padding: 12px 14px;
    color: var(--gray-700);
    font-weight: 700;
    border-radius: 12px;
}

.mobile-link:hover {
    background: var(--gray-100);
}

.hero {
    position: relative;
    min-height: 520px;
    overflow: hidden;
    color: var(--white);
    background: linear-gradient(135deg, var(--emerald-600), var(--teal-600), var(--cyan-600));
}

.hero-slider {
    position: absolute;
    inset: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 1.1s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    mix-blend-mode: overlay;
    opacity: 0.86;
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(3, 7, 18, 0.82), rgba(3, 7, 18, 0.52), rgba(3, 7, 18, 0.22));
}

.hero-content {
    position: relative;
    z-index: 2;
    min-height: 520px;
    display: flex;
    align-items: center;
}

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

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.95);
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 999px;
    backdrop-filter: blur(6px);
    font-weight: 700;
}

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

.hero p {
    max-width: 620px;
    margin: 0 0 28px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
}

.hero-actions,
.section-actions,
.detail-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
}

.btn-primary,
.btn-ghost,
.btn-soft {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 12px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn-primary {
    color: var(--emerald-700);
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover,
.btn-soft:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-ghost {
    color: var(--white);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.26);
}

.btn-soft {
    color: var(--emerald-700);
    background: var(--emerald-50);
    border: 1px solid var(--emerald-100);
}

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

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

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

.section {
    padding: 72px 0 0;
}

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

.section-eyebrow {
    margin: 0 0 8px;
    color: var(--emerald-600);
    font-weight: 800;
}

.section-head h1,
.section-head h2,
.page-hero h1,
.detail-title h1 {
    margin: 0;
    color: var(--gray-900);
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.12;
    letter-spacing: -0.03em;
}

.section-head p,
.page-hero p,
.detail-title p {
    max-width: 760px;
    margin: 12px 0 0;
    color: var(--gray-600);
}

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

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

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

.poster-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 3 / 4;
    background: linear-gradient(135deg, var(--emerald-600), var(--teal-600));
}

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

.movie-card:hover .poster-wrap img,
.category-card:hover img,
.small-movie:hover img,
.ranking-thumb:hover img {
    transform: scale(1.06);
}

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, rgba(3, 7, 18, 0.76));
    opacity: 0.9;
}

.poster-play {
    position: absolute;
    right: 12px;
    bottom: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--emerald-700);
    background: rgba(255, 255, 255, 0.92);
    border-radius: 50%;
    transform: translateY(8px);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    color: var(--gray-500);
    font-size: 13px;
    font-weight: 700;
}

.movie-card h2 {
    margin: 8px 0 8px;
    font-size: 19px;
    line-height: 1.25;
}

.movie-card h2 a:hover,
.ranking-info h2 a:hover,
.detail-recommend a:hover {
    color: var(--emerald-600);
}

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

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

.tag-list span,
.meta-chip {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 10px;
    color: var(--emerald-700);
    background: var(--emerald-50);
    border: 1px solid var(--emerald-100);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    color: var(--white);
    background: var(--gray-900);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
}

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.55;
    transition: transform 0.35s ease;
}

.category-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(3, 7, 18, 0.1), rgba(3, 7, 18, 0.78));
}

.category-card div {
    position: absolute;
    inset: auto 18px 18px;
    z-index: 2;
}

.category-card h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

.category-card p {
    margin: 0;
    color: rgba(255, 255, 255, 0.84);
    font-size: 14px;
}

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

.feature-panel,
.side-panel,
.filter-panel,
.content-panel {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-sm);
}

.feature-panel {
    overflow: hidden;
}

.feature-panel .movie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    padding: 24px;
}

.side-panel {
    padding: 24px;
}

.side-panel h2 {
    margin: 0 0 18px;
    font-size: 22px;
}

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

.small-movie {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 16px;
    transition: background 0.2s ease;
}

.small-movie:hover {
    background: var(--gray-100);
}

.small-movie img {
    width: 76px;
    height: 92px;
    object-fit: cover;
    border-radius: 12px;
    transition: transform 0.25s ease;
}

.small-movie strong {
    display: block;
    margin-bottom: 4px;
    color: var(--gray-900);
}

.small-movie em {
    color: var(--gray-500);
    font-style: normal;
    font-size: 13px;
}

.page-hero {
    padding: 64px 0;
    color: var(--white);
    background: linear-gradient(135deg, var(--emerald-600), var(--teal-600));
}

.page-hero h1,
.page-hero p {
    color: var(--white);
}

.page-hero p {
    color: rgba(255, 255, 255, 0.88);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.86);
    font-weight: 700;
}

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

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 14px;
    padding: 18px;
    margin-bottom: 26px;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid var(--gray-200);
    outline: 0;
    background: var(--gray-50);
    border-radius: 14px;
    padding: 12px 14px;
    color: var(--gray-700);
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--emerald-500);
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

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

.ranking-item {
    display: grid;
    grid-template-columns: 64px 92px minmax(0, 1fr) 86px;
    gap: 18px;
    align-items: center;
    padding: 16px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 22px;
    box-shadow: var(--shadow-sm);
}

.ranking-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    color: var(--emerald-700);
    background: var(--emerald-50);
    border-radius: 16px;
    font-size: 20px;
    font-weight: 900;
}

.ranking-thumb {
    overflow: hidden;
    width: 92px;
    height: 118px;
    border-radius: 14px;
    background: var(--emerald-50);
}

.ranking-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.25s ease;
}

.ranking-info h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

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

.ranking-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    color: var(--white);
    background: var(--emerald-600);
    border-radius: 12px;
    font-weight: 800;
}

.detail-hero {
    padding: 44px 0;
    color: var(--white);
    background: linear-gradient(135deg, #064e3b, var(--teal-600), var(--cyan-600));
}

.detail-hero-inner {
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    gap: 28px;
    align-items: center;
}

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

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

.detail-title h1 {
    color: var(--white);
}

.detail-title p {
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
}

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

.detail-meta .meta-chip {
    color: var(--white);
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.25);
}

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

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

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    padding: 0;
    overflow: hidden;
    color: var(--white);
    background: #000000;
    z-index: 3;
}

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

.player-overlay img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.58;
    filter: saturate(1.04);
}

.player-overlay::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(3, 7, 18, 0.18), rgba(3, 7, 18, 0.78));
}

.player-overlay-content {
    position: relative;
    z-index: 2;
    display: grid;
    justify-items: center;
    gap: 16px;
    text-align: center;
}

.play-orb {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    color: var(--emerald-700);
    background: rgba(255, 255, 255, 0.94);
    border-radius: 50%;
    box-shadow: var(--shadow-lg);
    font-size: 30px;
}

.player-overlay strong {
    max-width: 780px;
    padding: 0 24px;
    font-size: clamp(24px, 4vw, 42px);
    line-height: 1.15;
}

.content-panel {
    padding: 30px;
}

.content-panel h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 16px;
    font-size: 26px;
}

.content-panel h2::before {
    content: "";
    display: inline-block;
    width: 8px;
    height: 30px;
    background: var(--emerald-600);
    border-radius: 999px;
}

.content-panel p {
    margin: 0 0 18px;
    color: var(--gray-700);
    font-size: 17px;
}

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

.detail-recommend a {
    overflow: hidden;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 18px;
    box-shadow: var(--shadow-sm);
}

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

.detail-recommend span {
    display: block;
    padding: 12px;
    font-weight: 800;
    line-height: 1.3;
}

.no-results {
    display: none;
    padding: 36px;
    text-align: center;
    color: var(--gray-600);
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
}

.no-results.is-visible {
    display: block;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    padding: 48px 0;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: var(--white);
    font-size: 18px;
}

.site-footer p {
    max-width: 620px;
    color: var(--gray-300);
}

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

.site-footer a:hover {
    color: var(--emerald-500);
}

.footer-brand {
    color: var(--white);
    font-size: 21px;
}

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

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

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

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

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

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

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

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

    .site-nav {
        min-height: 62px;
    }

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

    .header-search {
        display: none;
    }

    .hero,
    .hero-content {
        min-height: 540px;
    }

    .hero-copy {
        padding: 74px 0 96px;
    }

    .section {
        padding-top: 52px;
    }

    .section-head {
        display: block;
    }

    .section-actions {
        margin-top: 18px;
    }

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

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

    .movie-card h2 {
        font-size: 17px;
    }

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

    .ranking-item {
        grid-template-columns: 44px 72px minmax(0, 1fr);
        gap: 12px;
    }

    .ranking-number {
        width: 42px;
        height: 42px;
        font-size: 16px;
    }

    .ranking-thumb {
        width: 72px;
        height: 96px;
    }

    .ranking-action {
        grid-column: 2 / 4;
    }

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

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

    .content-panel {
        padding: 22px;
    }

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

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }
}

@media (max-width: 480px) {
    .movie-grid,
    .feature-panel .movie-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

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

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

    .page-hero {
        padding: 48px 0;
    }
}
