:root {
    --pink: #ec4899;
    --pink-dark: #db2777;
    --orange: #f97316;
    --orange-soft: #fed7aa;
    --blue: #60a5fa;
    --cyan: #22d3ee;
    --green: #10b981;
    --ink: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --soft: #fff7ed;
    --paper: #ffffff;
    --shadow: 0 18px 45px rgba(31, 41, 55, 0.12);
    --round: 24px;
}

* {
    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(--ink);
    background: linear-gradient(135deg, #fff7ed 0%, #fdf2f8 48%, #eff6ff 100%);
    line-height: 1.6;
}

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

img {
    display: block;
    width: 100%;
    height: auto;
}

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(14px);
    box-shadow: 0 10px 30px rgba(31, 41, 55, 0.08);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
}

.brand-mark {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--pink), var(--orange));
    box-shadow: 0 12px 30px rgba(236, 72, 153, 0.28);
    transform: translateZ(0);
    transition: transform 0.25s ease;
}

.brand:hover .brand-mark {
    transform: scale(1.08) rotate(-6deg);
}

.brand-text {
    font-size: 1.55rem;
    background: linear-gradient(90deg, var(--pink), var(--orange));
    -webkit-background-clip: text;
    color: transparent;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 26px;
}

.nav-link {
    color: #4b5563;
    font-weight: 700;
    transition: color 0.2s ease, transform 0.2s ease;
}

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

.menu-button {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: #f9fafb;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.menu-button span {
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: #374151;
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    padding: 10px 16px 16px;
    background: rgba(255, 255, 255, 0.96);
}

.mobile-nav.is-open {
    display: grid;
    gap: 8px;
}

.mobile-link {
    padding: 11px 14px;
    border-radius: 14px;
    color: #4b5563;
    font-weight: 700;
}

.mobile-link:hover,
.mobile-link.active {
    color: var(--pink);
    background: #fdf2f8;
}

.hero {
    position: relative;
    min-height: 680px;
    overflow: hidden;
    background: #111827;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.7s ease, visibility 0.7s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: blur(6px) saturate(1.18);
    transform: scale(1.06);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 18% 22%, rgba(236, 72, 153, 0.52), transparent 32%),
        radial-gradient(circle at 72% 16%, rgba(249, 115, 22, 0.45), transparent 34%),
        linear-gradient(90deg, rgba(17, 24, 39, 0.93), rgba(17, 24, 39, 0.68), rgba(17, 24, 39, 0.35));
}

.hero-content {
    position: relative;
    min-height: 680px;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(280px, 0.58fr);
    align-items: center;
    gap: 48px;
    color: #fff;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font-weight: 800;
    letter-spacing: 0.04em;
    backdrop-filter: blur(10px);
}

.eyebrow.light {
    background: linear-gradient(90deg, #fdf2f8, #fff7ed);
    color: var(--pink-dark);
}

.hero h1 {
    margin: 18px 0 18px;
    font-size: clamp(2.6rem, 8vw, 5.8rem);
    line-height: 1.02;
    letter-spacing: -0.055em;
}

.hero p {
    max-width: 660px;
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(1rem, 2.4vw, 1.3rem);
}

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

.hero-tags {
    margin: 24px 0 30px;
}

.hero-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 6px 12px;
    color: #9d174d;
    background: rgba(255, 255, 255, 0.88);
    font-size: 0.82rem;
    font-weight: 800;
}

.tag-row span {
    color: var(--pink-dark);
    background: #fdf2f8;
}

.tag-row.large span {
    padding: 8px 14px;
}

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

.hero-actions.narrow {
    margin-top: 24px;
}

.primary-button,
.secondary-button,
.ghost-button,
.text-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    padding: 0 24px;
    color: #fff;
    background: linear-gradient(90deg, var(--pink), var(--orange));
    box-shadow: 0 14px 30px rgba(236, 72, 153, 0.32);
}

.primary-button:hover,
.secondary-button:hover,
.ghost-button:hover {
    transform: translateY(-2px);
}

.secondary-button {
    padding: 0 22px;
    color: var(--pink-dark);
    background: #fff;
}

.ghost-button {
    padding: 0 22px;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.42);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

.text-link {
    min-height: auto;
    color: var(--pink-dark);
    font-size: 0.96rem;
}

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

