:root {
    color-scheme: light;
    --bg: #f8fafc;
    --surface: #ffffff;
    --surface-soft: #f1f5f9;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --dark: #020617;
    --dark-soft: #0f172a;
    --cyan: #06b6d4;
    --blue: #2563eb;
    --orange: #f97316;
    --shadow: 0 24px 70px rgba(15, 23, 42, 0.16);
    --radius: 22px;
    --radius-sm: 14px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    background: var(--bg);
    color: var(--ink);
    line-height: 1.65;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(15, 23, 42, 0.94);
    color: #ffffff;
    border-bottom: 1px solid rgba(148, 163, 184, 0.24);
    backdrop-filter: blur(18px);
}

.header-inner {
    width: min(1180px, calc(100% - 32px));
    min-height: 76px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    font-weight: 900;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 14px 36px rgba(6, 182, 212, 0.26);
}

.brand-text {
    display: grid;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 22px;
    letter-spacing: -0.04em;
}

.brand-text em {
    margin-top: 4px;
    color: #cbd5e1;
    font-size: 12px;
    font-style: normal;
}

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

.nav-link,
.mobile-link {
    color: #e2e8f0;
    font-weight: 700;
    transition: color 180ms ease, transform 180ms ease;
}

.nav-link:hover,
.mobile-link:hover,
.nav-link.is-active,
.mobile-link.is-active {
    color: #67e8f9;
}

.nav-search,
.mobile-search {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-search input,
.mobile-search input,
.landing-search input,
.search-page-form input,
.filter-field input,
.filter-field select {
    border: 1px solid rgba(148, 163, 184, 0.36);
    border-radius: 999px;
    outline: none;
    background: rgba(255, 255, 255, 0.95);
    color: var(--ink);
    transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.nav-search input {
    width: 220px;
    padding: 10px 14px;
}

.nav-search button,
.mobile-search button,
.landing-search button,
.search-page-form button {
    border: 0;
    border-radius: 999px;
    padding: 10px 18px;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    color: #ffffff;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 12px 26px rgba(37, 99, 235, 0.22);
}

.nav-search input:focus,
.mobile-search input:focus,
.landing-search input:focus,
.search-page-form input:focus,
.filter-field input:focus,
.filter-field select:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.14);
}

.mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    cursor: pointer;
}

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

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
}

.mobile-nav.is-open {
    display: grid;
    gap: 12px;
}

.mobile-search input {
    flex: 1;
    padding: 11px 14px;
}

.search-panel {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: min(420px, 92vw);
    max-height: 440px;
    overflow: auto;
    display: none;
    padding: 10px;
    border: 1px solid rgba(148, 163, 184, 0.32);
    border-radius: 18px;
    background: #ffffff;
    color: var(--ink);
    box-shadow: var(--shadow);
}

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

.search-result {
    display: grid;
    grid-template-columns: 54px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px;
    border-radius: 14px;
    transition: background 180ms ease;
}

.search-result:hover {
    background: #f1f5f9;
}

.search-result img {
    width: 54px;
    height: 72px;
    object-fit: cover;
    border-radius: 10px;
    background: linear-gradient(135deg, #0f172a, #0891b2);
}

.search-result strong,
.search-result span,
.search-result em {
    display: block;
}

.search-result strong {
    line-height: 1.35;
}

.search-result span,
.search-result em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

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

.hero-slider {
    position: relative;
    overflow: hidden;
    background: var(--dark);
    color: #ffffff;
}

.hero-stage {
    position: relative;
    min-height: 650px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 48px;
    align-items: center;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    left: 50%;
    transform: translateX(-50%);
    isolation: isolate;
    opacity: 0;
    pointer-events: none;
    transition: opacity 540ms ease;
}

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

.hero-bg {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    z-index: 0;
    width: 100vw;
    background-size: cover;
    background-position: center;
    transform: translateX(-50%) scale(1.05);
    filter: saturate(1.08);
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 20%, rgba(6, 182, 212, 0.18), transparent 38%);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 720px;
    padding-top: 40px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    padding: 6px 12px;
    border: 1px solid rgba(103, 232, 249, 0.38);
    border-radius: 999px;
    color: #67e8f9;
    background: rgba(6, 182, 212, 0.12);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero-content h1,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    font-size: clamp(40px, 7vw, 76px);
    line-height: 1;
    letter-spacing: -0.07em;
}

.hero-content p,
.page-hero p,
.detail-info p {
    max-width: 720px;
    color: #dbeafe;
    font-size: 18px;
}

