:root {
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-600: #2563eb;
    --blue-700: #1d4ed8;
    --indigo-50: #eef2ff;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    --white: #ffffff;
    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08);
    --shadow-md: 0 10px 24px rgba(15, 23, 42, 0.10);
    --shadow-xl: 0 24px 50px rgba(15, 23, 42, 0.18);
    --radius-lg: 18px;
    --radius-xl: 24px;
    --container: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    color: var(--slate-900);
    background: var(--slate-50);
    line-height: 1.6;
}

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: var(--shadow-sm);
}

.top-nav {
    height: 68px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 20px;
    color: var(--slate-900);
    white-space: nowrap;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-600), #06b6d4);
    box-shadow: 0 10px 18px rgba(37, 99, 235, 0.25);
    font-size: 13px;
}

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

.nav-link {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    color: var(--slate-700);
    font-weight: 600;
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--blue-700);
    background: var(--blue-50);
}

.header-search,
.mobile-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    border: 1px solid var(--slate-200);
    background: var(--white);
    border-radius: 999px;
}

.header-search input,
.mobile-search input {
    width: 190px;
    border: 0;
    outline: 0;
    padding: 10px 14px;
    background: transparent;
}

.header-search button,
.mobile-search button {
    border: 0;
    padding: 10px 16px;
    color: var(--white);
    background: var(--blue-600);
    cursor: pointer;
}

.mobile-menu-button {
    display: none;
    margin-left: auto;
    border: 0;
    background: transparent;
    color: var(--slate-700);
    font-size: 26px;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 16px;
}

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

.mobile-link {
    display: block;
    padding: 12px 14px;
    border-radius: 12px;
    color: var(--slate-700);
    font-weight: 600;
}

.mobile-link:hover,
.mobile-link.is-active {
    color: var(--blue-700);
    background: var(--blue-50);
}

.mobile-search {
    margin-top: 10px;
}

.mobile-search input {
    width: 100%;
    flex: 1;
}

.hero-carousel {
    position: relative;
    height: 620px;
    overflow: hidden;
    background: var(--slate-900);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    background-size: cover;
    background-position: center;
    transition: opacity 0.7s ease;
}

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

.hero-inner {
    height: 100%;
    display: flex;
    align-items: center;
}

.hero-copy {
    max-width: 720px;
    color: var(--white);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: #bfdbfe;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.eyebrow.dark {
    color: var(--blue-600);
}

.hero-copy h1 {
    margin: 0 0 20px;
    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.hero-copy p {
    max-width: 650px;
    margin: 0 0 24px;
    color: #e5e7eb;
    font-size: clamp(17px, 2vw, 22px);
}

.hero-tags,
.card-tags,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-tags span {
    padding: 8px 14px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.17);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    backdrop-filter: blur(12px);
    font-weight: 600;
}

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

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

.primary-button {
    color: var(--white);
    background: var(--blue-600);
    box-shadow: 0 18px 30px rgba(37, 99, 235, 0.34);
}

.primary-button:hover {
    background: var(--blue-700);
    transform: translateY(-2px) scale(1.02);
}

.ghost-button {
    color: var(--white);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(12px);
}

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

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

.hero-dot {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.48);
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.is-active {
    width: 36px;
    background: var(--white);
}

.section-block {
    padding: 64px 0;
}

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

