:root {
    --bg: #f9fafb;
    --panel: #ffffff;
    --text: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --orange: #ea580c;
    --orange-dark: #c2410c;
    --red: #dc2626;
    --yellow: #fde047;
    --shadow: 0 20px 50px rgba(17, 24, 39, 0.12);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    background: var(--bg);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(229, 231, 235, 0.8);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(14px);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 20px;
    font-weight: 800;
    color: var(--orange);
    letter-spacing: -0.02em;
}

.brand-mark {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 10px 25px rgba(234, 88, 12, 0.35);
}

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

.nav-links a {
    padding: 10px 14px;
    border-radius: 999px;
    color: #374151;
    font-weight: 650;
}

.nav-links a:hover {
    color: var(--orange);
    background: #fff7ed;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #ffffff;
}

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

.hero-carousel {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(90deg, var(--orange), var(--red));
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.55s ease, transform 0.75s ease;
}

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

.hero-bg,
.detail-hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.hero-bg::after,
.detail-hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 78% 20%, rgba(253, 224, 71, 0.28), transparent 28%), rgba(0, 0, 0, 0.08);
}

.hero-content {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    align-items: center;
    gap: 56px;
    min-height: 620px;
    padding: 72px 0;
}

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

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 14px;
    color: var(--yellow);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-kicker {
    color: var(--orange);
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
    margin: 0 0 18px;
    font-size: clamp(40px, 6vw, 72px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.06em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
    max-width: 820px;
    margin: 0 0 28px;
    font-size: clamp(17px, 2vw, 22px);
    color: rgba(255, 255, 255, 0.88);
}

.hero-actions,
.detail-meta,
.hero-tags,
.footer-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-light {
    color: var(--orange);
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.16);
}

.btn-outline {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.55);
    background: rgba(255, 255, 255, 0.12);
}

.hero-tags {
    margin-top: 24px;
}

.hero-tags span,
.tag-row span,
.detail-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.hero-tags span,
.detail-meta span {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.hero-poster,
.detail-cover {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: linear-gradient(135deg, #fb923c, #ef4444);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
}

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

img.is-missing {
    opacity: 0;
}

.hero-dots {
    position: absolute;
    right: max(24px, calc((100vw - 1180px) / 2));
    bottom: 34px;
    z-index: 3;
    display: flex;
    gap: 10px;
}

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

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

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: -42px;
    position: relative;
    z-index: 5;
}

.stat-card,
.category-card,
.category-overview-card,
.movie-card,
.hot-panel,
.player-card,
.detail-content,
.archive-year-block {
    background: var(--panel);
    border: 1px solid rgba(229, 231, 235, 0.88);
    border-radius: var(--radius);
    box-shadow: 0 12px 30px rgba(17, 24, 39, 0.07);
}

.stat-card {
    display: block;
    padding: 24px;
}

.stat-card span,
.movie-meta-line,
.archive-link-grid span,
.compact-movie-list span {
    color: var(--muted);
    font-size: 13px;
}

.stat-card strong {
    display: block;
    margin-top: 6px;
    font-size: 21px;
}

.section-block {
    padding: 72px 0 0;
}

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

.section-heading.compact {
    align-items: center;
    margin-bottom: 18px;
}

.section-heading h2,
.archive-year-block h2,
.player-card h2,
.detail-content h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.search-box {
    display: block;
    min-width: min(320px, 100%);
}

.search-input {
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: none;
    background: #ffffff;
}

.search-input:focus {
    border-color: var(--orange);
    box-shadow: 0 0 0 4px rgba(234, 88, 12, 0.12);
}

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

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

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

.movie-card {
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
}

.poster-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    background: linear-gradient(135deg, #fb923c, #ef4444);
}

.poster-wrap img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.poster-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.58));
}

.rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 14px;
    color: #ffffff;
    background: rgba(234, 88, 12, 0.92);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.24);
}

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

