:root {
    --bg: #fff7fb;
    --surface: #ffffff;
    --surface-soft: #fff1f8;
    --text: #171827;
    --muted: #6b7280;
    --line: rgba(219, 39, 119, 0.14);
    --pink: #ec4899;
    --purple: #7c3aed;
    --blue: #2563eb;
    --orange: #f97316;
    --shadow: 0 22px 55px rgba(88, 28, 135, 0.16);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background: linear-gradient(180deg, #fff7fb 0%, #f8fbff 45%, #ffffff 100%);
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 80;
    background: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(236, 72, 153, 0.12);
    backdrop-filter: blur(18px);
    box-shadow: 0 10px 30px rgba(88, 28, 135, 0.08);
}

.nav-shell {
    width: min(1240px, calc(100% - 32px));
    height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 24px;
}

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 25px;
    font-weight: 900;
    letter-spacing: -0.03em;
    background: linear-gradient(90deg, var(--pink), var(--purple), var(--blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    white-space: nowrap;
}

.logo-mark {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 15px;
    background: linear-gradient(135deg, var(--pink), var(--purple), var(--blue));
    box-shadow: 0 12px 25px rgba(124, 58, 237, 0.32);
}

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

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

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover {
    color: var(--pink);
    background: rgba(236, 72, 153, 0.10);
    transform: translateY(-1px);
}

.top-search {
    display: flex;
    align-items: center;
    width: min(340px, 28vw);
    border: 1px solid rgba(124, 58, 237, 0.16);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.86);
    overflow: hidden;
}

.top-search input,
.large-search input,
.filter-controls input,
.filter-controls select {
    width: 100%;
    border: 0;
    outline: 0;
    color: var(--text);
    background: transparent;
}

.top-search input {
    padding: 10px 12px 10px 16px;
}

.top-search button,
.large-search button,
.filter-controls button {
    border: 0;
    color: #ffffff;
    font-weight: 800;
    background: linear-gradient(135deg, var(--pink), var(--purple));
    cursor: pointer;
}

.top-search button {
    align-self: stretch;
    padding: 0 16px;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: rgba(236, 72, 153, 0.10);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    border-radius: 999px;
    background: var(--pink);
}

.mobile-nav {
    display: none;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto 14px;
    padding: 12px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.mobile-nav.open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.hero {
    padding: 26px 0 40px;
}

.hero-stage {
    position: relative;
    width: min(1240px, calc(100% - 32px));
    min-height: 610px;
    margin: 0 auto;
    overflow: hidden;
    border-radius: 34px;
    background: #111827;
    box-shadow: 0 35px 80px rgba(17, 24, 39, 0.25);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.5fr);
    align-items: center;
    gap: 40px;
    padding: clamp(32px, 6vw, 76px);
    opacity: 0;
    pointer-events: none;
    background-position: center;
    background-size: cover;
    transition: opacity 0.65s ease, transform 0.65s ease;
    transform: scale(1.02);
}

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

.hero-copy {
    position: relative;
    z-index: 2;
    color: #ffffff;
}

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #f9a8d4;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
    margin: 14px 0 18px;
    font-size: clamp(38px, 7vw, 72px);
    line-height: 1.02;
    font-weight: 950;
    letter-spacing: -0.06em;
}

.hero p,
.page-hero p,
.detail-copy p {
    width: min(700px, 100%);
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.75;
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

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

.hero-tags span,
.tag-row span,
.detail-meta span,
.card-meta span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-weight: 800;
}

.hero-tags span {
    padding: 8px 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
}

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

.primary-btn,
.ghost-btn,
.full-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.25s ease, box-shadow 0.25s ease, opacity 0.25s ease;
}

.primary-btn {
    min-height: 48px;
    padding: 0 24px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--pink), var(--purple), var(--blue));
    box-shadow: 0 18px 40px rgba(124, 58, 237, 0.35);
}

.ghost-btn {
    min-height: 48px;
    padding: 0 22px;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.36);
    background: rgba(255, 255, 255, 0.12);
}

.primary-btn:hover,
.ghost-btn:hover,
.full-link:hover {
    transform: translateY(-2px) scale(1.02);
}

.hero-poster {
    position: relative;
    z-index: 2;
    width: min(320px, 100%);
    justify-self: end;
    border-radius: 30px;
    overflow: hidden;
    box-shadow: 0 28px 55px rgba(0, 0, 0, 0.45);
    transform: rotate(2deg);
}

.hero-poster img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.hero-poster span,
.detail-poster span {
    position: absolute;
    top: 16px;
    right: 16px;
    display: grid;
    place-items: center;
    min-width: 54px;
    height: 38px;
    padding: 0 10px;
    color: #ffffff;
    font-size: 18px;
    font-weight: 950;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    box-shadow: 0 12px 25px rgba(236, 72, 153, 0.35);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    font-size: 38px;
    line-height: 1;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(12px);
    cursor: pointer;
    transform: translateY(-50%);
}

.hero-prev {
    left: 18px;
}

.hero-next {
    right: 18px;
}

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

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

