:root {
    color-scheme: light;
    --bg: #f8fafc;
    --surface: #ffffff;
    --surface-soft: #ecfdf5;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --emerald: #10b981;
    --teal: #0d9488;
    --cyan: #0891b2;
    --orange: #f97316;
    --shadow: 0 22px 60px rgba(15, 23, 42, 0.14);
    --shadow-soft: 0 12px 32px rgba(15, 23, 42, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 45%, #f1f5f9 100%);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.72);
    color: #ffffff;
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.10);
    transition: background 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.site-header.is-scrolled,
.site-header.header-solid {
    background: rgba(255, 255, 255, 0.96);
    color: var(--ink);
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
    border-bottom-color: rgba(226, 232, 240, 0.9);
}

.header-inner {
    max-width: 1240px;
    margin: 0 auto;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.logo-mark {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 900;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 14px 32px rgba(16, 185, 129, 0.38);
}

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

.logo-title {
    font-size: 18px;
    font-weight: 900;
    letter-spacing: -0.03em;
    white-space: nowrap;
}

.logo-subtitle {
    font-size: 12px;
    color: currentColor;
    opacity: 0.72;
    margin-top: 3px;
}

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

.nav-link {
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    color: currentColor;
    opacity: 0.88;
    transition: background 0.2s ease, transform 0.2s ease, opacity 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    opacity: 1;
    background: rgba(16, 185, 129, 0.16);
    transform: translateY(-1px);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-search {
    width: 210px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.20);
}

.site-header.is-scrolled .header-search,
.site-header.header-solid .header-search {
    background: #f8fafc;
    border-color: var(--line);
}

.header-search input {
    min-width: 0;
    width: 100%;
    border: 0;
    outline: 0;
    color: currentColor;
    background: transparent;
    font-size: 13px;
}

.header-search input::placeholder {
    color: currentColor;
    opacity: 0.58;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 12px;
    color: currentColor;
    background: rgba(255, 255, 255, 0.14);
    cursor: pointer;
}

.menu-toggle span,
.menu-toggle span::before,
.menu-toggle span::after {
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
    content: "";
}

.menu-toggle span::before {
    transform: translateY(-6px);
}

.menu-toggle span::after {
    transform: translateY(4px);
}

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

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

.mobile-nav .nav-link {
    display: block;
    background: rgba(16, 185, 129, 0.12);
}

.hero {
    position: relative;
    min-height: 760px;
    overflow: hidden;
    color: #ffffff;
    background: #020617;
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease;
}

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

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
    filter: saturate(1.12);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 78% 22%, rgba(20, 184, 166, 0.46), transparent 35%),
        linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.72) 48%, rgba(15, 23, 42, 0.28) 100%),
        linear-gradient(0deg, rgba(2, 6, 23, 0.92) 0%, rgba(2, 6, 23, 0) 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1240px;
    width: 100%;
    margin: 0 auto;
    padding: 120px 20px 110px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 350px;
    gap: 42px;
    align-items: center;
}

.hero-kicker {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(16, 185, 129, 0.18);
    border: 1px solid rgba(110, 231, 183, 0.35);
    color: #a7f3d0;
    font-size: 14px;
    font-weight: 800;
}

.hero h1 {
    max-width: 820px;
    margin: 22px 0 20px;
    font-size: clamp(40px, 6vw, 86px);
    line-height: 0.98;
    letter-spacing: -0.065em;
    font-weight: 950;
}

.hero-lead {
    max-width: 720px;
    margin: 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(16px, 2vw, 20px);
    line-height: 1.8;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 26px;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(12px);
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 18px;
    border-radius: 14px;
    border: 0;
    font-weight: 900;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 18px 38px rgba(16, 185, 129, 0.34);
}

.btn-ghost {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.13);
    border: 1px solid rgba(255, 255, 255, 0.20);
    backdrop-filter: blur(14px);
}

.hero-panel {
    position: relative;
    min-height: 470px;
    border-radius: 34px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-panel img {
    width: 100%;
    height: 100%;
    min-height: 470px;
    object-fit: cover;
}

.hero-panel-info {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 24px;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0));
}

.hero-panel-title {
    margin: 0;
    font-size: 24px;
    font-weight: 950;
}

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

.hero-dot {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.34);
    cursor: pointer;
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 34px;
    background: #ffffff;
}

.section {
    max-width: 1240px;
    margin: 0 auto;
    padding: 70px 20px;
}

.section-soft {
    background: linear-gradient(135deg, #ecfdf5 0%, #f0fdfa 50%, #ecfeff 100%);
}

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

.section-title {
    margin: 0;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.1;
    letter-spacing: -0.04em;
    font-weight: 950;
}

.section-desc {
    max-width: 680px;
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

.section-link {
    flex: 0 0 auto;
    color: var(--teal);
    font-weight: 900;
}

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

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

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

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

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

.movie-poster {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #064e3b, #0f172a);
}

.movie-poster.wide {
    aspect-ratio: 16 / 10;
}

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

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

.movie-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 2;
    padding: 6px 10px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.35);
}

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
    margin-bottom: 8px;
}

.movie-card h3 {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 950;
}

.movie-card p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 14px;
}

