:root {
    --slate-950: #020617;
    --slate-900: #0f172a;
    --slate-800: #1e293b;
    --slate-700: #334155;
    --slate-600: #475569;
    --slate-200: #e2e8f0;
    --slate-100: #f1f5f9;
    --orange-600: #ea580c;
    --orange-500: #f97316;
    --orange-400: #fb923c;
    --amber-300: #fcd34d;
    --white: #ffffff;
    --shadow-lg: 0 18px 38px rgba(15, 23, 42, 0.18);
    --shadow-xl: 0 24px 60px rgba(2, 6, 23, 0.35);
    --radius-xl: 24px;
    --radius-lg: 18px;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    color: #1f2937;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 42%, #ffffff 100%);
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.6;
}

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: var(--white);
    background: linear-gradient(90deg, var(--slate-900), var(--slate-700), var(--slate-900));
    box-shadow: 0 12px 30px rgba(2, 6, 23, 0.26);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--orange-400), var(--orange-600));
    box-shadow: 0 12px 25px rgba(249, 115, 22, 0.35);
}

.brand-text strong {
    display: block;
    font-size: 20px;
    letter-spacing: 0.06em;
}

.brand-text small {
    display: block;
    color: #cbd5e1;
    font-size: 12px;
}

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

.nav-link {
    padding: 10px 18px;
    border-radius: 12px;
    color: #e2e8f0;
    font-weight: 600;
    transition: all 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff;
    background: var(--orange-500);
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.28);
}

.mobile-toggle {
    display: none;
    color: #ffffff;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    font-size: 24px;
    padding: 8px 12px;
}

.hero {
    position: relative;
    min-height: 620px;
    color: #ffffff;
    overflow: hidden;
    background: var(--slate-950);
}

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

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

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.72) 42%, rgba(15, 23, 42, 0.25) 100%), linear-gradient(0deg, rgba(2, 6, 23, 0.86), rgba(2, 6, 23, 0));
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(760px, calc(100% - 32px));
    padding-top: 145px;
    margin-left: max(16px, calc((100vw - 1180px) / 2));
}

.eyebrow {
    display: inline-flex;
    color: var(--amber-300);
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.eyebrow.dark {
    color: var(--orange-600);
}

.hero-content h1,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    font-size: clamp(38px, 7vw, 72px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero-content p {
    max-width: 690px;
    margin: 22px 0 22px;
    color: #e5e7eb;
    font-size: 18px;
}

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

.primary-btn,
.secondary-btn,
.filter-reset,
.text-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 14px;
    padding: 0 22px;
    font-weight: 800;
    transition: all 0.25s ease;
}

.primary-btn {
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
    box-shadow: 0 15px 30px rgba(249, 115, 22, 0.3);
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(249, 115, 22, 0.42);
}

.secondary-btn {
    color: #ffffff;
    margin-left: 12px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.26);
    backdrop-filter: blur(8px);
}

.hero-control {
    position: absolute;
    z-index: 3;
    left: 50%;
    bottom: 34px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hero-arrow {
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    font-size: 32px;
    line-height: 1;
}

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

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

.hero-dot.active {
    width: 32px;
    background: var(--orange-500);
}

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

.section-heading {
    margin-bottom: 28px;
}

.split-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
}

.section-heading h2 {
    margin: 0;
    color: var(--slate-900);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
}

.light-heading h2 {
    color: #ffffff;
}

.text-link {
    color: var(--orange-600);
    background: #fff7ed;
}

.text-link.light {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 180px 180px 180px auto;
    gap: 12px;
    margin-bottom: 28px;
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--shadow-lg);
}

.search-box {
    position: relative;
}

.search-box span {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 20px;
}

.search-box input,
.filter-select {
    width: 100%;
    min-height: 48px;
    border: 1px solid #cbd5e1;
    border-radius: 14px;
    color: #334155;
    background: #ffffff;
    font-size: 15px;
    outline: none;
    padding: 0 14px;
}

.search-box input {
    padding-left: 44px;
}

.search-box input:focus,
.filter-select:focus {
    border-color: var(--orange-500);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.18);
}

.filter-reset {
    border: 0;
    color: #ffffff;
    background: var(--slate-800);
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.11);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--slate-800);
}

.poster-link img,
.rank-cover img,
.category-card img,
.category-overview-card img,
.detail-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.66), rgba(2, 6, 23, 0));
    opacity: 0.88;
}

.play-chip,
.rank-badge {
    position: absolute;
    z-index: 2;
    color: #ffffff;
    border-radius: 999px;
    font-weight: 800;
}

.play-chip {
    right: 12px;
    bottom: 12px;
    padding: 6px 12px;
    background: var(--orange-500);
}

.rank-badge {
    left: 12px;
    top: 12px;
    min-width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.82);
}

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

.movie-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
    margin-bottom: 10px;
}

.movie-meta-row span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #f1f5f9;
}

.movie-card h3 {
    margin: 0 0 8px;
    color: var(--slate-900);
    font-size: 19px;
    line-height: 1.3;
}

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

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

.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    color: #c2410c;
    background: #ffedd5;
    font-size: 12px;
    font-weight: 800;
}

.hero-tags span,
.detail-tags span {
    color: #fed7aa;
    background: rgba(249, 115, 22, 0.18);
    border: 1px solid rgba(251, 146, 60, 0.28);
}

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

.category-card {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 20px;
    color: #ffffff;
    box-shadow: var(--shadow-lg);
}

.category-card img,
.category-overlay {
    position: absolute;
    inset: 0;
}