.movie-meta-line {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.movie-meta-line a {
    color: var(--orange);
    font-weight: 800;
}

.movie-card h3 {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.3;
}

.movie-card p {
    min-height: 50px;
    margin: 0 0 12px;
    color: #4b5563;
    font-size: 14px;
}

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

.tag-row span {
    color: #9a3412;
    background: #fff7ed;
}

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

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

.category-card {
    padding: 22px;
}

.category-card-main {
    display: block;
}

.category-card-main span,
.category-overview-head span {
    color: var(--orange);
    font-weight: 900;
}

.category-card-main strong {
    display: block;
    margin-top: 8px;
    font-size: 19px;
}

.category-card-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.category-card-links a {
    padding: 6px 10px;
    border-radius: 999px;
    color: #374151;
    background: #f3f4f6;
    font-size: 13px;
}

.hot-panel {
    position: sticky;
    top: 96px;
    padding: 22px;
}

.hot-panel .section-heading a,
.section-heading.compact > a {
    color: var(--orange);
    font-weight: 800;
}

.ranking-list {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.ranking-list a {
    display: grid;
    grid-template-columns: 34px 1fr;
    gap: 10px;
    padding: 10px;
    border-radius: 14px;
    background: #f9fafb;
}

.ranking-list span {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    font-weight: 900;
}

.ranking-list strong {
    display: block;
    line-height: 1.25;
}

.ranking-list em {
    display: block;
    color: var(--muted);
    font-style: normal;
    font-size: 12px;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(90deg, var(--orange), var(--red));
}

.page-hero {
    padding: 72px 0;
}

.small-hero {
    background: linear-gradient(135deg, #ea580c, #dc2626 60%, #991b1b);
}

.category-hero {
    background: radial-gradient(circle at 80% 20%, rgba(253, 224, 71, 0.25), transparent 30%), linear-gradient(135deg, #ea580c, #dc2626);
}

.ranking-hero {
    background: radial-gradient(circle at 20% 10%, rgba(253, 224, 71, 0.32), transparent 30%), linear-gradient(135deg, #7f1d1d, #ea580c);
}

.breadcrumb {
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.82);
    font-weight: 700;
}

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

.category-overview-card {
    padding: 24px;
}

.category-overview-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.category-overview-head a {
    color: var(--orange);
    font-weight: 800;
}

.category-overview-card p {
    margin: 10px 0 18px;
    color: #4b5563;
}

.compact-movie-list {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.compact-movie-list a {
    display: block;
    padding: 10px 12px;
    border-radius: 12px;
    background: #f9fafb;
}

.compact-movie-list strong,
.compact-movie-list span {
    display: block;
}

.detail-hero {
    min-height: 560px;
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    padding: 44px 0 64px;
}

.detail-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
}

.detail-copy h1 {
    font-size: clamp(38px, 5vw, 66px);
}

.detail-copy p {
    max-width: 820px;
}

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

.detail-main {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.8fr);
    gap: 26px;
    padding-top: 48px;
}

.player-card,
.detail-content {
    padding: 22px;
}

.player-card h2,
.detail-content h2 {
    margin-bottom: 16px;
    font-size: 25px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    background: #020617;
    aspect-ratio: 16 / 9;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.68));
    cursor: pointer;
    transition: opacity 0.2s ease;
}

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

.play-icon {
    display: grid;
    width: 78px;
    height: 78px;
    place-items: center;
    border-radius: 999px;
    color: var(--orange);
    background: #ffffff;
    box-shadow: 0 22px 45px rgba(0, 0, 0, 0.35);
    font-size: 28px;
    text-indent: 4px;
}

.player-message {
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 14px;
    z-index: 4;
    margin: 0;
    color: #fecaca;
    font-weight: 700;
    pointer-events: none;
}

.detail-content p {
    margin: 0 0 22px;
    color: #374151;
    font-size: 16px;
}

.archive-wrapper {
    padding: 48px 0 0;
}

.archive-year-block {
    padding: 24px;
    margin-bottom: 24px;
}

.archive-link-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 18px;
}

.archive-link-grid a {
    display: block;
    padding: 12px;
    border-radius: 12px;
    background: #f9fafb;
}

.archive-link-grid strong,
.archive-link-grid span {
    display: block;
}

.site-footer {
    margin-top: 80px;
    padding: 36px 0;
    border-top: 1px solid var(--line);
    background: #ffffff;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-inner p {
    margin: 6px 0 0;
    color: var(--muted);
}

.footer-links a {
    color: #4b5563;
    font-weight: 700;
}

.is-filtered-out {
    display: none !important;
}

@media (max-width: 1024px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .hero-poster {
        display: none;
    }

    .stat-grid,
    .movie-grid,
    .ranking-grid,
    .related-grid,
    .archive-link-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

    .hot-panel {
        position: static;
    }
}

@media (max-width: 760px) {
    .nav-inner {
        min-height: 64px;
    }

    .menu-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 72px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 14px;
        border: 1px solid var(--line);
        border-radius: 18px;
        background: #ffffff;
        box-shadow: var(--shadow);
    }

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

    .hero-carousel,
    .hero-content {
        min-height: 560px;
    }

    .stat-grid,
    .movie-grid,
    .ranking-grid,
    .related-grid,
    .category-grid,
    .category-overview-grid,
    .archive-link-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .section-heading {
        display: grid;
        align-items: start;
    }

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

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

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

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

    .hero-carousel,
    .hero-content {
        min-height: 620px;
    }

    .hero-content {
        padding: 54px 0;
    }

    .stat-grid,
    .movie-grid,
    .ranking-grid,
    .related-grid,
    .category-grid,
    .category-overview-grid,
    .archive-link-grid {
        grid-template-columns: 1fr;
    }

    .section-block {
        padding-top: 50px;
    }
}
