:root {
    --candy-pink: #ffb3d9;
    --candy-rose: #ff8dc7;
    --candy-yellow: #ffe66d;
    --candy-mint: #a8e6ce;
    --candy-blue: #87ceeb;
    --candy-purple: #c497ff;
    --ink: #1f2937;
    --muted: #6b7280;
    --glass: rgba(255, 255, 255, 0.82);
    --shadow: 0 22px 70px rgba(255, 141, 199, 0.22);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--ink);
    background:
        radial-gradient(circle at top left, rgba(255, 179, 217, 0.38), transparent 34rem),
        radial-gradient(circle at top right, rgba(168, 230, 206, 0.32), transparent 32rem),
        linear-gradient(135deg, #fff5f8 0%, #ffffff 45%, #ffe5ec 100%);
    font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 179, 217, 0.18) 1px, transparent 1px),
        linear-gradient(90deg, rgba(135, 206, 235, 0.14) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent 72%);
    z-index: -3;
}

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

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

button,
input {
    font: inherit;
}

button {
    cursor: pointer;
}

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

.candy-rain {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: -1;
}

.candy-rain span {
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 999px;
    opacity: 0.5;
    background: var(--candy-pink);
    animation: candy-fall 5s linear infinite;
}

.gradient-text,
.site-logo span:last-child,
.section-heading h2,
.page-hero h1,
.detail-copy h1 {
    color: transparent;
    background: linear-gradient(135deg, var(--candy-rose), #ffb347, var(--candy-yellow), var(--candy-mint), var(--candy-blue));
    background-clip: text;
    -webkit-background-clip: text;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(255, 179, 217, 0.26);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px);
    box-shadow: 0 12px 36px rgba(255, 179, 217, 0.18);
}

.nav-shell {
    display: flex;
    align-items: center;
    gap: 24px;
    min-height: 72px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
    font-size: 1.45rem;
    font-weight: 900;
    letter-spacing: 0.02em;
}

.logo-mark {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    color: white;
    background: linear-gradient(135deg, var(--candy-rose), var(--candy-yellow), var(--candy-mint));
    box-shadow: 0 12px 28px rgba(255, 141, 199, 0.35);
}

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

.nav-link,
.mobile-link {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 10px 16px;
    color: #374151;
    font-weight: 700;
    transition: all 0.25s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: #be185d;
    background: rgba(255, 179, 217, 0.22);
}

.header-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    border: 2px solid rgba(255, 179, 217, 0.35);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.75);
}

.header-search input,
.mobile-search input,
.big-search input,
.page-filter-box input {
    border: 0;
    outline: 0;
    color: var(--ink);
    background: transparent;
}

.header-search input {
    width: 220px;
    padding: 10px 14px;
}

.header-search button,
.mobile-search button,
.big-search button {
    border: 0;
    color: white;
    font-weight: 800;
    background: linear-gradient(135deg, var(--candy-rose), var(--candy-yellow));
}

.header-search button {
    padding: 10px 16px;
}

.mobile-menu-button {
    display: none;
    margin-left: auto;
    border: 0;
    border-radius: 14px;
    padding: 10px;
    background: rgba(255, 179, 217, 0.18);
}

.mobile-menu-button span {
    display: block;
    width: 24px;
    height: 2px;
    margin: 5px 0;
    border-radius: 999px;
    background: var(--candy-rose);
}

.mobile-panel {
    padding: 0 20px 20px;
}

.mobile-search {
    display: flex;
    margin: 8px 0 14px;
    overflow: hidden;
    border: 2px solid rgba(255, 179, 217, 0.35);
    border-radius: 18px;
    background: white;
}

.mobile-search input {
    flex: 1;
    padding: 13px 14px;
}

.mobile-search button {
    padding: 0 16px;
}

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

.hero-carousel {
    position: relative;
    min-height: 680px;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.65s ease, transform 0.65s ease;
    pointer-events: none;
}

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

