:root {
    color-scheme: light;
    --rose-50: #fff1f2;
    --rose-100: #ffe4e6;
    --rose-500: #f43f5e;
    --rose-600: #e11d48;
    --orange-400: #fb923c;
    --orange-500: #f97316;
    --amber-400: #fbbf24;
    --text: #111827;
    --muted: #6b7280;
    --soft: #f9fafb;
    --line: rgba(17, 24, 39, 0.1);
    --shadow: 0 20px 45px rgba(244, 63, 94, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(251, 146, 60, 0.2), transparent 32rem),
        radial-gradient(circle at top right, rgba(244, 63, 94, 0.18), transparent 28rem),
        linear-gradient(135deg, #fff7ed 0%, #fff1f2 45%, #fdf2f8 100%);
}

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: 60;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.72);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.header-inner {
    width: min(1180px, calc(100% - 32px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 168px;
}

.brand-icon {
    width: 42px;
    height: 42px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    color: #fff;
    background: linear-gradient(135deg, var(--rose-500), var(--orange-400));
    box-shadow: 0 12px 28px rgba(244, 63, 94, 0.28);
}

.brand-text {
    display: grid;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 22px;
    letter-spacing: 0.02em;
    background: linear-gradient(90deg, var(--rose-600), var(--orange-500));
    -webkit-background-clip: text;
    color: transparent;
}

.brand-text small {
    color: var(--muted);
    font-size: 12px;
}

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

.nav-link {
    padding: 10px 15px;
    border-radius: 12px;
    color: #374151;
    font-weight: 700;
    transition: 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #fff;
    background: linear-gradient(90deg, var(--rose-500), var(--orange-400));
    box-shadow: 0 12px 24px rgba(244, 63, 94, 0.22);
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: #374151;
    background: #fff1f2;
}

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

.mobile-panel.is-open {
    display: block;
}

.mobile-panel nav {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 12px 0 18px;
    display: grid;
    gap: 8px;
}

.mobile-cats {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 8px;
}

.mobile-cats a {
    padding: 7px 12px;
    color: var(--rose-600);
    background: var(--rose-50);
    border-radius: 999px;
    font-size: 13px;
}

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

.hero {
    position: relative;
    min-height: 610px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(135deg, var(--rose-500), var(--orange-400), var(--amber-400));
}

.hero-track,
.hero-slide,
.hero-slide img,
.hero-shade {
    position: absolute;
    inset: 0;
}

.hero-slide {
    opacity: 0;
    transition: opacity 0.7s ease;
}

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

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

.hero-shade {
    background:
        linear-gradient(90deg, rgba(8, 13, 31, 0.82), rgba(8, 13, 31, 0.45), rgba(8, 13, 31, 0.08)),
        linear-gradient(0deg, rgba(8, 13, 31, 0.9), transparent 55%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 610px;
    margin: 0 auto;
    padding: 84px 0 64px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: end;
    gap: 44px;
}

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

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    color: #fde68a;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(12px);
    font-weight: 800;
}

.hero h1,
.hero h2 {
    margin: 0;
    font-size: clamp(40px, 7vw, 74px);
    line-height: 1.03;
    letter-spacing: -0.05em;
}

.hero p {
    margin: 20px 0 0;
    max-width: 660px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
    line-height: 1.8;
}

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

.primary-btn,
.secondary-btn,
.ghost-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 999px;
    font-weight: 800;
    transition: 0.25s ease;
}

.primary-btn {
    color: var(--rose-600);
    background: #fff;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.primary-btn:hover {
    transform: translateY(-2px);
    background: #fff7ed;
}

.secondary-btn {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(10px);
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.24);
}

