:root {
    --bg: #f7f8fb;
    --text: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --card: #ffffff;
    --orange: #f97316;
    --red: #ef4444;
    --purple: #7c3aed;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

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

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

img {
    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: 100;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    backdrop-filter: blur(16px);
}

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

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    color: #111827;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.logo-mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--orange), var(--red));
    color: #fff;
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.32);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    color: #374151;
    font-weight: 700;
    font-size: 14px;
}

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

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover,
.quick-links a:hover {
    color: var(--orange);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: #f3f4f6;
    cursor: pointer;
    padding: 10px;
}

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

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 14px;
    padding: 14px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.mobile-nav a {
    display: block;
    padding: 10px 8px;
    color: #374151;
    font-weight: 700;
}

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

.hero-slider {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    background: #050505;
}

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

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

.hero-bg,
.detail-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
    filter: saturate(1.08);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.58) 48%, rgba(0, 0, 0, 0.28) 100%),
        linear-gradient(0deg, rgba(0, 0, 0, 0.94), rgba(0, 0, 0, 0.05) 54%);
}

.hero-content {
    position: relative;
    width: min(1180px, calc(100% - 32px));
    min-height: 600px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: center;
    gap: 56px;
    color: #fff;
    padding: 80px 0 90px;
}

.hero-copy h1,
.page-hero h1,
.detail-info h1 {
    margin: 12px 0 16px;
    font-size: clamp(38px, 7vw, 76px);
    line-height: 1.04;
    letter-spacing: -0.055em;
}

.hero-copy p {
    max-width: 680px;
    margin: 0 0 22px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 19px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fed7aa;
    font-weight: 900;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.hero-tags,
.detail-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.detail-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.12);
    color: #ea580c;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

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

.hero-actions,
.detail-info .btn {
    margin-top: 28px;
}

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

.btn + .btn {
    margin-left: 10px;
}

.btn.primary {
    background: linear-gradient(135deg, var(--orange), var(--red));
    color: #fff;
    box-shadow: 0 14px 26px rgba(239, 68, 68, 0.34);
}

.btn.ghost {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.24);
}

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

.hero-poster {
    position: relative;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 35px 80px rgba(0, 0, 0, 0.5);
    transform: rotate(2deg);
}

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

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

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

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

.quick-search-band {
    margin-top: -34px;
    position: relative;
    z-index: 5;
}

.quick-search-band .container {
    background: #fff;
    border-radius: 24px;
    padding: 18px;
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
}

.hero-search,
.filter-panel {
    display: flex;
    gap: 12px;
}

.hero-search input,
.filter-panel input {
    min-width: 0;
    flex: 1;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #f9fafb;
    padding: 13px 18px;
    color: #111827;
    outline: none;
}

.hero-search input:focus,
.filter-panel input:focus {
    border-color: rgba(249, 115, 22, 0.55);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.1);
}

.hero-search button,
.filter-chips button {
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--orange), var(--red));
    color: #fff;
    padding: 0 22px;
    font-weight: 900;
    cursor: pointer;
}

.quick-links {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    font-weight: 800;
    color: #4b5563;
}

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

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

.section-heading h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 40px);
    letter-spacing: -0.04em;
}

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

.section-more {
    color: var(--orange);
    font-weight: 900;
}

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

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

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

.movie-card {
    background: var(--card);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 22px 45px rgba(15, 23, 42, 0.16);
}

.poster-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 3 / 4;
    background: #111827;
}

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

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

.poster-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 58%);
}

.card-badge,
.play-chip {
    position: absolute;
    border-radius: 999px;
    font-style: normal;
    font-size: 12px;
    font-weight: 900;
}

.card-badge {
    top: 12px;
    left: 12px;
    color: #fff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    padding: 5px 10px;
}

.play-chip {
    right: 12px;
    bottom: 12px;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.22);
    padding: 5px 10px;
    backdrop-filter: blur(10px);
}

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

.movie-card-body strong {
    display: block;
    color: #111827;
    font-size: 16px;
    line-height: 1.35;
}

.movie-card-body small,
.card-line {
    display: block;
    color: var(--muted);
    font-size: 13px;
}

.card-line {
    margin: 8px 0 10px;
}

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

.category-tile,
.category-card-large {
    position: relative;
    overflow: hidden;
    min-height: 160px;
    border-radius: 24px;
    background: #111827;
    color: #fff;
    box-shadow: var(--shadow);
}

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

.category-tile:hover img {
    transform: scale(1.08);
}

.category-tile span {
    position: absolute;
    inset: auto 18px 18px 18px;
}

.category-tile strong,
.category-card-large strong {
    display: block;
    font-size: 20px;
    line-height: 1.2;
}

.category-tile small,
.category-card-large small {
    display: block;
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.78);
}

.rank-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 34px;
}

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

