:root {
    --teal-50: #f0fdfa;
    --teal-100: #ccfbf1;
    --teal-500: #14b8a6;
    --teal-600: #0d9488;
    --teal-700: #0f766e;
    --teal-800: #115e59;
    --teal-900: #134e4a;
    --amber-500: #f59e0b;
    --red-600: #dc2626;
    --blue-600: #2563eb;
    --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 50px rgba(15, 23, 42, 0.12);
    --shadow-card: 0 10px 26px rgba(15, 23, 42, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--gray-800);
    background: linear-gradient(180deg, var(--gray-50), #ffffff);
}

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

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

button,
input,
select {
    font: inherit;
}

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

.page-bg {
    min-height: 70vh;
    background: linear-gradient(180deg, var(--gray-50), #ffffff 42%, #ffffff);
}

.main-space {
    padding: 32px 0 64px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #ffffff;
    background: linear-gradient(90deg, var(--teal-700), var(--teal-900));
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.22);
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 72px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand:hover {
    opacity: 0.86;
}

.brand-mark,
.footer-brand span {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    color: var(--teal-900);
    background: #ffffff;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
}

.brand-name {
    font-size: 20px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 22px;
    font-weight: 650;
}

.nav-links a {
    color: rgba(255, 255, 255, 0.92);
    transition: color 0.2s ease, opacity 0.2s ease;
}

.nav-links a:hover {
    color: var(--teal-100);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.12);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 21px;
    height: 2px;
    margin: 5px auto;
    border-radius: 999px;
    background: #ffffff;
}

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

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

.mobile-links {
    display: grid;
    gap: 10px;
    padding: 14px 0 18px;
}

.mobile-links a {
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.08);
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    margin-bottom: 56px;
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    background: var(--gray-900);
}

.hero-slides,
.hero-slide {
    position: absolute;
    inset: 0;
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.02);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.54) 48%, rgba(0, 0, 0, 0.12));
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(680px, 92%);
    padding: 90px 48px;
    color: #ffffff;
}

.hero-pills,
.hero-meta,
.hero-actions,
.hero-cats,
.detail-meta,
.tag-line,
.meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-pills span,
.hero-pills a,
.hero-meta span,
.detail-meta span,
.detail-meta a,
.tag-line span,
.tag-line a {
    border-radius: 999px;
    padding: 7px 12px;
    font-weight: 700;
}

.hero-pills span:first-child,
.hero-pills a {
    background: var(--teal-600);
}

.hero-pills span:nth-child(2) {
    background: var(--amber-500);
}

.hero h1 {
    margin: 18px 0 14px;
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.08;
    letter-spacing: -0.03em;
}

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

.hero-meta span {
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(8px);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 26px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px) scale(1.02);
}

.btn-primary {
    color: #ffffff;
    background: var(--teal-600);
}

.btn-primary:hover {
    background: var(--teal-700);
}

.btn-ghost {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(8px);
}

.hero-dots {
    position: absolute;
    right: 28px;
    bottom: 28px;
    z-index: 4;
    display: flex;
    gap: 8px;
}

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

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

.hero-search {
    position: absolute;
    left: 48px;
    right: 48px;
    bottom: 40px;
    z-index: 3;
    display: flex;
    max-width: 560px;
    overflow: hidden;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.22);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    padding: 16px 18px;
    outline: 0;
}

.hero-search button {
    border: 0;
    padding: 0 24px;
    color: #ffffff;
    font-weight: 800;
    background: var(--teal-600);
    cursor: pointer;
}

.hero-cats {
    position: absolute;
    right: 48px;
    bottom: 86px;
    z-index: 3;
    justify-content: flex-end;
    max-width: 440px;
}

.hero-cats a {
    padding: 9px 13px;
    border-radius: 999px;
    color: #ffffff;
    font-weight: 700;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(8px);
}

.content-section {
    margin-bottom: 56px;
}

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

.section-head h2,
.page-hero h1 {
    margin: 0;
    color: var(--gray-800);
    font-size: clamp(26px, 3vw, 36px);
    letter-spacing: -0.02em;
}

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

