* {
    box-sizing: border-box;
}

:root {
    --bg: #f6f8fb;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --panel: #ffffff;
    --dark: #0f172a;
    --dark-soft: #1e293b;
    --cyan: #06b6d4;
    --blue: #2563eb;
    --orange: #f97316;
    --pink: #ec4899;
    --green: #10b981;
    --radius: 22px;
    --shadow: 0 20px 50px rgba(15, 23, 42, 0.12);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #ffffff;
    background: linear-gradient(90deg, #0f172a, #1e293b, #0f172a);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.28);
}

.header-inner {
    width: min(1180px, calc(100% - 32px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

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

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    color: #ffffff;
    box-shadow: 0 10px 25px rgba(6, 182, 212, 0.35);
}

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

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

.nav-link,
.mobile-link {
    color: rgba(255, 255, 255, 0.86);
    border-radius: 12px;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link {
    padding: 10px 14px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: #ffffff;
    background: rgba(148, 163, 184, 0.2);
}

.header-search,
.mobile-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    border-radius: 999px;
    background: #334155;
    border: 1px solid rgba(148, 163, 184, 0.25);
}

.header-search input,
.mobile-search input {
    width: 230px;
    border: 0;
    color: #ffffff;
    outline: 0;
    padding: 11px 14px;
    background: transparent;
}

.header-search input::placeholder,
.mobile-search input::placeholder {
    color: #cbd5e1;
}

.header-search button,
.mobile-search button {
    border: 0;
    color: #ffffff;
    cursor: pointer;
    padding: 11px 16px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: rgba(148, 163, 184, 0.2);
    cursor: pointer;
    padding: 10px;
}

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

.mobile-panel {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
}

.mobile-link {
    display: block;
    padding: 11px 12px;
    margin-top: 6px;
}

.site-main {
    min-height: 70vh;
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 420px);
    align-items: center;
    gap: 46px;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 0.7s ease;
    padding: 90px max(32px, calc((100% - 1180px) / 2)) 78px;
}

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

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(24px) saturate(130%);
    opacity: 0.36;
    transform: scale(1.08);
}

.hero-layer {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 15% 30%, rgba(6, 182, 212, 0.36), transparent 28%),
        radial-gradient(circle at 85% 18%, rgba(236, 72, 153, 0.28), transparent 30%),
        linear-gradient(135deg, rgba(15, 23, 42, 0.94), rgba(30, 41, 59, 0.76) 50%, rgba(15, 23, 42, 0.98));
}

.hero-content,
.hero-poster-wrap {
    position: relative;
    z-index: 2;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 14px 30px rgba(37, 99, 235, 0.24);
}

.hero-content h1,
.page-hero h1 {
    margin: 22px 0 18px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.02;
    letter-spacing: -0.05em;
}

.hero-content p,
.page-hero p {
    margin: 0;
    max-width: 720px;
    color: #dbeafe;
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.8;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 20px;
    border: 0;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 800;
    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(--cyan), var(--blue));
    box-shadow: 0 18px 35px rgba(6, 182, 212, 0.28);
}

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

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.detail-tags span {
    border-radius: 999px;
    background: #e0f2fe;
    color: #0369a1;
    font-size: 13px;
    font-weight: 700;
}

.hero-tags span {
    color: #e0f2fe;
    background: rgba(14, 165, 233, 0.18);
    border: 1px solid rgba(125, 211, 252, 0.22);
    padding: 8px 12px;
}

.hero-poster {
    display: block;
    overflow: hidden;
    border-radius: 30px;
    box-shadow: 0 35px 70px rgba(0, 0, 0, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.18);
    transform: rotate(2deg);
    transition: transform 0.25s ease;
}

.hero-poster:hover {
    transform: rotate(0deg) translateY(-6px);
}

.hero-poster img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    background: linear-gradient(135deg, #1e293b, #0f172a);
}

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

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

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

.quick-search {
    width: min(1180px, calc(100% - 32px));
    margin: -38px auto 0;
    position: relative;
    z-index: 8;
    padding: 18px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
}

.quick-search input {
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 0 18px;
    min-height: 52px;
    outline: 0;
}

.quick-search input:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.content-section,
.page-wrap {
    width: min(1180px, calc(100% - 32px));
    margin: 58px auto;
}

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

.section-heading h2,
.category-card h2,
.footer-links h2 {
    margin: 12px 0 8px;
}

.section-heading p,
.category-card p,
.footer-main p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

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

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

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

.movie-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.16);
}

.card-cover {
    position: relative;
    display: block;
    overflow: hidden;
    background: linear-gradient(135deg, #cbd5e1, #f8fafc);
}

.card-cover img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.movie-card:hover .card-cover img {
    transform: scale(1.08);
}

.card-badge,
.rank-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    border-radius: 999px;
    color: #ffffff;
    padding: 6px 10px;
    font-size: 12px;
    font-weight: 800;
    background: rgba(15, 23, 42, 0.78);
}

.rank-badge {
    left: 12px;
    right: auto;
    background: linear-gradient(135deg, var(--orange), var(--pink));
}

.play-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 46px;
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.64);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.card-body {
    padding: 17px;
}

.card-title {
    display: -webkit-box;
    min-height: 48px;
    color: var(--ink);
    font-size: 17px;
    font-weight: 800;
    line-height: 1.45;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-title:hover {
    color: var(--cyan);
}

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

.card-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
}

.card-meta span,
.detail-meta span {
    padding: 5px 9px;
    border-radius: 999px;
    background: #f1f5f9;
}