.section-heading h2,
.page-hero h1 {
    margin: 0;
    font-size: clamp(30px, 4vw, 42px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.text-link {
    color: var(--blue-600);
    font-weight: 800;
}

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

.movie-grid {
    display: grid;
    gap: 24px;
}

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

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

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-sm);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

.card-link {
    display: block;
    height: 100%;
}

.poster-frame {
    position: relative;
    height: 230px;
    overflow: hidden;
    background-color: var(--slate-200);
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

.movie-card:hover .poster-frame {
    transform: scale(1.035);
}

.duration-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    padding: 5px 10px;
    color: var(--white);
    background: var(--blue-600);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.play-hover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    color: var(--white);
    background: rgba(0, 0, 0, 0.28);
    font-size: 48px;
    transition: opacity 0.2s ease;
}

.movie-card:hover .play-hover {
    opacity: 1;
}

.card-body {
    padding: 18px;
}

.card-body h3 {
    min-height: 3em;
    margin: 0 0 10px;
    font-size: 17px;
    line-height: 1.45;
    transition: color 0.2s ease;
}

.movie-card:hover .card-body h3 {
    color: var(--blue-600);
}

.card-body p {
    min-height: 3.2em;
    margin: 0 0 14px;
    color: var(--slate-600);
    font-size: 14px;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    color: var(--slate-500);
    font-size: 13px;
}

.card-meta span:not(:last-child)::after {
    content: "·";
    margin-left: 8px;
    color: var(--slate-400);
}

.card-tags span,
.detail-tags a {
    display: inline-flex;
    padding: 4px 9px;
    color: var(--blue-700);
    background: var(--blue-50);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.category-zone {
    padding: 44px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, var(--blue-50), var(--indigo-50));
}

.category-preview-grid,
.category-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
}

.category-preview-card,
.category-card-large,
.about-grid article,
.info-card,
.side-card,
.ranking-aside {
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.category-preview-card {
    padding: 24px;
}

.category-preview-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 8px;
}

.category-preview-head h3,
.category-card-body h2,
.info-card h2,
.side-card h2,
.ranking-aside h2,
.about-grid h2 {
    margin: 0;
    font-size: 22px;
}

.category-preview-head a {
    color: var(--blue-600);
    font-weight: 800;
}

.category-preview-card p,
.category-card-body p {
    color: var(--slate-600);
}

.media-list,
.side-related,
.ranking-list {
    display: grid;
    gap: 12px;
}

.media-row {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border-radius: 14px;
    transition: background 0.2s ease;
}

.media-row:hover {
    background: var(--slate-50);
}

.mini-poster {
    width: 68px;
    height: 68px;
    flex: 0 0 68px;
    border-radius: 12px;
    background-color: var(--slate-200);
    background-size: cover;
    background-position: center;
}

.media-row-text {
    min-width: 0;
}

.media-row-text strong,
.media-row-text em {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.media-row-text strong {
    color: var(--slate-900);
    font-size: 15px;
}

.media-row-text em {
    color: var(--slate-500);
    font-size: 13px;
    font-style: normal;
}

.page-shell {
    min-height: 70vh;
}

.page-hero {
    margin-top: 34px;
    padding: 54px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, #ffffff, #eff6ff 56%, #eef2ff);
    box-shadow: var(--shadow-md);
}

.page-hero p {
    max-width: 760px;
    margin: 14px 0 0;
    color: var(--slate-600);
    font-size: 18px;
}

.filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 28px;
    padding: 18px;
    border-radius: 18px;
    background: var(--white);
    box-shadow: var(--shadow-sm);
}

.filter-bar input {
    width: min(640px, 100%);
    border: 1px solid var(--slate-200);
    border-radius: 999px;
    padding: 13px 18px;
    outline: 0;
}

.filter-bar input:focus {
    border-color: var(--blue-600);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.filter-bar span {
    color: var(--slate-600);
    font-weight: 700;
    white-space: nowrap;
}

.category-card-large {
    overflow: hidden;
}

.category-card-large a {
    display: block;
}

.category-collage {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 2px;
    height: 180px;
    background: var(--slate-200);
}

.category-collage span {
    background-size: cover;
    background-position: center;
}

.category-collage span:first-child {
    grid-row: span 2;
}

.category-card-body {
    padding: 24px;
}

.category-card-body strong {
    color: var(--blue-600);
}

.ranking-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 28px;
}

