:root {
    --brand-orange: #f97316;
    --brand-red: #ef4444;
    --brand-pink: #ec4899;
    --brand-yellow: #f59e0b;
    --ink: #111827;
    --muted: #6b7280;
    --soft: #f8fafc;
    --line: #e5e7eb;
    --card: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;
    color: var(--ink);
    background: linear-gradient(180deg, #f9fafb 0%, #ffffff 44%, #fff7ed 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #ffffff;
    background: linear-gradient(90deg, var(--brand-orange), var(--brand-red), var(--brand-pink));
    box-shadow: 0 12px 30px rgba(239, 68, 68, 0.28);
}

.header-inner {
    max-width: 1180px;
    height: 68px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    gap: 24px;
}

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

.brand-icon {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    display: inline-grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.2);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.brand-text {
    font-size: 21px;
    white-space: nowrap;
}

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

.nav-link {
    font-weight: 700;
    opacity: 0.9;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    opacity: 1;
    transform: translateY(-1px);
}

.header-search {
    position: relative;
    width: 260px;
}

.header-search input,
.mobile-search input {
    width: 100%;
    border: 0;
    outline: 0;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    padding: 10px 46px 10px 16px;
}

.header-search input::placeholder,
.mobile-search input::placeholder {
    color: rgba(255, 255, 255, 0.72);
}

.header-search button {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    border: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    cursor: pointer;
}

.mobile-menu-button {
    display: none;
    margin-left: auto;
    border: 0;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    padding: 9px 12px;
    cursor: pointer;
}

.mobile-menu {
    display: none;
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 20px 18px;
}

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

.mobile-search {
    display: flex;
    gap: 10px;
    margin-bottom: 14px;
}

.mobile-search button {
    border: 0;
    border-radius: 999px;
    padding: 0 18px;
    color: var(--brand-red);
    background: #ffffff;
    font-weight: 800;
}

.mobile-nav {
    display: grid;
    gap: 10px;
}

.mobile-nav-link,
.mobile-category-links a {
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.13);
}

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

.hero-carousel {
    position: relative;
    height: 620px;
    overflow: hidden;
    background: #030712;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.65s ease, transform 0.65s ease;
    transform: scale(1.03);
}

.hero-slide.is-active {
    opacity: 1;
    transform: scale(1);
    z-index: 2;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.84) 0%, rgba(0, 0, 0, 0.58) 48%, rgba(0, 0, 0, 0.16) 100%);
}

.hero-content {
    position: absolute;
    inset: 0;
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    color: #ffffff;
    max-width: 1180px;
}

.hero-content h1,
.hero-content h2 {
    max-width: 780px;
    margin: 0 0 18px;
    font-size: clamp(42px, 6vw, 76px);
    line-height: 1;
    letter-spacing: -0.05em;
}

.hero-content p {
    max-width: 700px;
    margin: 0 0 26px;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(17px, 2vw, 22px);
}

.hero-eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    color: var(--brand-orange);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hero-eyebrow span {
    color: #ffffff;
    background: linear-gradient(90deg, var(--brand-orange), var(--brand-red));
    border-radius: 999px;
    padding: 6px 14px;
    letter-spacing: 0;
}

.hero-eyebrow strong {
    color: #fdba74;
}

.hero-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 30px;
}

.hero-meta span,
.detail-meta span {
    border-radius: 999px;
    padding: 8px 14px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
}

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

.primary-button,
.ghost-button,
.text-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: #ffffff;
    background: linear-gradient(90deg, var(--brand-orange), var(--brand-red));
    padding: 14px 26px;
    box-shadow: 0 16px 32px rgba(249, 115, 22, 0.35);
}

.primary-button:hover,
.ghost-button:hover,
.text-button:hover {
    transform: translateY(-2px);
}

.ghost-button {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.36);
    background: rgba(255, 255, 255, 0.1);
    padding: 13px 22px;
}

.text-button {
    color: var(--brand-red);
    padding: 8px 0;
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 4;
    transform: translateY(-50%);
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

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

.home-section,
.filter-section {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
    padding: 70px 0;
}

.section-soft {
    width: 100%;
    max-width: none;
    padding: 70px max(20px, calc((100% - 1180px) / 2));
    background: linear-gradient(90deg, #fff7ed, #fff1f2);
}

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

.section-heading h2,
.rank-panel h2,
.content-card h2 {
    margin: 0;
    font-size: clamp(28px, 3.2vw, 40px);
    line-height: 1.1;
}

.section-heading a {
    color: var(--brand-red);
    font-weight: 900;
}

.compact-heading h2 {
    font-size: 30px;
}

.movie-grid {
    display: grid;
    gap: 22px;
}

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

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

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

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

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

.movie-card[hidden] {
    display: none;
}

.movie-poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, #111827, #7f1d1d);
}

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

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

.poster-type,
.rank-badge {
    position: absolute;
    top: 12px;
    border-radius: 999px;
    padding: 5px 10px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
    box-shadow: 0 10px 22px rgba(15, 23, 42, 0.18);
}

.poster-type {
    right: 12px;
    background: linear-gradient(90deg, var(--brand-orange), var(--brand-red));
}

.rank-badge {
    left: 12px;
    min-width: 34px;
    text-align: center;
    background: linear-gradient(90deg, #facc15, var(--brand-orange));
}

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

.movie-title {
    margin: 0 0 8px;
    font-size: 20px;
    line-height: 1.25;
}

.movie-title a:hover {
    color: var(--brand-red);
}

.movie-meta,
.movie-line {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.movie-line {
    margin-top: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-tags,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 14px;
}

.movie-tags span,
.detail-tags span {
    border-radius: 999px;
    padding: 4px 9px;
    color: #9a3412;
    background: #ffedd5;
    font-size: 12px;
    font-weight: 800;
}

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

.category-tile,
.category-overview-card {
    border-radius: 26px;
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.08);
}

.category-tile {
    padding: 24px;
    min-height: 190px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    background: linear-gradient(145deg, #ffffff, #fff7ed);
}

.category-name {
    color: var(--ink);
    font-size: 24px;
    font-weight: 900;
}

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

.category-link {
    color: var(--brand-red);
    font-weight: 900;
}

.split-section {
    display: grid;
    grid-template-columns: 0.72fr 1.28fr;
    gap: 28px;
    align-items: start;
}

.rank-panel {
    position: sticky;
    top: 96px;
    border-radius: 30px;
    padding: 30px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand-orange), var(--brand-red), var(--brand-pink));
    box-shadow: var(--shadow);
}

.rank-panel .section-kicker {
    color: #ffedd5;
}

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

.ranking-list li {
    display: grid;
    grid-template-columns: 40px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.13);
}