.tag-row,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 12px;
}

.tag-row span,
.detail-tags span {
    padding: 5px 9px;
}

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

.category-card {
    min-height: 190px;
    padding: 22px;
    border-radius: 24px;
    color: #ffffff;
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.24), transparent 32%),
        linear-gradient(135deg, #0f172a, #2563eb);
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 50px rgba(37, 99, 235, 0.24);
}

.category-card p {
    color: #dbeafe;
}

.category-card span {
    display: inline-flex;
    margin-top: 24px;
    font-weight: 800;
}

.page-hero {
    position: relative;
    width: min(1180px, calc(100% - 32px));
    margin: 36px auto 0;
    padding: 54px;
    overflow: hidden;
    color: #ffffff;
    border-radius: 32px;
    background:
        radial-gradient(circle at 18% 20%, rgba(6, 182, 212, 0.35), transparent 26%),
        radial-gradient(circle at 84% 18%, rgba(236, 72, 153, 0.32), transparent 26%),
        linear-gradient(135deg, #0f172a, #1e293b 48%, #020617);
    box-shadow: var(--shadow);
}

.slim-hero {
    margin-top: 34px;
}

.filter-panel {
    width: min(1180px, calc(100% - 32px));
    margin: 24px auto 0;
    padding: 18px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 16px 32px rgba(15, 23, 42, 0.08);
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 0.8fr;
    gap: 14px;
}

.filter-panel label {
    display: grid;
    gap: 8px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

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

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.empty-state {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 28px auto;
    padding: 28px;
    text-align: center;
    color: var(--muted);
    border-radius: 22px;
    background: #ffffff;
}

.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: #020617;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(22px) saturate(130%);
    opacity: 0.28;
    transform: scale(1.08);
}

.detail-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.72), rgba(2, 6, 23, 0.98));
}

.detail-inner {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 54px 0;
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 36px;
    align-items: end;
}

.detail-cover {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.36);
}

.detail-cover img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    background: linear-gradient(135deg, #334155, #0f172a);
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: #bfdbfe;
    font-size: 14px;
}

.breadcrumbs a:hover {
    color: #ffffff;
}

.detail-info h1 {
    margin: 0 0 16px;
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.08;
    letter-spacing: -0.04em;
}

.detail-info .lead {
    max-width: 760px;
    color: #dbeafe;
    font-size: 18px;
    line-height: 1.8;
}

.detail-meta span {
    color: #e2e8f0;
    background: rgba(148, 163, 184, 0.18);
}

.detail-shell {
    width: min(1180px, calc(100% - 32px));
    margin: 44px auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 28px;
    align-items: start;
}

.player-card,
.story-card,
.side-card {
    border-radius: 26px;
    background: #ffffff;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
    overflow: hidden;
}

.player-wrap {
    position: relative;
    overflow: hidden;
    background: #000000;
    aspect-ratio: 16 / 9;
}

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

.player-start {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    color: #ffffff;
    cursor: pointer;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.24), rgba(15, 23, 42, 0.74));
}

.player-start span {
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-size: 28px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 20px 45px rgba(37, 99, 235, 0.36);
}

.player-wrap.is-playing .player-start {
    display: none;
}

.player-caption,
.story-card,
.side-card {
    padding: 24px;
}

.player-caption h2,
.story-card h2,
.side-card h2 {
    margin: 0 0 14px;
}

.player-caption p,
.story-card p,
.side-card p {
    color: var(--muted);
    line-height: 1.85;
}

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

.side-item {
    display: grid;
    grid-template-columns: 94px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
}

.side-item img {
    width: 94px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 14px;
    background: #e2e8f0;
}

.side-item h3 {
    margin: 0 0 6px;
    font-size: 15px;
    line-height: 1.4;
}

.side-item p {
    margin: 0;
    font-size: 13px;
    line-height: 1.55;
}

.site-footer {
    color: #cbd5e1;
    background: linear-gradient(135deg, #0f172a, #1e293b, #020617);
    margin-top: 72px;
}

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

.footer-main p {
    color: #cbd5e1;
    margin-top: 16px;
}

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

.footer-links h2 {
    color: #ffffff;
    font-size: 18px;
}

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

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 28px;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    display: flex;
    justify-content: space-between;
    gap: 18px;
    color: #94a3b8;
    font-size: 14px;
}

[data-card].is-hidden {
    display: none;
}

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

    .menu-toggle {
        display: block;
    }

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

    .hero-slide {
        grid-template-columns: 1fr;
        min-height: 720px;
    }

    .hero-poster-wrap {
        max-width: 340px;
    }

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

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

@media (max-width: 760px) {
    .header-inner {
        width: calc(100% - 24px);
    }

    .brand-name {
        font-size: 18px;
    }

    .hero-slider {
        min-height: 700px;
    }

    .hero-slide {
        padding: 74px 18px 70px;
        gap: 28px;
    }

    .hero-poster-wrap {
        max-width: 260px;
    }

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

    .content-section,
    .page-wrap,
    .page-hero,
    .filter-panel {
        width: calc(100% - 24px);
    }

    .page-hero {
        padding: 34px 22px;
        border-radius: 24px;
    }

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

    .card-body {
        padding: 14px;
    }

    .detail-inner {
        grid-template-columns: 1fr;
        padding: 36px 0;
    }

    .detail-cover {
        max-width: 260px;
    }

    .detail-shell {
        width: calc(100% - 24px);
    }

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

    .footer-bottom {
        flex-direction: column;
    }
}

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

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