* {
    box-sizing: border-box;
}

:root {
    --slate-950: #020617;
    --slate-900: #0f172a;
    --slate-800: #1e293b;
    --slate-700: #334155;
    --slate-600: #475569;
    --slate-500: #64748b;
    --slate-200: #e2e8f0;
    --slate-100: #f1f5f9;
    --orange-600: #ea580c;
    --orange-500: #f97316;
    --amber-400: #fbbf24;
    --red-500: #ef4444;
    --pink-600: #db2777;
    --white: #ffffff;
    --shadow-soft: 0 20px 45px rgba(15, 23, 42, 0.12);
    --shadow-card: 0 10px 28px rgba(15, 23, 42, 0.10);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--slate-800);
    background: linear-gradient(135deg, #f8fafc 0%, #fff7ed 48%, #fffbeb 100%);
}

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

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

button,
input {
    font: inherit;
}

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

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

.header-inner {
    min-height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

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

.brand {
    font-size: 21px;
}

.brand-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--orange-500), var(--red-500));
    box-shadow: 0 10px 26px rgba(249, 115, 22, 0.36);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    color: #cbd5e1;
    font-size: 15px;
}

.main-nav a {
    transition: color 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover {
    color: var(--white);
    transform: translateY(-1px);
}

.mobile-toggle {
    width: 42px;
    height: 42px;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 0;
    border-radius: 12px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
    cursor: pointer;
}

.mobile-toggle span {
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: var(--white);
}

.hero-carousel {
    position: relative;
    min-height: 660px;
    overflow: hidden;
    color: var(--white);
    background: radial-gradient(circle at 20% 20%, rgba(249, 115, 22, 0.48), transparent 32%), var(--slate-950);
}

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

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

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.04);
    opacity: 0.48;
}

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

.hero-content {
    position: relative;
    z-index: 2;
    min-height: 660px;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) 360px;
    gap: 58px;
    align-items: center;
    padding: 78px 0 82px;
}

.hero-copy h1 {
    margin: 16px 0 10px;
    max-width: 820px;
    font-size: clamp(38px, 7vw, 74px);
    line-height: 1.02;
    letter-spacing: -0.04em;
}

.hero-copy h2 {
    margin: 0 0 16px;
    font-size: clamp(25px, 4vw, 40px);
    color: #fed7aa;
}

.hero-copy p {
    max-width: 720px;
    margin: 0 0 28px;
    color: #e2e8f0;
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.8;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    color: #fed7aa;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    font-size: 14px;
    font-weight: 700;
}

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

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

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

.btn-primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--orange-500), var(--red-500), var(--pink-600));
    box-shadow: 0 18px 35px rgba(239, 68, 68, 0.3);
}

.btn-soft {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
}

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

.hero-tags span,
.detail-badges span,
.movie-tags span,
.latest-meta span,
.rank-meta span {
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 12px;
    line-height: 1;
}

.hero-tags span {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.1);
}

.hero-poster {
    position: relative;
    min-height: 500px;
    border-radius: 28px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.35), rgba(219, 39, 119, 0.18));
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.42);
    transform: rotate(2deg);
    transition: transform 0.25s ease;
}

.hero-poster:hover {
    transform: rotate(0deg) translateY(-4px);
}

.hero-poster img {
    width: 100%;
    height: 100%;
    min-height: 500px;
    object-fit: cover;
}

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

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

.hero-dot.active {
    width: 34px;
    background: var(--white);
}

.quick-search {
    position: relative;
    z-index: 4;
    margin-top: -38px;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(260px, 480px);
    gap: 24px;
    align-items: center;
    padding: 24px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(18px);
}

.search-panel h2 {
    margin: 0 0 6px;
    font-size: 24px;
}

.search-panel p {
    margin: 0;
    color: var(--slate-600);
}

.search-box input {
    width: 100%;
    height: 52px;
    padding: 0 18px;
    border: 1px solid var(--slate-200);
    border-radius: 16px;
    outline: none;
    color: var(--slate-800);
    background: var(--white);
    box-shadow: inset 0 1px 0 rgba(15, 23, 42, 0.03);
    transition: border 0.2s ease, box-shadow 0.2s ease;
}

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

.content-section {
    padding: 72px 0;
}

.white-section {
    background: rgba(255, 255, 255, 0.78);
}

.gradient-section {
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.10), rgba(255, 255, 255, 0.72), rgba(251, 191, 36, 0.12));
}

.section-heading {
    margin-bottom: 32px;
    text-align: center;
}

.section-heading h2 {
    margin: 0 0 8px;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
    color: transparent;
    background: linear-gradient(90deg, var(--orange-600), var(--red-500), var(--pink-600));
    background-clip: text;
    -webkit-background-clip: text;
}

