:root {
    --brand: #f97316;
    --brand-dark: #dc2626;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --soft: #fff7ed;
    --panel: #ffffff;
    --dark: #0f172a;
    --radius: 18px;
    --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 34%, #f8fafc 100%);
    color: var(--ink);
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

a {
    color: inherit;
}

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

.header-inner {
    max-width: 1280px;
    margin: 0 auto;
    min-height: 74px;
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 0 24px;
}

.logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -0.03em;
    color: #111827;
}

.logo-mark {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 14px 25px rgba(249, 115, 22, 0.28);
}

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

.nav-link {
    padding: 10px 14px;
    border-radius: 999px;
    color: #374151;
    font-weight: 700;
    transition: all 0.22s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.22);
}

.nav-search {
    margin-left: auto;
    width: min(340px, 30vw);
    display: flex;
    align-items: center;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.06);
}

.nav-search input {
    flex: 1;
    min-width: 0;
    padding: 8px 12px;
    outline: none;
    color: #111827;
}

.nav-search button,
.primary-btn,
.secondary-btn,
.filter-panel button,
.player-play {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.nav-search button,
.primary-btn,
.filter-panel button {
    padding: 10px 18px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.22);
}

.secondary-btn {
    padding: 10px 18px;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.34);
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(10px);
}

.nav-search button:hover,
.primary-btn:hover,
.secondary-btn:hover,
.filter-panel button:hover,
.player-play:hover {
    transform: translateY(-2px);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
}

.hero-carousel {
    position: relative;
    min-height: 640px;
    overflow: hidden;
    background: #111827;
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
    transform: scale(1.02);
}

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

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 72% 35%, rgba(249, 115, 22, 0.38), transparent 32%),
        linear-gradient(90deg, rgba(15, 23, 42, 0.96) 0%, rgba(15, 23, 42, 0.72) 45%, rgba(15, 23, 42, 0.26) 100%),
        linear-gradient(0deg, rgba(15, 23, 42, 0.9), transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    color: #ffffff;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 48px;
    align-items: center;
}

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

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    color: #fed7aa;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
    font-weight: 800;
}

.hero-copy h1 {
    font-size: clamp(40px, 6vw, 72px);
    line-height: 1;
    margin-bottom: 22px;
    font-weight: 950;
    letter-spacing: -0.06em;
}

.hero-copy p {
    max-width: 700px;
    font-size: 18px;
    line-height: 1.9;
    color: rgba(255, 255, 255, 0.9);
}

.hero-actions,
.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
}

.hero-side {
    display: grid;
    gap: 16px;
}

.hero-mini-card {
    display: flex;
    gap: 12px;
    padding: 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(14px);
}

.hero-mini-card img {
    width: 88px;
    height: 120px;
    border-radius: 14px;
    object-fit: cover;
}

.hero-mini-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 18px;
}

.hero-mini-card span,
.hero-mini-card p {
    color: rgba(255, 255, 255, 0.78);
    font-size: 13px;
    line-height: 1.6;
}

.hero-controls {
    position: absolute;
    z-index: 3;
    right: clamp(20px, 6vw, 80px);
    bottom: 34px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-controls button,
.hero-dot {
    width: 42px;
    height: 42px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(12px);
}

.hero-dot {
    width: 11px;
    height: 11px;
    padding: 0;
}

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

main,
.page-main {
    max-width: 1280px;
    margin: 0 auto;
    padding: 54px 24px;
}

.section-block {
    margin-bottom: 72px;
}

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

.section-heading h2,
.page-title-row h1,
.detail-title h1 {
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 950;
    letter-spacing: -0.04em;
    color: #111827;
}

.section-heading p,
.page-title-row p,
.detail-title p {
    margin-top: 8px;
    color: var(--muted);
    line-height: 1.8;
}

.section-more {
    flex: 0 0 auto;
    padding: 10px 18px;
    border-radius: 999px;
    color: var(--brand-dark);
    background: #fff7ed;
    font-weight: 800;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(229, 231, 235, 0.9);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.movie-poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #111827;
}

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

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.78), transparent 55%);
}

.play-corner {
    position: absolute;
    left: 14px;
    bottom: 12px;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 10px 22px rgba(220, 38, 38, 0.34);
}

.year-badge,
.rank-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.62);
    font-size: 12px;
    font-weight: 800;
}

.rank-badge {
    left: 12px;
    right: auto;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
}

.movie-body {
    padding: 18px;
}

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

.movie-body h3 {
    margin: 8px 0;
    font-size: 20px;
    line-height: 1.35;
    font-weight: 900;
}

.movie-body h3 a:hover {
    color: var(--brand-dark);
}

.movie-body p {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.75;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.tag-row span,
.info-pill,
.breadcrumb a,
.breadcrumb span {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    background: #f3f4f6;
    color: #4b5563;
    font-size: 12px;
    font-weight: 700;
}

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

.category-tile {
    position: relative;
    min-height: 220px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: end;
    padding: 24px;
    border-radius: 24px;
    color: #ffffff;
    background: #111827;
    box-shadow: var(--shadow);
}

.category-tile img,
.category-glow {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-glow {
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.92) 0%, rgba(15, 23, 42, 0.28) 100%);
}

