:root {
    --dark-950: #05070a;
    --dark-900: #07090c;
    --dark-850: #0d1118;
    --dark-800: #12171e;
    --dark-700: #1d2530;
    --dark-600: #2d3748;
    --text-strong: #ffffff;
    --text-main: #d1d5db;
    --text-soft: #9ca3af;
    --primary-600: #0043ad;
    --primary-500: #0056e0;
    --primary-400: #1c73ff;
    --accent-500: #e6a800;
    --accent-400: #ffc61a;
    --radius-lg: 18px;
    --radius-xl: 24px;
    --shadow-card: 0 22px 65px rgba(0, 0, 0, 0.32);
    --container: 1280px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--text-main);
    background: linear-gradient(180deg, var(--dark-900), var(--dark-800) 48%, var(--dark-900));
}

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

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

button,
input {
    font: inherit;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(7, 9, 12, 0.94);
    border-bottom: 1px solid rgba(29, 37, 48, 0.95);
    backdrop-filter: blur(18px);
}

.nav-shell {
    width: min(var(--container), calc(100% - 32px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--text-strong);
    letter-spacing: 0.02em;
}

.logo-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: white;
    background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
    box-shadow: 0 8px 28px rgba(0, 86, 224, 0.35);
}

.logo-text {
    font-size: 21px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-link {
    color: #d1d5db;
    font-size: 14px;
    font-weight: 650;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-400);
}

.mobile-menu-button {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: rgba(29, 37, 48, 0.75);
    cursor: pointer;
}

.mobile-menu-button span {
    display: block;
    width: 21px;
    height: 2px;
    margin: 4px auto;
    background: var(--text-strong);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.mobile-menu-button.is-open span:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
}

.mobile-menu-button.is-open span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-button.is-open span:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--dark-700);
    background: var(--dark-800);
}

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

.mobile-nav-link {
    display: block;
    padding: 14px 24px;
    color: var(--text-main);
    border-bottom: 1px solid rgba(29, 37, 48, 0.72);
}

.hero-carousel {
    position: relative;
    height: 72vh;
    min-height: 560px;
    overflow: hidden;
    background: var(--dark-950);
}

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

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

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, var(--dark-900) 0%, rgba(7, 9, 12, 0.72) 52%, rgba(7, 9, 12, 0.18) 100%),
                radial-gradient(circle at 25% 70%, rgba(0, 86, 224, 0.35), transparent 40%),
                radial-gradient(circle at 72% 42%, rgba(230, 168, 0, 0.24), transparent 34%);
}

.hero-content {
    position: absolute;
    left: 50%;
    bottom: 92px;
    width: min(var(--container), calc(100% - 32px));
    transform: translateX(-50%);
    max-width: 760px;
    margin-left: calc((min(var(--container), calc(100% - 32px)) - min(var(--container), calc(100% - 32px))) / 2);
}