.section-heading p {
    margin: 0;
    color: var(--slate-600);
    font-size: 17px;
}

.section-topline {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
}

.section-topline .section-heading {
    text-align: left;
}

.section-topline > a {
    margin-top: 12px;
    color: var(--orange-600);
    font-weight: 800;
}

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

.movie-card {
    min-width: 0;
}

.movie-card-link {
    display: block;
    height: 100%;
    overflow: hidden;
    border-radius: 18px;
    background: var(--white);
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card-link:hover {
    transform: translateY(-8px);
    box-shadow: 0 22px 50px rgba(15, 23, 42, 0.18);
}

.movie-poster {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fed7aa, #fef3c7 48%, #e2e8f0);
}

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

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

.movie-poster-shade {
    position: absolute;
    inset: 0;
    opacity: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.84), rgba(2, 6, 23, 0.05));
    transition: opacity 0.25s ease;
}

.movie-card-link:hover .movie-poster-shade {
    opacity: 1;
}

.movie-year {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 8px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(15, 23, 42, 0.72);
    font-size: 12px;
    font-weight: 800;
}

.movie-hover-text {
    position: absolute;
    left: 12px;
    right: 12px;
    bottom: 12px;
    margin: 0;
    color: var(--white);
    font-size: 13px;
    line-height: 1.55;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-card-link:hover .movie-hover-text {
    opacity: 1;
    transform: translateY(0);
}

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

.movie-card-body h3 {
    margin: 0 0 9px;
    min-height: 48px;
    color: var(--slate-800);
    font-size: 17px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.2s ease;
}

.movie-card-link:hover h3 {
    color: var(--orange-600);
}

.movie-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: var(--slate-600);
    font-size: 13px;
}

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

.movie-tags span {
    color: var(--orange-600);
    background: #ffedd5;
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 10px;
    max-width: 520px;
}

.filter-pill {
    border: 0;
    border-radius: 999px;
    padding: 10px 14px;
    color: var(--slate-700);
    background: var(--slate-100);
    cursor: pointer;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.filter-pill:hover,
.filter-pill.active {
    color: var(--white);
    background: linear-gradient(135deg, var(--orange-500), var(--red-500));
    transform: translateY(-1px);
}

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

.latest-item,
.rank-link {
    display: grid;
    grid-template-columns: 92px 120px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    padding: 16px;
    border-radius: 18px;
    background: var(--white);
    box-shadow: var(--shadow-card);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.latest-item:hover,
.rank-link:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-soft);
}

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

.latest-rank,
.rank-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 46px;
    border-radius: 14px;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--orange-500), var(--red-500));
}

.latest-item h3,
.rank-content h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

.latest-item p,
.rank-content p {
    margin: 0 0 12px;
    color: var(--slate-600);
    line-height: 1.65;
}

.latest-meta span,
.rank-meta span {
    color: var(--slate-700);
    background: var(--slate-100);
}

.page-hero {
    color: var(--white);
    background:
        radial-gradient(circle at 20% 10%, rgba(249, 115, 22, 0.38), transparent 34%),
        linear-gradient(135deg, var(--slate-950), var(--slate-800));
}

.compact-hero {
    padding: 92px 0 74px;
}

.compact-hero h1 {
    margin: 18px 0 14px;
    max-width: 860px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.05;
}

.compact-hero p {
    max-width: 780px;
    margin: 0;
    color: #e2e8f0;
    font-size: 20px;
    line-height: 1.75;
}

.feature-strip {
    display: grid;
    grid-template-columns: repeat(8, minmax(0, 1fr));
    gap: 12px;
    margin-top: 34px;
}

.feature-pill {
    overflow: hidden;
    border-radius: 16px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.18);
}

.feature-pill img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    background: #fed7aa;
}

.feature-pill span {
    display: block;
    padding: 10px;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.detail-page {
    padding: 34px 0 80px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 28px;
    align-items: start;
}

.back-link {
    display: inline-flex;
    margin-bottom: 18px;
    color: var(--slate-600);
    font-weight: 700;
}

.back-link:hover {
    color: var(--orange-600);
}

.player-card,
.detail-block,
.side-card {
    overflow: hidden;
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--shadow-card);
}

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

.video-player {
    width: 100%;
    height: 100%;
    display: block;
    background: #000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    color: var(--white);
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.68), rgba(2, 6, 23, 0.18));
    cursor: pointer;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.player-shell.is-playing .player-overlay {
    opacity: 0;
    pointer-events: none;
}

.play-icon {
    width: 78px;
    height: 78px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--white);
    background: linear-gradient(135deg, var(--orange-500), var(--red-500));
    box-shadow: 0 20px 44px rgba(239, 68, 68, 0.42);
    font-size: 30px;
}

