:root {
    --bg: #020617;
    --panel: #0f172a;
    --panel-soft: rgba(15, 23, 42, 0.76);
    --panel-strong: #111827;
    --text: #ffffff;
    --muted: #94a3b8;
    --line: rgba(148, 163, 184, 0.16);
    --primary: #2563eb;
    --primary-bright: #38bdf8;
    --accent: #f59e0b;
    --danger: #ef4444;
    --radius: 22px;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: radial-gradient(circle at 12% 0%, rgba(37, 99, 235, 0.28), transparent 34%), var(--bg);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(2, 6, 23, 0.86);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 850;
    letter-spacing: -0.04em;
}

.brand span:last-child {
    background: linear-gradient(90deg, var(--primary-bright), var(--primary), #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-mark {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-bright));
    border-radius: 14px;
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.35);
    font-size: 16px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    color: #cbd5e1;
    font-size: 15px;
}

.desktop-nav a,
.mobile-nav a {
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
    color: var(--primary-bright);
}

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: #fff;
    background: rgba(15, 23, 42, 0.95);
    font-size: 22px;
}

.mobile-nav {
    display: none;
    padding: 0 16px 16px;
    border-top: 1px solid var(--line);
}

.mobile-nav a {
    display: block;
    padding: 12px 14px;
    color: #dbeafe;
    border-radius: 12px;
}

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

.hero {
    position: relative;
    overflow: hidden;
    min-height: 640px;
    background: #050a18;
}

.hero-track {
    position: relative;
    min-height: 640px;
}

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

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

.hero-bg {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    transform: scale(1.04);
    filter: saturate(1.15);
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.76) 42%, rgba(2, 6, 23, 0.28) 100%), linear-gradient(0deg, var(--bg) 0%, transparent 38%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 48px;
    align-items: center;
    padding: 84px 0 72px;
}

.hero-copy {
    max-width: 760px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 12px;
    border: 1px solid rgba(56, 189, 248, 0.35);
    border-radius: 999px;
    color: #bae6fd;
    background: rgba(14, 165, 233, 0.1);
    font-size: 14px;
}

.hero h1 {
    margin: 0 0 18px;
    max-width: 780px;
    font-size: clamp(40px, 7vw, 84px);
    line-height: 0.98;
    letter-spacing: -0.08em;
}

.hero p {
    margin: 0;
    max-width: 720px;
    color: #cbd5e1;
    font-size: 18px;
}

.hero-actions,
.section-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: 1px solid transparent;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-bright));
    box-shadow: 0 14px 34px rgba(37, 99, 235, 0.32);
}

.btn-soft {
    color: #e0f2fe;
    background: rgba(15, 23, 42, 0.72);
    border-color: rgba(148, 163, 184, 0.24);
}

.hero-panel {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 28px;
    background: rgba(15, 23, 42, 0.72);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

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

.hero-panel-body {
    position: absolute;
    inset: auto 0 0;
    padding: 22px;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.9), transparent);
}

.hero-panel strong {
    display: block;
    margin-bottom: 8px;
    font-size: 22px;
}

.hero-panel span {
    color: #e2e8f0;
    font-size: 14px;
}

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

.hero-dots button {
    width: 42px;
    height: 5px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.3);
}

.hero-dots button.is-active {
    background: var(--primary-bright);
}

.section {
    padding: 72px 0;
}

.section.soft {
    background: rgba(15, 23, 42, 0.48);
}

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

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

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

.search-box {
    display: flex;
    gap: 12px;
    align-items: center;
    width: min(520px, 100%);
    padding: 10px 12px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.72);
}

.search-box input {
    width: 100%;
    border: 0;
    outline: 0;
    color: #fff;
    background: transparent;
    font-size: 16px;
}

.search-box span {
    color: var(--primary-bright);
}

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

.category-card {
    display: block;
    min-height: 150px;
    padding: 22px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 22px;
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.92), rgba(30, 41, 59, 0.66));
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(56, 189, 248, 0.5);
    background: linear-gradient(145deg, rgba(30, 41, 59, 0.96), rgba(37, 99, 235, 0.22));
}

.category-card strong {
    display: block;
    margin-bottom: 10px;
    font-size: 20px;
}

.category-card span {
    color: var(--muted);
    font-size: 14px;
}

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

.movie-card {
    display: block;
    min-width: 0;
    color: #fff;
}

.movie-poster {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: 20px;
    background: #111827;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

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

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

.movie-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), transparent 54%);
    opacity: 0.72;
}

.movie-type,
.movie-rating,
.movie-play {
    position: absolute;
    z-index: 2;
}

.movie-type {
    left: 12px;
    bottom: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.88);
    font-size: 12px;
    font-weight: 800;
}

.movie-rating {
    top: 12px;
    right: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    color: #111827;
    background: var(--accent);
    font-size: 12px;
    font-weight: 900;
}

.movie-play {
    left: 50%;
    top: 50%;
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.9);
    box-shadow: 0 14px 34px rgba(37, 99, 235, 0.4);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.85);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.movie-info {
    display: block;
    margin-top: 12px;
}

.movie-info strong {
    display: -webkit-box;
    overflow: hidden;
    min-height: 48px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 17px;
    line-height: 1.35;
    transition: color 0.2s ease;
}

