:root {
    --emerald: #059669;
    --teal: #0d9488;
    --cyan: #0891b2;
    --rose: #e11d48;
    --amber: #d97706;
    --slate: #0f172a;
    --muted: #64748b;
    --light: #f8fafc;
    --card: #ffffff;
    --line: #e5e7eb;
    --shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: #1f2937;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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: linear-gradient(90deg, var(--emerald), var(--teal), var(--cyan));
    box-shadow: 0 10px 30px rgba(8, 145, 178, 0.28);
}

.nav-shell {
    max-width: 1280px;
    height: 68px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-weight: 800;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    color: #fef08a;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.16);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
    transition: transform 0.25s ease;
}

.brand:hover .brand-mark {
    transform: rotate(12deg) scale(1.05);
}

.brand-text {
    font-size: 24px;
}

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

.nav-link {
    color: rgba(255, 255, 255, 0.92);
    font-weight: 600;
    transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #fef08a;
    transform: translateY(-1px);
}

.header-search {
    width: 280px;
}

.header-search input,
.mobile-search input,
.filter-search input {
    width: 100%;
    border: 0;
    outline: 0;
    border-radius: 999px;
    padding: 12px 18px;
    color: #0f172a;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.3);
}

.header-search input:focus,
.mobile-search input:focus,
.filter-search input:focus {
    box-shadow: 0 0 0 3px rgba(253, 224, 71, 0.75);
}

.menu-toggle {
    width: 42px;
    height: 42px;
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
}

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

.mobile-nav {
    padding: 18px 24px 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
    background: linear-gradient(180deg, #0d9488, #0891b2);
}

.mobile-nav a {
    display: block;
    color: #ffffff;
    padding: 12px 0;
    font-weight: 600;
}

.mobile-search {
    margin-bottom: 8px;
}

.hero-carousel {
    position: relative;
    min-height: 560px;
    overflow: hidden;
    color: #ffffff;
    background: #0f172a;
}

.hero-track {
    position: relative;
    min-height: 560px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: end;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

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

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

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 75% 35%, rgba(34, 211, 238, 0.32), transparent 32%),
        linear-gradient(180deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.98)),
        linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(15, 23, 42, 0.38));
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    padding: 94px 24px 78px;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    background: linear-gradient(90deg, var(--rose), #f97316);
    box-shadow: 0 10px 30px rgba(225, 29, 72, 0.35);
}

.hero-content h1 {
    max-width: 850px;
    margin: 18px 0 18px;
    font-size: clamp(40px, 6vw, 76px);
    line-height: 1.05;
    letter-spacing: -0.05em;
    text-shadow: 0 14px 35px rgba(0, 0, 0, 0.45);
}

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

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
}

.hero-meta span {
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(16px);
}

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

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

.button-primary,
.detail-button.primary {
    color: #ffffff;
    background: linear-gradient(90deg, #10b981, #14b8a6);
    box-shadow: 0 16px 34px rgba(16, 185, 129, 0.35);
}

.button-secondary,
.detail-button.secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(16px);
}

.button-primary:hover,
.button-secondary:hover,
.detail-button:hover {
    transform: translateY(-2px) scale(1.02);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 50%;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(12px);
    font-size: 28px;
    line-height: 1;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.7);
}

.hero-arrow.prev {
    left: 24px;
}

.hero-arrow.next {
    right: 24px;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.45);
}

.hero-dot.active {
    width: 30px;
    border-radius: 999px;
    background: #fef08a;
}

.page-wrap,
.home-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 44px 24px 70px;
}

.home-section,
.page-section {
    margin-bottom: 58px;
}

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

.section-head h2,
.page-title h1 {
    margin: 0;
    color: #0f172a;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

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

.section-more {
    color: var(--emerald);
    font-weight: 800;
    white-space: nowrap;
}

.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;
    border-radius: 20px;
    background: var(--card);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.10);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.movie-cover {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #0f172a;
}

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

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

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

.cover-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 38%, rgba(0, 0, 0, 0.82));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.movie-card:hover .cover-gradient {
    opacity: 1;
}

.play-chip,
.duration-chip {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
}

