:root {
    --cyan-50: #ecfeff;
    --cyan-100: #cffafe;
    --cyan-500: #06b6d4;
    --cyan-600: #0891b2;
    --blue-600: #2563eb;
    --indigo-50: #eef2ff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --shadow-soft: 0 18px 40px rgba(8, 47, 73, 0.12);
    --shadow-card: 0 10px 30px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background: linear-gradient(135deg, var(--cyan-50), #eff6ff 48%, var(--indigo-50));
    color: var(--gray-900);
    min-height: 100vh;
}

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

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

button,
input {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(16px);
    box-shadow: 0 1px 18px rgba(15, 23, 42, 0.08);
}

.nav-shell {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    min-height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.03em;
    background: linear-gradient(90deg, var(--cyan-600), var(--blue-600));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-mark,
.footer-brand span {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan-500), var(--blue-600));
    box-shadow: 0 10px 20px rgba(6, 182, 212, 0.26);
    font-size: 14px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
    font-weight: 650;
    color: var(--gray-700);
}

.nav-links a {
    transition: color 0.25s ease, transform 0.25s ease;
}

.nav-links a:hover {
    color: var(--cyan-600);
    transform: translateY(-1px);
}

.search-link {
    padding: 8px 16px;
    border-radius: 999px;
    color: #ffffff !important;
    background: linear-gradient(90deg, var(--cyan-500), var(--blue-600));
    box-shadow: 0 10px 20px rgba(6, 182, 212, 0.2);
}

.nav-toggle {
    display: none;
    border: 0;
    background: var(--gray-100);
    border-radius: 12px;
    padding: 8px 12px;
    color: var(--gray-800);
}

.mobile-menu {
    display: none;
}

.hero-carousel {
    position: relative;
    height: 70vh;
    min-height: 560px;
    overflow: hidden;
    background: var(--gray-900);
}

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

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

.hero-image,
.hero-image img,
.hero-shade {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.hero-image img {
    object-fit: cover;
    transform: scale(1.03);
}

.hero-shade {
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.58) 42%, rgba(0, 0, 0, 0.1));
}

.hero-inner {
    position: relative;
    z-index: 2;
    height: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
}

.hero-copy {
    max-width: 720px;
    color: #ffffff;
}

.hero-badges,
.hero-actions,
.hero-meta,
.tag-row,
.detail-meta,
.detail-tags,
.pill-row,
.filter-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.hero-badges span,
.tag-row span,
.detail-tags a {
    border-radius: 999px;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 700;
}

.hero-badges span:first-child {
    background: var(--cyan-500);
}

.hero-badges span:not(:first-child) {
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
}

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

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

.hero-meta {
    margin: 22px 0 34px;
    color: rgba(255, 255, 255, 0.9);
}

.hero-meta strong {
    color: #fde047;
}

.primary-btn,
.ghost-btn,
.panel-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 24px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.primary-btn,
.panel-link {
    color: #ffffff;
    background: linear-gradient(90deg, var(--cyan-500), var(--blue-600));
    box-shadow: 0 16px 32px rgba(37, 99, 235, 0.28);
}

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

.primary-btn:hover,
.ghost-btn:hover,
.panel-link:hover {
    transform: translateY(-2px) scale(1.02);
}

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

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

.hero-dot.active {
    width: 34px;
    background: #ffffff;
}

.category-strip {
    padding: 28px 24px;
    background: rgba(255, 255, 255, 0.64);
    backdrop-filter: blur(14px);
}

.pill-row {
    max-width: 1280px;
    margin: 0 auto;
    justify-content: center;
}

.pill,
.filter-row button {
    border: 0;
    border-radius: 999px;
    padding: 10px 20px;
    background: #ffffff;
    color: var(--gray-700);
    font-weight: 750;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}

.pill:hover,
.pill.active,
.filter-row button:hover,
.filter-row button.active {
    color: #ffffff;
    background: linear-gradient(90deg, var(--cyan-500), var(--blue-600));
    transform: translateY(-1px);
}

.content-section {
    max-width: 1280px;
    margin: 0 auto;
    padding: 72px 24px;
}

.soft-bg {
    max-width: none;
    background: linear-gradient(135deg, rgba(207, 250, 254, 0.45), rgba(219, 234, 254, 0.45));
}

