:root {
    --bg: #f9fafb;
    --card: #ffffff;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --orange: #ea580c;
    --orange-dark: #c2410c;
    --red: #dc2626;
    --yellow: #facc15;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.13);
    --radius: 18px;
}

body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--ink);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

.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 {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    color: #111827;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    border-radius: 14px;
    box-shadow: 0 12px 25px rgba(234, 88, 12, 0.32);
}

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

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

.nav-links a {
    padding: 10px 14px;
    border-radius: 999px;
    color: #4b5563;
    font-weight: 600;
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--orange);
    background: #fff7ed;
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #fff7ed;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.menu-toggle span {
    width: 20px;
    height: 2px;
    background: var(--orange);
    border-radius: 99px;
}

.hero-wrap {
    position: relative;
    min-height: 660px;
    overflow: hidden;
    background: #0f172a;
}

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

.hero-slide {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 56px;
    align-items: center;
    padding: 92px max(24px, calc((100vw - 1280px) / 2)) 128px;
    color: #ffffff;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.6s ease, transform 0.8s ease;
}

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

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    color: #ffedd5;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.hero-content h1,
.page-hero h1,
.detail-info h1 {
    font-size: clamp(38px, 6vw, 68px);
    line-height: 1.04;
    font-weight: 900;
    margin-bottom: 22px;
    letter-spacing: -0.04em;
}

.hero-content p,
.page-hero p,
.detail-one-line {
    max-width: 760px;
    color: #f3f4f6;
    font-size: 18px;
    line-height: 1.85;
}

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

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

.hero-tags span,
.detail-tags span,
.movie-tags span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.hero-tags span,
.detail-tags span {
    padding: 7px 12px;
    color: #fff7ed;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.movie-tags span {
    padding: 5px 9px;
    color: var(--orange-dark);
    background: #ffedd5;
}

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

.btn-primary,
.btn-ghost,
.section-link,
.category-card-body span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 13px;
    font-weight: 800;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 18px 32px rgba(234, 88, 12, 0.34);
}

.btn-primary:hover,
.btn-ghost:hover,
.section-link:hover,
.category-card-body span:hover {
    transform: translateY(-2px);
}

.btn-ghost {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-poster {
    position: relative;
    align-self: center;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
    aspect-ratio: 2 / 3;
    background: rgba(255, 255, 255, 0.08);
}

.hero-poster img,
.movie-poster img,
.detail-poster img,
.rank-cover img,
.category-covers img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-poster span {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 72px;
    height: 72px;
    transform: translate(-50%, -50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: rgba(234, 88, 12, 0.88);
    border-radius: 999px;
    font-size: 28px;
    box-shadow: 0 18px 35px rgba(0, 0, 0, 0.28);
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 28px;
    z-index: 5;
    width: min(1280px, calc(100% - 48px));
    transform: translateX(-50%);
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
}

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

.hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.45);
    transition: width 0.25s ease, background 0.25s ease;
}

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

.hero-thumbs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    width: min(620px, 58vw);
}

.hero-thumb {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 10px;
    align-items: center;
    min-width: 0;
    padding: 8px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.13);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 16px;
    backdrop-filter: blur(14px);
    opacity: 0.74;
}

.hero-thumb.is-active,
.hero-thumb:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.22);
}

.hero-thumb img {
    width: 42px;
    height: 56px;
    object-fit: cover;
    border-radius: 10px;
}

.hero-thumb span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 700;
    text-align: left;
}

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

.stat-card {
    padding: 28px;
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-align: center;
}

.stat-card strong {
    display: block;
    margin-bottom: 8px;
    color: var(--orange);
    font-size: 32px;
    font-weight: 900;
}

.stat-card span {
    color: var(--muted);
    font-weight: 600;
}

.section-block {
    padding-top: 72px;
    padding-bottom: 72px;
}

.white-section {
    background: #ffffff;
}

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

.section-heading h2 {
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.16;
    font-weight: 900;
    color: var(--ink);
}

.section-heading p {
    margin-top: 8px;
    color: var(--muted);
    line-height: 1.7;
}

.section-link,
.category-card-body span {
    color: var(--orange);
    background: #fff7ed;
}

.category-grid,
.category-large-grid {
    display: grid;
    gap: 20px;
}

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

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

.category-tile,
.category-card-large a {
    display: block;
    height: 100%;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.category-tile {
    padding: 26px;
}

.category-tile:hover,
.category-card-large a:hover,
.movie-card:hover,
.rank-row:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 50px rgba(15, 23, 42, 0.13);
    border-color: #fed7aa;
}

.category-tile span,
.category-card-body h2 {
    display: block;
    color: var(--ink);
    font-size: 20px;
    font-weight: 900;
    margin-bottom: 10px;
}

.category-tile em,
.category-card-body p {
    color: var(--muted);
    font-style: normal;
    line-height: 1.75;
}

.category-covers {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    height: 168px;
    background: linear-gradient(135deg, #fff7ed, #fee2e2);
}

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

.category-card-body span {
    margin-top: 18px;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.07);
}

.search-box {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 52px;
    padding: 0 16px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
}

.search-box span {
    color: var(--orange);
    font-size: 24px;
    font-weight: 900;
}

.search-box input {
    width: 100%;
    outline: none;
    color: var(--ink);
    background: transparent;
}

.filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.filter-chip {
    min-height: 38px;
    padding: 0 14px;
    color: #4b5563;
    background: #f3f4f6;
    border-radius: 999px;
    font-weight: 700;
}

.filter-chip:hover,
.filter-chip.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
}

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

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