.ranking-list {
    padding: 18px;
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.rank-number {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    color: var(--white);
    background: var(--blue-600);
    border-radius: 14px;
    font-weight: 900;
}

.ranking-aside {
    height: max-content;
    padding: 24px;
}

.ranking-aside a {
    display: block;
    margin-top: 12px;
    padding: 12px 14px;
    color: var(--blue-700);
    background: var(--blue-50);
    border-radius: 12px;
    font-weight: 800;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
    color: var(--slate-500);
    font-size: 14px;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 28px;
    padding: 28px 0 0;
}

.detail-main,
.detail-side {
    min-width: 0;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: #000000;
    box-shadow: var(--shadow-xl);
    aspect-ratio: 16 / 9;
}

.video-player {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: #000000;
    cursor: pointer;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 5;
    border: 0;
    padding: 0;
    color: var(--white);
    background: #000000;
    cursor: pointer;
    overflow: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.cover-image,
.cover-gradient {
    position: absolute;
    inset: 0;
}

.cover-image {
    background-size: cover;
    background-position: center;
    transform: scale(1.04);
}

.cover-gradient {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.82), rgba(15, 23, 42, 0.28));
}

.cover-play {
    position: absolute;
    left: 50%;
    top: 48%;
    width: 82px;
    height: 82px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--blue-600);
    box-shadow: 0 20px 45px rgba(37, 99, 235, 0.45);
    transform: translate(-50%, -50%);
    font-size: 32px;
    line-height: 1;
}

.cover-title {
    position: absolute;
    left: 32px;
    right: 32px;
    bottom: 28px;
    z-index: 2;
    text-align: left;
    font-size: clamp(24px, 4vw, 38px);
    font-weight: 900;
}

.detail-content {
    margin-top: 26px;
    padding: 34px;
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--shadow-md);
}

.detail-content h1 {
    margin: 0 0 14px;
    font-size: clamp(34px, 5vw, 52px);
    letter-spacing: -0.05em;
    line-height: 1.1;
}

.lead-text {
    color: var(--slate-700);
    font-size: 19px;
}

.detail-content h2 {
    margin: 30px 0 10px;
    font-size: 24px;
}

.detail-content p {
    color: var(--slate-700);
    font-size: 16px;
}

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

.info-card,
.side-card {
    padding: 24px;
    margin-bottom: 22px;
}

.info-card dl {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 12px 16px;
    margin: 20px 0 0;
}

.info-card dt {
    color: var(--slate-500);
    font-weight: 700;
}

.info-card dd {
    margin: 0;
    color: var(--slate-900);
    font-weight: 700;
}

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

.about-grid article {
    padding: 30px;
}

.about-grid p {
    color: var(--slate-700);
}

.site-footer {
    margin-top: 70px;
    color: #cbd5e1;
    background: var(--slate-900);
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 1fr 1fr;
    gap: 40px;
    padding: 54px 0;
}

.footer-brand {
    color: var(--white);
}

.footer-main p {
    max-width: 560px;
    color: #94a3b8;
}

.site-footer h2 {
    margin: 0 0 14px;
    color: var(--white);
    font-size: 18px;
}

.site-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer li {
    margin: 8px 0;
}

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

.footer-bottom {
    padding: 18px 0;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    text-align: center;
    color: #94a3b8;
    font-size: 14px;
}

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

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

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

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

    .info-card,
    .side-card {
        margin-bottom: 0;
    }
}

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

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

    .top-nav {
        gap: 14px;
    }

    .hero-carousel {
        height: 560px;
    }

    .hero-copy h1 {
        font-size: 42px;
    }

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

    .three-columns,
    .five-columns,
    .four-columns,
    .compact-grid,
    .category-preview-grid,
    .category-card-grid,
    .about-grid,
    .detail-side,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .category-zone,
    .page-hero,
    .detail-content {
        padding: 26px;
    }

    .filter-bar {
        align-items: stretch;
        flex-direction: column;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(100% - 22px, var(--container));
    }

    .brand {
        font-size: 18px;
    }

    .hero-carousel {
        height: 590px;
    }

    .hero-copy h1 {
        font-size: 36px;
    }

    .hero-tags span {
        padding: 6px 10px;
        font-size: 13px;
    }

    .movie-grid {
        gap: 16px;
    }

    .poster-frame {
        height: 210px;
    }

    .cover-play {
        width: 64px;
        height: 64px;
        font-size: 26px;
    }

    .cover-title {
        left: 20px;
        right: 20px;
        bottom: 20px;
    }
}