.soft-bg > * {
    max-width: 1280px;
    margin-left: auto;
    margin-right: auto;
}

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

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

.section-heading p,
.page-hero p {
    margin: 0;
    color: var(--gray-600);
    line-height: 1.8;
}

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

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

.movie-card {
    min-width: 0;
}

.movie-card a {
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card a:hover {
    transform: translateY(-6px);
    box-shadow: 0 22px 45px rgba(15, 23, 42, 0.18);
}

.poster-wrap {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, var(--cyan-100), #dbeafe);
}

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

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

.card-play {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 58px;
    height: 58px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--cyan-600);
    background: rgba(255, 255, 255, 0.92);
    transform: translate(-50%, -50%) scale(0.72);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card a:hover .card-play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.card-year {
    position: absolute;
    right: 12px;
    top: 12px;
    border-radius: 999px;
    padding: 5px 10px;
    color: #ffffff;
    background: rgba(17, 24, 39, 0.72);
    font-size: 12px;
    font-weight: 800;
}

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

.movie-card-body h3 {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.35;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.movie-meta,
.movie-line {
    margin: 0;
    color: var(--gray-600);
}

.movie-line {
    margin-top: 10px;
    line-height: 1.6;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tag-row {
    margin-top: 14px;
    gap: 8px;
}

.tag-row span,
.detail-tags a {
    color: var(--cyan-700, #0e7490);
    background: var(--cyan-100);
}

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

.rank-panel,
.side-card {
    border-radius: 24px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: var(--shadow-soft);
}

.rank-panel {
    position: sticky;
    top: 92px;
}

.rank-panel h2,
.side-card h2 {
    margin: 0 0 18px;
    font-size: 24px;
}

.rank-panel ol,
.side-rank ol {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 12px;
}

.rank-item a {
    display: grid;
    grid-template-columns: 34px 56px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px;
    border-radius: 16px;
    transition: background 0.25s ease, transform 0.25s ease;
}

.rank-item a:hover {
    background: var(--cyan-50);
    transform: translateX(3px);
}

.rank-num {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan-500), var(--blue-600));
    font-weight: 850;
}

.rank-item img {
    width: 56px;
    height: 74px;
    object-fit: cover;
    border-radius: 12px;
    background: var(--cyan-100);
}

.rank-text {
    min-width: 0;
}

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

.rank-text em {
    margin-top: 4px;
    color: var(--gray-500);
    font-style: normal;
    font-size: 13px;
}

.panel-link {
    width: 100%;
    margin-top: 18px;
}

.page-hero {
    min-height: 330px;
    padding: 90px 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: radial-gradient(circle at top left, rgba(6, 182, 212, 0.25), transparent 35%), linear-gradient(135deg, #ecfeff, #eff6ff 54%, #eef2ff);
}

.page-hero > div {
    max-width: 850px;
}

.eyebrow {
    display: inline-flex;
    margin-bottom: 14px;
    padding: 7px 14px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(90deg, var(--cyan-500), var(--blue-600));
    font-weight: 800;
}

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

.category-card {
    border-radius: 26px;
    padding: 24px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.16);
}

.category-card h2 {
    margin: 0 0 10px;
    font-size: 24px;
}

.category-card p {
    margin: 0;
    color: var(--gray-600);
    line-height: 1.7;
}

.category-samples {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--gray-200);
}

.category-samples a {
    color: var(--cyan-600);
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.search-panel {
    margin-bottom: 34px;
    padding: 22px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow-soft);
}

.search-panel label {
    display: block;
    margin-bottom: 10px;
    font-weight: 850;
}

.search-panel input {
    width: 100%;
    border: 1px solid var(--gray-200);
    border-radius: 18px;
    padding: 15px 18px;
    outline: none;
    color: var(--gray-900);
    background: #ffffff;
    transition: border 0.25s ease, box-shadow 0.25s ease;
}

.search-panel input:focus {
    border-color: var(--cyan-500);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.14);
}

.filter-row {
    margin-top: 16px;
}

.empty-state {
    display: none;
    margin: 30px 0 0;
    text-align: center;
    color: var(--gray-600);
    font-weight: 800;
}

.empty-state.show {
    display: block;
}