.movie-card {
    min-width: 0;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-poster {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #fff7ed, #fee2e2);
}

.poster-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(15, 23, 42, 0.5));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.play-badge {
    position: absolute;
    right: 12px;
    bottom: 12px;
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: rgba(234, 88, 12, 0.92);
    border-radius: 999px;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.28);
    transform: translateY(8px);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .poster-shine,
.movie-card:hover .play-badge {
    opacity: 1;
    transform: translateY(0);
}

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #9ca3af;
    font-size: 12px;
    font-weight: 700;
}

.movie-card h3 {
    margin-top: 10px;
    color: var(--ink);
    font-size: 18px;
    line-height: 1.35;
    font-weight: 900;
}

.movie-card h3 a:hover,
.rank-row h3 a:hover,
.breadcrumb a:hover {
    color: var(--orange);
}

.movie-card p {
    display: -webkit-box;
    min-height: 46px;
    margin-top: 8px;
    overflow: hidden;
    color: var(--muted);
    line-height: 1.55;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-tags {
    margin-top: 14px;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 86px 58px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    padding: 14px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.rank-cover {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: #fff7ed;
    border-radius: 14px;
}

.rank-number {
    font-size: 26px;
    font-weight: 900;
    color: #d1d5db;
}

.rank-row.is-top .rank-number {
    color: var(--orange);
}

.rank-content h3 {
    margin-bottom: 6px;
    color: var(--ink);
    font-size: 20px;
    font-weight: 900;
}

.rank-content p {
    margin-bottom: 8px;
    color: var(--muted);
    line-height: 1.65;
}

.page-hero {
    padding: 86px 0 78px;
    color: #ffffff;
}

.gradient-hero,
.category-hero {
    background: linear-gradient(135deg, #ea580c, #dc2626 62%, #7f1d1d);
}

.page-hero .breadcrumb {
    margin-bottom: 18px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
    font-weight: 700;
}

.breadcrumb strong {
    color: #ffffff;
}

.detail-hero {
    position: relative;
    color: #ffffff;
    overflow: hidden;
}

.detail-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: saturate(1.05);
}

.detail-hero-inner {
    position: relative;
    padding-top: 58px;
    padding-bottom: 68px;
}

.detail-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 48px;
    align-items: end;
    margin-top: 24px;
}

.detail-poster {
    aspect-ratio: 2 / 3;
    border-radius: 28px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.36);
}

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

.detail-one-line {
    margin-bottom: 24px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

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

.detail-info .btn-primary {
    margin-top: 28px;
}

.player-section {
    margin-top: 42px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #020617;
    box-shadow: 0 26px 60px rgba(15, 23, 42, 0.22);
    aspect-ratio: 16 / 9;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.22), rgba(2, 6, 23, 0.72));
}

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

.player-play {
    width: 84px;
    height: 84px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding-left: 5px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    border-radius: 999px;
    font-size: 34px;
    box-shadow: 0 20px 46px rgba(234, 88, 12, 0.34);
}

.player-cover strong {
    font-size: 24px;
    font-weight: 900;
}

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

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

.content-card h2 {
    margin-bottom: 16px;
    font-size: 24px;
    font-weight: 900;
    color: var(--ink);
}

.content-card p {
    color: #4b5563;
    line-height: 1.95;
    margin-bottom: 12px;
}

.empty-state {
    display: none;
    padding: 26px;
    margin-top: 20px;
    color: var(--muted);
    text-align: center;
    background: #ffffff;
    border: 1px dashed #fdba74;
    border-radius: var(--radius);
}

.empty-state.is-visible {
    display: block;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 32px;
    padding-top: 56px;
    padding-bottom: 44px;
}

.footer-brand {
    margin-bottom: 14px;
    color: #ffffff;
    font-size: 22px;
}

.site-footer p {
    max-width: 460px;
    color: #9ca3af;
    line-height: 1.8;
}

.footer-links {
    display: grid;
    gap: 10px;
}

.footer-links h2 {
    margin-bottom: 4px;
    color: #ffffff;
    font-size: 18px;
    font-weight: 900;
}

.footer-links a:hover {
    color: #fed7aa;
}

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

@media (max-width: 1100px) {
    .hero-slide {
        grid-template-columns: minmax(0, 1fr) 280px;
        gap: 32px;
    }

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

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

@media (max-width: 820px) {
    .menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        left: 16px;
        right: 16px;
        top: 78px;
        display: none;
        padding: 12px;
        background: rgba(255, 255, 255, 0.98);
        border: 1px solid var(--line);
        border-radius: 18px;
        box-shadow: var(--shadow);
        flex-direction: column;
        align-items: stretch;
    }

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

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

    .hero-slide {
        grid-template-columns: 1fr;
        padding-top: 90px;
        padding-bottom: 150px;
    }

    .hero-poster {
        width: min(280px, 72vw);
        justify-self: center;
    }

    .hero-thumbs {
        display: none;
    }

    .hero-controls {
        justify-content: center;
    }

    .stat-grid,
    .category-grid,
    .movie-grid,
    .compact-grid,
    .category-large-grid,
    .detail-content,
    .footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

    .detail-poster {
        width: min(280px, 78vw);
    }
}

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

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

    .hero-content p,
    .page-hero p,
    .detail-one-line {
        font-size: 16px;
    }

    .hero-actions,
    .detail-meta {
        flex-direction: column;
        align-items: stretch;
    }

    .stat-grid,
    .category-grid,
    .movie-grid,
    .compact-grid,
    .category-large-grid,
    .detail-content,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .rank-row {
        grid-template-columns: 72px 44px minmax(0, 1fr);
        gap: 12px;
    }

    .rank-content p {
        display: none;
    }

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