:root {
    --bg: #f5f7fb;
    --panel: #ffffff;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --brand: #2563eb;
    --brand-2: #7c3aed;
    --dark: #0f172a;
    --radius: 22px;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background: radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 32rem), var(--bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    line-height: 1.65;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 30;
    color: #ffffff;
    box-shadow: 0 12px 35px rgba(37, 99, 235, 0.28);
}

.header-inner {
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.logo-mark {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.18);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    font-size: 0.98rem;
}

.nav-link {
    position: relative;
    opacity: 0.9;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    opacity: 1;
    transform: translateY(-1px);
}

.nav-link.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 3px;
    border-radius: 999px;
    background: #ffffff;
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    font-size: 1.4rem;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    padding: 0 18px 18px;
    background: rgba(29, 78, 216, 0.96);
}

.mobile-nav a {
    display: block;
    padding: 11px 12px;
    border-radius: 12px;
}

.mobile-nav a:hover {
    background: rgba(255, 255, 255, 0.12);
}

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

.hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: #101827;
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transform: scale(1.02);
    transition: opacity 0.55s ease, visibility 0.55s ease, transform 0.8s ease;
    background-image: linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(15, 23, 42, 0.72) 42%, rgba(15, 23, 42, 0.28)), var(--hero-bg);
    background-position: center;
    background-size: cover;
}

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

.hero-content {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) 360px;
    gap: 44px;
    align-items: center;
    padding: 96px 0 74px;
}

.hero-copy h1 {
    margin: 16px 0 16px;
    max-width: 760px;
    font-size: clamp(2.3rem, 5vw, 5rem);
    line-height: 1.04;
    letter-spacing: -0.05em;
}

.hero-copy p {
    max-width: 720px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 1.1rem;
}

.eyebrow,
.kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    color: #dbeafe;
    background: rgba(37, 99, 235, 0.28);
    border: 1px solid rgba(191, 219, 254, 0.28);
    font-size: 0.9rem;
    font-weight: 700;
}

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

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

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    box-shadow: 0 16px 38px rgba(37, 99, 235, 0.34);
}

.btn-secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.24);
}

.btn-light {
    color: var(--brand);
    background: #ffffff;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.2);
}

.hero-card {
    position: relative;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
    transform: rotate(2deg);
}

.hero-card img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.hero-card span {
    position: absolute;
    left: 20px;
    bottom: 20px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(12px);
    font-weight: 800;
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 2;
}

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

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

.search-panel,
.glass-panel {
    margin: 28px auto 0;
    padding: 22px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(14px);
}

.search-panel label {
    display: block;
    margin-bottom: 10px;
    color: var(--dark);
    font-weight: 800;
}

.search-bar {
    display: flex;
    gap: 10px;
}

.search-bar input {
    width: 100%;
    min-height: 50px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    outline: none;
    font-size: 1rem;
}

.search-bar input:focus {
    border-color: rgba(37, 99, 235, 0.52);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.search-clear {
    min-width: 86px;
    border: 0;
    border-radius: 16px;
    color: #ffffff;
    background: var(--dark);
    cursor: pointer;
    font-weight: 700;
}

.search-results {
    display: none;
    margin-top: 12px;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: #ffffff;
}

.search-results.is-open {
    display: block;
}

.search-result-item {
    display: grid;
    grid-template-columns: 52px 1fr;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid var(--line);
}

.search-result-item:last-child {
    border-bottom: 0;
}

.search-result-item img {
    width: 52px;
    height: 70px;
    border-radius: 10px;
    object-fit: cover;
}

.search-result-item strong {
    display: block;
    color: var(--dark);
}

.search-result-item span {
    color: var(--muted);
    font-size: 0.9rem;
}

.section {
    padding: 58px 0 0;
}

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

.section-title {
    margin: 0;
    font-size: clamp(1.7rem, 3vw, 2.5rem);
    line-height: 1.15;
}

.section-lead {
    margin: 8px 0 0;
    color: var(--muted);
    max-width: 760px;
}

.category-strip,
.filter-bar,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.category-chip,
.filter-btn,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 34px;
    padding: 0 13px;
    border-radius: 999px;
    color: #1d4ed8;
    background: #dbeafe;
    font-size: 0.9rem;
    font-weight: 700;
}

.filter-btn {
    border: 0;
    cursor: pointer;
}

