:root {
    --bg: #f8fafc;
    --text: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --card: #ffffff;
    --teal: #14b8a6;
    --teal-dark: #0f766e;
    --blue: #1e3a8a;
    --orange: #f97316;
    --red: #ef4444;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --soft-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    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;
}

img {
    display: block;
    width: 100%;
    height: auto;
}

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, #1e3a8a 0%, #0f766e 100%);
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.18);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 24px;
    min-height: 72px;
}

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

.logo-mark {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

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

.desktop-nav > a,
.nav-dropdown > a {
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    padding: 0 14px;
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.9);
    transition: background 0.2s ease, color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active {
    background: rgba(255, 255, 255, 0.16);
    color: #ffffff;
}

.nav-dropdown {
    position: relative;
}

.dropdown-panel {
    position: absolute;
    top: 100%;
    left: 0;
    width: 190px;
    padding: 10px;
    border-radius: 16px;
    background: #ffffff;
    color: var(--text);
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s ease;
}

.nav-dropdown:hover .dropdown-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-panel a {
    display: block;
    padding: 10px 12px;
    border-radius: 12px;
    color: #334155;
}

.dropdown-panel a:hover {
    background: #ecfeff;
    color: var(--teal-dark);
}

.top-search {
    position: relative;
    display: flex;
    align-items: center;
    width: 300px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.96);
    padding: 4px;
}

.top-search input,
.mobile-search input,
.page-search-form input,
.filter-bar input {
    width: 100%;
    border: 0;
    outline: 0;
    color: var(--text);
    background: transparent;
}

.top-search input {
    padding: 9px 12px;
}

.top-search button,
.mobile-search button,
.page-search-form button {
    border: 0;
    border-radius: 999px;
    background: var(--teal);
    color: #ffffff;
    padding: 8px 14px;
    cursor: pointer;
}

.search-suggest {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    max-height: 370px;
    overflow: auto;
    border-radius: 18px;
    background: #ffffff;
    color: var(--text);
    box-shadow: var(--shadow);
    display: none;
}

.search-suggest.is-open {
    display: block;
}

.search-suggest a {
    display: grid;
    grid-template-columns: 58px 1fr;
    gap: 10px;
    padding: 10px;
    border-bottom: 1px solid var(--line);
}

.search-suggest img {
    height: 42px;
    border-radius: 10px;
    object-fit: cover;
}

.search-suggest strong {
    display: block;
    font-size: 14px;
}

.search-suggest span {
    color: var(--muted);
    font-size: 12px;
}

.menu-toggle {
    display: none;
    margin-left: auto;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.15);
}

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

.mobile-panel {
    display: none;
    padding: 0 16px 16px;
}

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

.mobile-panel a {
    padding: 12px 14px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.12);
}

.mobile-search {
    display: flex;
    gap: 8px;
    background: #ffffff;
    border-radius: 999px;
    padding: 5px;
}

.mobile-search input {
    padding: 9px 12px;
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    background: linear-gradient(90deg, var(--blue), var(--teal-dark));
}

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

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

.hero-slide > img,
.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.46), rgba(0, 0, 0, 0.12));
}

.hero-content {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    color: #ffffff;
    max-width: min(1180px, calc(100% - 32px));
}

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border-radius: 999px;
    background: var(--teal);
    color: #ffffff;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.hero h1 {
    max-width: 720px;
    margin: 18px 0 12px;
    font-size: clamp(38px, 6vw, 68px);
    line-height: 1.05;
    font-weight: 900;
}

.hero p {
    max-width: 660px;
    margin: 0 0 20px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
}

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