.tag {
    display: inline-flex;
    padding: 5px 8px;
    border-radius: 999px;
    color: #047857;
    background: #ecfdf5;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    display: flex;
    min-height: 210px;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px;
    border-radius: 26px;
    color: #ffffff;
    background:
        radial-gradient(circle at 80% 10%, rgba(255, 255, 255, 0.22), transparent 32%),
        linear-gradient(135deg, #059669, #0f766e 52%, #155e75);
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card h3 {
    margin: 0 0 10px;
    font-size: 24px;
    font-weight: 950;
}

.category-card p {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.75;
}

.category-mini-list {
    display: grid;
    gap: 8px;
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
    font-weight: 800;
}

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

.ranking-item {
    display: grid;
    grid-template-columns: 72px 120px 1fr;
    gap: 16px;
    align-items: center;
    padding: 14px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.ranking-number {
    width: 56px;
    height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    color: #ffffff;
    font-size: 20px;
    font-weight: 950;
    background: linear-gradient(135deg, var(--orange), #ef4444);
}

.ranking-thumb {
    aspect-ratio: 4 / 5;
    overflow: hidden;
    border-radius: 16px;
    background: #0f172a;
}

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

.ranking-info h3 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 950;
}

.ranking-info p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

.page-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background:
        radial-gradient(circle at 80% 10%, rgba(16, 185, 129, 0.34), transparent 35%),
        linear-gradient(135deg, #020617 0%, #0f172a 52%, #064e3b 100%);
}

.page-hero-inner {
    max-width: 1240px;
    margin: 0 auto;
    padding: 82px 20px 74px;
}

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

.breadcrumb.dark {
    color: var(--muted);
}

.page-hero h1,
.detail-title {
    max-width: 980px;
    margin: 0;
    font-size: clamp(34px, 5vw, 64px);
    line-height: 1.1;
    letter-spacing: -0.05em;
    font-weight: 950;
}

.page-hero p {
    max-width: 760px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.85;
    font-size: 17px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 180px;
    gap: 12px;
    padding: 16px;
    margin-bottom: 26px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(226, 232, 240, 0.84);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--line);
    outline: 0;
    border-radius: 14px;
    padding: 0 14px;
    color: var(--ink);
    background: #f8fafc;
}

.empty-state {
    display: none;
    padding: 28px;
    border-radius: 22px;
    color: var(--muted);
    background: #ffffff;
    border: 1px dashed var(--line);
    text-align: center;
}

.empty-state.is-visible {
    display: block;
}

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

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #000000;
    box-shadow: var(--shadow);
}

.movie-video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    padding: 0;
    color: #ffffff;
    background: #000000;
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.72;
}

.player-cover::after {
    position: absolute;
    inset: 0;
    content: "";
    background: radial-gradient(circle at center, rgba(16, 185, 129, 0.20), rgba(0, 0, 0, 0.62));
}

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

.play-mark {
    position: relative;
    z-index: 2;
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    font-size: 34px;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 18px 42px rgba(16, 185, 129, 0.42);
}

.detail-card,
.side-card {
    padding: 26px;
    border-radius: 28px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(226, 232, 240, 0.82);
}

.detail-card h2,
.side-card h2 {
    margin: 0 0 16px;
    font-size: 24px;
    font-weight: 950;
}

.detail-card p {
    color: #334155;
    line-height: 1.9;
    margin: 0 0 16px;
}

.side-poster {
    overflow: hidden;
    border-radius: 22px;
    background: #0f172a;
    margin-bottom: 18px;
}

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

.info-list {
    display: grid;
    gap: 10px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--line);
    color: var(--muted);
}

.info-row strong {
    color: var(--ink);
}

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

.site-footer {
    margin-top: 60px;
    color: #cbd5e1;
    background: #020617;
}

.footer-inner {
    max-width: 1240px;
    margin: 0 auto;
    padding: 54px 20px 30px;
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) 1fr 1fr;
    gap: 34px;
}

.footer-title {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #ffffff;
    font-size: 20px;
    font-weight: 950;
}

.footer-text {
    max-width: 520px;
    margin: 16px 0 0;
    color: #94a3b8;
    line-height: 1.8;
}

.footer-links {
    display: grid;
    gap: 10px;
}

.footer-links strong {
    color: #ffffff;
    margin-bottom: 4px;
}

.footer-links a {
    color: #94a3b8;
}

.footer-links a:hover {
    color: #5eead4;
}

.footer-bottom {
    max-width: 1240px;
    margin: 0 auto;
    padding: 18px 20px 30px;
    color: #64748b;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    font-size: 13px;
}

@media (max-width: 1080px) {
    .hero-content,
    .detail-layout {
        grid-template-columns: 1fr;
    }

    .hero-panel {
        max-width: 420px;
    }

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

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

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

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

    .hero {
        min-height: auto;
    }

    .hero-content {
        padding: 92px 20px 92px;
    }

    .hero-panel {
        min-height: 360px;
    }

    .hero-panel img {
        min-height: 360px;
    }

    .section-head {
        display: block;
    }

    .section-link {
        display: inline-flex;
        margin-top: 16px;
    }

    .movie-grid,
    .movie-grid.compact,
    .category-grid,
    .ranking-list,
    .related-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ranking-item {
        grid-template-columns: 54px 96px 1fr;
    }

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

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

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

    .logo-title {
        max-width: 210px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .hero-content {
        padding-left: 14px;
        padding-right: 14px;
    }

    .hero-actions {
        display: grid;
    }

    .section,
    .page-hero-inner {
        padding-left: 14px;
        padding-right: 14px;
    }

    .movie-grid,
    .movie-grid.compact,
    .category-grid,
    .ranking-list,
    .related-grid {
        grid-template-columns: 1fr;
    }

    .ranking-item {
        grid-template-columns: 48px 86px 1fr;
        gap: 10px;
    }

    .detail-card,
    .side-card {
        padding: 20px;
        border-radius: 22px;
    }
}
