:root {
    --green: #059669;
    --green-dark: #047857;
    --teal: #0d9488;
    --cyan: #0891b2;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --soft: #f9fafb;
    --card: #ffffff;
    --shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background: #f9fafb;
    color: var(--ink);
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(229, 231, 235, 0.92);
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.06);
    backdrop-filter: blur(16px);
}

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

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

.brand-icon {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, var(--green), var(--teal));
    box-shadow: 0 10px 22px rgba(5, 150, 105, 0.28);
    font-size: 14px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 26px;
    color: #374151;
    font-weight: 650;
}

.nav-links a {
    transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--green);
}

.mobile-toggle {
    display: none;
    border: 0;
    border-radius: 12px;
    padding: 8px 12px;
    background: #f3f4f6;
    color: #111827;
    cursor: pointer;
}

.hero {
    position: relative;
    min-height: 560px;
    color: #fff;
    overflow: hidden;
    background: linear-gradient(135deg, var(--green), var(--teal), var(--cyan));
}

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

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

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

.hero-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    mix-blend-mode: overlay;
    transform: scale(1.04);
    filter: saturate(1.1);
}

.hero-shade {
    background:
        radial-gradient(circle at 82% 24%, rgba(20, 184, 166, 0.28), transparent 32%),
        linear-gradient(90deg, rgba(3, 7, 18, 0.82) 0%, rgba(3, 7, 18, 0.58) 46%, rgba(3, 7, 18, 0.24) 100%),
        linear-gradient(0deg, rgba(3, 7, 18, 0.42), rgba(3, 7, 18, 0.18));
}

.hero-content {
    position: relative;
    min-height: 560px;
    display: flex;
    align-items: center;
    padding: 72px 0 160px;
}

.hero-copy {
    width: min(720px, 100%);
}

.hero-label {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.24);
    backdrop-filter: blur(12px);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 18px;
}

.hero h1,
.detail-copy h1 {
    margin: 0 0 16px;
    font-size: clamp(38px, 7vw, 72px);
    line-height: 1.02;
    font-weight: 900;
    letter-spacing: -0.055em;
}

.hero-one-line,
.detail-one-line {
    margin: 0 0 14px;
    font-size: clamp(18px, 2.2vw, 24px);
    font-weight: 700;
}

.hero-summary {
    max-width: 680px;
    margin: 0 0 22px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 16px;
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.tag {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 11px;
    font-size: 12px;
    font-weight: 700;
}

.hero-tags span {
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.20);
}

.tag {
    color: var(--green-dark);
    background: #d1fae5;
}

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

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

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

.btn-primary {
    color: var(--green-dark);
    background: #fff;
    box-shadow: 0 18px 32px rgba(0, 0, 0, 0.18);
}

.btn-ghost {
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.btn-outline {
    color: var(--green-dark);
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
}

.btn.full {
    width: 100%;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 6;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
    backdrop-filter: blur(10px);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

.hero-bottom {
    position: relative;
    z-index: 8;
    padding-bottom: 26px;
    margin-top: -138px;
}

.hero-search,
.filter-box {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    padding: 12px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow);
}

.hero-search input,
.filter-box input,
.filter-box select {
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0 14px;
    outline: none;
    color: var(--ink);
    background: #fff;
}

.hero-search button,
.filter-box button {
    min-height: 46px;
    border: 0;
    border-radius: 14px;
    padding: 0 18px;
    color: #fff;
    background: linear-gradient(135deg, var(--green), var(--teal));
    font-weight: 800;
    cursor: pointer;
}

.hero-dots {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 12px;
    margin-top: 16px;
}

.hero-dot {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    cursor: pointer;
    backdrop-filter: blur(10px);
    opacity: 0.76;
}

.hero-dot.active,
.hero-dot:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.25);
}

.hero-dot img {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    object-fit: cover;
    flex: none;
}

.hero-dot span {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 13px;
    font-weight: 750;
}

.quick-categories {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 14px;
    margin-top: 28px;
}

.category-pill {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 18px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    border: 1px solid #eef2f7;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-pill:hover,
.overview-card:hover,
.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 50px rgba(15, 23, 42, 0.14);
}

.category-pill strong {
    color: var(--green);
}

.category-pill.soft {
    background: #f0fdfa;
}

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

.content-band {
    margin-top: 64px;
    padding: 56px 0;
    background: linear-gradient(135deg, #f8fafc, #eef2f7);
}

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

.section-title h2 {
    margin: 0;
    font-size: clamp(26px, 4vw, 34px);
    line-height: 1.15;
    letter-spacing: -0.035em;
}

.section-title p {
    margin: 8px 0 0;
    color: var(--muted);
}

.section-more,
.text-link {
    color: var(--green);
    font-weight: 800;
}

.movie-grid,
.featured-grid,
.overview-grid,
.ranking-hero-grid {
    display: grid;
    gap: 18px;
}

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

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: #fff;
    border: 1px solid #eef2f7;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, #064e3b, #0f766e);
}

