:root {
    --bg: #f5f7fb;
    --surface: #ffffff;
    --surface-soft: #eef9ff;
    --text: #111827;
    --muted: #64748b;
    --line: #e5e7eb;
    --cyan: #06b6d4;
    --cyan-dark: #0891b2;
    --blue: #2563eb;
    --dark: #0f172a;
    --dark-2: #111827;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: linear-gradient(180deg, #f8fbff 0%, var(--bg) 42%, #eef7fb 100%);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.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.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.72);
    box-shadow: 0 8px 30px rgba(15, 23, 42, 0.06);
}

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

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

.brand__mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 12px 26px rgba(8, 145, 178, 0.28);
    font-size: 15px;
}

.brand__text {
    font-size: 22px;
    background: linear-gradient(90deg, var(--cyan-dark), var(--blue));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

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

.nav-link {
    color: #334155;
    font-weight: 700;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--cyan-dark);
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: #f1f5f9;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    width: 18px;
    height: 2px;
    background: #334155;
    border-radius: 999px;
}

.mobile-panel {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 12px 0 18px;
    border-top: 1px solid var(--line);
}

.mobile-panel.is-open {
    display: grid;
    gap: 8px;
}

.mobile-panel a {
    padding: 12px 14px;
    border-radius: 14px;
    color: #334155;
    font-weight: 700;
    background: #f8fafc;
}

.hero-slider {
    position: relative;
    min-height: 70vh;
    overflow: hidden;
    background: var(--dark);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    background-size: cover;
    background-position: center;
    transform: scale(1.04);
    transition: opacity 0.7s ease, transform 1.1s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 80% 20%, rgba(6, 182, 212, 0.4), transparent 32%),
        linear-gradient(90deg, rgba(15, 23, 42, 0.92) 0%, rgba(15, 23, 42, 0.72) 44%, rgba(15, 23, 42, 0.28) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 96px 0 108px;
    max-width: 720px;
    color: #ffffff;
}

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

.hero-kicker span,
.detail-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 13px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
    font-weight: 800;
    font-size: 14px;
}

.hero-kicker span:first-child {
    background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.hero-content h1 {
    margin: 18px 0 18px;
    font-size: clamp(42px, 8vw, 78px);
    line-height: 1.02;
    letter-spacing: -0.05em;
}

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

.hero-tags {
    color: #a5f3fc;
    font-weight: 800;
    margin-bottom: 30px;
}

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

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

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

.btn-primary {
    color: #ffffff;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
    box-shadow: 0 18px 35px rgba(37, 99, 235, 0.28);
}

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

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 34px;
    z-index: 4;
    width: min(1180px, calc(100% - 32px));
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: none;
}

.hero-arrow,
.hero-dots button {
    pointer-events: auto;
}

.hero-arrow {
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(12px);
    font-size: 30px;
    line-height: 1;
}

.hero-dots {
    display: flex;
    gap: 8px;
}

.hero-dots button {
    width: 34px;
    height: 9px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.38);
}

.hero-dots button.is-active {
    background: #ffffff;
}

.filter-panel {
    margin: -34px 0 34px;
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 16px;
    padding: 18px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
    border: 1px solid rgba(226, 232, 240, 0.75);
    backdrop-filter: blur(16px);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 0 16px;
    color: #0f172a;
    background: #f8fafc;
    outline: 0;
}

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

.filter-panel__selects {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

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

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

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

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

.section-title a,
.text-link {
    color: var(--cyan-dark);
    font-weight: 900;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(226, 232, 240, 0.82);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
}

.movie-card.is-hidden {
    display: none;
}

.movie-card__poster {
    position: relative;
    min-height: 270px;
    display: block;
    overflow: hidden;
    background:
        linear-gradient(135deg, rgba(6, 182, 212, 0.9), rgba(37, 99, 235, 0.85)),
        #0f172a;
    background-size: cover;
    background-position: center;
}

.movie-grid--compact .movie-card__poster {
    min-height: 220px;
}

.movie-card__poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 34%, rgba(15, 23, 42, 0.78) 100%);
}

.movie-card__shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, transparent 20%, rgba(255, 255, 255, 0.18), transparent 64%);
    transform: translateX(-120%);
    transition: transform 0.55s ease;
}