.hero-tags span,
.detail-tags span {
    background: rgba(255, 255, 255, 0.13);
    color: #ffffff;
}

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

.primary-button,
.ghost-button,
.text-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.primary-button {
    padding: 13px 24px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 18px 36px rgba(37, 99, 235, 0.25);
}

.ghost-button {
    padding: 12px 22px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.primary-button:hover,
.ghost-button:hover,
.text-link:hover {
    transform: translateY(-2px);
}

.hero-poster {
    position: relative;
    z-index: 1;
    display: block;
    overflow: hidden;
    border-radius: 32px;
    box-shadow: 0 36px 100px rgba(0, 0, 0, 0.4);
}

.hero-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    background: linear-gradient(135deg, #0f172a, #0891b2);
}

.hero-poster span {
    position: absolute;
    inset: auto 24px 24px auto;
    width: 66px;
    height: 66px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--cyan);
    color: #ffffff;
    font-size: 28px;
    box-shadow: 0 18px 40px rgba(6, 182, 212, 0.36);
}

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

.hero-dot {
    width: 42px;
    height: 6px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.28);
    cursor: pointer;
}

.hero-dot.is-active {
    background: #67e8f9;
}

.search-landing {
    position: relative;
    margin-top: -36px;
    z-index: 5;
}

.landing-search,
.search-page-form {
    position: relative;
    display: flex;
    gap: 12px;
    padding: 14px;
    border-radius: 28px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.landing-search input,
.search-page-form input {
    flex: 1;
    padding: 16px 18px;
}

.landing-panel {
    left: 14px;
    right: auto;
    top: calc(100% + 8px);
    width: min(680px, 92vw);
}

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

.surface-section {
    background: var(--surface-soft);
}

.section-heading {
    margin-bottom: 30px;
}

.section-heading span {
    color: var(--cyan);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-heading h2 {
    margin: 6px 0 8px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.section-heading p {
    max-width: 760px;
    margin: 0;
    color: var(--muted);
}

.row-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
}

.compact-heading h2 {
    font-size: 28px;
}

.text-link {
    color: var(--blue);
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
    transition: transform 220ms ease, box-shadow 220ms ease, border-color 220ms ease;
}

.movie-card:hover {
    transform: translateY(-7px);
    border-color: rgba(6, 182, 212, 0.36);
    box-shadow: var(--shadow);
}

.poster-link {
    position: relative;
    display: block;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a, #0891b2);
}

.poster-link img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 520ms ease;
}

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(2, 6, 23, 0.58), transparent 52%);
}

.play-badge {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #ffffff;
    background: var(--cyan);
    transform: translate(-50%, -50%) scale(0.85);
    opacity: 0;
    transition: opacity 220ms ease, transform 220ms ease;
}

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

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

.movie-meta-line,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

.movie-meta-line span,
.detail-meta span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #f1f5f9;
}

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

.movie-card p {
    min-height: 46px;
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 14px;
}

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

.tag-row span {
    padding: 5px 9px;
    border-radius: 999px;
    background: #ecfeff;
    color: #0e7490;
    font-size: 12px;
    font-weight: 800;
}

.movie-card-compact {
    position: relative;
}

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

.category-card {
    min-height: 170px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px;
    border-radius: var(--radius);
    color: #ffffff;
    background: linear-gradient(135deg, #0f172a, #0e7490 58%, #2563eb);
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.18);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.24);
}

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

.category-card strong {
    color: #dbeafe;
    font-size: 14px;
    font-weight: 600;
}

.category-card em {
    font-style: normal;
    color: #67e8f9;
    font-weight: 900;
}

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