.movie-card.compact .movie-poster {
    aspect-ratio: 3 / 4;
}

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

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

.poster-play,
.rank-badge {
    position: absolute;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 900;
}

.poster-play {
    right: 12px;
    bottom: 12px;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    background: rgba(5, 150, 105, 0.92);
    opacity: 0;
    transform: scale(0.85);
    transition: all 0.2s ease;
}

.movie-card:hover .poster-play {
    opacity: 1;
    transform: scale(1);
}

.rank-badge {
    left: 12px;
    top: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(239, 68, 68, 0.95);
    font-size: 12px;
}

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

.movie-meta-line {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
    margin-bottom: 8px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 700;
}

.movie-meta-line span:not(:last-child)::after {
    content: "·";
    margin-left: 7px;
    color: #d1d5db;
}

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

.movie-card p {
    min-height: 46px;
    margin: 0 0 12px;
    color: #6b7280;
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.split-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 28px;
    align-items: start;
}

.ranking-panel,
.text-card,
.player-card,
.overview-card {
    border: 1px solid #eef2f7;
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.ranking-panel {
    padding: 22px;
    position: sticky;
    top: 92px;
}

.ranking-panel h2 {
    margin: 0 0 4px;
    font-size: 24px;
}

.ranking-panel p {
    margin: 0 0 16px;
    color: #6b7280;
}

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

.ranking-item {
    display: grid;
    grid-template-columns: auto 48px 1fr auto;
    align-items: center;
    gap: 10px;
    min-width: 0;
    padding: 8px;
    border-radius: 14px;
    background: #f9fafb;
}

.ranking-item img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 10px;
}

.rank-number {
    width: 24px;
    height: 24px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: var(--green);
    font-size: 12px;
    font-weight: 900;
}

.ranking-title {
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-weight: 800;
}

.ranking-score {
    color: #f59e0b;
    font-weight: 900;
}

.list-hero {
    color: #fff;
    padding: 68px 0;
    background:
        radial-gradient(circle at 80% 20%, rgba(34, 211, 238, 0.25), transparent 30%),
        linear-gradient(135deg, var(--green), var(--teal));
}

.list-hero h1 {
    margin: 0;
    font-size: clamp(36px, 6vw, 56px);
    letter-spacing: -0.045em;
    line-height: 1.06;
}

.list-hero p {
    max-width: 760px;
    margin: 12px 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 17px;
}

.filter-box {
    grid-template-columns: 1.6fr 0.8fr 0.8fr auto;
    margin-top: 24px;
}

.result-count {
    margin-top: 12px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 750;
}

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

.overview-card {
    padding: 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.overview-icon {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    background: #ecfdf5;
    color: var(--green);
    margin-bottom: 16px;
}

.overview-card h2 {
    margin: 0 0 4px;
    font-size: 22px;
}

.overview-card p {
    margin: 0;
    color: #6b7280;
}

.genre-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.genre-chip {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    padding: 10px 14px;
    border-radius: 999px;
    color: #065f46;
    background: #ecfdf5;
    border: 1px solid #a7f3d0;
    font-weight: 800;
}

.genre-chip span {
    color: #0f766e;
}

.ranking-table {
    overflow: hidden;
    border: 1px solid #eef2f7;
    border-radius: var(--radius);
    background: #fff;
}

.ranking-row {
    display: grid;
    grid-template-columns: 58px 70px 1fr 70px;
    align-items: center;
    gap: 14px;
    padding: 12px 18px;
    border-bottom: 1px solid #f1f5f9;
}

.ranking-row:last-child {
    border-bottom: 0;
}

.ranking-row:hover {
    background: #f9fafb;
}

.ranking-row img {
    width: 70px;
    height: 54px;
    object-fit: cover;
    border-radius: 12px;
}

.ranking-row-rank,
.ranking-row-score {
    font-weight: 900;
}

.ranking-row-rank {
    color: var(--green);
}

.ranking-row-main {
    min-width: 0;
}

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

.ranking-row-main em {
    color: #6b7280;
    font-size: 13px;
    font-style: normal;
}

.ranking-row-score {
    color: #f59e0b;
    text-align: right;
}

.detail-hero {
    position: relative;
    min-height: 540px;
    color: #fff;
    overflow: hidden;
    background: #020617;
}

.detail-bg,
.detail-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.detail-bg {
    object-fit: cover;
    opacity: 0.35;
    filter: blur(2px) saturate(1.1);
    transform: scale(1.03);
}

.detail-overlay {
    background:
        radial-gradient(circle at 82% 20%, rgba(20, 184, 166, 0.28), transparent 30%),
        linear-gradient(90deg, rgba(2, 6, 23, 0.88) 0%, rgba(2, 6, 23, 0.70) 50%, rgba(2, 6, 23, 0.45) 100%);
}

.detail-hero-inner {
    position: relative;
    padding: 34px 0 56px;
}

.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-bottom: 28px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 34px;
    align-items: center;
}

