:root {
    --pink: #ec4899;
    --pink-soft: #f9a8d4;
    --purple: #a855f7;
    --purple-dark: #581c87;
    --yellow: #facc15;
    --text: #1f2937;
    --muted: #6b7280;
    --line: #f0d9ef;
    --bg: #fff7fb;
    --card: #ffffff;
    --shadow: 0 20px 45px rgba(168, 85, 247, 0.18);
    --shadow-soft: 0 10px 30px rgba(236, 72, 153, 0.13);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background: linear-gradient(135deg, #fff1f7 0%, #faf5ff 48%, #fff1f7 100%);
    min-height: 100vh;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, #ec4899 0%, #a855f7 52%, #f472b6 100%);
    box-shadow: 0 12px 30px rgba(168, 85, 247, 0.28);
}

.top-nav {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.brand-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--purple-dark);
    background: var(--yellow);
    box-shadow: 0 8px 20px rgba(250, 204, 21, 0.34);
}

.nav-content {
    display: flex;
    align-items: center;
    gap: 22px;
    flex: 1;
    justify-content: flex-end;
}

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

.nav-link {
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 999px;
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 255, 255, 0.95);
    color: var(--pink);
    transform: translateY(-1px);
}

.nav-search {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.28);
    padding: 6px;
    border-radius: 999px;
    backdrop-filter: blur(12px);
}

.nav-search input {
    width: 220px;
    border: 0;
    outline: 0;
    border-radius: 999px;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.92);
}

.nav-search button,
.pink-button,
.ghost-button {
    border: 0;
    cursor: pointer;
    border-radius: 999px;
    padding: 9px 16px;
    font-weight: 700;
}

.nav-search button,
.pink-button {
    color: #ffffff;
    background: linear-gradient(90deg, var(--pink), var(--purple));
    box-shadow: 0 10px 25px rgba(236, 72, 153, 0.28);
}

.ghost-button {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.35);
}

.menu-toggle {
    display: none;
    color: #ffffff;
    background: transparent;
    border: 0;
    font-size: 28px;
    cursor: pointer;
}

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

.hero {
    position: relative;
    height: 500px;
    overflow: hidden;
    background: #111827;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1s ease;
}

.hero-slide.active {
    opacity: 1;
}

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.08));
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: center;
}

.hero-copy {
    width: min(650px, 92%);
    color: #ffffff;
}

.hero-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: var(--pink);
    font-weight: 700;
}

.hero h1,
.hero h2 {
    margin: 0 0 16px;
    font-size: clamp(36px, 6vw, 58px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
    text-shadow: 0 6px 26px rgba(0, 0, 0, 0.45);
}

.hero p {
    margin: 0 0 24px;
    font-size: 20px;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.8;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.hero-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
}

.hero-control {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    cursor: pointer;
    background: rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(10px);
    transition: background 0.25s ease, transform 0.25s ease;
}

.hero-control:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-50%) scale(1.04);
}

.hero-control.prev {
    left: 24px;
}

.hero-control.next {
    right: 24px;
}

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

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

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

.section {
    padding: 54px 0 0;
}

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

.section-title {
    margin: 0;
    font-size: clamp(26px, 4vw, 34px);
    font-weight: 850;
    color: #1f2937;
}

.section-desc {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

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

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

.poster-card,
.feature-card,
.category-tile,
.info-panel,
.rank-row,
.detail-main,
.detail-side,
.search-panel {
    background: var(--card);
    border-radius: 18px;
    box-shadow: var(--shadow-soft);
    overflow: hidden;
}

.poster-card {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fce7f3, #ede9fe);
}

.poster-frame img,
.feature-card img,
.movie-card-wide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.score-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    min-width: 42px;
    text-align: center;
    color: #ffffff;
    background: linear-gradient(90deg, #f59e0b, #ec4899);
    border-radius: 999px;
    padding: 5px 8px;
    font-size: 13px;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(236, 72, 153, 0.3);
}

.poster-card h3,
.feature-card h3,
.movie-card-wide h3,
.rank-row h3 {
    margin: 12px 14px 6px;
    font-size: 17px;
    line-height: 1.35;
    color: #1f2937;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.meta-line,
.pill-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.meta-line {
    margin: 0 14px 16px;
    color: #6b7280;
    font-size: 13px;
}

.meta-line span,
.pill-row span {
    border-radius: 999px;
    padding: 4px 9px;
    background: #fdf2f8;
    color: var(--pink);
}

.feature-card {
    position: relative;
    min-height: 360px;
}

.feature-card a {
    display: block;
    height: 100%;
}

.feature-card img {
    min-height: 360px;
}

.feature-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 28px;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.04));
}

.feature-overlay span {
    align-self: flex-start;
    padding: 5px 12px;
    border-radius: 999px;
    background: var(--pink);
    font-weight: 700;
}

.feature-overlay h3,
.feature-overlay p {
    color: #ffffff;
    margin-left: 0;
    margin-right: 0;
}

.feature-overlay p {
    color: rgba(255, 255, 255, 0.82);
}

.movie-card-wide a {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    padding: 14px;
}

.movie-card-wide img {
    height: 160px;
    border-radius: 14px;
}

.movie-card-wide h3,
.movie-card-wide p,
.movie-card-wide .meta-line {
    margin-left: 0;
    margin-right: 0;
}

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

.category-chip {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 92px;
    padding: 20px;
    color: #ffffff;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--pink), var(--purple));
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-chip:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.category-chip strong {
    display: block;
    font-size: 20px;
}

.category-chip span {
    opacity: 0.86;
    font-size: 13px;
}

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

.category-tile {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
}

.category-cover-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 4px;
    padding: 12px;
}