.hero-poster {
    position: relative;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 34px 90px rgba(0, 0, 0, 0.42);
    transform: perspective(900px) rotateY(-8deg) rotateX(3deg);
    transition: transform 0.35s ease;
}

.hero-poster:hover {
    transform: perspective(900px) rotateY(-2deg) rotateX(1deg) translateY(-4px);
}

.hero-poster img {
    height: 520px;
    object-fit: cover;
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 34px;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 4;
}

.hero-arrow,
.hero-dot {
    border: 0;
    color: #fff;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
}

.hero-arrow {
    width: 46px;
    height: 46px;
    border-radius: 999px;
    font-size: 2rem;
    line-height: 1;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    padding: 0;
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 34px;
    background: linear-gradient(90deg, var(--pink), var(--orange));
}

.section {
    padding: 64px 0;
}

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

.section-heading.centered {
    display: grid;
    justify-items: center;
    text-align: center;
}

.section-heading h2 {
    margin: 10px 0 0;
    font-size: clamp(1.9rem, 4vw, 3rem);
    line-height: 1.1;
    letter-spacing: -0.035em;
}

.section-heading p {
    margin: 10px 0 0;
    color: var(--muted);
}

.home-search {
    padding-bottom: 20px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 190px 220px;
    gap: 14px;
    padding: 18px;
    border-radius: var(--round);
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.filter-panel label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 800;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 48px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 16px;
    color: var(--ink);
    background: #fff;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: #f9a8d4;
    box-shadow: 0 0 0 4px rgba(236, 72, 153, 0.12);
}

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

.movie-card {
    overflow: hidden;
    border-radius: 24px;
    background: var(--paper);
    box-shadow: 0 12px 34px rgba(31, 41, 55, 0.09);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    height: 310px;
    overflow: hidden;
    background: #111827;
}

.poster-link img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 44%, rgba(17, 24, 39, 0.68));
}

.card-type,
.rank-badge {
    position: absolute;
    top: 14px;
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 12px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 900;
}

.card-type {
    left: 14px;
    color: #9d174d;
    background: rgba(255, 255, 255, 0.9);
}

.rank-badge {
    right: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--pink), var(--orange));
}

.card-body {
    padding: 18px;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
}

.card-body h2,
.card-body h3 {
    margin: 8px 0;
    font-size: 1.12rem;
    line-height: 1.35;
}

.card-body h2 a:hover,
.card-body h3 a:hover,
.compact-card h3 a:hover {
    color: var(--pink);
}

.card-body p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    min-height: 3.2em;
    overflow: hidden;
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 0.92rem;
}

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

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

.category-card {
    padding: 18px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 34px rgba(31, 41, 55, 0.09);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-covers {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    overflow: hidden;
    border-radius: 18px;
    margin-bottom: 16px;
}

.category-covers a {
    height: 92px;
    overflow: hidden;
}

.category-covers img {
    height: 100%;
    object-fit: cover;
}

.category-card h2 {
    margin: 0 0 8px;
    font-size: 1.18rem;
}

.category-card p {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 0.94rem;
}

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

.compact-card {
    display: grid;
    grid-template-columns: 78px 1fr;
    gap: 14px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 26px rgba(31, 41, 55, 0.07);
    transition: transform 0.2s ease, background 0.2s ease;
}

.compact-card:hover {
    transform: translateX(4px);
    background: #fff;
}

.compact-card img {
    height: 100px;
    border-radius: 14px;
    object-fit: cover;
}

.compact-card h3 {
    margin: 4px 0;
    font-size: 0.98rem;
    line-height: 1.35;
}

.compact-card p {
    margin: 0;
    color: var(--muted);
    font-size: 0.82rem;
}

.compact-rank {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 30px;
    height: 24px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(90deg, var(--pink), var(--orange));
    font-size: 0.76rem;
    font-weight: 900;
}

.page-hero {
    color: #fff;
    background:
        radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.2), transparent 28%),
        linear-gradient(95deg, var(--pink), var(--orange), var(--blue));
}

.compact-hero {
    padding: 82px 0 76px;
}