.play-chip {
    left: 50%;
    top: 50%;
    padding: 12px 18px;
    color: var(--emerald);
    background: rgba(255, 255, 255, 0.92);
    transform: translate(-50%, -50%) scale(0.86);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.duration-chip {
    right: 12px;
    bottom: 12px;
    padding: 4px 9px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.68);
}

.movie-info {
    padding: 18px;
}

.movie-title {
    display: block;
    color: #111827;
    font-size: 18px;
    font-weight: 800;
    line-height: 1.35;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.movie-card:hover .movie-title,
.compact-item:hover .compact-title {
    color: var(--emerald);
}

.movie-desc {
    min-height: 44px;
    margin: 8px 0 14px;
    color: #64748b;
    font-size: 14px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    color: #6b7280;
    font-size: 13px;
}

.meta-badge {
    color: #047857;
    background: #d1fae5;
    padding: 3px 9px;
    border-radius: 999px;
}

.feature-band {
    padding: 30px;
    border-radius: 30px;
    background: linear-gradient(135deg, #ecfeff, #eff6ff);
    box-shadow: var(--shadow);
}

.rank-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 0.55fr);
    gap: 30px;
}

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

.compact-item {
    display: grid;
    grid-template-columns: auto 150px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.compact-item:hover {
    transform: translateX(4px);
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.14);
}

.rank-num {
    min-width: 40px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--rose), #f97316);
    border-radius: 14px;
    text-align: center;
    font-weight: 900;
    padding: 8px 0;
}

.compact-cover {
    overflow: hidden;
    border-radius: 14px;
    aspect-ratio: 16 / 10;
    background: #0f172a;
}

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

.compact-item:hover img {
    transform: scale(1.06);
}

.compact-title {
    color: #111827;
    font-weight: 800;
}

.compact-item p {
    margin: 5px 0;
    color: #64748b;
    font-size: 14px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.compact-meta {
    color: #94a3b8;
    font-size: 13px;
}

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

.category-panel {
    position: relative;
    overflow: hidden;
    min-height: 210px;
    border-radius: 28px;
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    box-shadow: var(--shadow);
}

.category-panel::after {
    content: "";
    position: absolute;
    right: -48px;
    top: -54px;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.18), rgba(8, 145, 178, 0.2));
}

.category-link {
    position: relative;
    z-index: 1;
    display: block;
    padding: 26px 26px 12px;
}

.category-orb {
    width: 44px;
    height: 44px;
    display: inline-block;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--emerald), var(--cyan));
    box-shadow: 0 15px 30px rgba(8, 145, 178, 0.25);
}

.category-panel h2 {
    margin: 16px 0 8px;
    font-size: 24px;
    color: #0f172a;
}

.category-panel p {
    margin: 0;
    color: #64748b;
}

.category-samples {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0 26px 24px;
}

.category-samples a {
    color: #047857;
    font-size: 13px;
    background: #d1fae5;
    padding: 4px 9px;
    border-radius: 999px;
}

.page-hero {
    color: #ffffff;
    background: linear-gradient(90deg, var(--emerald), var(--teal), var(--cyan));
    padding: 58px 24px;
}

.page-title {
    max-width: 1280px;
    margin: 0 auto;
}

.page-title h1 {
    color: #ffffff;
}

.page-title p {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) auto;
    align-items: center;
    gap: 16px;
    margin-bottom: 26px;
    padding: 18px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.filter-pill {
    border: 0;
    border-radius: 999px;
    padding: 9px 14px;
    color: #334155;
    background: #f1f5f9;
    font-weight: 700;
}

.filter-pill.active,
.filter-pill:hover {
    color: #ffffff;
    background: linear-gradient(90deg, var(--emerald), var(--cyan));
}

.detail-hero {
    position: relative;
    overflow: hidden;
    min-height: 430px;
    color: #ffffff;
    background: #0f172a;
}

.detail-hero img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 70% 35%, rgba(16, 185, 129, 0.26), transparent 34%),
        linear-gradient(180deg, rgba(15, 23, 42, 0.26), rgba(15, 23, 42, 0.96)),
        linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.38));
}

.detail-hero-content {
    position: relative;
    z-index: 1;
    max-width: 1280px;
    margin: 0 auto;
    padding: 86px 24px 58px;
}

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