.hero-dots button.active {
    width: 34px;
    background: #ffffff;
}

.home-search-section,
.section-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
}

.home-search-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.7fr);
    align-items: center;
    gap: 24px;
    padding: 28px;
    border: 1px solid rgba(236, 72, 153, 0.12);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: var(--shadow);
}

.home-search-card h2,
.section-title h2,
.side-head h2,
.content-card h2,
.filter-panel h2 {
    margin: 0;
    color: #111827;
    font-weight: 950;
    letter-spacing: -0.04em;
}

.home-search-card h2 {
    font-size: clamp(24px, 3vw, 38px);
}

.home-search-card p,
.filter-panel p,
.site-footer p,
.category-overview-card p {
    color: var(--muted);
    line-height: 1.8;
}

.large-search {
    display: flex;
    min-height: 58px;
    border: 1px solid rgba(124, 58, 237, 0.16);
    border-radius: 999px;
    overflow: hidden;
    background: #ffffff;
}

.large-search input {
    padding: 0 22px;
}

.large-search button {
    padding: 0 26px;
}

.section-shell {
    padding: 70px 0;
}

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

.section-title h2 {
    margin-top: 6px;
    font-size: clamp(28px, 4vw, 42px);
}

.section-title a,
.light-title a {
    color: var(--pink);
    font-weight: 900;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(236, 72, 153, 0.10);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 12px 32px rgba(88, 28, 135, 0.10);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    border-color: rgba(236, 72, 153, 0.28);
    box-shadow: 0 22px 48px rgba(88, 28, 135, 0.18);
    transform: translateY(-6px);
}

.card-large:first-child {
    grid-column: span 2;
}

.poster-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    background: #111827;
}

.poster-wrap img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.card-large .poster-wrap img {
    aspect-ratio: 16 / 10;
}

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

.poster-shade {
    position: absolute;
    inset: auto 0 0;
    height: 45%;
    background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.82));
}

.play-chip {
    position: absolute;
    left: 14px;
    bottom: 14px;
    padding: 8px 12px;
    color: #ffffff;
    font-size: 13px;
    font-weight: 900;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--pink), var(--purple));
}

.rank-no {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    display: grid;
    place-items: center;
    min-width: 38px;
    height: 38px;
    color: #ffffff;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    box-shadow: 0 10px 22px rgba(249, 115, 22, 0.35);
}

.card-body {
    padding: 17px;
}

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

.card-meta span,
.detail-meta span {
    padding: 5px 8px;
    color: #7c2d12;
    font-size: 12px;
    background: #ffedd5;
}

.movie-card h3 {
    margin: 0 0 9px;
    font-size: 20px;
    font-weight: 950;
    line-height: 1.3;
}

.movie-card h3 a:hover {
    color: var(--pink);
}

.movie-card p {
    display: -webkit-box;
    min-height: 48px;
    margin: 0 0 14px;
    overflow: hidden;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.tag-row span {
    padding: 6px 9px;
    color: #6d28d9;
    font-size: 12px;
    background: #f3e8ff;
}

.category-section {
    background: linear-gradient(135deg, #831843, #581c87 55%, #1e3a8a);
}

.light-title h2,
.light-title .section-kicker,
.light-title a {
    color: #ffffff;
}

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

.category-card {
    position: relative;
    min-height: 190px;
    overflow: hidden;
    padding: 24px;
    border-radius: var(--radius);
    color: #ffffff;
    background-position: center;
    background-size: cover;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover,
.category-overview-card:hover {
    transform: translateY(-5px) scale(1.015);
}

.category-card span,
.category-overview-card span {
    display: block;
    margin-bottom: 10px;
    font-size: 23px;
    font-weight: 950;
}

.category-card strong {
    display: block;
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
    line-height: 1.65;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 30px;
    align-items: start;
}

.side-rank,
.detail-side,
.content-card,
.player-card,
.filter-panel,
.category-overview-card {
    border: 1px solid rgba(236, 72, 153, 0.12);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow);
}

.side-rank,
.detail-side {
    position: sticky;
    top: 96px;
    padding: 22px;
}

.side-head {
    margin-bottom: 16px;
}

.side-head span {
    color: var(--pink);
    font-weight: 950;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.side-head h2 {
    margin-top: 4px;
    font-size: 28px;
}

.rank-line {
    display: grid;
    grid-template-columns: 34px 62px minmax(0, 1fr) auto;
    gap: 12px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(236, 72, 153, 0.10);
}

.rank-line img {
    width: 62px;
    height: 78px;
    border-radius: 14px;
    object-fit: cover;
}

.rank-number {
    display: grid;
    place-items: center;
    width: 30px;
    height: 30px;
    color: #ffffff;
    font-weight: 950;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--pink), var(--purple));
}

.rank-title {
    min-width: 0;
}

.rank-title strong,
.rank-title em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-title strong {
    font-weight: 900;
}

.rank-title em {
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

.rank-score {
    color: var(--orange);
    font-weight: 950;
}

.full-link {
    width: 100%;
    min-height: 46px;
    margin-top: 16px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--pink), var(--purple));
}

