:root {
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.82);
    --panel-strong: rgba(15, 23, 42, 0.96);
    --line: rgba(59, 130, 246, 0.16);
    --muted-line: rgba(148, 163, 184, 0.18);
    --text: #f8fafc;
    --muted: #94a3b8;
    --soft: #cbd5e1;
    --blue: #3b82f6;
    --cyan: #22d3ee;
    --radius: 22px;
    --shadow: 0 28px 80px rgba(15, 23, 42, 0.42);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.22), transparent 34rem),
        radial-gradient(circle at top right, rgba(34, 211, 238, 0.12), transparent 32rem),
        linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
}

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

img {
    display: block;
    max-width: 100%;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95), rgba(15, 23, 42, 0.95));
}

button,
input,
select {
    font: inherit;
}

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

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

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

.brand-mark {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    box-shadow: 0 14px 32px rgba(59, 130, 246, 0.36);
}

.brand-text {
    font-size: 20px;
    background: linear-gradient(90deg, #60a5fa, #67e8f9);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

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

.nav-link,
.mobile-link {
    color: #cbd5e1;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link {
    padding: 10px 14px;
    border-radius: 999px;
    font-size: 14px;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: #ffffff;
    background: rgba(59, 130, 246, 0.18);
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--muted-line);
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.72);
    color: #ffffff;
    cursor: pointer;
}

.mobile-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: #ffffff;
    border-radius: 999px;
}

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

.mobile-nav.is-open {
    display: grid;
    gap: 6px;
}

.mobile-link {
    padding: 12px 14px;
    border-radius: 12px;
}

.hero-carousel {
    position: relative;
    height: min(85vh, 820px);
    min-height: 620px;
    overflow: hidden;
    border-bottom: 1px solid var(--line);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.9s ease;
}

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

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.54) 46%, rgba(2, 6, 23, 0.18)),
        linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.58) 34%, rgba(2, 6, 23, 0.12) 100%);
}

.hero-content {
    position: absolute;
    left: max(24px, calc((100vw - 1180px) / 2));
    bottom: 82px;
    width: min(720px, calc(100% - 48px));
}

.hero-labels,
.hero-tags,
.tag-row,
.detail-meta,
.card-meta,
.rank-meta,
.related-links,
.hero-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-labels span,
.hero-tags span,
.tag-row span,
.detail-meta span,
.rank-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    color: #dbeafe;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(96, 165, 250, 0.2);
}

.hero-labels span:first-child {
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    border: 0;
}

.hero-content h1 {
    margin: 18px 0 16px;
    font-size: clamp(38px, 6vw, 76px);
    line-height: 0.98;
    letter-spacing: -0.05em;
    text-shadow: 0 20px 50px rgba(0, 0, 0, 0.44);
}

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

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

.primary-button,
.ghost-button,
.text-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    min-height: 46px;
    padding: 0 24px;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), #2563eb);
    box-shadow: 0 18px 40px rgba(37, 99, 235, 0.34);
    font-weight: 800;
}

.primary-button:hover,
.ghost-button:hover,
.text-button:hover,
.movie-card:hover,
.category-tile:hover,
.category-card-wide:hover,
.rank-item:hover {
    transform: translateY(-2px);
}

.ghost-button {
    min-height: 46px;
    padding: 0 20px;
    border-radius: 14px;
    color: #e2e8f0;
    background: rgba(15, 23, 42, 0.74);
    border: 1px solid var(--muted-line);
}

.text-button {
    min-height: 38px;
    padding: 0 14px;
    border-radius: 12px;
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.14);
    border: 1px solid rgba(59, 130, 246, 0.22);
    font-weight: 700;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.72);
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
    backdrop-filter: blur(14px);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

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

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

.hero-dot.is-active {
    width: 34px;
    background: #60a5fa;
}

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

.content-section {
    padding: 68px 0 0;
}

.first-section {
    padding-top: 38px;
}

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

.section-heading h2 {
    margin: 0;
    font-size: clamp(25px, 3vw, 36px);
    letter-spacing: -0.03em;
}

.section-heading p {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.7;
}

.section-link {
    color: #93c5fd;
    font-weight: 800;
}