.rank-number {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--brand-red);
    background: #ffffff;
    font-weight: 900;
}

.ranking-list a {
    font-weight: 900;
}

.ranking-list em {
    color: rgba(255, 255, 255, 0.78);
    font-style: normal;
}

.page-hero {
    color: #ffffff;
    background: radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.2), transparent 28%), linear-gradient(120deg, #111827, #7f1d1d 48%, #db2777);
}

.small-hero {
    padding: 86px max(20px, calc((100% - 1180px) / 2));
}

.small-hero h1 {
    margin: 0 0 16px;
    font-size: clamp(38px, 5vw, 60px);
    line-height: 1;
}

.small-hero p {
    max-width: 820px;
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
}

.category-overview-card {
    padding: 18px;
    display: grid;
    grid-template-columns: 150px 1fr;
    gap: 18px;
    align-items: center;
}

.category-overview-card h2 {
    margin: 0 0 10px;
    font-size: 24px;
}

.category-overview-card p {
    color: var(--muted);
    margin: 0 0 10px;
}

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

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

.filter-bar {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr auto;
    gap: 12px;
    margin-bottom: 26px;
    padding: 16px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

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

.filter-bar input,
.filter-bar select,
.filter-bar button {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 12px 14px;
    outline: 0;
    background: #ffffff;
}

.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--brand-orange);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.13);
}

.filter-bar button {
    color: #ffffff;
    border: 0;
    background: linear-gradient(90deg, var(--brand-orange), var(--brand-red));
    font-weight: 900;
    cursor: pointer;
}

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

.detail-hero {
    padding: 34px max(20px, calc((100% - 1180px) / 2)) 46px;
    color: #ffffff;
    background: radial-gradient(circle at 70% 10%, rgba(249, 115, 22, 0.35), transparent 24%), linear-gradient(135deg, #030712, #450a0a 52%, #831843);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    margin-bottom: 24px;
    color: rgba(255, 255, 255, 0.78);
}

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

.detail-layout {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 34px;
    align-items: center;
}

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

.detail-info h1 {
    margin: 0 0 18px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.detail-one-line {
    max-width: 850px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 20px;
}

.player-section {
    width: min(1180px, calc(100% - 40px));
    margin: 34px auto 0;
}

.video-shell {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #000000;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.movie-video {
    width: 100%;
    height: 100%;
    display: block;
    background: #000000;
    cursor: pointer;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    border: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    color: #ffffff;
    background: radial-gradient(circle at 50% 44%, rgba(249, 115, 22, 0.22), transparent 22%), rgba(0, 0, 0, 0.42);
    cursor: pointer;
    font-weight: 900;
    font-size: 20px;
}

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

.play-mark {
    width: 78px;
    height: 78px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: var(--brand-red);
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

.detail-content {
    width: min(1180px, calc(100% - 40px));
    margin: 34px auto 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

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

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

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

.site-footer {
    margin-top: 70px;
    color: #d1d5db;
    background: #111827;
}

.footer-inner {
    width: min(1180px, calc(100% - 40px));
    margin: 0 auto;
    padding: 48px 0;
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 1fr;
    gap: 34px;
}

.footer-logo {
    color: #ffffff;
    font-size: 24px;
}

.footer-brand p,
.footer-col a {
    color: #9ca3af;
}

.footer-col h2 {
    margin: 0 0 14px;
    color: #ffffff;
    font-size: 18px;
}

.footer-col ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 8px;
}

.footer-col a:hover {
    color: #fb923c;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 18px 20px;
    text-align: center;
    color: #9ca3af;
}

@media (max-width: 1040px) {
    .desktop-nav,
    .header-search {
        display: none;
    }

    .mobile-menu-button {
        display: inline-flex;
    }

    .movie-grid-four,
    .ranking-card-grid,
    .category-grid,
    .category-overview-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

    .rank-panel {
        position: static;
    }

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

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

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

    .hero-carousel {
        height: 560px;
    }

    .hero-content {
        width: calc(100% - 32px);
    }

    .hero-control {
        display: none;
    }

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

    .home-section,
    .filter-section,
    .player-section,
    .detail-content {
        width: calc(100% - 28px);
    }

    .section-soft {
        padding-left: 14px;
        padding-right: 14px;
    }

    .movie-grid,
    .movie-grid-two,
    .movie-grid-three,
    .movie-grid-four,
    .ranking-card-grid,
    .category-grid,
    .category-overview-grid {
        grid-template-columns: 1fr;
    }

    .filter-bar {
        grid-template-columns: 1fr;
        padding: 12px;
    }

    .category-overview-card,
    .detail-layout,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .detail-poster {
        max-width: 230px;
    }

    .small-hero,
    .detail-hero {
        padding-left: 14px;
        padding-right: 14px;
    }

    .footer-inner {
        width: calc(100% - 28px);
    }
}