.hero-meta span,
.detail-meta span {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    padding: 7px 12px;
    font-size: 14px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

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

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

.btn.primary {
    background: var(--teal);
    color: #ffffff;
    box-shadow: 0 12px 24px rgba(20, 184, 166, 0.3);
}

.btn.ghost {
    background: rgba(255, 255, 255, 0.16);
    color: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.btn.text {
    color: #ffffff;
    background: transparent;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 5;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.45);
    color: #ffffff;
    font-size: 36px;
    cursor: pointer;
    transform: translateY(-50%);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

.hero-dots button {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    cursor: pointer;
}

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

.section {
    padding: 56px 0;
}

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

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

.section-heading h2 {
    margin: 10px 0 0;
    font-size: clamp(26px, 4vw, 36px);
    line-height: 1.15;
}

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

.section-heading > a {
    color: var(--teal-dark);
    font-weight: 800;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: 22px;
    background: var(--card);
    box-shadow: var(--soft-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.card-poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, #dbeafe, #ccfbf1);
}

.card-poster img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.play-chip,
.year-chip {
    position: absolute;
    display: inline-grid;
    place-items: center;
    border-radius: 999px;
    color: #ffffff;
}

.play-chip {
    left: 14px;
    bottom: 14px;
    width: 38px;
    height: 38px;
    background: rgba(20, 184, 166, 0.92);
}

.year-chip {
    top: 12px;
    right: 12px;
    padding: 4px 10px;
    background: rgba(15, 23, 42, 0.72);
    font-size: 12px;
    font-weight: 700;
}

.card-body {
    padding: 16px;
}

.card-meta {
    color: var(--teal-dark);
    font-size: 13px;
    font-weight: 800;
}

.card-body h2 {
    margin: 6px 0 8px;
    font-size: 18px;
    line-height: 1.3;
}

.card-body p {
    display: -webkit-box;
    min-height: 48px;
    margin: 0 0 12px;
    overflow: hidden;
    color: var(--muted);
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

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

.tag-row span {
    border-radius: 999px;
    background: #f1f5f9;
    color: #475569;
    padding: 4px 8px;
    font-size: 12px;
}

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

.category-tile {
    position: relative;
    overflow: hidden;
    min-height: 220px;
    border-radius: 26px;
    background: #0f172a;
    color: #ffffff;
    box-shadow: var(--soft-shadow);
}

.category-tile img {
    position: absolute;
    inset: 0;
    height: 100%;
    object-fit: cover;
    opacity: 0.52;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.category-tile:hover img {
    opacity: 0.68;
    transform: scale(1.06);
}

.category-tile span,
.category-tile p {
    position: relative;
    z-index: 1;
    display: block;
    padding: 0 18px;
}

.category-tile span {
    padding-top: 112px;
    font-size: 22px;
    font-weight: 900;
}

.category-tile p {
    margin: 8px 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 14px;
}

.split-section {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 24px;
}

.panel {
    border-radius: 30px;
    padding: 28px;
    background: var(--card);
    box-shadow: var(--soft-shadow);
}

.hot-panel {
    background: linear-gradient(135deg, #fff7ed, #fef2f2);
}

.editor-panel {
    background: linear-gradient(135deg, #eff6ff, #ecfeff);
}

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

.rank-row {
    display: grid;
    grid-template-columns: 48px 88px 1fr;
    gap: 14px;
    align-items: center;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.8);
    padding: 12px;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
}

.rank-row strong {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--red), var(--orange));
    color: #ffffff;
    font-size: 20px;
}

.rank-row img {
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-row span {
    display: block;
    font-weight: 800;
}

.rank-row em {
    display: block;
    color: var(--muted);
    font-size: 13px;
    font-style: normal;
}

.mini-grid {
    display: grid;
    gap: 12px;
}

.mini-card {
    display: grid;
    grid-template-columns: 82px 1fr;
    gap: 12px;
    align-items: center;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.8);
    padding: 10px;
}

.mini-card img {
    height: 56px;
    border-radius: 12px;
    object-fit: cover;
}

.mini-card span {
    display: block;
    font-weight: 800;
}

.mini-card em {
    display: block;
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

.scroll-row {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding-bottom: 12px;
}

.wide-card {
    flex: 0 0 330px;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #1e3a8a, #0f766e);
    color: #ffffff;
}

.page-hero {
    padding: 82px 0 70px;
}

.compact-hero {
    padding: 66px 0 58px;
}

.page-hero h1 {
    max-width: 850px;
    margin: 14px 0 12px;
    font-size: clamp(34px, 5vw, 54px);
    line-height: 1.1;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
}

.breadcrumb {
    display: inline-flex;
    color: #a7f3d0;
    font-weight: 800;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(240px, 360px) 1fr;
    gap: 18px;
    align-items: start;
    margin-bottom: 24px;
}

.filter-bar input,
.page-search-form input {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
    padding: 13px 16px;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
}

.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-buttons button {
    border: 0;
    border-radius: 999px;
    background: #ffffff;
    color: #334155;
    padding: 12px 16px;
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.06);
    cursor: pointer;
}

.filter-buttons button.is-active {
    background: var(--teal);
    color: #ffffff;
}

.category-overview-block + .category-overview-block {
    padding-top: 12px;
}

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

.ranking-card {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 18px;
    border-radius: 24px;
    background: #ffffff;
    padding: 14px;
    box-shadow: var(--soft-shadow);
}

.ranking-poster {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 11;
    border-radius: 18px;
}

.ranking-poster img {
    height: 100%;
    object-fit: cover;
}

.ranking-poster strong {
    position: absolute;
    top: 10px;
    left: 10px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--red), var(--orange));
    color: #ffffff;
}

.ranking-card h2 {
    margin: 4px 0 8px;
    font-size: 20px;
}

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

.ranking-card span {
    color: var(--teal-dark);
    font-weight: 800;
}

.page-search-form {
    display: flex;
    width: min(620px, 100%);
    gap: 10px;
    margin-top: 24px;
}

.detail-hero {
    min-height: 480px;
    display: flex;
    align-items: center;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    opacity: 0.24;
    filter: blur(2px);
}

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(15, 23, 42, 0.98), rgba(15, 118, 110, 0.72));
}

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