.scroll-row {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 260px;
    gap: 18px;
    overflow-x: auto;
    padding: 0 2px 18px;
    scrollbar-color: rgba(96, 165, 250, 0.45) rgba(15, 23, 42, 0.6);
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--muted-line);
    border-radius: var(--radius);
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.58));
    box-shadow: 0 16px 44px rgba(2, 6, 23, 0.28);
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    border-color: rgba(59, 130, 246, 0.48);
    box-shadow: 0 22px 54px rgba(2, 6, 23, 0.44);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: #0f172a;
}

.poster-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

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

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

.type-badge,
.rank-chip {
    position: absolute;
    top: 12px;
    min-height: 26px;
    display: inline-flex;
    align-items: center;
    padding: 0 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.type-badge {
    left: 12px;
    color: #ffffff;
    background: rgba(37, 99, 235, 0.86);
}

.rank-chip {
    right: 12px;
    color: #e0f2fe;
    background: rgba(8, 47, 73, 0.86);
}

.card-body {
    padding: 15px;
}

.card-body h3 {
    min-height: 46px;
    margin: 0 0 10px;
    font-size: 16px;
    line-height: 1.45;
}

.card-body h3 a:hover,
.rank-content h3 a:hover,
.category-card-wide h2 a:hover {
    color: #60a5fa;
}

.card-meta {
    gap: 8px;
    color: #94a3b8;
    font-size: 12px;
    margin-bottom: 10px;
}

.card-body p {
    min-height: 60px;
    margin: 0 0 12px;
    color: #cbd5e1;
    font-size: 13px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    overflow: hidden;
}

.tag-row {
    gap: 6px;
}

.tag-row span {
    min-height: 24px;
    padding: 3px 8px;
    font-size: 12px;
}

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

.category-tile {
    min-height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
    border: 1px solid var(--muted-line);
    border-radius: var(--radius);
    background:
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.22), transparent 12rem),
        linear-gradient(180deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.62));
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-tile:hover {
    border-color: rgba(34, 211, 238, 0.44);
}

.category-tile span {
    font-size: 20px;
    font-weight: 900;
}

.category-tile p,
.category-card-wide p,
.page-hero p,
.story-card p {
    color: var(--soft);
    line-height: 1.8;
}

.category-tile div,
.category-preview-links,
.related-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-tile div a,
.category-preview-links a,
.related-links a {
    padding: 7px 10px;
    border-radius: 999px;
    color: #bfdbfe;
    background: rgba(59, 130, 246, 0.12);
}

.page-hero {
    margin-top: 34px;
    padding: 56px;
    border: 1px solid var(--line);
    border-radius: 32px;
    background:
        radial-gradient(circle at 78% 20%, rgba(34, 211, 238, 0.16), transparent 18rem),
        radial-gradient(circle at 10% 10%, rgba(37, 99, 235, 0.24), transparent 18rem),
        linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.86));
    box-shadow: var(--shadow);
}

.small-hero {
    min-height: 300px;
    display: flex;
    align-items: end;
}

.rank-hero {
    min-height: 360px;
    display: flex;
    align-items: end;
}

.eyebrow {
    display: inline-flex;
    margin-bottom: 14px;
    color: #67e8f9;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.page-hero h1,
.detail-panel h1 {
    margin: 0;
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 820px;
    margin: 18px 0 0;
    font-size: 18px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 180px 180px;
    gap: 14px;
    margin-bottom: 24px;
    padding: 16px;
    border: 1px solid var(--muted-line);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.74);
}

.filter-panel label {
    display: grid;
    gap: 8px;
    color: #cbd5e1;
    font-weight: 700;
    font-size: 13px;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 44px;
    padding: 0 14px;
    color: #ffffff;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 14px;
    outline: none;
    background: rgba(2, 6, 23, 0.72);
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: rgba(96, 165, 250, 0.72);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
}

.category-list-wide {
    display: grid;
    gap: 18px;
}

