
:root {
    color-scheme: dark;
    --page-bg: #020617;
    --panel-bg: #0f172a;
    --card-bg: #111827;
    --soft-card: rgba(15, 23, 42, 0.82);
    --line: rgba(148, 163, 184, 0.22);
    --text: #e5e7eb;
    --muted: #94a3b8;
    --bright: #ffffff;
    --cyan: #22d3ee;
    --cyan-dark: #0891b2;
    --blue: #3b82f6;
    --amber: #fbbf24;
    --radius: 18px;
    --shadow: 0 24px 80px rgba(2, 8, 23, 0.5);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: radial-gradient(circle at top left, rgba(8, 145, 178, 0.22), transparent 32rem), var(--page-bg);
    color: var(--text);
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    line-height: 1.65;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.9);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
}

.header-inner {
    max-width: 1200px;
    height: 66px;
    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: 10px;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 10px 26px rgba(34, 211, 238, 0.26);
}

.brand-text,
.footer-brand {
    font-size: 1.28rem;
    background: linear-gradient(90deg, var(--cyan), #93c5fd);
    background-clip: text;
    color: transparent;
}

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

.nav-link {
    position: relative;
    color: #cbd5e1;
    font-weight: 700;
    transition: color 0.2s ease;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 2px;
    transform: scaleX(0);
    transform-origin: center;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
    transition: transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
}

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: currentColor;
    border-radius: 99px;
}

.mobile-panel {
    display: none;
    border-top: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.98);
}

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

.mobile-panel nav {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 24px 24px;
    display: grid;
    gap: 14px;
}

.mobile-category-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
}

.mobile-category-links a {
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
    color: #dbeafe;
    font-size: 0.9rem;
}

.hero {
    position: relative;
    height: 620px;
    min-height: 620px;
    overflow: hidden;
    background: linear-gradient(135deg, #020617, #164e63, #0f172a);
}

.hero-track,
.hero-slide,
.hero-bg,
.hero-overlay {
    position: absolute;
    inset: 0;
}

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

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

.hero-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.32;
}

.hero-bg:not([src]),
.hero-bg[src=""] {
    display: none;
}

.hero-overlay {
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.78) 45%, rgba(15, 23, 42, 0.25)), linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.16) 42%, rgba(2, 6, 23, 0.44) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 760px;
    height: 100%;
    padding: 92px 24px 120px;
    margin: 0 auto;
    transform: translateX(-220px);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-kicker,
.page-hero span,
.section-heading span,
.detail-label {
    color: var(--cyan);
    font-size: 0.84rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero-kicker {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
}

.hero-kicker span {
    color: var(--amber);
}

.hero h1,
.hero h2,
.page-hero h1,
.section-heading h2,
.detail-info h1,
.content-section h2 {
    margin: 0;
    color: var(--bright);
    line-height: 1.14;
}

.hero h1,
.hero h2 {
    max-width: 780px;
    font-size: clamp(2.4rem, 6vw, 5rem);
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 670px;
    margin: 22px 0 0;
    color: #cbd5e1;
    font-size: 1.13rem;
}

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

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

.hero-tags span,
.detail-tags a,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 4px 12px;
    border: 1px solid rgba(34, 211, 238, 0.34);
    border-radius: 999px;
    background: rgba(34, 211, 238, 0.12);
    color: #cffafe;
    font-size: 0.85rem;
    font-weight: 700;
}

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

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

.primary-btn {
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), #60a5fa);
    box-shadow: 0 18px 36px rgba(34, 211, 238, 0.25);
}

.ghost-btn {
    color: #e0f2fe;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
}

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

.hero-arrow {
    position: absolute;
    z-index: 4;
    top: 50%;
    width: 46px;
    height: 46px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.55);
    color: #fff;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    backdrop-filter: blur(10px);
}

.hero-prev {
    left: 28px;
}

.hero-next {
    right: 28px;
}

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

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

.hero-dot.active {
    width: 34px;
    background: var(--cyan);
}

.hero-side-panel {
    position: absolute;
    z-index: 3;
    right: calc(50% - 590px);
    bottom: 88px;
    width: 300px;
    padding: 18px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.52);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}

.hero-side-panel strong {
    display: block;
    margin-bottom: 12px;
    color: #fff;
}