.hero-backdrop {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255, 245, 248, 0.97) 0%, rgba(255, 245, 248, 0.86) 42%, rgba(255, 245, 248, 0.36) 100%),
        var(--hero-image) center / cover;
    filter: saturate(1.05);
}

.hero-backdrop::after {
    content: "";
    position: absolute;
    inset: 10% 4% 8% 42%;
    border-radius: 48px;
    background: rgba(255, 255, 255, 0.38);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow);
}

.hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 390px;
    gap: 60px;
    align-items: center;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 92px 0 96px;
}

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

.hero-kicker,
.section-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border-radius: 999px;
    padding: 8px 14px;
    color: #be185d;
    font-size: 0.9rem;
    font-weight: 900;
    background: rgba(255, 179, 217, 0.22);
}

.hero-copy h1 {
    margin: 22px 0 18px;
    color: #111827;
    font-size: clamp(3.2rem, 8vw, 6.7rem);
    line-height: 0.95;
    letter-spacing: -0.08em;
    text-shadow: 4px 8px 34px rgba(255, 141, 199, 0.25);
}

.hero-copy p {
    max-width: 680px;
    margin: 0;
    color: #4b5563;
    font-size: clamp(1rem, 1.6vw, 1.3rem);
}

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

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

.hero-tags span,
.tag-list span,
.detail-meta span {
    border-radius: 999px;
    padding: 6px 11px;
    color: #7c2d12;
    font-size: 0.82rem;
    font-weight: 800;
    background: rgba(255, 230, 109, 0.42);
}

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

.candy-button,
.ghost-button,
.section-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    min-height: 48px;
    padding: 0 24px;
    font-weight: 900;
    transition: all 0.25s ease;
}

.candy-button {
    color: white;
    background: linear-gradient(135deg, var(--candy-rose), #ffb347, var(--candy-mint));
    box-shadow: 0 12px 34px rgba(255, 141, 199, 0.42);
}

.candy-button:hover,
.ghost-button:hover,
.section-action:hover {
    transform: translateY(-3px) scale(1.02);
}

.ghost-button,
.section-action {
    color: #be185d;
    background: rgba(255, 255, 255, 0.75);
    box-shadow: inset 0 0 0 1px rgba(255, 141, 199, 0.28);
}

.hero-poster {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border: 12px solid rgba(255, 255, 255, 0.6);
    border-radius: 38px;
    background: white;
    box-shadow: 0 30px 90px rgba(255, 141, 199, 0.38);
    transform: rotate(2deg);
}

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

.hero-poster span {
    position: absolute;
    right: 22px;
    bottom: 22px;
    display: grid;
    place-items: center;
    width: 66px;
    height: 66px;
    border-radius: 999px;
    color: white;
    font-size: 1.55rem;
    background: rgba(255, 141, 199, 0.88);
    backdrop-filter: blur(10px);
}

.hero-control-row {
    position: absolute;
    z-index: 5;
    left: 50%;
    bottom: 28px;
    display: flex;
    gap: 10px;
    transform: translateX(-50%);
}

.hero-dot {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 141, 199, 0.35);
    transition: all 0.25s ease;
}

.hero-dot.is-active {
    width: 42px;
    background: var(--candy-rose);
}

.search-panel {
    transform: translateY(-34px);
}

.big-search {
    display: flex;
    overflow: hidden;
    max-width: 880px;
    margin: 0 auto;
    border: 1px solid rgba(255, 179, 217, 0.36);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow);
    backdrop-filter: blur(16px);
}

.big-search input {
    flex: 1;
    min-width: 0;
    padding: 20px 24px;
    font-size: 1.05rem;
}

.big-search button {
    border: 0;
    padding: 0 30px;
}

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

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

.section-heading h2 {
    margin: 10px 0 8px;
    font-size: clamp(2rem, 4vw, 3.35rem);
    line-height: 1;
}