.hero-kicker,
.detail-tags,
.movie-meta,
.category-jump {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-kicker > span:first-child,
.section-eyebrow {
    display: inline-flex;
    align-items: center;
    width: max-content;
    padding: 6px 12px;
    color: white;
    font-size: 13px;
    font-weight: 750;
    border-radius: 999px;
    background: rgba(230, 168, 0, 0.9);
}

.tag-pill {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 999px;
    color: #d6dae2;
    font-size: 13px;
    background: rgba(29, 37, 48, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-content h1 {
    max-width: 760px;
    margin: 20px 0 14px;
    color: var(--text-strong);
    font-size: clamp(40px, 6vw, 76px);
    line-height: 0.98;
    letter-spacing: -0.05em;
}

.hero-content p {
    max-width: 680px;
    margin: 0 0 28px;
    color: #e5e7eb;
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.7;
}

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

.primary-button,
.ghost-button,
.section-more,
.site-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 24px;
    border-radius: 999px;
    font-weight: 750;
    border: 0;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.primary-button,
.site-search button {
    color: white;
    background: linear-gradient(90deg, var(--primary-600), var(--primary-400));
    box-shadow: 0 12px 30px rgba(0, 67, 173, 0.34);
}

.primary-button:hover,
.site-search button:hover,
.ghost-button:hover,
.section-more:hover {
    transform: translateY(-2px);
}

.ghost-button,
.section-more {
    color: #f9fafb;
    background: rgba(18, 23, 30, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 52px;
    height: 52px;
    border: 0;
    border-radius: 50%;
    color: white;
    background: rgba(0, 0, 0, 0.52);
    backdrop-filter: blur(12px);
    cursor: pointer;
    font-size: 38px;
    line-height: 1;
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

.hero-dot.is-active {
    width: 38px;
    background: var(--accent-400);
}

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

.search-panel {
    margin-top: -44px;
    position: relative;
    z-index: 8;
}

.search-shell {
    display: grid;
    grid-template-columns: 1fr minmax(320px, 520px);
    gap: 24px;
    align-items: center;
    padding: 26px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    background: rgba(18, 23, 30, 0.92);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(18px);
}

.search-shell h2,
.section-heading h2,
.page-hero h1,
.synopsis-section h2 {
    margin: 10px 0 0;
    color: var(--text-strong);
    line-height: 1.2;
}

.site-search {
    display: flex;
    gap: 10px;
}

.site-search input {
    flex: 1;
    min-width: 0;
    min-height: 48px;
    padding: 0 16px;
    color: var(--text-strong);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    outline: none;
    background: rgba(7, 9, 12, 0.72);
}

.site-search input:focus {
    border-color: rgba(255, 198, 26, 0.68);
    box-shadow: 0 0 0 4px rgba(255, 198, 26, 0.1);
}

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

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

.section-heading h2 {
    font-size: clamp(28px, 4vw, 42px);
}

.section-heading p {
    max-width: 760px;
    margin: 10px 0 0;
    color: var(--text-soft);
    line-height: 1.7;
}

.compact-heading {
    align-items: center;
}

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

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

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

.horizontal-list,
.editor-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

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

.movie-link {
    display: block;
    height: 100%;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    background: rgba(18, 23, 30, 0.72);
    box-shadow: 0 15px 36px rgba(0, 0, 0, 0.16);
    transition: transform 0.24s ease, background 0.24s ease, border-color 0.24s ease;
}

.movie-link:hover {
    transform: translateY(-6px);
    border-color: rgba(255, 198, 26, 0.32);
    background: rgba(29, 37, 48, 0.88);
}

.movie-cover-wrap {
    position: relative;
    margin: 0;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, var(--dark-700), var(--dark-900));
}

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

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

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

.movie-cover-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.68), transparent 58%);
}

.movie-duration,
.movie-type {
    position: absolute;
    z-index: 2;
    padding: 5px 9px;
    color: white;
    font-size: 12px;
    border-radius: 7px;
    background: rgba(0, 0, 0, 0.72);
}

.movie-duration {
    right: 10px;
    top: 10px;
}

.movie-type {
    left: 10px;
    bottom: 10px;
    background: rgba(0, 86, 224, 0.78);
}

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

.movie-card-body h3 {
    margin: 0 0 8px;
    color: var(--text-strong);
    font-size: 18px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-card-body p {
    margin: 0 0 14px;
    color: var(--text-soft);
    line-height: 1.62;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-meta {
    gap: 8px;
    color: #7f8897;
    font-size: 12px;
}

.movie-meta span {
    padding: 4px 8px;
    border-radius: 7px;
    background: rgba(7, 9, 12, 0.56);
}

.movie-card-horizontal .movie-link {
    display: grid;
    grid-template-columns: 190px 1fr;
    min-height: 128px;
}

.movie-card-horizontal .movie-cover-wrap {
    aspect-ratio: auto;
    height: 100%;
}

.movie-card-horizontal .movie-card-body {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.category-tile {
    position: relative;
    overflow: hidden;
    min-height: 168px;
    padding: 24px;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: linear-gradient(145deg, rgba(29, 37, 48, 0.88), rgba(7, 9, 12, 0.92));
    box-shadow: var(--shadow-card);
}

.category-tile:hover {
    transform: translateY(-4px);
    border-color: rgba(255, 198, 26, 0.28);
}

.category-light {
    position: absolute;
    width: 160px;
    height: 160px;
    right: -50px;
    top: -50px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 86, 224, 0.55), transparent 66%);
}

.category-tile strong {
    position: relative;
    display: block;
    margin-bottom: 12px;
    color: var(--text-strong);
    font-size: 22px;
}

.category-tile span:not(.category-light) {
    position: relative;
    display: block;
    color: var(--text-soft);
    line-height: 1.7;
}

.category-tile em {
    position: relative;
    display: block;
    margin-top: 18px;
    color: var(--accent-400);
    font-style: normal;
    font-size: 14px;
}

.ranking-block {
    padding-bottom: 0;
}

.ranking-list {
    display: grid;
    gap: 12px;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background: rgba(18, 23, 30, 0.72);
}

.ranking-item {
    display: grid;
    grid-template-columns: 54px 1fr auto;
    gap: 18px;
    align-items: center;
    padding: 18px 22px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.ranking-item:hover,
.ranking-card:hover {
    background: rgba(29, 37, 48, 0.8);
}

.ranking-item span,
.ranking-number {
    color: var(--accent-400);
    font-weight: 900;
    font-size: 22px;
}

.ranking-item strong {
    color: var(--text-strong);
}

.ranking-item em {
    color: var(--text-soft);
    font-style: normal;
}

.site-footer {
    margin-top: 80px;
    border-top: 1px solid var(--dark-700);
    background: var(--dark-900);
}

.footer-shell {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
    padding: 46px 0;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
    align-items: center;
}

.footer-shell p {
    max-width: 640px;
    color: var(--text-soft);
    line-height: 1.7;
}

.footer-links {
    display: grid;
    gap: 10px;
}

.footer-links a:hover {
    color: var(--accent-400);
}

.page-main {
    padding-top: 108px;
}

.page-hero {
    padding: 58px 0 34px;
}

.page-hero h1 {
    max-width: 920px;
    font-size: clamp(36px, 6vw, 62px);
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 780px;
    color: var(--text-soft);
    font-size: 18px;
    line-height: 1.75;
}

.page-search {
    max-width: 720px;
    margin-top: 24px;
}

.category-jump {
    margin-top: 24px;
}

.category-jump a {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--text-main);
    background: rgba(18, 23, 30, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.full-library {
    display: grid;
    gap: 76px;
}

.category-overview-section {
    scroll-margin-top: 96px;
}

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

.ranking-card {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(18, 23, 30, 0.72);
}

.ranking-card-link {
    display: grid;
    grid-template-columns: 76px 120px 1fr;
    align-items: center;
    gap: 20px;
    padding: 16px;
}

.ranking-card img {
    width: 120px;
    height: 72px;
    object-fit: cover;
    border-radius: 12px;
    background: var(--dark-700);
}

.ranking-card strong {
    display: block;
    margin-bottom: 6px;
    color: var(--text-strong);
    font-size: 20px;
}

.ranking-card p {
    margin: 0 0 8px;
    color: var(--text-soft);
    line-height: 1.55;
}

.ranking-card em {
    color: #7f8897;
    font-style: normal;
}

.breadcrumb {
    display: flex;
    gap: 9px;
    align-items: center;
    color: var(--text-soft);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--accent-400);
}

.detail-hero {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 42px;
    align-items: center;
    padding-top: 36px;
}

.detail-poster {
    overflow: hidden;
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: var(--dark-700);
    box-shadow: var(--shadow-card);
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.detail-info h1 {
    margin: 16px 0 14px;
    color: var(--text-strong);
    font-size: clamp(34px, 5vw, 60px);
    line-height: 1.08;
}

.detail-line {
    max-width: 820px;
    margin: 0 0 20px;
    color: #e5e7eb;
    font-size: 19px;
    line-height: 1.75;
}

.detail-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    max-width: 680px;
    margin: 26px 0;
}

.detail-meta div {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(18, 23, 30, 0.86);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.detail-meta dt {
    color: #7f8897;
    font-size: 13px;
}

.detail-meta dd {
    margin: 6px 0 0;
    color: var(--text-strong);
    font-weight: 700;
}

.watch-section {
    padding-top: 72px;
}

.player-box {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: var(--radius-xl);
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: #000;
    box-shadow: var(--shadow-card);
}

.player-video {
    width: 100%;
    height: 100%;
    display: block;
    background: #000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    color: white;
    cursor: pointer;
    background: radial-gradient(circle, rgba(0, 67, 173, 0.28), rgba(0, 0, 0, 0.46)), rgba(0, 0, 0, 0.12);
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-icon {
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding-left: 6px;
    border-radius: 50%;
    color: white;
    font-size: 34px;
    background: linear-gradient(135deg, var(--primary-600), var(--accent-500));
    box-shadow: 0 16px 46px rgba(0, 0, 0, 0.45);
}

.synopsis-section {
    padding-top: 56px;
}

.synopsis-section h2 {
    font-size: 30px;
}

.synopsis-section p {
    margin: 14px 0 28px;
    color: var(--text-main);
    font-size: 17px;
    line-height: 1.9;
}

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

.is-filter-hidden {
    display: none !important;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-slide.is-active .hero-content {
    animation: slideUp 0.62s ease both;
}

.movie-card,
.category-tile,
.ranking-card {
    animation: fadeIn 0.45s ease both;
}

@media (max-width: 1080px) {
    .movie-grid,
    .library-grid,
    .poster-grid,
    .category-grid,
    .related-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .detail-hero {
        grid-template-columns: 240px 1fr;
    }
}

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

    .mobile-menu-button {
        display: block;
    }

    .hero-carousel {
        height: 76vh;
        min-height: 540px;
    }

    .hero-content {
        bottom: 84px;
    }

    .hero-control {
        display: none;
    }

    .search-shell,
    .footer-shell,
    .detail-hero,
    .horizontal-list,
    .editor-list,
    .movie-card-horizontal .movie-link,
    .ranking-card-link {
        grid-template-columns: 1fr;
    }

    .site-search {
        flex-direction: column;
    }

    .movie-grid,
    .library-grid,
    .poster-grid,
    .category-grid,
    .related-grid {
        grid-template-columns: 1fr;
    }

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

    .ranking-item {
        grid-template-columns: 42px 1fr;
    }

    .ranking-item em {
        grid-column: 2;
    }

    .ranking-card img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    .detail-poster {
        max-width: 280px;
    }

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