.detail-poster {
    overflow: hidden;
    border-radius: 28px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.28);
}

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

.detail-copy h1 {
    margin: 14px 0;
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1.1;
}

.detail-copy p {
    max-width: 850px;
    margin: 0 0 20px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
}

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

.player-section {
    padding-bottom: 16px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #020617;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.movie-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    border: 0;
    background: radial-gradient(circle at center, rgba(20, 184, 166, 0.42), rgba(2, 6, 23, 0.72));
    color: #ffffff;
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-overlay span {
    display: grid;
    place-items: center;
    width: 82px;
    height: 82px;
    border-radius: 999px;
    background: var(--teal);
    box-shadow: 0 22px 50px rgba(20, 184, 166, 0.36);
    font-size: 34px;
}

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

.article-section {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 24px;
    align-items: start;
}

.article-card,
.side-card {
    border-radius: 26px;
    background: #ffffff;
    padding: 28px;
    box-shadow: var(--soft-shadow);
}

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

.article-card h2 + p,
.article-card p + h2 {
    margin-top: 22px;
}

.article-card p {
    margin: 0 0 12px;
    color: #334155;
    font-size: 16px;
}

.side-card {
    display: grid;
    gap: 12px;
}

.side-card a {
    display: block;
    border-radius: 16px;
    background: #f8fafc;
    padding: 13px 14px;
    color: var(--teal-dark);
    font-weight: 800;
}

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

.site-footer {
    background: linear-gradient(180deg, #1f2937, #0f172a);
    color: #cbd5e1;
    margin-top: 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 36px;
    padding: 46px 0;
}

.footer-logo {
    color: #ffffff;
    margin-bottom: 12px;
}

.site-footer p {
    max-width: 520px;
    margin: 0;
}

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

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

.footer-links a:hover {
    color: #5eead4;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 18px 16px;
    text-align: center;
    color: #94a3b8;
}

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

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

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

    .top-search {
        width: 240px;
    }
}

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

    .menu-toggle {
        display: block;
    }

    .header-inner {
        min-height: 64px;
    }

    .hero {
        height: 560px;
    }

    .hero-content {
        justify-content: flex-end;
        padding-bottom: 78px;
    }

    .hero p {
        font-size: 16px;
    }

    .hero-arrow {
        display: none;
    }

    .section-heading,
    .split-section,
    .article-section,
    .footer-grid,
    .detail-layout,
    .filter-bar,
    .ranking-card {
        grid-template-columns: 1fr;
    }

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

    .split-section,
    .article-section {
        display: grid;
    }

    .movie-grid,
    .dense-grid,
    .related-grid,
    .ranking-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .detail-layout {
        gap: 22px;
    }

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

    .article-section {
        gap: 20px;
    }
}

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

    .logo {
        font-size: 18px;
    }

    .hero {
        height: 520px;
    }

    .hero h1 {
        font-size: 36px;
    }

    .hero-actions {
        width: 100%;
    }

    .btn {
        flex: 1 1 auto;
        padding: 0 14px;
    }

    .movie-grid,
    .dense-grid,
    .related-grid,
    .category-grid,
    .ranking-grid {
        grid-template-columns: 1fr;
    }

    .rank-row {
        grid-template-columns: 42px 72px 1fr;
    }

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

    .page-search-form {
        flex-direction: column;
    }

    .detail-copy h1 {
        font-size: 34px;
    }

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

    .article-card,
    .side-card,
    .panel {
        padding: 20px;
        border-radius: 22px;
    }
}
