:root {
    color-scheme: dark;
    --bg: #020617;
    --bg-soft: #0f172a;
    --panel: #111827;
    --panel-strong: #1e293b;
    --line: rgba(148, 163, 184, 0.18);
    --muted: #94a3b8;
    --text: #f8fafc;
    --text-soft: #cbd5e1;
    --amber: #f59e0b;
    --amber-strong: #d97706;
    --green: #22c55e;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background: radial-gradient(circle at 10% 0%, rgba(245, 158, 11, 0.16), transparent 28%), linear-gradient(180deg, #020617 0%, #0f172a 48%, #020617 100%);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.92);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 24px;
    width: min(1200px, calc(100% - 32px));
    height: 72px;
    margin: 0 auto;
}

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

.brand-icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--amber), #f97316);
    color: #ffffff;
    font-size: 18px;
    box-shadow: 0 14px 34px rgba(245, 158, 11, 0.26);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-copy strong {
    font-size: 20px;
    letter-spacing: 0.02em;
}

.brand-copy small {
    margin-top: 3px;
    color: var(--muted);
    font-size: 12px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-left: auto;
}

.site-nav a {
    color: var(--text-soft);
    font-size: 14px;
    font-weight: 600;
    transition: color 0.2s ease, transform 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
    color: var(--amber);
}

.header-search {
    display: flex;
    overflow: hidden;
    width: 220px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: none;
    padding: 9px 12px 9px 16px;
    background: transparent;
    color: var(--text);
}

.header-search button {
    border: 0;
    padding: 0 14px;
    background: var(--amber);
    color: #ffffff;
    cursor: pointer;
}

.menu-toggle {
    display: none;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 8px 11px;
    background: rgba(15, 23, 42, 0.8);
    color: var(--text);
    cursor: pointer;
}

.hero-carousel {
    position: relative;
    min-height: 70vh;
    overflow: hidden;
    background: #020617;
}

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

.hero-slide {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.8s ease;
}

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.76) 40%, rgba(2, 6, 23, 0.24) 100%), linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.1) 45%, rgba(2, 6, 23, 0.24) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: min(1200px, calc(100% - 32px));
    height: 100%;
    margin: 0 auto;
    padding: 90px 0 120px;
}

.hero-badge,
.eyebrow {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.16);
    color: #fbbf24;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.hero-badge {
    padding: 8px 14px;
    border: 1px solid rgba(245, 158, 11, 0.28);
}

.eyebrow {
    margin-bottom: 10px;
    padding: 5px 10px;
}

.hero-content h1 {
    max-width: 720px;
    margin: 22px 0 18px;
    font-size: clamp(38px, 7vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-content p {
    max-width: 690px;
    margin: 0 0 32px;
    color: var(--text-soft);
    font-size: clamp(17px, 2vw, 22px);
}

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

.primary-button,
.ghost-button,
.section-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.primary-button {
    min-height: 50px;
    padding: 0 24px;
    background: var(--amber);
    color: #ffffff;
    box-shadow: 0 16px 35px rgba(245, 158, 11, 0.26);
}

.primary-button:hover {
    background: var(--amber-strong);
    transform: translateY(-2px);
}

.ghost-button,
.section-link {
    min-height: 50px;
    border: 1px solid var(--line);
    padding: 0 22px;
    background: rgba(15, 23, 42, 0.7);
    color: var(--text);
}

.ghost-button:hover,
.section-link:hover {
    border-color: rgba(245, 158, 11, 0.48);
    transform: translateY(-2px);
}

.hero-controls {
    position: absolute;
    right: max(16px, calc((100% - 1200px) / 2));
    bottom: 32px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 14px;
}

.hero-arrow,
.hero-dot {
    border: 0;
    cursor: pointer;
}

.hero-arrow {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    color: var(--text);
    font-size: 26px;
}

.hero-dots {
    display: flex;
    gap: 8px;
}

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.34);
}

.hero-dot.active {
    width: 28px;
    background: var(--amber);
}