.category-overlay {
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.86), rgba(2, 6, 23, 0.14));
}

.category-card strong,
.category-card em {
    position: relative;
    z-index: 2;
}

.category-card strong {
    font-size: 22px;
    margin-bottom: 8px;
}

.category-card em {
    color: #e2e8f0;
    font-style: normal;
    font-size: 14px;
}

.ranking-band {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

.rank-grid .movie-card {
    background: #ffffff;
}

.page-main {
    min-height: 68vh;
}

.page-hero {
    color: #ffffff;
    background: radial-gradient(circle at top left, rgba(249, 115, 22, 0.34), transparent 34%), linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

.compact-hero {
    padding: 78px 0;
}

.page-hero p {
    max-width: 680px;
    margin: 18px 0 0;
    color: #dbeafe;
    font-size: 18px;
}

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

.category-overview-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: #ffffff;
    box-shadow: var(--shadow-lg);
}

.category-overview-card a {
    display: grid;
    grid-template-columns: 180px 1fr;
    min-height: 160px;
}

.category-overview-card div {
    padding: 22px;
}

.category-overview-card h2 {
    margin: 0 0 10px;
    color: var(--slate-900);
}

.category-overview-card p {
    margin: 0 0 16px;
    color: #64748b;
}

.category-overview-card span {
    color: var(--orange-600);
    font-weight: 800;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 132px 70px 1fr 130px;
    align-items: center;
    gap: 20px;
    padding: 16px;
}

.rank-cover {
    height: 86px;
    border-radius: 14px;
    overflow: hidden;
    background: var(--slate-800);
}

.rank-number {
    color: var(--orange-600);
    font-size: 34px;
    font-weight: 900;
    text-align: center;
}

.rank-info h3 {
    margin: 0 0 8px;
    color: var(--slate-900);
}

.rank-info p {
    margin: 0 0 8px;
    color: #64748b;
}

.rank-heat {
    color: #ffffff;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
    padding: 8px 12px;
    text-align: center;
    font-weight: 800;
}

.detail-hero {
    color: #ffffff;
    padding: 72px 0;
    background: radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.35), transparent 28%), linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

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

.detail-poster {
    aspect-ratio: 3 / 4;
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    background: var(--slate-800);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    color: #cbd5e1;
    margin-bottom: 18px;
}

.breadcrumb a {
    color: #fed7aa;
}

.breadcrumb em {
    font-style: normal;
}

.lead-text {
    max-width: 800px;
    color: #e2e8f0;
    font-size: 19px;
    margin: 18px 0;
}

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

.detail-meta span {
    padding: 8px 12px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.player-section {
    padding: 56px 0 26px;
}

.player-wrap {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: #000000;
    box-shadow: var(--shadow-xl);
}

.player-wrap video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: #ffffff;
    border: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.72), rgba(2, 6, 23, 0.18));
    cursor: pointer;
    transition: opacity 0.25s ease;
}

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

.player-cover span {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--orange-500);
    box-shadow: 0 18px 40px rgba(249, 115, 22, 0.36);
    font-size: 32px;
}

.player-cover strong {
    font-size: clamp(20px, 4vw, 34px);
}

.detail-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding: 34px 0 22px;
}

.content-panel {
    border-radius: var(--radius-lg);
    background: #ffffff;
    padding: 30px;
    box-shadow: var(--shadow-lg);
}

.content-panel h2 {
    margin: 0 0 14px;
    color: var(--slate-900);
}

.content-panel p {
    margin: 0;
    color: #475569;
    font-size: 17px;
}

.site-footer {
    color: #cbd5e1;
    background: linear-gradient(135deg, var(--slate-950), var(--slate-800));
    margin-top: 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 32px;
    padding: 48px 0;
}

.site-footer h2,
.site-footer h3 {
    color: #ffffff;
    margin: 0 0 14px;
}

.site-footer p {
    margin: 0;
    max-width: 520px;
}

.site-footer a {
    display: block;
    margin: 8px 0;
    color: #cbd5e1;
}

.site-footer a:hover {
    color: var(--orange-400);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 20px 16px;
    color: #94a3b8;
    text-align: center;
}

.is-hidden-card {
    display: none !important;
}

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

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

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

@media (max-width: 820px) {
    .site-nav {
        min-height: auto;
        padding: 14px 0;
        flex-wrap: wrap;
    }

    .mobile-toggle {
        display: inline-flex;
    }

    .nav-links {
        width: 100%;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding-top: 14px;
    }

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

    .hero {
        min-height: 560px;
    }

    .hero-content {
        padding-top: 105px;
    }

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

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

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

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

    .rank-row {
        grid-template-columns: 96px 54px 1fr;
    }

    .rank-heat {
        grid-column: 2 / 4;
        justify-self: start;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}

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

    .brand-text small {
        display: none;
    }

    .hero {
        min-height: 520px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .secondary-btn {
        margin-left: 0;
        margin-top: 10px;
    }

    .hero-actions {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

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

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

    .category-overview-card a {
        grid-template-columns: 1fr;
    }

    .category-overview-card img {
        height: 190px;
    }

    .rank-row {
        grid-template-columns: 88px 1fr;
    }

    .rank-number {
        position: absolute;
        left: 18px;
        top: 18px;
        color: #ffffff;
        background: rgba(15, 23, 42, 0.72);
        border-radius: 999px;
        width: 42px;
        height: 42px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-size: 22px;
    }

    .rank-info,
    .rank-heat {
        grid-column: 2;
    }
}