.movie-card:hover .movie-info strong {
    color: var(--primary-bright);
}

.movie-info em {
    display: block;
    margin: 7px 0;
    color: #cbd5e1;
    font-size: 13px;
    font-style: normal;
}

.movie-info span {
    display: -webkit-box;
    overflow: hidden;
    color: var(--muted);
    font-size: 14px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

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

.mini-card {
    display: flex;
    gap: 12px;
    align-items: center;
    min-width: 0;
    padding: 10px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.62);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.mini-card:hover {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.46);
}

.mini-card img {
    width: 84px;
    height: 56px;
    flex: 0 0 auto;
    object-fit: cover;
    border-radius: 12px;
}

.mini-card strong {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.mini-card em {
    display: block;
    margin-top: 3px;
    color: var(--muted);
    font-size: 13px;
    font-style: normal;
}

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

.ranking-item {
    display: grid;
    grid-template-columns: 64px 96px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 12px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.66);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.ranking-item:hover {
    transform: translateY(-2px);
    border-color: rgba(56, 189, 248, 0.48);
}

.rank-no {
    font-size: 22px;
    font-weight: 900;
    color: var(--accent);
    text-align: center;
}

.ranking-item img {
    width: 96px;
    height: 64px;
    border-radius: 12px;
    object-fit: cover;
}

.ranking-item strong {
    display: block;
    font-size: 18px;
}

.ranking-item em,
.ranking-score {
    color: var(--muted);
    font-style: normal;
}

.page-hero {
    padding: 74px 0 42px;
    background: radial-gradient(circle at 80% 20%, rgba(56, 189, 248, 0.2), transparent 28%);
}

.page-hero h1 {
    margin: 0;
    max-width: 880px;
    font-size: clamp(36px, 6vw, 64px);
    line-height: 1.05;
    letter-spacing: -0.06em;
}

.page-hero p {
    max-width: 760px;
    margin: 16px 0 0;
    color: #cbd5e1;
    font-size: 18px;
}

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

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

.player-card,
.detail-card,
.side-card {
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.72);
    box-shadow: 0 20px 54px rgba(0, 0, 0, 0.2);
}

.player-card {
    overflow: hidden;
}

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

.player-wrap video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background-position: center;
    background-size: cover;
    cursor: pointer;
    z-index: 3;
}

.player-cover::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.26), rgba(0, 0, 0, 0.78));
}

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

.play-button {
    position: relative;
    z-index: 2;
    display: grid;
    width: 86px;
    height: 86px;
    place-items: center;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--primary), var(--primary-bright));
    box-shadow: 0 22px 60px rgba(37, 99, 235, 0.48);
    font-size: 32px;
}

.player-title {
    padding: 22px;
}

.player-title h1 {
    margin: 0 0 10px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.12;
    letter-spacing: -0.04em;
}

.meta-row,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.meta-row span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 11px;
    border-radius: 999px;
    color: #cbd5e1;
    background: rgba(148, 163, 184, 0.12);
    font-size: 13px;
}

.tag-row span {
    color: #bfdbfe;
    background: rgba(37, 99, 235, 0.18);
}

.detail-card {
    margin-top: 24px;
    padding: 24px;
}

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

.detail-card p {
    margin: 0;
    color: #dbeafe;
    white-space: pre-line;
}

.detail-card + .detail-card {
    margin-top: 18px;
}

.side-card {
    position: sticky;
    top: 96px;
    padding: 18px;
}

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

.no-results {
    display: none;
    margin-top: 20px;
    color: var(--muted);
}

.has-no-results .no-results {
    display: block;
}

.site-footer {
    margin-top: 72px;
    border-top: 1px solid var(--line);
    background: rgba(15, 23, 42, 0.7);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 36px;
    padding: 44px 0;
}

.site-footer p,
.site-footer li,
.site-footer a {
    color: var(--muted);
}

.site-footer h2 {
    margin: 0 0 14px;
    color: #fff;
    font-size: 18px;
}

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

.footer-brand {
    margin-bottom: 12px;
}

.footer-bottom {
    padding: 18px 0;
    border-top: 1px solid var(--line);
    color: var(--muted);
    text-align: center;
    font-size: 14px;
}

@media (max-width: 1100px) {
    .movie-grid,
    .category-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .hero-content {
        grid-template-columns: 1fr 300px;
    }
}

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

    .menu-button {
        display: inline-grid;
        place-items: center;
    }

    .hero,
    .hero-track {
        min-height: 740px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-top: 56px;
    }

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

    .section-head {
        display: block;
    }

    .search-box {
        margin-top: 18px;
    }

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

    .mini-grid,
    .detail-layout,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .side-card {
        position: static;
    }
}

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

    .brand {
        font-size: 20px;
    }

    .brand-mark {
        width: 34px;
        height: 34px;
    }

    .hero,
    .hero-track {
        min-height: 690px;
    }

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

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

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

    .ranking-item {
        grid-template-columns: 44px 82px 1fr;
    }

    .ranking-score {
        grid-column: 3;
    }

    .ranking-item img {
        width: 82px;
        height: 56px;
    }

    .play-button {
        width: 72px;
        height: 72px;
    }
}