.content-section {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 72px 0;
}

.alt-section {
    width: 100%;
    max-width: none;
    padding-right: max(16px, calc((100% - 1200px) / 2));
    padding-left: max(16px, calc((100% - 1200px) / 2));
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.42), rgba(2, 6, 23, 0));
}

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

.section-heading h2,
.page-hero h1,
.detail-copy h1,
.story-card h2 {
    margin: 0;
}

.section-heading h2 {
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
}

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

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

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

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.72);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.18);
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    border-color: rgba(245, 158, 11, 0.42);
    box-shadow: var(--shadow);
    transform: translateY(-6px);
}

.poster-wrap {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: var(--panel-strong);
}

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

.movie-card:hover .poster-wrap img,
.category-tile:hover img,
.category-cover:hover img {
    transform: scale(1.06);
}

.poster-badge,
.rank-mark {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.poster-badge {
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    background: rgba(2, 6, 23, 0.74);
    color: #ffffff;
    backdrop-filter: blur(10px);
}

.rank-mark {
    top: 12px;
    right: 12px;
    display: grid;
    place-items: center;
    min-width: 32px;
    height: 32px;
    padding: 0 9px;
    background: var(--amber);
    color: #ffffff;
}

.movie-card-body {
    padding: 16px;
}

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
}

.movie-card h3 {
    margin: 9px 0 8px;
    color: var(--text);
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h3 a:hover {
    color: var(--amber);
}

.movie-card p {
    display: -webkit-box;
    overflow: hidden;
    min-height: 48px;
    margin: 0 0 12px;
    color: var(--text-soft);
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.tag-list,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.tag-list span,
.detail-tags span {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px 8px;
    color: var(--muted);
    font-size: 12px;
}

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

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

.rank-row {
    display: grid;
    grid-template-columns: 38px 56px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 10px;
    background: rgba(15, 23, 42, 0.62);
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.rank-row:hover {
    border-color: rgba(245, 158, 11, 0.45);
    transform: translateX(4px);
}

.rank-row img {
    width: 56px;
    height: 74px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-num {
    color: var(--amber);
    font-size: 20px;
    font-weight: 900;
    text-align: center;
}

.rank-copy {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.rank-copy strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-copy em,
.rank-heat {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

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

.category-tile,
.category-panel {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(15, 23, 42, 0.72);
}

.category-tile {
    min-height: 230px;
    padding: 18px;
}

.category-tile img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.44;
    transition: transform 0.35s ease, opacity 0.35s ease;
}

.category-tile::after {
    position: absolute;
    inset: 0;
    content: "";
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.32));
}

.category-tile span,
.category-tile strong {
    position: relative;
    z-index: 2;
    display: block;
}

.category-tile span {
    margin-top: 130px;
    color: var(--amber);
    font-weight: 900;
}

.category-tile strong {
    margin-top: 8px;
    color: var(--text);
    font-size: 14px;
    font-weight: 600;
}

.page-hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 360px;
    overflow: hidden;
    background: radial-gradient(circle at 20% 10%, rgba(245, 158, 11, 0.24), transparent 24%), linear-gradient(135deg, #020617 0%, #111827 55%, #0f172a 100%);
}

.page-hero > div {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
}

.page-hero h1 {
    max-width: 780px;
    margin-top: 18px;
    font-size: clamp(36px, 6vw, 62px);
    line-height: 1.08;
}

.page-hero p {
    max-width: 780px;
    color: var(--text-soft);
    font-size: 18px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) repeat(3, 180px);
    gap: 12px;
    margin-bottom: 28px;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: none;
    padding: 13px 14px;
    background: rgba(15, 23, 42, 0.86);
    color: var(--text);
}

.empty-state {
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 28px;
    color: var(--muted);
    text-align: center;
}

.category-panel-grid {
    display: grid;
    gap: 22px;
}

.category-panel {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 24px;
    padding: 18px;
}

.category-cover {
    overflow: hidden;
    border-radius: 18px;
    aspect-ratio: 16 / 11;
}

.category-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.category-panel h2 {
    margin: 0 0 8px;
    font-size: 28px;
}

.category-panel p {
    margin: 0 0 14px;
    color: var(--text-soft);
}

.category-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.category-links a {
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 7px 10px;
    color: var(--text-soft);
    font-size: 13px;
}

.category-links a:hover {
    border-color: rgba(245, 158, 11, 0.45);
    color: var(--amber);
}

.full-rank-list {
    margin-top: 30px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.detail-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.28fr) minmax(320px, 0.72fr);
    gap: 34px;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0 22px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 28px;
    background: #000000;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.movie-player {
    width: 100%;
    height: 100%;
    background: #000000;
    object-fit: contain;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: radial-gradient(circle, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.58));
    color: #ffffff;
    cursor: pointer;
}