.section-more {
    flex: 0 0 auto;
    color: var(--teal-600);
    font-weight: 800;
}

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

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

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

.card-grid.six {
    grid-template-columns: repeat(6, minmax(0, 1fr));
}

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

.card-link {
    display: block;
    height: 100%;
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster {
    position: relative;
    overflow: hidden;
    background: var(--gray-200);
}

.poster-wide {
    aspect-ratio: 16 / 9;
}

.poster-tall {
    aspect-ratio: 3 / 4;
}

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

.card-link:hover .poster img,
.mini-card:hover img,
.ranking-cover:hover img {
    transform: scale(1.08);
}

.poster::after {
    position: absolute;
    inset: 0;
    content: "";
    opacity: 0;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.74));
    transition: opacity 0.25s ease;
}

.card-link:hover .poster::after {
    opacity: 1;
}

.year-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    padding: 5px 9px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    background: var(--amber-500);
}

.play-badge {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    color: #ffffff;
    opacity: 0;
    background: var(--teal-600);
    transform: translate(-50%, -50%) scale(0.72);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-body {
    padding: 15px;
}

.card-body h3 {
    min-height: 2.8em;
    margin: 0 0 8px;
    color: var(--gray-800);
    font-size: 17px;
    line-height: 1.38;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.meta-row {
    justify-content: space-between;
    color: var(--gray-500);
    font-size: 12px;
}

.split-section {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 28px;
    align-items: start;
    margin-bottom: 56px;
}

.rank-panel {
    position: sticky;
    top: 96px;
    overflow: hidden;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.rank-title {
    padding: 20px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 900;
    background: linear-gradient(135deg, var(--teal-600), var(--teal-900));
}

.rank-row {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--gray-100);
}

.rank-row:hover {
    background: var(--teal-50);
}

.rank-row span {
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    color: #ffffff;
    font-weight: 900;
    background: var(--teal-600);
}

.rank-row strong {
    display: block;
    color: var(--gray-800);
    font-size: 15px;
}

.rank-row em {
    display: block;
    margin-top: 4px;
    color: var(--gray-500);
    font-size: 12px;
    font-style: normal;
}

.page-hero {
    margin-bottom: 28px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.small-hero {
    padding: 34px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: var(--gray-500);
    font-size: 14px;
}

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

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

.category-tile {
    padding: 24px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.category-tile h2 {
    margin: 0 0 8px;
    font-size: 24px;
}

.category-tile p {
    min-height: 3.4em;
    margin: 0 0 18px;
    color: var(--gray-600);
    line-height: 1.7;
}

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

.mini-card {
    display: grid;
    grid-template-columns: 56px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 14px;
    background: var(--gray-50);
}

.mini-card img {
    width: 56px;
    height: 42px;
    border-radius: 10px;
    object-fit: cover;
    transition: transform 0.25s ease;
}

.mini-card span {
    font-weight: 800;
}

.mini-card em {
    color: var(--gray-500);
    font-size: 12px;
    font-style: normal;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 18px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.filter-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr 1fr;
    gap: 12px;
}

.filter-grid input,
.filter-grid select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--gray-200);
    border-radius: 14px;
    padding: 0 14px;
    color: var(--gray-700);
    background: #ffffff;
    outline: 0;
}

.filter-grid input:focus,
.filter-grid select:focus {
    border-color: var(--teal-500);
    box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.12);
}

.empty-state {
    display: none;
    padding: 46px 20px;
    text-align: center;
    color: var(--gray-500);
}

.empty-state.is-visible {
    display: block;
}

.ranking-list {
    display: grid;
    gap: 18px;
}

.ranking-item {
    display: grid;
    grid-template-columns: 170px 1fr;
    gap: 20px;
    padding: 18px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.ranking-cover {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    aspect-ratio: 16 / 10;
    background: var(--gray-200);
}

.ranking-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.ranking-cover span {
    position: absolute;
    top: 10px;
    left: 10px;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    color: #ffffff;
    font-weight: 900;
    background: var(--teal-600);
}

.ranking-body h2 {
    margin: 2px 0 10px;
    font-size: 24px;
}

.ranking-body p {
    margin: 0 0 16px;
    color: var(--gray-600);
    line-height: 1.75;
}

.tag-line a,
.tag-line span,
.detail-meta a,
.detail-meta span {
    color: var(--teal-800);
    background: var(--teal-50);
}

.detail-breadcrumb {
    margin-bottom: 20px;
}

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

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    background: #000000;
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.24);
}

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