.movie-card:hover .movie-card__shine {
    transform: translateX(120%);
}

.movie-card__play {
    position: absolute;
    right: 16px;
    bottom: 16px;
    z-index: 2;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 14px 25px rgba(15, 23, 42, 0.35);
}

.movie-card__body {
    padding: 18px;
}

.movie-card__title {
    margin: 0;
    font-size: 19px;
    line-height: 1.35;
    font-weight: 900;
}

.movie-card__title a:hover {
    color: var(--cyan-dark);
}

.movie-card__meta {
    margin: 7px 0;
    color: var(--cyan-dark);
    font-size: 14px;
    font-weight: 800;
}

.movie-card__desc {
    min-height: 48px;
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 14px;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.tag-list span {
    display: inline-flex;
    padding: 4px 9px;
    border-radius: 999px;
    color: #0e7490;
    background: #ecfeff;
    font-size: 12px;
    font-weight: 800;
}

.tag-list--light span {
    color: #e0f2fe;
    background: rgba(255, 255, 255, 0.14);
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 30px;
    align-items: start;
}

.rank-panel {
    position: sticky;
    top: 92px;
    padding: 22px;
    border-radius: var(--radius);
    color: #ffffff;
    background:
        radial-gradient(circle at 20% 0, rgba(6, 182, 212, 0.35), transparent 30%),
        linear-gradient(145deg, #0f172a, #111827);
    box-shadow: var(--shadow);
}

.rank-panel__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

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

.rank-panel__head a {
    color: #67e8f9;
    font-weight: 900;
}

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

.rank-panel li a {
    display: grid;
    grid-template-columns: 44px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.07);
}

.rank-panel li a:hover {
    background: rgba(6, 182, 212, 0.18);
}

.rank-no {
    color: #67e8f9;
    font-weight: 900;
}

.rank-title {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-weight: 800;
}

.rank-year {
    color: #cbd5e1;
    font-size: 13px;
}

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

.category-card {
    position: relative;
    min-height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: hidden;
    padding: 18px;
    border-radius: var(--radius);
    color: #ffffff;
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow);
}

.category-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.15), rgba(15, 23, 42, 0.86));
}

.category-card span,
.category-card small {
    position: relative;
    z-index: 1;
}

.category-card span {
    font-size: 20px;
    font-weight: 900;
}

.category-card small {
    margin-top: 7px;
    color: #dbeafe;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: var(--dark);
    background-size: cover;
    background-position: center;
}

.page-hero {
    min-height: 320px;
    display: flex;
    align-items: center;
}

.page-hero--soft {
    background:
        radial-gradient(circle at 18% 20%, rgba(6, 182, 212, 0.38), transparent 30%),
        linear-gradient(135deg, #0f172a 0%, #164e63 50%, #1d4ed8 100%);
}

.page-hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.88), rgba(15, 23, 42, 0.42));
}

.page-hero__content,
.page-hero .container {
    position: relative;
    z-index: 1;
    padding: 70px 0;
}

.eyebrow {
    display: inline-flex;
    padding: 6px 13px;
    border-radius: 999px;
    color: #cffafe;
    background: rgba(6, 182, 212, 0.18);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.page-hero h1,
.detail-info h1 {
    margin: 14px 0 12px;
    font-size: clamp(38px, 7vw, 70px);
    line-height: 1.04;
    letter-spacing: -0.05em;
}

.page-hero p {
    max-width: 720px;
    margin: 0 0 24px;
    color: #dbeafe;
    font-size: 18px;
}

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

.category-overview-card {
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: 20px;
    overflow: hidden;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.category-overview-card__cover {
    min-height: 170px;
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(6, 182, 212, 0.85), rgba(37, 99, 235, 0.85)),
        #0f172a;
    background-size: cover;
    background-position: center;
}

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

.category-overview-card p {
    margin: 0 0 10px;
    color: var(--muted);
}

.category-sample {
    color: #0f172a;
    font-weight: 800;
}

.pager-links {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 34px;
}

.pager-links a,
.side-nav a {
    padding: 13px 16px;
    border-radius: 16px;
    background: #ffffff;
    border: 1px solid var(--line);
    color: var(--cyan-dark);
    font-weight: 900;
}

.detail-hero {
    min-height: 540px;
}

.detail-backdrop,
.detail-hero__overlay {
    position: absolute;
    inset: 0;
}

.detail-backdrop {
    background-size: cover;
    background-position: center;
    transform: scale(1.06);
    filter: blur(2px);
}

.detail-hero__overlay {
    background:
        radial-gradient(circle at 75% 18%, rgba(6, 182, 212, 0.36), transparent 26%),
        linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.72) 48%, rgba(15, 23, 42, 0.32));
}