.player-overlay span {
    display: grid;
    place-items: center;
    width: 82px;
    height: 82px;
    border-radius: 999px;
    background: var(--amber);
    font-size: 28px;
    box-shadow: 0 18px 44px rgba(245, 158, 11, 0.32);
}

.player-shell.is-playing .player-overlay {
    opacity: 0;
    pointer-events: none;
}

.detail-copy {
    align-self: center;
}

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

.breadcrumbs a:hover {
    color: var(--amber);
}

.detail-copy h1 {
    margin-top: 18px;
    font-size: clamp(34px, 4.8vw, 58px);
    line-height: 1.1;
}

.detail-copy p {
    color: var(--text-soft);
    font-size: 17px;
}

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

.detail-meta div {
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 12px 14px;
    background: rgba(15, 23, 42, 0.62);
}

.detail-meta dt {
    color: var(--muted);
    font-size: 12px;
}

.detail-meta dd {
    margin: 2px 0 0;
    color: var(--text);
    font-weight: 800;
}

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

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

.story-card h2 {
    margin-bottom: 14px;
    color: var(--amber);
    font-size: 24px;
}

.story-card p {
    margin: 0;
    color: var(--text-soft);
    font-size: 16px;
}

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

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

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

.footer-inner h2 {
    margin: 0 0 16px;
    color: var(--text);
    font-size: 18px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 16px;
}

.footer-links a {
    color: var(--muted);
    font-size: 14px;
}

.footer-links a:hover {
    color: var(--amber);
}

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

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

[hidden] {
    display: none !important;
}

@media (max-width: 1100px) {
    .site-nav {
        position: fixed;
        top: 72px;
        right: 16px;
        display: none;
        width: min(320px, calc(100vw - 32px));
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        border: 1px solid var(--line);
        border-radius: 18px;
        padding: 10px;
        background: rgba(15, 23, 42, 0.98);
        box-shadow: var(--shadow);
    }

    .site-nav.is-open {
        display: flex;
    }

    .site-nav a {
        border-radius: 12px;
        padding: 10px 12px;
    }

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

    .header-search {
        margin-left: auto;
    }

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

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

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

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

    .full-rank-list {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .header-inner {
        height: auto;
        min-height: 72px;
        flex-wrap: wrap;
        padding: 12px 0;
    }

    .brand-copy small {
        display: none;
    }

    .header-search {
        order: 3;
        width: 100%;
    }

    .hero-carousel {
        min-height: 640px;
    }

    .hero-content {
        justify-content: flex-end;
        padding-bottom: 110px;
    }

    .hero-controls {
        left: 16px;
        right: auto;
    }

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

    .movie-grid,
    .featured-grid,
    .compact-grid,
    .listing-grid,
    .category-grid,
    .detail-section,
    .footer-inner,
    .category-panel {
        grid-template-columns: 1fr;
    }

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

    .category-panel {
        gap: 16px;
    }

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

    .rank-row {
        grid-template-columns: 34px 48px minmax(0, 1fr);
    }

    .rank-heat {
        display: none;
    }
}