.ranking-panel,
.story-card,
.side-card,
.ranking-block {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

.ranking-panel {
    position: sticky;
    top: 100px;
    padding: 24px;
}

.ranking-list {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 12px;
}

.ranking-link {
    display: grid;
    grid-template-columns: 42px 54px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px;
    border-radius: 16px;
    transition: background 180ms ease;
}

.ranking-link:hover {
    background: #f1f5f9;
}

.ranking-number {
    font-size: 18px;
    font-weight: 950;
    color: var(--orange);
}

.ranking-link img {
    width: 54px;
    height: 72px;
    object-fit: cover;
    border-radius: 10px;
    background: linear-gradient(135deg, #0f172a, #0891b2);
}

.ranking-info strong,
.ranking-info em {
    display: block;
}

.ranking-info strong {
    line-height: 1.3;
}

.ranking-info em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

.full-button {
    width: 100%;
    margin-top: 20px;
}

.page-hero {
    padding: 90px 0;
    color: #ffffff;
    background: radial-gradient(circle at 18% 20%, rgba(6, 182, 212, 0.24), transparent 30%), linear-gradient(135deg, #020617, #0f172a 60%, #0e7490);
}

.compact-hero h1 {
    font-size: clamp(38px, 6vw, 62px);
}

.filter-bar {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, minmax(150px, 1fr));
    gap: 16px;
    margin-bottom: 30px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.08);
}

.filter-field {
    display: grid;
    gap: 8px;
}

.filter-field label {
    color: var(--muted);
    font-size: 13px;
    font-weight: 900;
}

.filter-field input,
.filter-field select {
    width: 100%;
    padding: 12px 14px;
}

.empty-state {
    display: none;
    padding: 38px;
    border-radius: var(--radius);
    background: #ffffff;
    color: var(--muted);
    text-align: center;
}

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

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

.ranking-block {
    margin-bottom: 24px;
    padding: 24px;
}

.ranking-block h2 {
    margin: 0 0 18px;
}

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

.detail-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: saturate(1.05);
}

.detail-hero-inner {
    position: relative;
    padding: 54px 0 68px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
    color: #cbd5e1;
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #67e8f9;
}

.detail-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
}

.detail-poster {
    overflow: hidden;
    border-radius: 30px;
    box-shadow: 0 36px 100px rgba(0, 0, 0, 0.36);
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    background: linear-gradient(135deg, #0f172a, #0891b2);
}

.detail-info h1 {
    max-width: 850px;
}

.detail-info p {
    color: #dbeafe;
}

.detail-meta span {
    background: rgba(255, 255, 255, 0.12);
    color: #e2e8f0;
}

.player-section {
    background: #020617;
    color: #ffffff;
}

.player-section .section-heading p {
    color: #cbd5e1;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(103, 232, 249, 0.22);
    border-radius: 30px;
    background: #000000;
    box-shadow: 0 36px 100px rgba(0, 0, 0, 0.3);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    gap: 12px;
    border: 0;
    color: #ffffff;
    background: radial-gradient(circle at center, rgba(6, 182, 212, 0.22), rgba(2, 6, 23, 0.74));
    cursor: pointer;
}

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

.player-icon {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    font-size: 34px;
    box-shadow: 0 24px 50px rgba(6, 182, 212, 0.36);
}

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

.player-message {
    position: absolute;
    left: 18px;
    bottom: 18px;
    z-index: 4;
    display: none;
    max-width: calc(100% - 36px);
    padding: 10px 14px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.82);
    color: #e2e8f0;
    font-size: 13px;
}

.player-message.is-visible {
    display: block;
}

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

.story-card,
.side-card {
    padding: 28px;
}

.story-card h2,
.side-card h2 {
    margin-top: 0;
}

.story-card p {
    color: #334155;
    font-size: 17px;
}

.side-card dl {
    display: grid;
    grid-template-columns: 70px 1fr;
    gap: 12px;
    margin: 0;
}

.side-card dt {
    color: var(--muted);
    font-weight: 900;
}

.side-card dd {
    margin: 0;
}

.site-footer {
    background: #020617;
    color: #94a3b8;
}

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

.footer-brand {
    color: #ffffff;
    font-size: 22px;
    font-weight: 900;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: #ffffff;
}

.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;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    padding: 22px 0;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    font-size: 14px;
}

.search-page-meta {
    margin: 26px 0;
    color: var(--muted);
    font-weight: 800;
}

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

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

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

    .ranking-panel {
        position: static;
    }
}

@media (max-width: 860px) {
    .header-inner {
        min-height: 68px;
    }

    .main-nav {
        display: none;
    }

    .mobile-toggle {
        display: block;
        margin-left: auto;
    }

    .hero-stage {
        min-height: 780px;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 46px 0 96px;
    }

    .hero-poster {
        width: min(260px, 70vw);
    }

    .featured-grid,
    .movie-grid,
    .category-grid,
    .wide-ranking-list,
    .footer-grid,
    .filter-bar,
    .detail-layout {
        grid-template-columns: 1fr;
    }

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

    .detail-poster {
        width: min(280px, 80vw);
    }

    .footer-bottom {
        flex-direction: column;
    }
}

@media (max-width: 560px) {
    .brand-text strong {
        font-size: 18px;
    }

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

    .hero-content p,
    .page-hero p,
    .detail-info p {
        font-size: 16px;
    }

    .landing-search,
    .search-page-form {
        flex-direction: column;
        border-radius: 22px;
    }

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

    .ranking-link {
        grid-template-columns: 36px 48px 1fr;
    }
}