.detail-cover {
    width: 280px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 22px;
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.34);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

.detail-copy {
    max-width: 790px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0;
}

.detail-meta span {
    display: inline-flex;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color: rgba(255, 255, 255, 0.88);
    font-size: 13px;
    font-weight: 700;
}

.detail-main {
    margin-top: -34px;
    position: relative;
    z-index: 5;
}

.player-card {
    overflow: hidden;
    margin-bottom: 28px;
}

.player-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 22px;
    border-bottom: 1px solid #eef2f7;
}

.player-head h2 {
    margin: 0;
    font-size: 22px;
}

.player-head span {
    color: #6b7280;
    font-size: 14px;
}

.video-shell {
    position: relative;
    background: #000;
}

.video-shell video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    color: #fff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.18));
    cursor: pointer;
}

.play-overlay.hidden {
    display: none;
}

.play-circle {
    width: 76px;
    height: 76px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.94);
    color: var(--green);
    font-size: 28px;
    box-shadow: 0 18px 42px rgba(0, 0, 0, 0.24);
}

.play-overlay strong {
    font-size: 18px;
}

.detail-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
}

.text-card {
    padding: 24px;
}

.text-card.wide {
    max-width: 920px;
}

.text-card h2,
.text-card h3 {
    margin-top: 0;
}

.text-card p {
    color: #374151;
}

.text-card ul {
    padding-left: 20px;
    color: #374151;
}

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

.sitemap-movie-list {
    columns: 3;
    column-gap: 28px;
}

.sitemap-movie-list li {
    break-inside: avoid;
}

.site-footer {
    margin-top: 72px;
    padding: 48px 0 0;
    color: #d1d5db;
    background: #111827;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 28px;
}

.footer-grid h3 {
    margin: 0 0 12px;
    color: #fff;
}

.footer-grid a {
    display: block;
    margin: 8px 0;
    color: #d1d5db;
}

.footer-grid a:hover {
    color: #a7f3d0;
}

.footer-about p {
    max-width: 620px;
    color: #d1d5db;
}

.footer-bottom {
    margin-top: 34px;
    padding: 18px;
    text-align: center;
    color: #9ca3af;
    border-top: 1px solid #1f2937;
}

[data-card].is-hidden {
    display: none;
}

@media (max-width: 1040px) {
    .featured-grid,
    .four-cols,
    .overview-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

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

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

    .ranking-panel {
        position: static;
    }
}

@media (max-width: 760px) {
    .site-nav {
        height: auto;
        min-height: 64px;
        flex-wrap: wrap;
        padding-top: 12px;
        padding-bottom: 12px;
    }

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

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 12px 0 4px;
    }

    .nav-links.open {
        display: flex;
    }

    .nav-links a {
        padding: 10px 12px;
        border-radius: 12px;
        background: #f9fafb;
    }

    .hero {
        min-height: 680px;
    }

    .hero-content {
        min-height: 680px;
        padding: 56px 0 220px;
    }

    .hero-bottom {
        margin-top: -206px;
    }

    .hero-search,
    .filter-box {
        grid-template-columns: 1fr;
    }

    .hero-dots {
        grid-template-columns: 1fr 1fr;
    }

    .hero-arrow {
        display: none;
    }

    .quick-categories,
    .featured-grid,
    .four-cols,
    .three-cols,
    .ranking-hero-grid,
    .overview-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

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

    .detail-cover {
        width: min(240px, 70vw);
    }

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

    .ranking-row {
        grid-template-columns: 38px 52px 1fr 44px;
        padding: 10px;
        gap: 8px;
    }

    .ranking-row img {
        width: 52px;
        height: 48px;
    }

    .sitemap-movie-list {
        columns: 1;
    }
}

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

    .brand {
        font-size: 20px;
    }

    .quick-categories,
    .featured-grid,
    .four-cols,
    .three-cols,
    .ranking-hero-grid,
    .overview-grid {
        grid-template-columns: 1fr;
    }

    .hero-dot span {
        display: none;
    }

    .hero-dot {
        justify-content: center;
    }
}