.category-cover-grid img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 10px;
}

.category-tile-body {
    padding: 22px 22px 22px 4px;
}

.category-tile-body h2 {
    margin: 0 0 10px;
    color: #1f2937;
    font-size: 24px;
}

.category-tile-body p {
    margin: 0 0 16px;
    color: var(--muted);
    line-height: 1.8;
}

.category-samples {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-samples a {
    border-radius: 999px;
    padding: 6px 10px;
    color: var(--pink);
    background: #fdf2f8;
    font-size: 13px;
}

.page-hero {
    margin: 36px 0 0;
    padding: 44px;
    border-radius: 26px;
    color: #ffffff;
    background: linear-gradient(90deg, var(--pink), var(--purple), #f472b6);
    box-shadow: var(--shadow);
}

.page-hero h1 {
    margin: 0 0 14px;
    font-size: clamp(32px, 5vw, 48px);
    line-height: 1.15;
}

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

.filter-tools {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 14px;
    margin: 28px 0;
    padding: 18px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(12px);
}

.filter-tools label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    color: #4b5563;
    font-weight: 700;
}

.filter-tools input,
.filter-tools select {
    width: 100%;
    border: 1px solid var(--line);
    outline: 0;
    border-radius: 14px;
    padding: 11px 12px;
    background: #ffffff;
}

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

.rank-row a {
    display: grid;
    grid-template-columns: 60px 80px minmax(0, 1fr) 80px;
    gap: 16px;
    align-items: center;
    padding: 14px 18px;
}

.rank-row strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: #ffffff;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--pink), var(--purple));
    font-size: 18px;
}

.rank-row img {
    width: 70px;
    height: 94px;
    object-fit: cover;
    border-radius: 10px;
}

.rank-score {
    justify-self: end;
    padding: 8px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(90deg, #f59e0b, var(--pink));
    font-weight: 850;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 360px;
    gap: 28px;
    margin-top: 36px;
}

.detail-main,
.detail-side {
    padding: 22px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 26px 0 0;
    color: #6b7280;
    font-size: 14px;
}

.breadcrumb a {
    color: var(--pink);
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    background: #000000;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.24);
    aspect-ratio: 16 / 9;
}

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

.player-start {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    cursor: pointer;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.16));
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-start span {
    width: 88px;
    height: 88px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--pink), var(--purple));
    box-shadow: 0 20px 55px rgba(236, 72, 153, 0.42);
    font-size: 34px;
    padding-left: 6px;
}

.player-shell.is-playing .player-start {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.detail-title {
    margin: 22px 0 10px;
    font-size: clamp(30px, 5vw, 46px);
    line-height: 1.15;
}

.detail-lead {
    color: #4b5563;
    font-size: 18px;
    line-height: 1.9;
}

.detail-section {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid #f3e8ff;
}

.detail-section h2 {
    margin: 0 0 12px;
    font-size: 24px;
}

.detail-section p {
    color: #4b5563;
    line-height: 2;
    margin: 0;
}

.detail-side img {
    width: 100%;
    border-radius: 18px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    box-shadow: var(--shadow-soft);
}

.side-meta {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.side-meta div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 0;
    border-bottom: 1px solid #f3e8ff;
}

.side-meta span:first-child {
    color: #6b7280;
}

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

.site-footer {
    margin-top: 70px;
    color: #ffffff;
    background: linear-gradient(90deg, #581c87 0%, #831843 50%, #581c87 100%);
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 30px;
}

.footer-inner h2,
.footer-inner h3 {
    margin: 0 0 14px;
}

.footer-inner p {
    color: rgba(255, 255, 255, 0.78);
    line-height: 1.8;
}

.footer-links {
    display: grid;
    gap: 9px;
    color: rgba(255, 255, 255, 0.82);
}

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

.copyright {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 26px;
    color: rgba(255, 255, 255, 0.72);
}

.hidden-by-filter {
    display: none !important;
}

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

    .nav-content {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 64px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 16px;
        border-radius: 0 0 22px 22px;
        background: linear-gradient(90deg, #ec4899 0%, #a855f7 100%);
        box-shadow: var(--shadow);
    }

    .site-header.menu-open .nav-content {
        display: flex;
    }

    .nav-links {
        flex-direction: column;
        align-items: stretch;
    }

    .nav-search,
    .nav-search input {
        width: 100%;
    }

    .hero {
        height: 560px;
    }

    .hero-control {
        display: none;
    }

    .feature-grid,
    .category-page-grid,
    .detail-layout,
    .footer-inner {
        grid-template-columns: 1fr;
    }

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

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

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

    .category-tile-body {
        padding: 20px;
    }

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

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

    .rank-score {
        grid-column: 3;
        justify-self: start;
    }
}

@media (max-width: 560px) {
    .top-nav,
    .main-wrap,
    .hero-inner,
    .footer-inner,
    .copyright {
        width: min(100% - 24px, 1180px);
    }

    .brand {
        font-size: 20px;
    }

    .hero h1,
    .hero h2 {
        font-size: 36px;
    }

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

    .page-hero {
        padding: 30px 22px;
    }

    .card-grid,
    .related-grid,
    .category-strip {
        grid-template-columns: 1fr;
    }

    .movie-card-wide a {
        grid-template-columns: 96px minmax(0, 1fr);
    }

    .movie-card-wide img {
        height: 130px;
    }
}