.detail-layout {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 310px 1fr;
    gap: 40px;
    align-items: center;
    padding: 70px 0;
}

.detail-poster {
    min-height: 440px;
    border-radius: 30px;
    background:
        linear-gradient(135deg, rgba(6, 182, 212, 0.85), rgba(37, 99, 235, 0.85)),
        #0f172a;
    background-size: cover;
    background-position: center;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.4);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #bae6fd;
    font-weight: 800;
}

.detail-one-line {
    max-width: 820px;
    margin: 0 0 20px;
    color: #dbeafe;
    font-size: 20px;
}

.detail-meta {
    margin-bottom: 18px;
}

.detail-actions {
    margin-top: 28px;
}

.player-section {
    margin-top: -70px;
    position: relative;
    z-index: 4;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #020617;
    box-shadow: 0 34px 80px rgba(15, 23, 42, 0.34);
    aspect-ratio: 16 / 9;
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    gap: 14px;
    align-items: center;
    justify-content: center;
    border: 0;
    color: #ffffff;
    background:
        radial-gradient(circle at 50% 40%, rgba(6, 182, 212, 0.28), transparent 28%),
        rgba(2, 6, 23, 0.48);
}

.player-overlay.is-hidden {
    display: none;
}

.player-overlay span {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 20px 45px rgba(6, 182, 212, 0.34);
    font-size: 28px;
}

.player-overlay strong {
    font-size: 20px;
}

.detail-main {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 30px;
    padding: 44px 0 18px;
}

.detail-article,
.detail-side {
    padding: 26px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid var(--line);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.detail-article h2,
.detail-side h2 {
    margin: 0 0 14px;
    font-size: 24px;
}

.detail-article p {
    margin: 0 0 24px;
    color: #334155;
    font-size: 17px;
}

.detail-side dl {
    display: grid;
    grid-template-columns: 76px 1fr;
    gap: 10px 14px;
    margin: 0;
}

.detail-side dt {
    color: var(--muted);
    font-weight: 800;
}

.detail-side dd {
    margin: 0;
    font-weight: 800;
}

.side-nav {
    display: grid;
    gap: 10px;
    margin-top: 24px;
}

.site-footer {
    margin-top: 34px;
    color: #cbd5e1;
    background:
        radial-gradient(circle at 18% 0, rgba(6, 182, 212, 0.24), transparent 26%),
        linear-gradient(135deg, #0f172a, #111827);
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 28px;
}

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

.footer-brand p,
.site-footer p {
    color: #94a3b8;
}

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

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

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

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 18px 0 24px;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    color: #94a3b8;
}

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

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

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

    .rank-panel {
        position: static;
    }
}

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

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

    .hero-slider {
        min-height: 640px;
    }

    .hero-content {
        padding: 82px 0 110px;
    }

    .filter-panel,
    .filter-panel__selects,
    .detail-layout,
    .category-overview-card {
        grid-template-columns: 1fr;
    }

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

    .detail-poster {
        min-height: 360px;
    }

    .player-section {
        margin-top: -44px;
    }
}

@media (max-width: 560px) {
    .container,
    .site-nav,
    .mobile-panel,
    .footer-inner,
    .footer-bottom {
        width: min(100% - 24px, 1180px);
    }

    .brand__text {
        font-size: 19px;
    }

    .hero-content h1,
    .detail-info h1,
    .page-hero h1 {
        font-size: 38px;
    }

    .hero-controls {
        bottom: 22px;
    }

    .hero-arrow {
        width: 38px;
        height: 38px;
    }

    .movie-grid,
    .movie-grid--compact,
    .category-grid,
    .category-overview-grid {
        grid-template-columns: 1fr;
    }

    .movie-card__poster {
        min-height: 245px;
    }

    .section-title,
    .pager-links {
        align-items: stretch;
        flex-direction: column;
    }

    .player-box {
        border-radius: 20px;
    }
}
