:root {
    color-scheme: dark;
    --bg: #020617;
    --bg-soft: #0f172a;
    --panel: #1e293b;
    --panel-strong: #273449;
    --line: #334155;
    --line-soft: rgba(148, 163, 184, 0.18);
    --text: #f8fafc;
    --muted: #94a3b8;
    --muted-strong: #cbd5e1;
    --accent: #f97316;
    --accent-dark: #ea580c;
    --accent-soft: rgba(249, 115, 22, 0.18);
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 12px;
    --container: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background: var(--bg);
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 20% 0%, rgba(249, 115, 22, 0.14), transparent 26rem),
        radial-gradient(circle at 90% 8%, rgba(59, 130, 246, 0.12), transparent 28rem),
        var(--bg);
    min-height: 100vh;
    line-height: 1.6;
}

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

button,
input,
select {
    font: inherit;
}

button {
    border: 0;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(18px);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.18);
}

.navbar {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: max-content;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--accent), #fb923c);
    box-shadow: 0 14px 34px rgba(249, 115, 22, 0.38);
    font-weight: 900;
    letter-spacing: -0.06em;
}

.brand-name {
    display: block;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 0.04em;
}

.brand-subtitle {
    display: block;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.2;
    margin-top: 2px;
}

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

.nav-links a {
    padding: 9px 14px;
    border-radius: 12px;
    color: var(--muted-strong);
    font-size: 14px;
    font-weight: 700;
    transition: 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: #fff;
    background: var(--accent);
    box-shadow: 0 12px 28px rgba(249, 115, 22, 0.24);
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: #fff;
    background: rgba(30, 41, 59, 0.92);
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto 14px;
    padding: 12px;
    border: 1px solid var(--line-soft);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.96);
}

.mobile-nav a {
    display: block;
    padding: 12px 14px;
    border-radius: 12px;
    color: var(--muted-strong);
    font-weight: 700;
}

.mobile-nav a:hover,
.mobile-nav a.active {
    background: var(--accent);
    color: #fff;
}

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

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

.main-content {
    min-height: 72vh;
}

.hero {
    position: relative;
    height: 70vh;
    min-height: 540px;
    overflow: hidden;
    isolation: isolate;
    background: #020617;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 900ms ease;
}

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

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.04);
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.58), rgba(2, 6, 23, 0.15)),
        linear-gradient(0deg, #020617, rgba(2, 6, 23, 0.25) 45%, rgba(2, 6, 23, 0.04));
}

.hero-inner {
    position: relative;
    z-index: 3;
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
}

.hero-copy {
    max-width: 720px;
    padding-top: 44px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fed7aa;
    background: rgba(249, 115, 22, 0.16);
    border: 1px solid rgba(249, 115, 22, 0.28);
    border-radius: 999px;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 800;
    margin-bottom: 18px;
}

.hero-title {
    margin: 0 0 18px;
    font-size: clamp(38px, 6vw, 76px);
    line-height: 0.98;
    letter-spacing: -0.05em;
    font-weight: 950;
    text-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
}

.hero-summary {
    margin: 0;
    max-width: 650px;
    color: #e2e8f0;
    font-size: clamp(16px, 2.2vw, 21px);
    line-height: 1.75;
    text-shadow: 0 12px 28px rgba(0, 0, 0, 0.7);
}

.pill-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 24px 0 28px;
}

.pill {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(30, 41, 59, 0.78);
    border: 1px solid rgba(148, 163, 184, 0.22);
    color: #e2e8f0;
    font-size: 13px;
    font-weight: 700;
    backdrop-filter: blur(10px);
}

.pill-accent {
    background: var(--accent);
    color: #fff;
    border-color: transparent;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 12px 18px;
    border-radius: 14px;
    font-weight: 850;
    cursor: pointer;
    transition: transform 0.22s ease, background 0.22s ease, border-color 0.22s ease, color 0.22s ease;
}

.btn-primary {
    color: #fff;
    background: var(--accent);
    box-shadow: 0 18px 38px rgba(249, 115, 22, 0.24);
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.02);
    background: var(--accent-dark);
}

.btn-ghost {
    color: #fff;
    border: 1px solid rgba(226, 232, 240, 0.25);
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(12px);
}

.btn-ghost:hover {
    transform: translateY(-2px);
    border-color: rgba(249, 115, 22, 0.7);
    color: #fed7aa;
}

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

.hero-dot {
    width: 30px;
    height: 5px;
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.55);
    cursor: pointer;
    transition: 0.25s ease;
}

.hero-dot.is-active {
    width: 54px;
    background: var(--accent);
}

.page-hero {
    padding: 58px 0 34px;
    border-bottom: 1px solid var(--line-soft);
    background:
        radial-gradient(circle at 25% 8%, rgba(249, 115, 22, 0.14), transparent 24rem),
        linear-gradient(180deg, rgba(15, 23, 42, 0.86), rgba(2, 6, 23, 0));
}

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

.breadcrumb a {
    color: #fed7aa;
}