.category-card-wide {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 22px;
    padding: 18px;
    border: 1px solid var(--muted-line);
    border-radius: 26px;
    background: rgba(15, 23, 42, 0.72);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-card-wide:hover {
    border-color: rgba(96, 165, 250, 0.44);
}

.category-poster-stack {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.category-poster-stack img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 16px;
}

.category-card-wide h2 {
    margin: 6px 0 10px;
    font-size: 28px;
}

.category-preview-links {
    margin: 18px 0;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 62px 92px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 14px;
    border: 1px solid var(--muted-line);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.72);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.rank-item:hover {
    border-color: rgba(96, 165, 250, 0.44);
}

.rank-number {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb, #06b6d4);
    font-weight: 900;
}

.rank-cover img {
    width: 92px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 16px;
}

.rank-content h3 {
    margin: 0 0 8px;
    font-size: 20px;
}

.rank-content p {
    margin: 0 0 10px;
    color: #cbd5e1;
    line-height: 1.6;
}

.rank-meta {
    color: #94a3b8;
    font-size: 13px;
    margin-bottom: 10px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 28px 0 18px;
    color: #94a3b8;
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #60a5fa;
}

.detail-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.65fr);
    gap: 24px;
    align-items: stretch;
}

.player-shell {
    position: relative;
    overflow: hidden;
    min-height: 520px;
    border: 1px solid rgba(96, 165, 250, 0.2);
    border-radius: 30px;
    background: #000000;
    box-shadow: var(--shadow);
}

.main-video,
.player-cover,
.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.main-video {
    background: #000000;
}

.player-cover {
    border: 0;
    padding: 0;
    color: #ffffff;
    background: #020617;
    cursor: pointer;
    transition: opacity 0.28s ease, visibility 0.28s ease;
}

.player-cover img {
    object-fit: cover;
    opacity: 0.58;
    filter: saturate(1.05) contrast(1.06);
}

.play-orb {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 96px;
    height: 96px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--cyan));
    box-shadow: 0 24px 70px rgba(37, 99, 235, 0.48);
    transform: translate(-50%, -50%);
    font-size: 34px;
}

.player-shell.is-playing .player-cover {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.detail-panel {
    padding: 34px;
    border: 1px solid var(--muted-line);
    border-radius: 30px;
    background:
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.18), transparent 16rem),
        rgba(15, 23, 42, 0.78);
}

.detail-line {
    margin: 18px 0;
    color: #dbeafe;
    font-size: 18px;
    line-height: 1.8;
}

.detail-meta {
    margin-bottom: 16px;
}

.detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-top: 24px;
}

.story-card {
    padding: 26px;
    border: 1px solid var(--muted-line);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.72);
}

.story-card:first-child {
    grid-column: span 2;
}

.story-card h2 {
    margin: 0 0 14px;
    font-size: 24px;
}

.story-card p {
    margin: 0;
    white-space: pre-line;
}

.large-tags span {
    min-height: 30px;
    padding: 5px 12px;
    font-size: 13px;
}

.related-section {
    width: 100%;
    padding-bottom: 70px;
}

.site-footer {
    margin-top: 70px;
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.72), rgba(2, 6, 23, 0.96));
}

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

.footer-brand p {
    max-width: 620px;
    color: var(--muted);
    line-height: 1.8;
}

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

.footer-links a {
    padding: 9px 12px;
    border-radius: 999px;
    color: #cbd5e1;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--muted-line);
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 30px;
    color: #64748b;
    border-top: 1px solid rgba(148, 163, 184, 0.12);
}

[hidden] {
    display: none !important;
}

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

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

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

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

    .mobile-toggle {
        display: block;
    }

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

    .hero-content {
        left: 20px;
        bottom: 72px;
        width: calc(100% - 40px);
    }

    .hero-arrow {
        display: none;
    }

    .content-section {
        padding-top: 48px;
    }

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

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

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

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

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

    .category-card-wide {
        grid-template-columns: 1fr;
    }

    .rank-item {
        grid-template-columns: 46px 74px 1fr;
    }

    .rank-item .text-button {
        grid-column: 2 / -1;
        justify-self: start;
    }

    .rank-number {
        width: 42px;
        height: 42px;
        border-radius: 14px;
    }

    .rank-cover img {
        width: 74px;
    }

    .player-shell {
        min-height: 58vw;
        border-radius: 22px;
    }

    .detail-panel {
        padding: 24px;
        border-radius: 22px;
    }

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

    .story-card:first-child {
        grid-column: auto;
    }

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

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

@media (max-width: 520px) {
    .header-inner {
        height: 64px;
    }

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

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

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

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

    .primary-button,
    .ghost-button {
        width: 100%;
    }

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

    .scroll-row {
        grid-auto-columns: 82%;
    }

    .play-orb {
        width: 76px;
        height: 76px;
        font-size: 28px;
    }
}
