:root {
    --candy-pink: #ffb3d9;
    --candy-rose: #ff8dc7;
    --candy-orange: #ffb347;
    --candy-yellow: #ffe66d;
    --candy-mint: #a8e6ce;
    --candy-blue: #87ceeb;
    --ink: #1f2937;
    --muted: #6b7280;
    --line: rgba(255, 179, 217, 0.32);
    --panel: rgba(255, 255, 255, 0.82);
    --shadow: 0 18px 55px rgba(255, 141, 199, 0.22);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at 10% 0%, rgba(255, 179, 217, 0.32), transparent 32rem),
        radial-gradient(circle at 90% 12%, rgba(168, 230, 206, 0.28), transparent 26rem),
        linear-gradient(135deg, #fff5f8 0%, #fffdf1 46%, #effff8 100%);
    overflow-x: hidden;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.4) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.4) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.6), transparent 70%);
}

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

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

button,
input {
    font: inherit;
}

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

.glass-effect {
    background: var(--panel);
    backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 255, 255, 0.72);
    box-shadow: var(--shadow);
}

.gradient-text {
    background: linear-gradient(135deg, var(--candy-rose), var(--candy-orange), var(--candy-yellow), var(--candy-mint), var(--candy-blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--line);
}

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

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 28px;
    font-weight: 900;
    letter-spacing: -0.04em;
    white-space: nowrap;
}

.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 30px rgba(255, 141, 199, 0.45);
}

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

.desktop-nav a,
.mobile-panel a,
.footer-links a {
    font-weight: 700;
    color: #374151;
    transition: color 0.25s ease, transform 0.25s ease;
}

.desktop-nav a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
    color: var(--candy-rose);
    transform: translateY(-1px);
}

.header-search,
.mobile-search,
.wide-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-search input,
.mobile-search input,
.wide-search input,
.filter-panel input,
.search-page-form input {
    min-width: 0;
    border: 2px solid rgba(255, 179, 217, 0.45);
    border-radius: 999px;
    padding: 12px 18px;
    color: var(--ink);
    background: rgba(255, 255, 255, 0.78);
    outline: none;
    transition: border 0.25s ease, box-shadow 0.25s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.wide-search input:focus,
.filter-panel input:focus,
.search-page-form input:focus {
    border-color: var(--candy-rose);
    box-shadow: 0 0 0 5px rgba(255, 141, 199, 0.16);
}

.header-search button,
.mobile-search button,
.wide-search button,
.candy-button {
    border: 0;
    border-radius: 999px;
    padding: 12px 22px;
    font-weight: 800;
    color: white;
    background: linear-gradient(90deg, var(--candy-rose), var(--candy-orange), var(--candy-yellow));
    box-shadow: 0 14px 34px rgba(255, 141, 199, 0.36);
    cursor: pointer;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.wide-search button:hover,
.candy-button:hover {
    transform: translateY(-2px) scale(1.01);
    box-shadow: 0 18px 44px rgba(255, 141, 199, 0.48);
}

.ghost-button {
    border: 2px solid rgba(255, 255, 255, 0.76);
    border-radius: 999px;
    padding: 10px 20px;
    font-weight: 800;
    color: white;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(12px);
    transition: transform 0.25s ease, background 0.25s ease;
}

.ghost-button:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.24);
}

.mobile-toggle {
    display: none;
    margin-left: auto;
    border: 0;
    border-radius: 14px;
    padding: 10px 14px;
    color: var(--candy-rose);
    background: rgba(255, 179, 217, 0.14);
}

.mobile-panel {
    display: none;
    padding: 16px;
    border-top: 1px solid var(--line);
}

.mobile-panel.is-open {
    display: grid;
    gap: 14px;
}

.hero-carousel {
    position: relative;
    min-height: 650px;
    display: grid;
    align-items: center;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 179, 217, 0.24);
}

.hero-glow {
    position: absolute;
    width: 520px;
    height: 520px;
    right: -120px;
    top: 40px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 230, 109, 0.5), rgba(255, 141, 199, 0.18), transparent 70%);
    filter: blur(10px);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
    align-items: center;
    gap: 56px;
    width: min(1280px, calc(100% - 32px));
    margin-inline: auto;
    opacity: 0;
    transform: translateY(24px) scale(0.98);
    pointer-events: none;
    transition: opacity 0.55s ease, transform 0.55s ease;
}

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 12% -10% 8% 28%;
    border-radius: 42px;
    background-image: linear-gradient(100deg, rgba(17, 24, 39, 0.68), rgba(17, 24, 39, 0.18)), var(--hero-image);
    background-size: cover;
    background-position: center;
    filter: blur(34px) saturate(1.08);
    opacity: 0.46;
}

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