.page-title {
    margin: 0;
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1.08;
    letter-spacing: -0.04em;
    font-weight: 950;
}

.page-desc {
    max-width: 820px;
    margin: 14px 0 0;
    color: var(--muted-strong);
    font-size: 17px;
}

.section {
    padding: 54px 0;
}

.section-tight {
    padding: 34px 0;
}

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

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 930;
    letter-spacing: -0.03em;
}

.section-title::before {
    content: "";
    width: 5px;
    height: 30px;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 0 22px rgba(249, 115, 22, 0.45);
}

.section-link {
    color: #fed7aa;
    font-weight: 800;
    font-size: 14px;
}

.section-link:hover {
    color: #fff;
}

.grid {
    display: grid;
    gap: 20px;
}

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

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

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

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

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

.movie-card {
    display: block;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(30, 41, 59, 0.88);
    border: 1px solid rgba(148, 163, 184, 0.1);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
    transform: translateY(0);
    transition: transform 0.26s ease, box-shadow 0.26s ease, border-color 0.26s ease, background 0.26s ease;
}

.movie-card:hover {
    transform: translateY(-7px);
    border-color: rgba(249, 115, 22, 0.45);
    background: rgba(39, 52, 73, 0.92);
    box-shadow: 0 26px 64px rgba(0, 0, 0, 0.36);
}

.poster {
    position: relative;
    height: 250px;
    overflow: hidden;
    background: #0f172a;
}

.card-small .poster {
    height: 170px;
}

.card-large .poster {
    height: 320px;
}

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

.movie-card:hover .poster img {
    transform: scale(1.1);
    filter: brightness(0.84);
}

.poster::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.76), transparent 62%);
    transition: opacity 0.26s ease;
}

.movie-card:hover .poster::after {
    opacity: 1;
}

.poster-play {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: grid;
    place-items: center;
    opacity: 0;
    transform: scale(0.9);
    transition: 0.26s ease;
}

.poster-play span {
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--accent);
    box-shadow: 0 18px 36px rgba(249, 115, 22, 0.34);
    font-size: 22px;
}

.movie-card:hover .poster-play {
    opacity: 1;
    transform: scale(1);
}

.badge {
    position: absolute;
    z-index: 3;
    top: 12px;
    min-height: 28px;
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border-radius: 9px;
    color: #fff;
    font-size: 12px;
    font-weight: 850;
}

.badge-year {
    left: 12px;
    background: var(--accent);
}

.badge-type {
    right: 12px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
}

.card-body {
    padding: 16px;
}

.card-title {
    margin: 0 0 8px;
    color: #fff;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 850;
    transition: color 0.22s ease;
}

.movie-card:hover .card-title {
    color: #fed7aa;
}

.card-text {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.55;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: var(--muted);
    font-size: 12px;
    margin-bottom: 12px;
}

.meta-chip {
    max-width: 58%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.78);
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag {
    padding: 4px 8px;
    border-radius: 999px;
    color: #cbd5e1;
    background: rgba(15, 23, 42, 0.78);
    font-size: 12px;
}

.feature-card {
    overflow: hidden;
    border-radius: var(--radius-xl);
    border: 1px solid var(--line-soft);
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.86), rgba(15, 23, 42, 0.94));
    box-shadow: var(--shadow);
}

.feature-card .feature-text {
    padding: 18px;
    color: var(--muted-strong);
}

.category-box {
    position: relative;
    overflow: hidden;
    min-height: 170px;
    padding: 24px;
    border-radius: var(--radius-xl);
    background:
        linear-gradient(135deg, rgba(249, 115, 22, 0.18), rgba(15, 23, 42, 0.88)),
        rgba(30, 41, 59, 0.92);
    border: 1px solid var(--line-soft);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
    transition: transform 0.24s ease, border-color 0.24s ease;
}

.category-box:hover {
    transform: translateY(-5px);
    border-color: rgba(249, 115, 22, 0.45);
}

.category-box h2,
.category-box h3 {
    margin: 0 0 10px;
    font-size: 24px;
    font-weight: 900;
}

.category-box p {
    margin: 0;
    color: var(--muted-strong);
}

.category-box .category-arrow {
    position: absolute;
    right: 22px;
    bottom: 18px;
    color: #fed7aa;
    font-weight: 900;
}

.filter-panel {
    padding: 22px;
    border-radius: var(--radius-xl);
    border: 1px solid var(--line-soft);
    background: rgba(15, 23, 42, 0.78);
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.18);
    backdrop-filter: blur(16px);
}

.filter-row {
    display: grid;
    grid-template-columns: 1fr 190px 190px;
    gap: 14px;
}

.search-input,
.select-input {
    width: 100%;
    min-height: 48px;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    outline: none;
    color: #fff;
    background: rgba(30, 41, 59, 0.88);
    padding: 0 15px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-input:focus,
.select-input:focus {
    border-color: rgba(249, 115, 22, 0.72);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.14);
}

.select-input option {
    background: #0f172a;
    color: #fff;
}