.breadcrumb {
    max-width: 1280px;
    margin: 0 auto;
    padding: 28px 24px 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    color: var(--gray-600);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--cyan-600);
}

.detail-layout {
    max-width: 1280px;
    margin: 0 auto;
    padding: 28px 24px 46px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 32px;
    align-items: start;
}

.player-card,
.detail-card,
.detail-sidebar .side-card {
    background: #ffffff;
    border-radius: 26px;
    box-shadow: var(--shadow-card);
}

.player-card {
    overflow: hidden;
    background: #000000;
}

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

.player-frame video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    padding: 0;
    background: #000000;
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.62;
}

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

.big-play {
    position: relative;
    z-index: 2;
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--cyan-600);
    background: rgba(255, 255, 255, 0.92);
    font-size: 34px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.28);
}

.detail-card {
    margin-top: 24px;
    padding: 32px;
}

.detail-meta {
    margin: 16px 0 18px;
    color: var(--gray-600);
}

.detail-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--gray-100);
    font-weight: 750;
}

.detail-tags {
    margin-bottom: 28px;
}

.detail-card section + section {
    margin-top: 28px;
}

.detail-card h2 {
    margin: 0 0 12px;
    font-size: 23px;
}

.detail-card p {
    margin: 0;
    color: var(--gray-700);
    line-height: 1.95;
    font-size: 16px;
}

.detail-sidebar {
    display: grid;
    gap: 24px;
    position: sticky;
    top: 92px;
}

.side-card dl {
    display: grid;
    gap: 14px;
    margin: 0;
}

.side-card dl div {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--gray-200);
    padding-bottom: 12px;
}

.side-card dt {
    color: var(--gray-500);
}

.side-card dd {
    margin: 0;
    text-align: right;
    font-weight: 800;
}

.related-section {
    padding-top: 26px;
}

.site-footer {
    background: linear-gradient(135deg, var(--gray-900), var(--gray-800));
    color: #d1d5db;
    margin-top: 32px;
}

.footer-grid {
    max-width: 1280px;
    margin: 0 auto;
    padding: 54px 24px;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 34px;
}

.footer-brand {
    color: #ffffff;
    background: none;
    -webkit-background-clip: initial;
    background-clip: initial;
}

.site-footer p {
    margin: 14px 0 0;
    color: #9ca3af;
    line-height: 1.8;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: #ffffff;
    font-size: 18px;
}

.site-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 10px;
}

.site-footer a:hover {
    color: #67e8f9;
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding: 22px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: #9ca3af;
}

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

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

    .rank-panel,
    .detail-sidebar {
        position: static;
    }
}

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

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

    .mobile-menu.open {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 68px;
        display: grid;
        gap: 6px;
        padding: 14px;
        border-radius: 20px;
        background: rgba(255, 255, 255, 0.96);
        box-shadow: var(--shadow-card);
    }

    .mobile-menu a {
        padding: 10px 12px;
        border-radius: 12px;
        font-weight: 750;
    }

    .mobile-menu a:hover {
        background: var(--gray-100);
        color: var(--cyan-600);
    }

    .hero-carousel {
        min-height: 620px;
        height: 78vh;
    }

    .hero-shade {
        background: linear-gradient(180deg, rgba(0, 0, 0, 0.42), rgba(0, 0, 0, 0.86));
    }

    .hero-inner {
        align-items: flex-end;
        padding-bottom: 92px;
    }

    .hero-copy p {
        font-size: 16px;
    }

    .hero-actions {
        align-items: stretch;
    }

    .primary-btn,
    .ghost-btn {
        width: 100%;
    }

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

    .content-section {
        padding: 50px 16px;
    }

    .page-hero {
        min-height: 280px;
        padding: 64px 18px;
    }

    .detail-layout,
    .breadcrumb {
        padding-left: 16px;
        padding-right: 16px;
    }

    .detail-card {
        padding: 24px;
    }
}

@media (max-width: 520px) {
    .nav-shell {
        padding: 0 16px;
    }

    .brand {
        font-size: 20px;
    }

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

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

    .movie-card-body h3 {
        font-size: 16px;
    }

    .movie-line,
    .tag-row {
        display: none;
    }

    .rank-item a {
        grid-template-columns: 30px 48px 1fr;
    }

    .rank-item img {
        width: 48px;
        height: 64px;
    }
}