.player-overlay strong {
    font-size: 19px;
}

.detail-content {
    padding: 28px;
}

.detail-content h1 {
    margin: 0 0 16px;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.12;
}

.detail-badges {
    margin-bottom: 16px;
}

.detail-badges span {
    color: #9a3412;
    background: #ffedd5;
}

.one-line {
    margin: 0;
    color: var(--slate-700);
    font-size: 18px;
    line-height: 1.8;
}

.detail-tags {
    margin-top: 18px;
}

.detail-block {
    margin-top: 24px;
    padding: 28px;
}

.detail-block h2,
.side-card h2 {
    margin: 0 0 14px;
    color: var(--slate-800);
    font-size: 24px;
}

.detail-block p,
.side-card p {
    margin: 0;
    color: var(--slate-700);
    line-height: 1.9;
}

.detail-sidebar {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 20px;
}

.side-card {
    padding: 20px;
}

.poster-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 18px;
    margin-bottom: 16px;
    background: #fed7aa;
}

.info-card dl {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 10px 12px;
    margin: 0;
}

.info-card dt {
    color: var(--slate-500);
}

.info-card dd {
    margin: 0;
    color: var(--slate-800);
    font-weight: 700;
}

.mini-related-item {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    padding: 10px 0;
    border-top: 1px solid var(--slate-100);
}

.mini-related-item img {
    width: 54px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 9px;
    background: #fed7aa;
}

.mini-related-item span {
    color: var(--slate-800);
    font-weight: 700;
    line-height: 1.45;
}

.movie-card-compact .movie-card-body h3 {
    min-height: 42px;
    font-size: 15px;
}

.site-footer {
    color: var(--white);
    background: linear-gradient(90deg, var(--slate-900), var(--slate-950), var(--slate-900));
}

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

.footer-grid h3 {
    margin: 0 0 14px;
    color: #fdba74;
}

.footer-grid p,
.footer-grid a {
    color: #cbd5e1;
    line-height: 1.8;
}

.footer-grid a {
    display: block;
    margin: 6px 0;
    transition: color 0.2s ease;
}

.footer-grid a:hover {
    color: #fdba74;
}

.footer-brand {
    margin-bottom: 16px;
    font-size: 18px;
}

.footer-bottom {
    padding: 20px;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    color: #94a3b8;
    text-align: center;
}

.back-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 90;
    width: 48px;
    height: 48px;
    display: none;
    border: 0;
    border-radius: 50%;
    color: var(--white);
    background: linear-gradient(135deg, var(--orange-500), var(--red-500));
    box-shadow: 0 15px 35px rgba(239, 68, 68, 0.32);
    cursor: pointer;
}

.back-top.show {
    display: block;
}

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

@media (max-width: 1100px) {
    .movie-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .hero-content {
        grid-template-columns: minmax(0, 1fr) 280px;
    }

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

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

    .detail-sidebar {
        position: static;
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

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

    .main-nav {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 66px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 10px;
        border-radius: 16px;
        background: rgba(15, 23, 42, 0.96);
        box-shadow: var(--shadow-soft);
    }

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

    .main-nav a {
        padding: 13px 14px;
        border-radius: 12px;
    }

    .main-nav a:hover {
        background: rgba(255, 255, 255, 0.08);
        transform: none;
    }

    .hero-carousel,
    .hero-content {
        min-height: 620px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 30px;
        padding-top: 58px;
    }

    .hero-poster {
        display: none;
    }

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

    .section-topline,
    .library-heading {
        display: block;
    }

    .filter-pills {
        justify-content: flex-start;
        margin-bottom: 26px;
    }

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

    .latest-item,
    .rank-link {
        grid-template-columns: 1fr;
    }

    .latest-rank,
    .rank-number {
        width: fit-content;
        padding: 0 16px;
    }

    .feature-strip,
    .footer-grid,
    .detail-sidebar {
        grid-template-columns: 1fr 1fr;
    }
}

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

    .brand {
        font-size: 18px;
    }

    .brand-icon {
        width: 30px;
        height: 30px;
    }

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

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

    .hero-copy h2 {
        font-size: 25px;
    }

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

    .content-section {
        padding: 52px 0;
    }

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

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

    .movie-card-body h3 {
        font-size: 15px;
    }

    .movie-meta,
    .movie-tags span {
        font-size: 11px;
    }

    .feature-strip,
    .footer-grid,
    .detail-sidebar {
        grid-template-columns: 1fr;
    }

    .detail-content,
    .detail-block,
    .side-card {
        padding: 20px;
    }

    .back-top {
        right: 16px;
        bottom: 16px;
    }
}