.breadcrumb a:hover {
    color: #fef08a;
}

.detail-hero h1 {
    max-width: 880px;
    margin: 0 0 18px;
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.detail-hero p {
    max-width: 820px;
    margin: 0 0 22px;
    color: #e5e7eb;
    font-size: 18px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 26px;
}

.detail-meta span {
    padding: 8px 13px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(14px);
}

.detail-wrap {
    max-width: 1280px;
    margin: 0 auto;
    padding: 38px 24px 72px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 30px;
}

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

.player-box {
    overflow: hidden;
    margin-bottom: 26px;
}

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

.player-stage video {
    width: 100%;
    height: 100%;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.68));
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

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

.player-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.42);
}

.player-play {
    position: relative;
    z-index: 2;
    width: 84px;
    height: 84px;
    border: 0;
    border-radius: 50%;
    color: var(--emerald);
    background: rgba(255, 255, 255, 0.94);
    font-size: 34px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
    transition: transform 0.2s ease;
}

.player-play:hover {
    transform: scale(1.08);
}

.player-caption {
    padding: 22px 24px;
}

.player-caption h2 {
    margin: 0 0 8px;
    color: #0f172a;
}

.player-caption p {
    margin: 0;
    color: #64748b;
}

.content-card {
    padding: 28px;
    margin-bottom: 26px;
}

.content-card h2 {
    margin: 0 0 14px;
    color: #0f172a;
    font-size: 25px;
}

.content-card p {
    margin: 0 0 14px;
    color: #4b5563;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.tag-cloud span,
.tag-cloud a {
    padding: 7px 12px;
    border-radius: 999px;
    color: #0e7490;
    background: #cffafe;
    font-size: 14px;
    font-weight: 700;
}

.side-card {
    position: sticky;
    top: 92px;
    padding: 22px;
}

.side-card h2 {
    margin: 0 0 18px;
    color: #0f172a;
    font-size: 22px;
}

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

.side-list .compact-item {
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 12px;
    padding: 0;
    box-shadow: none;
}

.side-list .compact-item .rank-num {
    display: none;
}

.side-list .compact-cover {
    width: 110px;
}

.side-list .compact-item p {
    -webkit-line-clamp: 1;
}

.no-result {
    display: none;
    padding: 48px 24px;
    text-align: center;
    border-radius: 22px;
    color: #64748b;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.no-result.show {
    display: block;
}

.site-footer {
    color: #d1d5db;
    background: linear-gradient(180deg, #1e293b, #0f172a);
}

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

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

.site-footer p {
    margin: 0;
    color: #cbd5e1;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.footer-links a:hover {
    color: #22d3ee;
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding: 22px 24px 34px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    text-align: center;
    font-size: 14px;
}

@media (max-width: 1100px) {
    .desktop-nav,
    .header-search {
        display: none;
    }

    .menu-toggle {
        display: flex;
        margin-left: auto;
    }

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

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

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

    .side-card {
        position: static;
    }

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

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

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

    .hero-carousel,
    .hero-track {
        min-height: 520px;
    }

    .hero-content {
        padding: 72px 18px 70px;
    }

    .hero-arrow {
        display: none;
    }

    .page-wrap,
    .home-wrap,
    .detail-wrap {
        padding-left: 16px;
        padding-right: 16px;
    }

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

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

    .movie-info {
        padding: 14px;
    }

    .movie-title {
        font-size: 16px;
    }

    .compact-item {
        grid-template-columns: 100px minmax(0, 1fr);
    }

    .compact-item .rank-num {
        display: none;
    }

    .compact-cover {
        width: 100px;
    }

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

    .filter-bar {
        grid-template-columns: 1fr;
    }

    .detail-hero-content {
        padding: 64px 16px 44px;
    }

    .player-play {
        width: 68px;
        height: 68px;
        font-size: 28px;
    }
}

@media (max-width: 460px) {
    .movie-grid,
    .movie-grid.compact-grid {
        grid-template-columns: 1fr;
    }

    .hero-meta,
    .detail-meta {
        gap: 8px;
    }

    .button-primary,
    .button-secondary,
    .detail-button {
        width: 100%;
    }
}