.page-hero,
.detail-hero {
    color: #ffffff;
    background-position: center;
    background-size: cover;
}

.small-hero {
    padding: 86px 0;
    background: linear-gradient(135deg, #831843, #581c87 55%, #1e3a8a);
}

.small-hero > div {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
}

.category-overview-card {
    overflow: hidden;
    padding-bottom: 20px;
    transition: transform 0.25s ease;
}

.category-overview-card img {
    width: 100%;
    height: 170px;
    object-fit: cover;
}

.category-overview-card span,
.category-overview-card p {
    padding: 0 20px;
}

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

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(340px, 1.1fr);
    align-items: center;
    gap: 24px;
    margin-bottom: 28px;
    padding: 24px;
}

.filter-panel h2 {
    font-size: 30px;
}

.filter-controls {
    display: grid;
    grid-template-columns: minmax(180px, 1fr) 150px 150px auto;
    gap: 10px;
}

.filter-controls input,
.filter-controls select {
    min-height: 46px;
    padding: 0 14px;
    border: 1px solid rgba(124, 58, 237, 0.16);
    border-radius: 14px;
    background: #ffffff;
}

.filter-controls button {
    min-height: 46px;
    padding: 0 18px;
    border-radius: 14px;
}

.detail-hero {
    padding: 70px 0;
}

.detail-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 40px;
    align-items: center;
}

.detail-poster {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    box-shadow: 0 28px 55px rgba(0, 0, 0, 0.38);
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 800;
}

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

.detail-tags {
    margin: 22px 0 28px;
}

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

.player-card {
    overflow: hidden;
    padding: 14px;
}

.video-player {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    background: #050816;
    aspect-ratio: 16 / 9;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    gap: 10px;
    border: 0;
    color: #ffffff;
    text-align: center;
    background: radial-gradient(circle at center, rgba(236, 72, 153, 0.24), rgba(15, 23, 42, 0.88));
    cursor: pointer;
}

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

.player-icon {
    display: grid;
    place-items: center;
    width: 78px;
    height: 78px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 30px;
    background: linear-gradient(135deg, var(--pink), var(--purple), var(--blue));
    box-shadow: 0 20px 45px rgba(124, 58, 237, 0.45);
}

.player-cover strong {
    font-size: clamp(22px, 4vw, 36px);
    font-weight: 950;
}

.player-cover em {
    color: rgba(255, 255, 255, 0.78);
    font-style: normal;
    font-weight: 800;
}

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

.content-card h2 {
    margin-bottom: 16px;
    font-size: 30px;
}

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

.side-card-list .rank-line {
    grid-template-columns: 30px 58px minmax(0, 1fr);
}

.side-card-list .rank-score {
    display: none;
}

.no-result {
    grid-column: 1 / -1;
    padding: 36px;
    color: var(--muted);
    text-align: center;
    border: 1px dashed rgba(124, 58, 237, 0.28);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.82);
}

.site-footer {
    margin-top: 40px;
    border-top: 1px solid rgba(236, 72, 153, 0.12);
    background: linear-gradient(135deg, #fff1f8, #f3e8ff, #eff6ff);
}

.footer-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    align-items: center;
    padding: 42px 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.footer-links a {
    padding: 10px 14px;
    color: #6d28d9;
    font-weight: 900;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.7);
}

@media (max-width: 1100px) {
    .top-search {
        display: none;
    }

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

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

    .side-rank,
    .detail-side {
        position: static;
    }
}

@media (max-width: 820px) {
    .desktop-nav {
        display: none;
    }

    .menu-toggle {
        display: block;
        margin-left: auto;
    }

    .hero-stage {
        min-height: 740px;
        border-radius: 26px;
    }

    .hero-slide,
    .detail-shell,
    .home-search-card,
    .filter-panel {
        grid-template-columns: 1fr;
    }

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

    .hero-arrow {
        display: none;
    }

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

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

    .card-large:first-child {
        grid-column: span 1;
    }

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

@media (max-width: 560px) {
    .nav-shell {
        height: 64px;
        gap: 12px;
    }

    .site-logo,
    .footer-logo {
        font-size: 20px;
    }

    .logo-mark {
        width: 34px;
        height: 34px;
    }

    .hero-stage {
        width: min(100% - 20px, 1240px);
        min-height: 690px;
    }

    .hero-slide {
        padding: 28px;
    }

    .home-search-section,
    .section-shell,
    .small-hero > div,
    .detail-shell,
    .footer-shell {
        width: min(100% - 24px, 1240px);
    }

    .home-search-card,
    .content-card,
    .filter-panel,
    .side-rank,
    .detail-side {
        padding: 20px;
    }

    .large-search {
        border-radius: 20px;
        flex-direction: column;
    }

    .large-search input {
        min-height: 54px;
    }

    .large-search button {
        min-height: 50px;
    }

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

    .detail-shell {
        gap: 24px;
    }

    .detail-poster {
        width: min(260px, 82vw);
    }

    .rank-line {
        grid-template-columns: 30px 52px minmax(0, 1fr);
    }

    .rank-score {
        display: none;
    }
}