.hero-side-panel div {
    display: grid;
    gap: 10px;
}

.hero-side-panel a {
    display: grid;
    grid-template-columns: 54px 1fr;
    align-items: center;
    gap: 10px;
    color: #dbeafe;
    font-weight: 800;
}

.hero-side-panel img {
    width: 54px;
    height: 40px;
    object-fit: cover;
    border-radius: 10px;
    background: linear-gradient(135deg, #164e63, #1e293b);
}

.section-block,
.quick-search,
.page-main,
.detail-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 70px 24px;
}

.page-main,
.detail-main {
    padding-top: 34px;
}

.dark-section {
    max-width: none;
    padding-left: calc((100% - 1200px) / 2 + 24px);
    padding-right: calc((100% - 1200px) / 2 + 24px);
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.24), rgba(8, 47, 73, 0.3));
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

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

.section-heading.centered {
    display: block;
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.section-heading h2 {
    margin-top: 6px;
    font-size: clamp(1.8rem, 4vw, 2.65rem);
    letter-spacing: -0.04em;
}

.section-heading p {
    color: var(--muted);
}

.section-heading a {
    color: var(--cyan);
    font-weight: 900;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1fr 180px 180px;
    gap: 14px;
    margin-bottom: 28px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.72);
    box-shadow: 0 18px 40px rgba(2, 8, 23, 0.24);
}

.filter-panel label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 0.84rem;
    font-weight: 800;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 46px;
    border: 1px solid rgba(148, 163, 184, 0.28);
    border-radius: 14px;
    outline: none;
    background: rgba(2, 6, 23, 0.66);
    color: #f8fafc;
    padding: 0 14px;
    font: inherit;
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.78);
    box-shadow: 0 18px 40px rgba(2, 8, 23, 0.28);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(34, 211, 238, 0.5);
    box-shadow: 0 26px 60px rgba(8, 145, 178, 0.18);
}

.poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 22;
    overflow: hidden;
    background: radial-gradient(circle at 30% 20%, rgba(34, 211, 238, 0.4), transparent 10rem), linear-gradient(135deg, #0f172a, #164e63);
}

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

.poster img.hidden-image {
    opacity: 0;
}

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

.poster-shade {
    position: absolute;
    inset: auto 0 0;
    height: 55%;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.92), transparent);
}

.poster-title {
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 14px;
    color: #fff;
    font-weight: 900;
    line-height: 1.35;
}

.rank-badge {
    position: absolute;
    z-index: 2;
    top: 12px;
    left: 12px;
    min-width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #08111f;
    background: linear-gradient(135deg, var(--amber), #fde68a);
    box-shadow: 0 10px 24px rgba(251, 191, 36, 0.25);
}

.card-body {
    padding: 16px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: #67e8f9;
    font-size: 0.82rem;
    font-weight: 900;
}

.card-body h3 {
    min-height: 3.1em;
    margin: 10px 0 8px;
    color: #fff;
    font-size: 1.04rem;
    line-height: 1.35;
}

.card-body p {
    min-height: 3.6em;
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 0.92rem;
}

.tag-row {
    gap: 6px;
}

.tag-row span {
    min-height: 24px;
    padding: 2px 8px;
    border-color: rgba(148, 163, 184, 0.25);
    background: rgba(255, 255, 255, 0.06);
    color: #cbd5e1;
    font-size: 0.76rem;
}

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

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

.category-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.92), rgba(8, 47, 73, 0.42));
    box-shadow: 0 18px 44px rgba(2, 8, 23, 0.28);
}

.category-main-link {
    display: block;
    padding: 24px 24px 18px;
}

.category-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    margin-bottom: 16px;
    border-radius: 15px;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.category-card strong {
    display: block;
    color: #fff;
    font-size: 1.35rem;
}

.category-card p {
    margin: 8px 0 0;
    color: var(--muted);
}

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

.category-samples a {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #0f172a;
}

.category-samples img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.8;
}

.category-samples span {
    position: absolute;
    left: 8px;
    right: 8px;
    bottom: 8px;
    color: #fff;
    font-size: 0.78rem;
    font-weight: 900;
    text-shadow: 0 2px 8px #000;
}

.page-hero {
    border: 1px solid var(--line);
    border-radius: 28px;
    background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.28), transparent 22rem), linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(8, 47, 73, 0.76));
    box-shadow: var(--shadow);
}