.hero-panel {
    padding: 22px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(20px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

.hero-panel h3 {
    margin: 0 0 16px;
    font-size: 18px;
}

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

.hero-mini {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.13);
    transition: 0.25s ease;
}

.hero-mini:hover {
    transform: translateX(4px);
    background: rgba(255, 255, 255, 0.2);
}

.hero-mini img {
    width: 72px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 12px;
}

.hero-mini strong {
    display: block;
    margin-bottom: 4px;
}

.hero-mini span {
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
}

.hero-control {
    position: absolute;
    z-index: 4;
    top: 50%;
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
    cursor: pointer;
}

.hero-control:hover {
    background: rgba(255, 255, 255, 0.28);
}

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

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

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

.hero-dots button {
    width: 10px;
    height: 10px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.46);
    cursor: pointer;
}

.hero-dots button.is-active {
    width: 28px;
    background: #fff;
}

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

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

.section-header span {
    display: inline-block;
    margin-bottom: 8px;
    color: var(--rose-600);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.12em;
}

.section-header h1,
.section-header h2 {
    margin: 0;
    color: #111827;
    font-size: clamp(28px, 4vw, 42px);
    letter-spacing: -0.03em;
}

.section-header p {
    max-width: 700px;
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

.section-more {
    color: var(--rose-600);
    font-weight: 900;
}

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

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

.movie-card {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.08);
    transition: 0.28s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fff1f2, #ffedd5);
}

.movie-card-small .poster-link {
    aspect-ratio: 16 / 11;
}

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

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

.poster-gradient {
    position: absolute;
    inset: 0;
    opacity: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.66), transparent 60%);
    transition: opacity 0.25s ease;
}

.movie-card:hover .poster-gradient {
    opacity: 1;
}

.type-pill,
.rank-badge {
    position: absolute;
    color: #fff;
    background: rgba(0, 0, 0, 0.66);
    backdrop-filter: blur(8px);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.type-pill {
    right: 12px;
    bottom: 12px;
    padding: 6px 10px;
}

.rank-badge {
    left: 12px;
    top: 12px;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, var(--rose-500), var(--orange-400));
}

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

.category-pill,
.tag-pill {
    display: inline-flex;
    align-items: center;
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--rose-600);
    background: var(--rose-50);
    font-size: 12px;
    font-weight: 800;
}

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

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

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

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
    color: #6b7280;
    font-size: 13px;
}

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

.category-box {
    position: relative;
    min-height: 150px;
    overflow: hidden;
    padding: 22px;
    border-radius: 24px;
    color: #fff;
    background: linear-gradient(135deg, var(--rose-500), var(--orange-400));
    box-shadow: 0 18px 34px rgba(244, 63, 94, 0.18);
}

.category-box:nth-child(2n) {
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
}

.category-box:nth-child(3n) {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
}

.category-box h3 {
    margin: 0 0 10px;
    font-size: 22px;
}

.category-box p {
    margin: 0;
    color: rgba(255, 255, 255, 0.84);
    line-height: 1.65;
}

.page-hero {
    margin-top: 34px;
    padding: 46px;
    border-radius: 32px;
    color: #fff;
    background:
        radial-gradient(circle at right top, rgba(255, 255, 255, 0.28), transparent 18rem),
        linear-gradient(135deg, var(--rose-500), var(--orange-400));
    box-shadow: var(--shadow);
}

.page-hero h1 {
    max-width: 780px;
    margin: 0;
    font-size: clamp(34px, 5vw, 58px);
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 760px;
    margin: 16px 0 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.8;
}

.filter-bar,
.search-panel {
    margin: 28px 0;
    padding: 18px;
    display: grid;
    grid-template-columns: 1fr auto auto;
    gap: 12px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.07);
}

.filter-bar input,
.filter-bar select,
.search-panel input,
.search-panel select {
    min-height: 48px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0 14px;
    background: #fff;
    outline: none;
}

.filter-bar input:focus,
.filter-bar select:focus,
.search-panel input:focus,
.search-panel select:focus {
    border-color: var(--rose-500);
    box-shadow: 0 0 0 4px rgba(244, 63, 94, 0.12);
}

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

.rank-row {
    display: grid;
    grid-template-columns: 112px 56px 1fr auto;
    gap: 18px;
    align-items: center;
    padding: 14px;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.06);
}

