:root {
    --color-rose-50: #fff1f2;
    --color-rose-100: #ffe4e6;
    --color-rose-600: #e11d48;
    --color-rose-700: #be123c;
    --color-amber-50: #fffbeb;
    --color-amber-500: #f59e0b;
    --color-gray-50: #f9fafb;
    --color-gray-100: #f3f4f6;
    --color-gray-200: #e5e7eb;
    --color-gray-500: #6b7280;
    --color-gray-600: #4b5563;
    --color-gray-700: #374151;
    --color-gray-800: #1f2937;
    --color-gray-900: #111827;
    --shadow-soft: 0 10px 25px rgba(17, 24, 39, 0.08);
    --shadow-strong: 0 25px 50px rgba(17, 24, 39, 0.18);
    --radius-large: 24px;
    --radius-medium: 18px;
    --radius-small: 12px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--color-gray-800);
    background: linear-gradient(180deg, var(--color-gray-50), #ffffff 42%, var(--color-rose-50));
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    backdrop-filter: blur(16px);
}

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

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--color-gray-900);
    font-size: 21px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.logo-mark {
    display: inline-grid;
    width: 34px;
    height: 34px;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-rose-600), var(--color-amber-500));
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(225, 29, 72, 0.24);
}

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

.desktop-nav a,
.mobile-panel a {
    color: var(--color-gray-700);
    font-weight: 650;
    padding: 10px 14px;
    border-radius: 999px;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-panel a:hover,
.mobile-panel a.is-active {
    color: var(--color-rose-700);
    background: var(--color-rose-50);
}

.mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: var(--color-gray-100);
    cursor: pointer;
}

.mobile-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 4px auto;
    background: var(--color-gray-800);
    border-radius: 99px;
}

.mobile-panel {
    display: none;
    border-top: 1px solid var(--color-gray-200);
    background: #ffffff;
}

.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: 6px;
}

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

.hero {
    position: relative;
    min-height: 540px;
    height: 72vh;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(135deg, #881337, #78350f);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s ease;
}

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

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-layer {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 78% 18%, rgba(244, 63, 94, 0.28), transparent 28%),
        linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.55) 46%, rgba(0, 0, 0, 0.12));
}

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

.hero-copy {
    max-width: 720px;
    padding-top: 36px;
}

.hero-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 7px 14px;
    color: #fff;
    background: rgba(225, 29, 72, 0.88);
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    box-shadow: 0 14px 30px rgba(225, 29, 72, 0.22);
}

.hero h1 {
    margin: 0;
    font-size: clamp(42px, 7vw, 74px);
    line-height: 0.98;
    letter-spacing: -0.055em;
}

.hero p {
    max-width: 650px;
    margin: 22px 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(17px, 2.2vw, 22px);
}

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

.button-primary,
.button-secondary,
.button-light {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border: 0;
    border-radius: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button-primary {
    color: #ffffff;
    background: var(--color-rose-600);
    box-shadow: 0 16px 30px rgba(225, 29, 72, 0.24);
}

.button-primary:hover,
.play-button:hover {
    background: var(--color-rose-700);
    transform: translateY(-2px);
}

.button-secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.26);
    backdrop-filter: blur(8px);
}

.button-light {
    color: var(--color-rose-700);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.hero-controls button {
    position: absolute;
    z-index: 3;
    top: 50%;
    display: grid;
    width: 46px;
    height: 46px;
    place-items: center;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(8px);
    cursor: pointer;
    transform: translateY(-50%);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

.hero-dots button.is-active {
    width: 34px;
    background: #ffffff;
}

.section {
    padding: 70px 0;
}

.section-soft {
    background: linear-gradient(90deg, var(--color-amber-50), var(--color-rose-50));
}

.section-gray {
    background: var(--color-gray-50);
}

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

.section-title h2,
.page-title h1 {
    margin: 0;
    color: var(--color-gray-900);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.1;
    letter-spacing: -0.035em;
}

.section-title p,
.page-title p {
    max-width: 780px;
    margin: 10px 0 0;
    color: var(--color-gray-600);
}

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

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

.movie-card {
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.95);
    border-radius: var(--radius-medium);
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    border-color: rgba(225, 29, 72, 0.28);
    box-shadow: var(--shadow-strong);
    transform: translateY(-5px);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, var(--color-rose-100), var(--color-amber-50));
}