.compact-hero {
    padding: 54px;
}

.page-hero h1 {
    margin-top: 8px;
    font-size: clamp(2rem, 4vw, 3.4rem);
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 780px;
    color: #cbd5e1;
    font-size: 1.08rem;
}

.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
    color: var(--muted);
    font-size: 0.94rem;
}

.breadcrumb a {
    color: #67e8f9;
    font-weight: 800;
}

.detail-hero {
    display: grid;
    grid-template-columns: 310px 1fr;
    gap: 36px;
    align-items: center;
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: 30px;
    background: radial-gradient(circle at 28% 0%, rgba(34, 211, 238, 0.25), transparent 22rem), rgba(15, 23, 42, 0.82);
    box-shadow: var(--shadow);
}

.detail-poster {
    overflow: hidden;
    border-radius: 24px;
    background: linear-gradient(135deg, #0f172a, #164e63);
    box-shadow: 0 18px 44px rgba(2, 8, 23, 0.46);
}

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

.detail-info h1 {
    margin-top: 10px;
    font-size: clamp(2rem, 4vw, 3.5rem);
    letter-spacing: -0.04em;
}

.detail-info p {
    max-width: 760px;
    color: #cbd5e1;
    font-size: 1.08rem;
}

.detail-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    padding: 0;
    margin: 24px 0;
    list-style: none;
}

.detail-meta li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 14px;
    background: rgba(2, 6, 23, 0.38);
}

.detail-meta strong {
    color: var(--muted);
}

.detail-meta span,
.detail-meta a {
    color: #fff;
    font-weight: 900;
    text-align: right;
}

.detail-tags {
    margin-bottom: 26px;
}

.player-section,
.content-section,
.related-block {
    margin-top: 44px;
}

.video-shell {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(34, 211, 238, 0.28);
    border-radius: 28px;
    background: #000;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.video-player {
    width: 100%;
    height: 100%;
    display: block;
    background: #000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: radial-gradient(circle, rgba(34, 211, 238, 0.16), rgba(2, 6, 23, 0.78));
    color: #fff;
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.play-overlay span {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    padding-left: 5px;
    border-radius: 50%;
    color: #001018;
    background: linear-gradient(135deg, var(--cyan), #60a5fa);
    font-size: 2rem;
    box-shadow: 0 22px 50px rgba(34, 211, 238, 0.32);
}

.video-shell.is-playing .play-overlay {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.content-section {
    padding: 34px;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: rgba(15, 23, 42, 0.72);
}

.content-section h2 {
    margin-top: 0;
    font-size: 1.6rem;
}

.content-section p {
    color: #cbd5e1;
    font-size: 1.02rem;
}

.compact-card .card-body p {
    display: none;
}

.site-footer {
    border-top: 1px solid var(--line);
    background: rgba(2, 6, 23, 0.88);
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 42px 24px;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 36px;
}

.footer-inner p {
    max-width: 560px;
    color: var(--muted);
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.footer-links a {
    padding: 7px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: #cbd5e1;
    background: rgba(255, 255, 255, 0.04);
}

[hidden],
.movie-card.hidden-card {
    display: none !important;
}

@media (max-width: 1180px) {
    .hero-content {
        margin-left: 70px;
        transform: none;
    }

    .hero-side-panel {
        display: none;
    }
}

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

    .menu-toggle {
        display: block;
    }

    .hero {
        height: 660px;
    }

    .hero-content {
        margin-left: 0;
        padding-left: 24px;
        padding-right: 24px;
    }

    .hero-arrow {
        display: none;
    }

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

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

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

    .footer-links {
        justify-content: flex-start;
    }

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

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

    .brand-text {
        font-size: 1.08rem;
    }

    .hero {
        height: 700px;
    }

    .hero h1,
    .hero h2 {
        font-size: 2.35rem;
    }

    .hero-actions {
        display: grid;
    }

    .section-block,
    .quick-search,
    .page-main,
    .detail-main {
        padding-left: 16px;
        padding-right: 16px;
    }

    .section-heading {
        display: block;
    }

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

    .compact-hero,
    .detail-hero,
    .content-section {
        padding: 24px;
        border-radius: 22px;
    }

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

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