.play-layer {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.58));
    cursor: pointer;
}

.play-layer.is-hidden {
    display: none;
}

.play-layer span {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 30px;
    background: var(--teal-600);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.26);
}

.play-layer strong {
    font-size: 20px;
}

.detail-card,
.info-panel {
    margin-top: 24px;
    padding: 26px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.detail-card h1 {
    margin: 0 0 16px;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.2;
}

.detail-card h2,
.info-panel h2 {
    margin: 0 0 16px;
    color: var(--gray-800);
    font-size: 22px;
}

.detail-card p {
    color: var(--gray-700);
    line-height: 1.9;
}

.lead-text {
    font-weight: 800;
}

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

.tag-list span {
    padding: 7px 12px;
    border-radius: 999px;
    color: var(--teal-700);
    font-weight: 700;
    background: var(--teal-50);
}

.detail-side {
    position: sticky;
    top: 96px;
}

.info-panel {
    margin-top: 0;
    color: #ffffff;
    background: linear-gradient(145deg, var(--teal-600), var(--teal-900));
}

.info-panel h2 {
    color: #ffffff;
}

.info-panel dl {
    display: grid;
    gap: 14px;
    margin: 0;
}

.info-panel dt {
    color: var(--teal-100);
    font-size: 13px;
}

.info-panel dd {
    margin: 4px 0 0;
    font-size: 18px;
    font-weight: 800;
}

.related-section {
    margin-top: 40px;
}

.site-footer {
    color: rgba(255, 255, 255, 0.78);
    background: var(--gray-900);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 36px;
    padding: 46px 0;
}

.footer-brand {
    margin-bottom: 14px;
    color: #ffffff;
    font-size: 20px;
}

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

.site-footer p {
    max-width: 480px;
    line-height: 1.8;
}

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

.site-footer a:hover {
    color: var(--teal-100);
}

.footer-bottom {
    padding: 18px 0 26px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
    color: rgba(255, 255, 255, 0.54);
}

@media (max-width: 1100px) {
    .card-grid.six {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

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

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

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

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

    .menu-toggle {
        display: block;
    }

    .hero {
        height: 640px;
        border-radius: 18px;
    }

    .hero-content {
        padding: 48px 24px;
    }

    .hero-search {
        left: 18px;
        right: 18px;
        bottom: 24px;
        max-width: none;
    }

    .hero-cats {
        left: 20px;
        right: 20px;
        bottom: 92px;
        justify-content: flex-start;
        max-width: none;
    }

    .hero-dots {
        right: 20px;
        bottom: 154px;
    }

    .category-grid,
    .footer-grid,
    .filter-grid,
    .ranking-item {
        grid-template-columns: 1fr;
    }

    .card-grid.six,
    .card-grid.four,
    .card-grid.three {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

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

    .small-hero,
    .detail-card,
    .info-panel {
        padding: 22px;
    }
}

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

    .brand-name {
        font-size: 17px;
    }

    .hero h1 {
        font-size: 32px;
    }

    .hero p {
        font-size: 15px;
    }

    .hero-search {
        flex-direction: column;
        border-radius: 16px;
    }

    .hero-search button {
        min-height: 44px;
    }

    .card-grid.six,
    .card-grid.four,
    .card-grid.three {
        grid-template-columns: 1fr;
    }

    .ranking-cover {
        aspect-ratio: 16 / 9;
    }
}