.filter-btn.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.movie-poster {
    position: relative;
    display: block;
    overflow: hidden;
    background: linear-gradient(135deg, #172554, #312e81);
}

.movie-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.movie-poster em,
.rank-badge {
    position: absolute;
    top: 12px;
    border-radius: 999px;
    font-style: normal;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

.movie-poster em {
    right: 12px;
    padding: 5px 10px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.72);
    font-size: 0.82rem;
}

.rank-badge {
    left: 12px;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.movie-info {
    padding: 16px;
}

.movie-title {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 8px;
    font-size: 1.05rem;
    font-weight: 900;
    line-height: 1.35;
}

.movie-info p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0 0 12px;
    min-height: 3.3em;
    color: var(--muted);
    font-size: 0.93rem;
}

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    color: #4b5563;
    font-size: 0.86rem;
}

.movie-meta span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #f3f4f6;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 220px;
    padding: 26px;
    border-radius: 26px;
    color: #ffffff;
    background-image: linear-gradient(135deg, rgba(15, 23, 42, 0.92), rgba(37, 99, 235, 0.72)), var(--cat-bg);
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow);
}

.category-card h2 {
    margin: 0 0 10px;
    font-size: 1.7rem;
}

.category-card p {
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.86);
}

.page-hero {
    padding: 58px 0 30px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(124, 58, 237, 0.10));
}

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 4vw, 4rem);
    line-height: 1.08;
}

.page-hero p {
    max-width: 820px;
    margin: 0;
    color: var(--muted);
    font-size: 1.08rem;
}

.detail-shell {
    padding: 34px 0 0;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--muted);
    font-size: 0.95rem;
}

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

.detail-main,
.detail-side {
    border-radius: 28px;
    background: var(--panel);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.player-wrap {
    padding: 18px;
    background: #0b1120;
}

.video-stage {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: #020617;
}

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

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: #ffffff;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.16), rgba(2, 6, 23, 0.18));
    cursor: pointer;
}

.play-overlay span {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 22px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-2));
    box-shadow: 0 20px 45px rgba(37, 99, 235, 0.36);
    font-weight: 900;
    font-size: 1.05rem;
}

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

.detail-content {
    padding: 26px;
}

.detail-content h1 {
    margin: 0 0 12px;
    font-size: clamp(1.9rem, 4vw, 3.2rem);
    line-height: 1.15;
}

.detail-meta,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 14px 0 20px;
}

.detail-meta span,
.detail-tags span {
    padding: 7px 12px;
    border-radius: 999px;
    background: #eef2ff;
    color: #3730a3;
    font-weight: 700;
    font-size: 0.9rem;
}

.detail-content h2 {
    margin: 28px 0 10px;
    font-size: 1.36rem;
}

.detail-content p {
    color: #374151;
    margin: 0 0 14px;
}

.detail-side {
    padding: 18px;
}

.detail-side img {
    width: 100%;
    border-radius: 22px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    margin-bottom: 18px;
}

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

.side-item {
    display: grid;
    grid-template-columns: 58px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 16px;
    background: #f8fafc;
}

.side-item img {
    width: 58px;
    height: 78px;
    margin: 0;
    border-radius: 12px;
}

.side-item strong {
    display: block;
    line-height: 1.3;
}

.side-item span {
    display: block;
    color: var(--muted);
    font-size: 0.86rem;
}

.empty-state {
    display: none;
    padding: 22px;
    border-radius: 18px;
    color: var(--muted);
    background: #ffffff;
    border: 1px dashed #cbd5e1;
}

.site-footer {
    margin-top: 70px;
    color: #cbd5e1;
    background: #111827;
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0 28px;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 32px;
}

.footer-inner p {
    color: #94a3b8;
}

.footer-inner h3 {
    color: #ffffff;
    margin: 0 0 14px;
}

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

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

.copyright {
    margin: 0;
    padding: 18px;
    text-align: center;
    color: #94a3b8;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

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

    .mobile-toggle {
        display: inline-grid;
        place-items: center;
    }

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

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

    .hero-card {
        max-width: 320px;
        transform: none;
    }

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

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

@media (max-width: 680px) {
    .hero-slider {
        min-height: 760px;
    }

    .hero-content {
        padding-top: 58px;
        gap: 28px;
    }

    .search-bar {
        flex-direction: column;
    }

    .search-clear {
        min-height: 46px;
    }

    .section-head {
        display: block;
    }

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

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

    .movie-info {
        padding: 12px;
    }

    .movie-meta {
        gap: 6px;
    }
}