.section-heading p,
.page-hero p,
.detail-copy p,
.site-footer p,
.movie-card p,
.prose-card p,
.category-overview-card p,
.category-tile small {
    color: var(--muted);
}

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 179, 217, 0.26);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 12px 38px rgba(255, 179, 217, 0.16);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 22px 58px rgba(255, 141, 199, 0.28);
}

.poster-link {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    background: linear-gradient(135deg, rgba(255, 179, 217, 0.28), rgba(168, 230, 206, 0.28));
}

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

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

.poster-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.55) 100%);
}

.play-pill,
.rank-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    color: white;
    font-weight: 900;
    background: rgba(255, 141, 199, 0.9);
    backdrop-filter: blur(10px);
}

.play-pill {
    left: 14px;
    bottom: 14px;
    padding: 7px 12px;
    font-size: 0.82rem;
}

.rank-badge {
    top: 12px;
    left: 12px;
    padding: 7px 10px;
}

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

.movie-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    color: #9f1239;
    font-size: 0.78rem;
    font-weight: 800;
}

.movie-card h3 {
    margin: 10px 0 8px;
    font-size: 1.16rem;
    line-height: 1.24;
}

.movie-card h3 a:hover {
    color: #be185d;
}

.movie-card p {
    display: -webkit-box;
    min-height: 3.1em;
    margin: 0 0 14px;
    overflow: hidden;
    font-size: 0.92rem;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tag-list span {
    color: #065f46;
    background: rgba(168, 230, 206, 0.34);
}

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

.category-tile,
.category-overview-card {
    overflow: hidden;
    border: 1px solid rgba(255, 179, 217, 0.28);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: 0 16px 42px rgba(255, 179, 217, 0.16);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover,
.category-overview-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 64px rgba(255, 141, 199, 0.24);
}

.category-tile {
    position: relative;
    display: grid;
    min-height: 190px;
    align-content: end;
    padding: 22px;
    color: white;
}

.category-tile img {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.category-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(17, 24, 39, 0.72));
}

.category-tile span {
    font-size: 1.55rem;
    font-weight: 900;
}

.category-tile small {
    color: rgba(255, 255, 255, 0.86);
}

.page-main {
    padding-top: 44px;
}

.page-hero {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 179, 217, 0.28);
    border-radius: 36px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: var(--shadow);
}

.small-hero {
    padding: 46px;
}

.page-hero h1 {
    margin: 12px 0 12px;
    font-size: clamp(2.4rem, 6vw, 5rem);
    line-height: 1;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 18px;
    color: #9f1239;
    font-size: 0.92rem;
    font-weight: 800;
}

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

.page-filter-box {
    width: min(560px, 100%);
    margin-top: 24px;
    border: 2px solid rgba(255, 179, 217, 0.34);
    border-radius: 999px;
    background: white;
}

.page-filter-box input {
    width: 100%;
    padding: 14px 18px;
}

.category-overview-link {
    display: grid;
    grid-template-columns: 180px 1fr;
    gap: 22px;
    align-items: center;
    padding: 22px;
}

.category-thumb-stack {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
}

.category-thumb-stack img {
    width: 100%;
    aspect-ratio: 2 / 3;
    border-radius: 14px;
    object-fit: cover;
}

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

.movie-detail-hero {
    position: relative;
    overflow: hidden;
    min-height: 620px;
    margin-top: -44px;
    padding: 92px 0 70px;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(255, 245, 248, 0.98), rgba(255, 245, 248, 0.86) 50%, rgba(255, 245, 248, 0.5)),
        var(--detail-image) center / cover;
    filter: saturate(1.08);
}

.detail-hero-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 48px;
    align-items: center;
}

.detail-poster-card {
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border: 12px solid rgba(255, 255, 255, 0.68);
    border-radius: 34px;
    background: white;
    box-shadow: var(--shadow);
}