.rank-item,
.ranking-row {
    display: grid;
    align-items: center;
    gap: 14px;
    background: #fff;
    border-radius: 18px;
    padding: 12px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.rank-item {
    grid-template-columns: 46px 56px minmax(0, 1fr);
}

.ranking-row {
    grid-template-columns: 64px 84px minmax(0, 1fr) auto;
}

.rank-item:hover,
.ranking-row:hover {
    transform: translateX(4px);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.13);
}

.rank-num,
.ranking-index {
    color: var(--orange);
    font-weight: 1000;
    font-size: 22px;
}

.rank-item img,
.ranking-row img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 12px;
    background: #111827;
}

.rank-item strong,
.ranking-copy strong {
    display: block;
    color: #111827;
}

.rank-item small,
.ranking-copy small,
.ranking-copy em {
    display: block;
    color: var(--muted);
    font-style: normal;
}

.ranking-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: #fff7ed;
    color: #ea580c;
    font-weight: 900;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at 20% 10%, rgba(249, 115, 22, 0.28), transparent 30%), #111827;
    color: #fff;
}

.small-hero {
    padding: 84px 0 72px;
}

.page-hero p {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 18px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 700;
}

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

.category-card-large {
    min-height: 260px;
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: linear-gradient(135deg, #1f2937, #111827);
}

.thumb-stack {
    display: flex;
    gap: 8px;
}

.thumb-stack img {
    width: 30%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 14px;
    box-shadow: 0 14px 24px rgba(0, 0, 0, 0.28);
}

.filter-panel {
    margin-bottom: 24px;
    padding: 18px;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
    align-items: center;
}

.filter-chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-chips button {
    min-height: 42px;
    background: #fff7ed;
    color: #ea580c;
    padding: 0 14px;
}

.search-page-panel {
    position: sticky;
    top: 86px;
    z-index: 12;
}

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

.detail-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.24)),
        linear-gradient(0deg, rgba(0, 0, 0, 0.9), transparent 60%);
}

.detail-head {
    position: relative;
    z-index: 2;
    padding: 74px 0 80px;
}

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

.detail-poster {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 28px;
    box-shadow: 0 32px 70px rgba(0, 0, 0, 0.5);
}

.detail-info h1 {
    max-width: 880px;
}

.detail-one-line {
    max-width: 820px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 20px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px 0;
}

.detail-meta span {
    border-radius: 999px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.13);
    color: #fff;
    font-weight: 800;
}

.watch-card {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr);
    gap: 24px;
    align-items: stretch;
    border-radius: 28px;
    background: #fff;
    box-shadow: var(--shadow);
    padding: 18px;
}

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

.player-shell video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    cursor: pointer;
}

.player-start {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0.52));
    cursor: pointer;
}

.player-start span {
    width: 82px;
    height: 82px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--orange), var(--red));
    color: #fff;
    font-size: 34px;
    box-shadow: 0 18px 42px rgba(239, 68, 68, 0.38);
}

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

.watch-copy {
    padding: 18px 8px;
}

.watch-copy h2,
.content-card h2 {
    margin: 0 0 14px;
    font-size: 28px;
    letter-spacing: -0.03em;
}

.watch-copy p,
.content-card p {
    color: #4b5563;
    margin: 0;
}

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

.content-card {
    border-radius: 24px;
    background: #fff;
    padding: 28px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.site-footer {
    margin-top: 40px;
    padding: 42px 0;
    background: #111827;
    color: rgba(255, 255, 255, 0.78);
}

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

.footer-inner strong {
    display: block;
    color: #fff;
    margin-bottom: 8px;
    font-size: 20px;
}

.footer-inner p {
    max-width: 620px;
    margin: 0;
}

.footer-links {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-weight: 800;
}

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

@media (max-width: 1080px) {
    .movie-grid,
    .all-grid,
    .compact-grid,
    .category-grid,
    .category-large-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .rank-layout,
    .watch-card,
    .detail-content {
        grid-template-columns: 1fr;
    }
}

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

    .menu-toggle {
        display: block;
    }

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

    .hero-poster,
    .detail-poster {
        max-width: 240px;
    }

    .quick-search-band .container,
    .filter-panel,
    .footer-inner {
        grid-template-columns: 1fr;
        flex-direction: column;
        align-items: stretch;
    }

    .hero-search,
    .filter-panel {
        flex-direction: column;
    }

    .hero-search button {
        min-height: 46px;
    }
}

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

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

    .hero-copy h1,
    .page-hero h1,
    .detail-info h1 {
        font-size: 36px;
    }

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

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

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

    .ranking-row {
        grid-template-columns: 44px 64px minmax(0, 1fr);
    }

    .ranking-action {
        display: none;
    }

    .category-tile {
        min-height: 138px;
    }

    .content-card {
        padding: 22px;
    }
}