.rank-cover {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 16px;
    background: #fff1f2;
}

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

.rank-number {
    width: 48px;
    height: 48px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    font-weight: 900;
    background: linear-gradient(135deg, var(--rose-500), var(--orange-400));
}

.rank-info h3 {
    margin: 0 0 8px;
    font-size: 20px;
}

.rank-info p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.rank-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 10px;
    color: #6b7280;
    font-size: 13px;
}

.ghost-link {
    color: #fff;
    background: linear-gradient(90deg, var(--rose-500), var(--orange-400));
}

.detail-hero {
    margin-top: 34px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    align-items: stretch;
}

.player-card,
.detail-side,
.text-card {
    overflow: hidden;
    border-radius: 28px;
    background: #fff;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.player-wrap {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.player-wrap video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    background: #020617;
}

.play-layer {
    position: absolute;
    inset: 0;
    border: 0;
    color: #fff;
    background:
        radial-gradient(circle at center, rgba(244, 63, 94, 0.28), transparent 15rem),
        linear-gradient(0deg, rgba(2, 6, 23, 0.52), rgba(2, 6, 23, 0.16));
    cursor: pointer;
    display: grid;
    place-items: center;
    transition: opacity 0.24s ease;
}

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

.play-ring {
    width: 88px;
    height: 88px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: var(--rose-600);
    background: #fff;
    box-shadow: 0 22px 48px rgba(0, 0, 0, 0.28);
    font-size: 30px;
}

.player-info {
    padding: 24px;
}

.player-info h1 {
    margin: 0 0 12px;
    font-size: clamp(30px, 5vw, 46px);
    line-height: 1.15;
}

.player-info p {
    margin: 0;
    color: var(--muted);
    line-height: 1.8;
}

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

.detail-side-body {
    padding: 22px;
}

.detail-meta {
    display: grid;
    gap: 11px;
    margin-top: 18px;
}

.detail-meta div {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding-bottom: 11px;
    border-bottom: 1px solid var(--line);
    color: #374151;
}

.detail-meta span:first-child {
    color: var(--muted);
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 18px;
}

.detail-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    margin-top: 28px;
}

.text-card {
    padding: 28px;
}

.text-card h2 {
    margin: 0 0 16px;
    font-size: 26px;
}

.text-card p {
    margin: 0 0 22px;
    color: #374151;
    line-height: 1.95;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 26px 0 0;
    color: var(--muted);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--rose-600);
    font-weight: 700;
}

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

.side-item {
    display: grid;
    grid-template-columns: 82px 1fr;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.side-item img {
    width: 82px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 12px;
}

.side-item strong {
    display: block;
    margin-bottom: 6px;
}

.side-item span {
    color: var(--muted);
    font-size: 13px;
}

.search-results {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 22px;
    margin-top: 26px;
}

.empty-state {
    padding: 38px;
    border-radius: 22px;
    color: var(--muted);
    background: #fff;
    text-align: center;
}

.site-footer {
    margin-top: 70px;
    padding: 44px 0;
    color: rgba(255, 255, 255, 0.84);
    background: #111827;
}

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

.site-footer h2 {
    margin: 0 0 10px;
    color: #fff;
}

.site-footer p {
    max-width: 620px;
    margin: 0;
    line-height: 1.8;
}

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

.footer-links a,
.footer-cats a {
    color: rgba(255, 255, 255, 0.78);
}

.footer-cats {
    grid-column: 1 / -1;
}

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

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

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

    .hero-panel {
        display: none;
    }
}

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

    .mobile-toggle {
        display: grid;
        place-items: center;
    }

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

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

    .hero-control {
        display: none;
    }

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

    .category-strip,
    .filter-bar,
    .search-panel,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .section-header {
        align-items: start;
        flex-direction: column;
    }

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

    .rank-number,
    .rank-row .ghost-link {
        display: none;
    }

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

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

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