.empty-message {
    padding: 24px;
    border-radius: var(--radius-lg);
    color: var(--muted-strong);
    text-align: center;
    background: rgba(30, 41, 59, 0.68);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 60px 128px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 14px;
    border-radius: 18px;
    background: rgba(30, 41, 59, 0.78);
    border: 1px solid var(--line-soft);
    transition: 0.24s ease;
}

.rank-item:hover {
    transform: translateX(4px);
    border-color: rgba(249, 115, 22, 0.42);
    background: rgba(39, 52, 73, 0.92);
}

.rank-num {
    color: rgba(148, 163, 184, 0.48);
    font-size: 32px;
    font-weight: 950;
    letter-spacing: -0.08em;
    text-align: center;
}

.rank-thumb {
    height: 76px;
    border-radius: 12px;
    overflow: hidden;
    background: #0f172a;
}

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

.rank-title {
    margin: 0 0 6px;
    font-size: 18px;
    font-weight: 900;
}

.rank-desc {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.rank-meta {
    color: var(--muted);
    font-size: 13px;
    white-space: nowrap;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(240px, 360px) 1fr;
    gap: 32px;
    align-items: start;
}

.detail-poster {
    position: sticky;
    top: 96px;
    overflow: hidden;
    border-radius: var(--radius-xl);
    border: 1px solid var(--line-soft);
    box-shadow: var(--shadow);
    background: rgba(15, 23, 42, 0.85);
}

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

.detail-info {
    padding: 26px;
    border-radius: var(--radius-xl);
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid var(--line-soft);
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.24);
}

.detail-info h2 {
    margin: 0 0 12px;
    font-size: 24px;
    font-weight: 900;
}

.detail-copy {
    color: #dbe4ef;
    font-size: 16px;
    line-height: 1.82;
}

.detail-copy p {
    margin: 0 0 16px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: #000;
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: var(--shadow);
}

.player-shell video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    cursor: pointer;
    background:
        linear-gradient(0deg, rgba(0, 0, 0, 0.74), rgba(0, 0, 0, 0.15)),
        rgba(2, 6, 23, 0.18);
}

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

.player-start {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--accent);
    font-size: 32px;
    box-shadow: 0 24px 58px rgba(249, 115, 22, 0.38);
    cursor: pointer;
    transition: transform 0.22s ease, background 0.22s ease;
}

.player-start:hover {
    transform: scale(1.08);
    background: var(--accent-dark);
}

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

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

.footer-inner {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
    padding: 34px 0;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
    align-items: center;
}

.footer-title {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 900;
}

.footer-text {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    color: var(--muted-strong);
    font-size: 14px;
    font-weight: 700;
}

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

.backtop {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 40;
    width: 48px;
    height: 48px;
    display: none;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: var(--accent);
    box-shadow: 0 18px 36px rgba(249, 115, 22, 0.3);
    cursor: pointer;
}

.backtop.is-visible {
    display: grid;
}

.line-clamp-1,
.line-clamp-2,
.line-clamp-3,
.line-clamp-4 {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
}

.line-clamp-1 {
    -webkit-line-clamp: 1;
}

.line-clamp-2 {
    -webkit-line-clamp: 2;
}

.line-clamp-3 {
    -webkit-line-clamp: 3;
}

.line-clamp-4 {
    -webkit-line-clamp: 4;
}

[hidden] {
    display: none !important;
}

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

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

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

    .detail-layout {
        grid-template-columns: 300px 1fr;
    }
}

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

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

    .hero {
        min-height: 620px;
        height: 74vh;
    }

    .hero-slide::after {
        background:
            linear-gradient(0deg, #020617, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.18)),
            linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(2, 6, 23, 0.32));
    }

    .hero-copy {
        padding-top: 76px;
    }

    .section-head {
        align-items: start;
        flex-direction: column;
    }

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

    .grid-6,
    .grid-5,
    .grid-4,
    .grid-3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .detail-poster {
        position: relative;
        top: auto;
        max-width: 360px;
    }

    .rank-item {
        grid-template-columns: 44px 96px 1fr;
    }

    .rank-meta {
        display: none;
    }

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

@media (max-width: 560px) {
    .navbar,
    .container,
    .footer-inner,
    .hero-inner,
    .mobile-nav {
        width: min(100% - 22px, var(--container));
    }

    .brand-subtitle {
        display: none;
    }

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

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

    .hero {
        min-height: 620px;
    }

    .hero-title {
        font-size: 40px;
    }

    .hero-summary {
        font-size: 16px;
    }

    .hero-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .grid-6,
    .grid-5,
    .grid-4,
    .grid-3,
    .grid-2,
    .related-strip {
        grid-template-columns: 1fr;
    }

    .poster,
    .card-small .poster,
    .card-large .poster {
        height: 300px;
    }

    .rank-item {
        grid-template-columns: 38px 82px 1fr;
        gap: 12px;
        padding: 12px;
    }

    .rank-num {
        font-size: 24px;
    }

    .rank-thumb {
        height: 62px;
    }

    .rank-title {
        font-size: 15px;
    }

    .rank-desc {
        display: none;
    }
}