.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-link::after {
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    content: "";
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent);
}

.poster-badge,
.poster-year {
    position: absolute;
    z-index: 2;
    top: 12px;
    padding: 5px 10px;
    color: #ffffff;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.poster-badge {
    left: 12px;
    background: rgba(225, 29, 72, 0.92);
}

.poster-year {
    right: 12px;
    background: rgba(17, 24, 39, 0.65);
    backdrop-filter: blur(6px);
}

.poster-action {
    position: absolute;
    z-index: 2;
    left: 14px;
    bottom: 14px;
    opacity: 0;
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
    transform: translateY(8px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .poster-action {
    opacity: 1;
    transform: translateY(0);
}

.card-body {
    padding: 16px;
}

.card-body h3 {
    margin: 0;
    color: var(--color-gray-900);
    font-size: 18px;
    line-height: 1.25;
}

.card-body h3 a:hover {
    color: var(--color-rose-700);
}

.card-body p {
    display: -webkit-box;
    min-height: 46px;
    margin: 10px 0 0;
    overflow: hidden;
    color: var(--color-gray-600);
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-meta,
.rank-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 13px;
    color: var(--color-gray-500);
    font-size: 13px;
}

.card-meta span,
.card-meta a,
.rank-meta span,
.detail-meta span {
    padding: 4px 8px;
    background: var(--color-gray-100);
    border-radius: 999px;
}

.card-meta a {
    color: var(--color-rose-700);
    background: var(--color-rose-50);
    font-weight: 700;
}

.horizontal-scroll {
    display: flex;
    gap: 22px;
    overflow-x: auto;
    padding: 4px 4px 22px;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
}

.horizontal-scroll .movie-card {
    flex: 0 0 280px;
    scroll-snap-align: start;
}

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

.category-card {
    min-height: 188px;
    padding: 22px;
    color: var(--color-gray-900);
    background:
        radial-gradient(circle at top right, rgba(225, 29, 72, 0.15), transparent 36%),
        #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.95);
    border-radius: var(--radius-medium);
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-card strong {
    display: block;
    font-size: 22px;
    line-height: 1.2;
}

.category-card p {
    margin: 10px 0 18px;
    color: var(--color-gray-600);
    font-size: 14px;
}

.category-count {
    display: inline-flex;
    color: var(--color-rose-700);
    font-weight: 800;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(135deg, #881337, #78350f);
}

.page-hero {
    padding: 76px 0 64px;
}

.page-hero::before,
.detail-hero::before {
    position: absolute;
    inset: 0;
    content: "";
    background:
        radial-gradient(circle at 85% 20%, rgba(251, 191, 36, 0.22), transparent 28%),
        radial-gradient(circle at 20% 15%, rgba(244, 63, 94, 0.22), transparent 32%);
}

.page-title,
.detail-hero-inner {
    position: relative;
    z-index: 1;
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

.breadcrumbs a:hover {
    color: #ffffff;
}

.filter-panel {
    margin: 34px auto 30px;
    padding: 20px;
    background: #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.95);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-soft);
}

.filter-search {
    display: flex;
    gap: 12px;
}

.filter-search input {
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    color: var(--color-gray-900);
    border: 1px solid var(--color-gray-200);
    border-radius: 14px;
    outline: 0;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filter-search input:focus {
    border-color: rgba(225, 29, 72, 0.6);
    box-shadow: 0 0 0 4px rgba(225, 29, 72, 0.12);
}

.filter-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 130px;
    padding: 0 16px;
    color: #ffffff;
    background: var(--color-rose-600);
    border-radius: 14px;
    font-weight: 800;
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.filter-button {
    min-height: 36px;
    padding: 0 13px;
    color: var(--color-gray-700);
    background: var(--color-gray-100);
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 750;
}

.filter-button.is-active,
.filter-button:hover {
    color: #ffffff;
    background: var(--color-rose-600);
}

.filter-status {
    margin-top: 14px;
    color: var(--color-gray-500);
    font-size: 14px;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 78px 54px minmax(0, 1fr) 64px;
    align-items: center;
    gap: 18px;
    padding: 12px 16px 12px 12px;
    border-radius: var(--radius-medium);
}

.rank-cover {
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 14px;
    background: var(--color-rose-50);
}

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

.rank-index {
    color: var(--color-rose-600);
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.rank-info h3 {
    margin: 0;
    color: var(--color-gray-900);
    font-size: 18px;
}

.rank-info p {
    margin: 8px 0 0;
    color: var(--color-gray-600);
    font-size: 14px;
}

.rank-score {
    display: grid;
    width: 52px;
    height: 52px;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-rose-600), var(--color-amber-500));
    border-radius: 16px;
    font-size: 20px;
    font-weight: 900;
}

.detail-hero {
    padding: 62px 0;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0.32;
    object-fit: cover;
    filter: blur(2px);
    transform: scale(1.04);
}

.detail-hero::after {
    position: absolute;
    inset: 0;
    content: "";
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.48));
}

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

.detail-layout {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 32px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    border: 4px solid rgba(255, 255, 255, 0.22);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-strong);
}

.detail-poster img {
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.detail-info h1 {
    margin: 0;
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.05;
    letter-spacing: -0.045em;
}

.detail-info p {
    max-width: 820px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
}

.detail-meta span {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.tag-list span {
    padding: 7px 11px;
    color: #ffffff;
    background: rgba(225, 29, 72, 0.82);
    border-radius: 999px;
    font-size: 13px;
    font-weight: 750;
}

.player-section {
    padding-top: 56px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    background: #050505;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-strong);
}

.video-player {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
    outline: 0;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: #ffffff;
    border: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.52));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-button {
    display: grid;
    width: 82px;
    height: 82px;
    place-items: center;
    color: #ffffff;
    background: var(--color-rose-600);
    border-radius: 50%;
    font-size: 30px;
    box-shadow: 0 22px 42px rgba(225, 29, 72, 0.32);
}

.player-message {
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

.article-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding: 48px 0;
}

.content-card {
    padding: 28px;
    background: #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.95);
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-soft);
}

.content-card h2 {
    margin: 0 0 14px;
    color: var(--color-gray-900);
    font-size: 24px;
}

.content-card p {
    margin: 0;
    color: var(--color-gray-700);
    line-height: 1.85;
}

.site-footer {
    margin-top: 70px;
    background: linear-gradient(180deg, var(--color-gray-50), var(--color-gray-100));
    border-top: 1px solid var(--color-gray-200);
}

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

.footer-inner p {
    max-width: 460px;
    color: var(--color-gray-600);
}

.footer-inner h2 {
    margin: 0 0 14px;
    color: var(--color-gray-900);
    font-size: 16px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.footer-links a {
    color: var(--color-gray-600);
    background: #ffffff;
    border-radius: 999px;
    padding: 6px 11px;
    font-size: 14px;
}

.footer-links a:hover {
    color: var(--color-rose-700);
}

.empty-state {
    display: none;
    padding: 24px;
    color: var(--color-gray-600);
    text-align: center;
    background: #ffffff;
    border-radius: var(--radius-medium);
    box-shadow: var(--shadow-soft);
}

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

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

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

    .mobile-toggle {
        display: block;
    }

    .hero {
        min-height: 620px;
    }

    .hero-controls button {
        display: none;
    }

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

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

    .detail-layout,
    .article-section,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .detail-poster {
        width: min(230px, 70vw);
    }

    .filter-search {
        flex-direction: column;
    }

    .rank-row {
        grid-template-columns: 62px 42px minmax(0, 1fr);
    }

    .rank-score {
        display: none;
    }
}

@media (max-width: 560px) {
    .nav-shell,
    .container,
    .hero-content,
    .detail-hero-inner,
    .footer-inner {
        width: min(100% - 24px, 1180px);
    }

    .site-logo {
        font-size: 18px;
    }

    .hero {
        min-height: 590px;
    }

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

    .horizontal-scroll .movie-card {
        flex-basis: 245px;
    }

    .rank-row {
        grid-template-columns: 56px minmax(0, 1fr);
        gap: 12px;
    }

    .rank-index {
        display: none;
    }
}