.hero-media {
    position: relative;
    overflow: hidden;
    min-height: 460px;
    border-radius: 34px;
    background: linear-gradient(135deg, rgba(255, 179, 217, 0.56), rgba(255, 230, 109, 0.36), rgba(168, 230, 206, 0.44));
    box-shadow: 0 30px 80px rgba(31, 41, 55, 0.22);
}

.hero-media::after,
.poster-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.28), transparent 50%);
    pointer-events: none;
}

.hero-image,
.poster-image,
.tile-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 0.35s ease, transform 0.5s ease;
}

.hero-image.is-loaded,
.poster-image.is-loaded,
.tile-thumb.is-loaded {
    opacity: 1;
}

.hero-copy {
    position: relative;
    z-index: 1;
    padding: 40px;
    border-radius: 34px;
    color: white;
    background: linear-gradient(135deg, rgba(17, 24, 39, 0.9), rgba(88, 28, 135, 0.58));
    box-shadow: 0 28px 80px rgba(31, 41, 55, 0.25);
}

.hero-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--candy-rose);
}

.hero-copy h1,
.hero-copy h2,
.sub-hero h1,
.section-heading h2,
.ranking-head h2,
.content-card h2,
.detail-copy h1 {
    margin: 0;
    letter-spacing: -0.05em;
    line-height: 1.05;
}

.hero-copy h1,
.hero-copy h2 {
    font-size: clamp(40px, 7vw, 82px);
}

.hero-copy p,
.sub-hero p,
.section-heading p,
.content-card p,
.detail-copy p,
.site-footer p {
    color: var(--muted);
    line-height: 1.8;
}

.hero-copy p {
    max-width: 720px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
}

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

.compact-actions {
    margin-top: 22px;
}

.hero-controls {
    position: absolute;
    right: max(16px, calc((100% - 1280px) / 2));
    bottom: 72px;
    z-index: 3;
    display: flex;
    gap: 12px;
}

.hero-controls button {
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 50%;
    font-size: 32px;
    color: white;
    background: rgba(31, 41, 55, 0.62);
    backdrop-filter: blur(12px);
    cursor: pointer;
}

.hero-dots {
    position: absolute;
    left: max(16px, calc((100% - 1280px) / 2));
    bottom: 82px;
    z-index: 3;
    display: flex;
    gap: 10px;
}

.hero-dots button {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(31, 41, 55, 0.25);
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
    width: 34px;
    background: var(--candy-rose);
}

.quick-search-panel {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 24px;
    align-items: center;
    margin-top: -42px;
    position: relative;
    z-index: 5;
    padding: 28px;
    border-radius: 28px;
}

.quick-search-panel h2 {
    margin: 0 0 8px;
    font-size: clamp(24px, 3vw, 36px);
}

.quick-search-panel p {
    margin: 0;
    color: var(--muted);
}

.wide-search input {
    flex: 1;
}

.page-section {
    padding-block: 72px;
}

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

.section-heading h2,
.ranking-head h2,
.sub-hero h1 {
    font-size: clamp(30px, 5vw, 56px);
}

.section-more,
.ranking-head a {
    color: var(--candy-rose);
    font-weight: 900;
}

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

.category-tile {
    overflow: hidden;
    border-radius: 28px;
    padding: 18px;
    min-height: 230px;
    background: rgba(255, 255, 255, 0.68);
    border: 1px solid rgba(255, 255, 255, 0.82);
    box-shadow: 0 16px 45px rgba(255, 179, 217, 0.22);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover,
.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 22px 60px rgba(255, 141, 199, 0.32);
}

.tile-thumbs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    height: 96px;
    margin-bottom: 16px;
}

.tile-thumb {
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255, 179, 217, 0.58), rgba(168, 230, 206, 0.45));
}

.category-tile span {
    display: block;
    margin-bottom: 8px;
    font-size: 22px;
    font-weight: 900;
}

.category-tile p {
    margin: 0;
    color: var(--muted);
    line-height: 1.7;
}

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

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

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

.movie-card {
    overflow: hidden;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.86);
    box-shadow: 0 12px 36px rgba(31, 41, 55, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card-link {
    display: grid;
    min-height: 100%;
}

.poster-frame {
    position: relative;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    background: linear-gradient(135deg, rgba(255, 179, 217, 0.66), rgba(255, 230, 109, 0.42), rgba(168, 230, 206, 0.5));
}

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

.play-chip {
    position: absolute;
    right: 12px;
    bottom: 12px;
    z-index: 2;
    border-radius: 999px;
    padding: 7px 12px;
    color: white;
    font-size: 13px;
    font-weight: 900;
    background: linear-gradient(90deg, var(--candy-rose), var(--candy-orange));
}

.rank-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 2;
    display: grid;
    place-items: center;
    min-width: 34px;
    height: 34px;
    border-radius: 12px;
    color: white;
    background: rgba(17, 24, 39, 0.78);
    backdrop-filter: blur(10px);
}