.category-tile strong,
.category-tile em {
    position: relative;
    z-index: 1;
}

.category-tile strong {
    font-size: 25px;
    font-weight: 950;
}

.category-tile em {
    margin-top: 8px;
    color: rgba(255, 255, 255, 0.78);
    font-style: normal;
    line-height: 1.7;
    font-size: 14px;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1fr 180px 180px auto;
    gap: 12px;
    margin: 0 0 28px;
    padding: 18px;
    border-radius: 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.07);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 44px;
    padding: 0 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    outline: none;
    color: #111827;
    background: #f9fafb;
}

.ranking-list {
    display: grid;
    gap: 16px;
}

.ranking-item {
    display: grid;
    grid-template-columns: 82px 120px minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    padding: 16px;
    border-radius: 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.07);
}

.ranking-num {
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    color: #ffffff;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    font-weight: 950;
    font-size: 20px;
}

.ranking-item img {
    width: 120px;
    height: 76px;
    border-radius: 16px;
    object-fit: cover;
}

.ranking-item h3 {
    font-size: 22px;
    font-weight: 900;
    margin-bottom: 8px;
}

.ranking-item p {
    color: var(--muted);
    line-height: 1.7;
}

.score-pill {
    min-width: 66px;
    text-align: center;
    padding: 10px 14px;
    border-radius: 999px;
    color: #b45309;
    background: #fffbeb;
    font-weight: 950;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 360px;
    gap: 34px;
    align-items: start;
}

.detail-title {
    margin-bottom: 24px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.player-card,
.content-card,
.side-card {
    border-radius: 26px;
    background: #ffffff;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.player-shell {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.player-shell video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #020617;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    cursor: pointer;
}

.player-cover::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(249, 115, 22, 0.15), rgba(2, 6, 23, 0.74));
}

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

.player-play {
    position: relative;
    z-index: 1;
    width: 84px;
    height: 84px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
    box-shadow: 0 18px 42px rgba(220, 38, 38, 0.36);
    font-size: 30px;
}

.content-card {
    padding: 28px;
    margin-top: 26px;
}

.content-card h2,
.side-card h2 {
    margin-bottom: 18px;
    font-size: 26px;
    font-weight: 950;
}

.content-card p {
    margin-bottom: 18px;
    color: #374151;
    line-height: 2;
    text-align: justify;
}

.side-card {
    padding: 22px;
    position: sticky;
    top: 96px;
}

.side-cover {
    overflow: hidden;
    border-radius: 20px;
    aspect-ratio: 16 / 10;
    margin-bottom: 18px;
    background: #111827;
}

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

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

.related-item {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
}

.related-item img {
    width: 96px;
    height: 64px;
    border-radius: 14px;
    object-fit: cover;
}

.related-item strong {
    display: block;
    font-weight: 900;
    margin-bottom: 6px;
}

.related-item span {
    color: var(--muted);
    font-size: 13px;
}

.site-footer {
    margin-top: 70px;
    color: #e5e7eb;
    background: linear-gradient(180deg, #111827, #020617);
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.4fr;
    gap: 34px;
    padding: 48px 24px;
}

.footer-logo {
    color: #ffffff;
    margin-bottom: 14px;
}

.site-footer p {
    color: #9ca3af;
    line-height: 1.9;
}

.footer-links,
.footer-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-content: start;
}

.footer-links a,
.footer-cats a {
    padding: 8px 12px;
    border-radius: 999px;
    color: #d1d5db;
    background: rgba(255, 255, 255, 0.08);
}

.hide-card {
    display: none;
}

@media (max-width: 1080px) {
    .hero-content,
    .detail-layout,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .hero-side {
        grid-template-columns: repeat(3, 1fr);
    }

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

    .side-card {
        position: static;
    }
}

@media (max-width: 820px) {
    .header-inner {
        min-height: auto;
        padding: 14px 18px;
        flex-wrap: wrap;
    }

    .menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        margin-left: auto;
    }

    .main-nav {
        order: 3;
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        padding-top: 12px;
    }

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

    .nav-search {
        order: 2;
        width: 100%;
        margin-left: 0;
        flex-basis: 100%;
    }

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

    .hero-content {
        width: min(100% - 32px, 1180px);
        padding-top: 20px;
    }

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

    main,
    .page-main {
        padding: 38px 16px;
    }

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

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

    .ranking-item {
        grid-template-columns: 58px 96px minmax(0, 1fr);
    }

    .ranking-item .score-pill {
        grid-column: 2 / -1;
        justify-self: start;
    }
}

@media (max-width: 560px) {
    .logo-text {
        font-size: 22px;
    }

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

    .hero-copy h1 {
        font-size: 42px;
    }

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

    .section-heading,
    .page-title-row {
        display: block;
    }

    .section-more {
        margin-top: 14px;
    }

    .ranking-item {
        grid-template-columns: 48px minmax(0, 1fr);
    }

    .ranking-item img {
        display: none;
    }
}