.compact-hero h1 {
    margin: 16px 0 12px;
    font-size: clamp(2.3rem, 6vw, 4.7rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.compact-hero p {
    max-width: 800px;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.12rem;
}

.crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.88);
    font-weight: 700;
}

.crumbs a:hover {
    color: #fff;
}

.detail-top {
    padding: 48px 0;
    color: #fff;
    background:
        radial-gradient(circle at 18% 18%, rgba(236, 72, 153, 0.46), transparent 30%),
        radial-gradient(circle at 80% 12%, rgba(249, 115, 22, 0.42), transparent 30%),
        linear-gradient(135deg, #111827, #312e81 48%, #7c2d12);
}

.detail-hero-card {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 34px;
    align-items: center;
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(18px);
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.25);
}

.detail-poster {
    overflow: hidden;
    border-radius: 24px;
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.34);
}

.detail-poster img {
    height: 430px;
    object-fit: cover;
}

.detail-copy h1 {
    margin: 16px 0 14px;
    font-size: clamp(2.1rem, 5vw, 4.6rem);
    line-height: 1.06;
    letter-spacing: -0.045em;
}

.lead {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.14rem;
}

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

.info-list div {
    padding: 13px 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.14);
}

.info-list dt {
    color: rgba(255, 255, 255, 0.68);
    font-size: 0.8rem;
    font-weight: 800;
}

.info-list dd {
    margin: 2px 0 0;
    font-weight: 900;
}

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

.detail-main,
.detail-side {
    display: grid;
    gap: 24px;
}

.player-card {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #000;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

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

.play-layer {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 12px;
    border: 0;
    color: #fff;
    background: linear-gradient(180deg, rgba(17, 24, 39, 0.2), rgba(17, 24, 39, 0.76));
    font-size: 1.1rem;
    font-weight: 900;
    z-index: 2;
}

.play-layer.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.play-icon {
    width: 82px;
    height: 82px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--pink), var(--orange));
    box-shadow: 0 16px 42px rgba(236, 72, 153, 0.42);
    font-size: 2.4rem;
    padding-left: 5px;
}

.content-card,
.side-card {
    padding: 26px;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 12px 34px rgba(31, 41, 55, 0.08);
}

.accent-card {
    background: linear-gradient(135deg, #fdf2f8, #fff7ed);
}

.content-card h2,
.side-card h2 {
    margin: 0 0 14px;
    font-size: 1.38rem;
}

.content-card p {
    margin: 0;
    color: #374151;
    font-size: 1.02rem;
}

.side-card {
    position: sticky;
    top: 92px;
}

.side-list {
    display: grid;
    gap: 12px;
}

.ranking-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.site-footer {
    margin-top: 64px;
    color: #e5e7eb;
    background: linear-gradient(90deg, #1f2937, #111827);
}

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

.site-footer h2 {
    margin: 0 0 12px;
    font-size: 1.08rem;
    color: #fff;
}

.site-footer p,
.site-footer li {
    color: #cbd5e1;
    font-size: 0.94rem;
}

.site-footer ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer a:hover {
    color: #f9a8d4;
}

.footer-bottom {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    padding: 18px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    font-size: 0.9rem;
}

[data-card].is-hidden {
    display: none;
}

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

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

    .hero-content {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 100px 0 120px;
    }

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

    .hero-poster img {
        height: 460px;
    }

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

    .side-card {
        position: static;
    }

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

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

    .menu-button {
        display: inline-flex;
    }

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

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

    .hero-poster {
        display: none;
    }

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

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

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

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

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

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

    .brand-text {
        font-size: 1.32rem;
    }

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

    .hero h1 {
        font-size: 2.65rem;
    }

    .hero-controls {
        bottom: 22px;
    }

    .hero-actions,
    .section-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .primary-button,
    .secondary-button,
    .ghost-button {
        width: 100%;
    }

    .movie-grid,
    .ranking-grid,
    .ranking-list,
    .category-grid,
    .category-grid.wide,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .poster-link {
        height: 360px;
    }

    .compact-card {
        grid-template-columns: 70px 1fr;
    }

    .compact-card img {
        height: 94px;
    }

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

    .detail-top {
        padding: 30px 0;
    }

    .detail-hero-card {
        padding: 16px;
        border-radius: 24px;
    }

    .info-list {
        grid-template-columns: 1fr;
    }

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