.movie-card-body {
    display: grid;
    gap: 10px;
    padding: 16px;
}

.movie-meta-line,
.card-stats,
.detail-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    color: var(--muted);
    font-size: 13px;
}

.movie-meta-line span,
.card-stats span,
.detail-stats span {
    border-radius: 999px;
    padding: 4px 9px;
    background: rgba(255, 179, 217, 0.18);
}

.movie-card h3 {
    margin: 0;
    font-size: 19px;
    line-height: 1.35;
}

.movie-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.tag-row span,
.detail-tags span,
.filter-tags a {
    border-radius: 999px;
    padding: 5px 10px;
    color: #be185d;
    font-size: 12px;
    font-weight: 800;
    background: rgba(255, 179, 217, 0.22);
}

.ranking-panel {
    position: sticky;
    top: 96px;
    border-radius: 30px;
    padding: 24px;
}

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

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

.rank-row {
    display: grid;
    grid-template-columns: 42px 1fr auto auto;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.58);
    transition: background 0.25s ease, transform 0.25s ease;
}

.rank-row:hover {
    transform: translateX(4px);
    background: rgba(255, 179, 217, 0.18);
}

.rank-number {
    color: var(--candy-rose);
    font-weight: 900;
}

.rank-title {
    min-width: 0;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rank-category,
.rank-score {
    color: var(--muted);
    font-size: 13px;
}

.filter-panel,
.search-summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 24px;
    padding: 18px;
    border-radius: 24px;
}

.filter-panel input {
    width: min(520px, 100%);
}

.sub-hero {
    padding-top: 76px;
    padding-bottom: 34px;
}

.sub-hero h1 {
    max-width: 980px;
}

.sub-hero p {
    max-width: 780px;
    font-size: 18px;
}

.detail-hero {
    padding: 60px 0 42px;
    background: radial-gradient(circle at 80% 10%, rgba(255, 179, 217, 0.28), transparent 28rem);
}

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

.detail-poster {
    border-radius: 32px;
    box-shadow: 0 28px 76px rgba(31, 41, 55, 0.18);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--muted);
    font-weight: 700;
}

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

.detail-copy h1 {
    font-size: clamp(36px, 6vw, 70px);
}

.detail-copy p {
    max-width: 780px;
    font-size: 18px;
}

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

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 34px;
    padding: 10px;
    background: rgba(17, 24, 39, 0.94);
}

.movie-player {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 26px;
    background: #050505;
}

.player-overlay {
    position: absolute;
    inset: 10px;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    border: 0;
    border-radius: 26px;
    color: white;
    background: linear-gradient(135deg, rgba(17, 24, 39, 0.32), rgba(190, 24, 93, 0.22));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.player-start {
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 50%;
    padding-left: 6px;
    font-size: 34px;
    color: white;
    background: linear-gradient(135deg, var(--candy-rose), var(--candy-orange), var(--candy-yellow));
    box-shadow: 0 20px 50px rgba(255, 141, 199, 0.5);
}

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

.detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.content-card {
    border-radius: 28px;
    padding: 28px;
}

.content-card p {
    margin-bottom: 0;
    font-size: 17px;
}

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

.site-footer {
    margin-top: 50px;
    padding: 42px 0;
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.46);
}

.footer-grid {
    display: flex;
    justify-content: space-between;
    gap: 28px;
}

.footer-grid p {
    max-width: 680px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-content: start;
    justify-content: end;
}

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

@media (max-width: 1080px) {
    .desktop-nav,
    .header-search {
        display: none;
    }

    .mobile-toggle {
        display: inline-flex;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        gap: 22px;
        padding-block: 34px;
    }

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

    .hero-media {
        min-height: 360px;
    }

    .quick-search-panel,
    .split-layout,
    .detail-grid,
    .detail-content {
        grid-template-columns: 1fr;
    }

    .ranking-panel {
        position: static;
    }

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

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

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

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

    .hero-copy {
        padding: 24px;
    }

    .hero-media {
        min-height: 300px;
    }

    .hero-controls,
    .hero-dots {
        bottom: 24px;
    }

    .quick-search-panel {
        margin-top: 20px;
        padding: 20px;
    }

    .wide-search,
    .filter-panel,
    .footer-grid,
    .section-heading {
        align-items: stretch;
        flex-direction: column;
    }

    .category-grid,
    .movie-grid,
    .featured-grid,
    .related-grid {
        grid-template-columns: 1fr;
    }

    .rank-row {
        grid-template-columns: 36px 1fr auto;
    }

    .rank-category {
        display: none;
    }

    .detail-grid {
        gap: 24px;
    }

    .detail-poster {
        max-width: 280px;
        margin-inline: auto;
    }
}