.detail-poster-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-copy h1 {
    margin: 12px 0 18px;
    font-size: clamp(2.6rem, 6vw, 5.8rem);
    line-height: 0.98;
    letter-spacing: -0.05em;
}

.detail-copy p {
    max-width: 820px;
    font-size: 1.18rem;
}

.detail-meta {
    margin: 22px 0 16px;
}

.player-section {
    margin-top: -42px;
}

.player-frame {
    position: relative;
    overflow: hidden;
    border: 10px solid rgba(255, 255, 255, 0.7);
    border-radius: 34px;
    background: #111827;
    box-shadow: 0 30px 90px rgba(17, 24, 39, 0.25);
}

.movie-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #111827;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 16px;
    align-content: center;
    color: white;
    text-align: center;
    background: linear-gradient(180deg, rgba(17, 24, 39, 0.15), rgba(17, 24, 39, 0.64));
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.player-play-button {
    display: grid;
    place-items: center;
    width: 92px;
    height: 92px;
    border: 0;
    border-radius: 999px;
    color: white;
    font-size: 2.1rem;
    background: linear-gradient(135deg, var(--candy-rose), #ffb347, var(--candy-mint));
    box-shadow: 0 18px 48px rgba(255, 141, 199, 0.38);
}

.player-overlay strong {
    font-size: clamp(1.4rem, 4vw, 2.6rem);
    text-shadow: 0 8px 24px rgba(0, 0, 0, 0.36);
}

.detail-content {
    padding: 44px 0 4px;
}

.glass-panel {
    border: 1px solid rgba(255, 179, 217, 0.25);
    border-radius: 30px;
    background: var(--glass);
    box-shadow: 0 14px 42px rgba(255, 179, 217, 0.14);
    backdrop-filter: blur(16px);
}

.prose-card {
    padding: 34px;
}

.prose-card h2 {
    margin: 0 0 12px;
    font-size: 1.65rem;
}

.prose-card h2:not(:first-child) {
    margin-top: 28px;
}

.prose-card p {
    margin: 0;
    font-size: 1.06rem;
}

.site-footer {
    margin-top: 70px;
    border-top: 1px solid rgba(255, 179, 217, 0.25);
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(18px);
}

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

.footer-logo {
    margin-bottom: 14px;
}

.site-footer h2 {
    margin: 0 0 14px;
    color: #be185d;
    font-size: 1.1rem;
}

.footer-links {
    display: grid;
    gap: 9px;
}

.footer-links a {
    color: var(--muted);
}

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

.search-page-form {
    margin-top: 24px;
    margin-left: 0;
}

@keyframes candy-fall {
    0% {
        transform: translateY(-12vh) rotate(0deg);
    }
    100% {
        transform: translateY(112vh) rotate(360deg);
    }
}

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

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

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

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

    .mobile-menu-button {
        display: block;
    }

    .hero-carousel {
        min-height: 760px;
    }

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

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

    .hero-poster,
    .detail-poster-card {
        width: min(310px, 78vw);
        margin: 0 auto;
    }

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

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

    .detail-hero-grid {
        gap: 28px;
    }
}

@media (max-width: 640px) {
    .section-container {
        width: min(100% - 22px, 1280px);
    }

    .site-logo {
        font-size: 1.15rem;
    }

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

    .hero-carousel {
        min-height: 700px;
    }

    .hero-copy h1,
    .detail-copy h1,
    .page-hero h1 {
        letter-spacing: -0.04em;
    }

    .hero-actions,
    .big-search {
        flex-direction: column;
    }

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

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

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

    .small-hero,
    .prose-card {
        padding: 24px;
    }

    .player-frame {
        border-width: 5px;
        border-radius: 22px;
    }
}

@media (max-width: 430px) {
    .movie-grid,
    .compact-grid,
    .ranking-grid {
        grid-template-columns: 1fr;
    }
}
