:root {
    --bg: #f8fafc;
    --text: #0f172a;
    --muted: #64748b;
    --soft: #e2e8f0;
    --brand: #f59e0b;
    --brand-dark: #d97706;
    --dark: #0f172a;
    --panel: #ffffff;
    --shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
    font: inherit;
}

.site-nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, #0f172a 0%, #1e293b 52%, #0f172a 100%);
    color: #ffffff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.28);
}

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

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

.brand {
    font-size: 22px;
}

.brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    color: #ffffff;
    box-shadow: 0 8px 22px rgba(245, 158, 11, 0.36);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 18px;
}

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

.nav-link:hover,
.nav-link.active {
    color: #fbbf24;
}

.mobile-toggle {
    display: none;
    border: 0;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 8px 12px;
    cursor: pointer;
}

.mobile-menu {
    display: none;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: #1e293b;
    padding: 12px 18px 18px;
}

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

.mobile-link {
    display: block;
    padding: 10px 8px;
    border-radius: 10px;
    color: #e2e8f0;
}

.mobile-link:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fbbf24;
}

.hero {
    position: relative;
    height: 70vh;
    min-height: 540px;
    overflow: hidden;
    background: #000000;
}

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

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

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

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.46) 48%, rgba(0, 0, 0, 0.2));
}

.hero-content {
    position: absolute;
    left: max(32px, calc((100vw - 1180px) / 2));
    right: 32px;
    bottom: 86px;
    max-width: 760px;
    color: #ffffff;
}

.hero-kicker,
.eyebrow,
.category-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    border-radius: 999px;
    background: #f59e0b;
    color: #ffffff;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 800;
}

.hero-content h1 {
    margin: 18px 0 12px;
    font-size: clamp(40px, 6vw, 72px);
    line-height: 1.04;
    font-weight: 900;
    text-shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
}

.hero-content p {
    margin: 0 0 26px;
    color: #e2e8f0;
    font-size: 20px;
    line-height: 1.7;
}

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

.primary-btn,
.ghost-btn,
.section-link,
.quick-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 12px;
    padding: 0 20px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.primary-btn,
.quick-search button {
    border: 0;
    background: #f59e0b;
    color: #ffffff;
    cursor: pointer;
}

.primary-btn:hover,
.quick-search button:hover {
    background: #d97706;
    transform: translateY(-2px);
}

.ghost-btn {
    border: 1px solid rgba(255, 255, 255, 0.44);
    color: #ffffff;
    background: rgba(15, 23, 42, 0.34);
    backdrop-filter: blur(10px);
}

.ghost-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.48);
    backdrop-filter: blur(8px);
    cursor: pointer;
    font-size: 34px;
    line-height: 1;
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

.hero-dot.is-active {
    width: 34px;
    background: #f59e0b;
}

.search-band {
    background: linear-gradient(90deg, #fffbeb, #fff7ed);
    border-bottom: 1px solid #fde68a;
}

.search-band-inner,
.content-section,
.footer-inner,
.detail-hero-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.search-band-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 26px;
    align-items: center;
    padding: 34px 0;
}

.eyebrow {
    background: rgba(245, 158, 11, 0.12);
    color: #b45309;
    margin-bottom: 10px;
}

.search-band h2,
.section-heading h2,
.page-hero h1,
.article-card h2,
.aside-card h2 {
    margin: 0;
    color: #0f172a;
    font-weight: 900;
}

.search-band h2 {
    font-size: 28px;
}

.quick-search,
.filter-panel {
    display: flex;
    gap: 10px;
}

.quick-search input,
.filter-panel input {
    flex: 1;
    min-width: 0;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #ffffff;
    padding: 0 16px;
    min-height: 48px;
    outline: none;
    box-shadow: 0 8px 26px rgba(15, 23, 42, 0.06);
}

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

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

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

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

.section-link {
    color: #b45309;
    background: #fffbeb;
    border: 1px solid #fde68a;
}

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

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

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

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

.movie-card {
    display: block;
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

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

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

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

.movie-card:hover .movie-thumb img {
    transform: scale(1.06);
}

.movie-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.46), transparent 62%);
}

.category-pill {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 2;
    padding: 5px 10px;
    font-size: 12px;
}

.play-mark {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.92);
    color: #ffffff;
    transform: translate(-50%, -50%) scale(0.92);
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.movie-info {
    padding: 16px;
}

.movie-info h3 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 850;
    line-height: 1.35;
}

.movie-info p {
    display: -webkit-box;
    min-height: 44px;
    margin: 0 0 12px;
    overflow: hidden;
    color: var(--muted);
    line-height: 1.55;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
}

.movie-meta span,
.detail-meta span,
.tag-row span,
.filter-chips button {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    border-radius: 999px;
    background: #f1f5f9;
    padding: 0 10px;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
    color: #92400e;
    font-size: 12px;
}

.tag-row span {
    background: #fffbeb;
}

.movie-card-large .large-thumb {
    aspect-ratio: 16 / 9;
}

.movie-card-large .movie-info h3 {
    font-size: 24px;
}

.movie-card-horizontal {
    display: grid;
    grid-template-columns: 170px minmax(0, 1fr);
}

.horizontal-thumb {
    height: 100%;
    min-height: 128px;
    aspect-ratio: auto;
}

.horizontal-info p {
    min-height: auto;
}

.stack-list,
.rank-panel,
.rank-list,
.mini-list {
    display: grid;
    gap: 16px;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.82fr);
    gap: 34px;
}

.rank-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 4;
    border-radius: 999px;
    background: #ef4444;
    color: #ffffff;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 900;
}

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

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

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.58;
    transition: transform 0.28s ease;
}

.category-card:hover img {
    transform: scale(1.06);
}

.category-card div {
    position: absolute;
    inset: auto 20px 20px 20px;
    z-index: 2;
}

.category-card span {
    display: inline-flex;
    margin-bottom: 8px;
    border-radius: 999px;
    background: #f59e0b;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

.category-card h3 {
    margin: 0 0 8px;
    font-size: 24px;
    font-weight: 900;
}

.category-card p {
    margin: 0;
    color: #e2e8f0;
    line-height: 1.6;
}

.home-category-block + .home-category-block {
    margin-top: 52px;
}

.page-hero {
    min-height: 330px;
    display: grid;
    align-items: center;
    background: radial-gradient(circle at top left, rgba(245, 158, 11, 0.28), transparent 34%), linear-gradient(120deg, #0f172a, #1e293b);
    color: #ffffff;
}

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

.page-hero h1 {
    color: #ffffff;
    font-size: clamp(40px, 6vw, 62px);
}

.page-hero p {
    max-width: 760px;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.8;
}

.filter-panel {
    flex-direction: column;
    margin-bottom: 28px;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.9);
    padding: 18px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
}

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

.filter-chips button {
    border: 0;
    cursor: pointer;
    color: #334155;
    min-height: 34px;
}

.filter-chips button:hover,
.filter-chips button.is-active {
    background: #f59e0b;
    color: #ffffff;
}

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

.detail-hero {
    position: relative;
    overflow: hidden;
    min-height: 620px;
    background: #020617;
}

.detail-bg {
    position: absolute;
    inset: 0;
    opacity: 0.42;
    filter: blur(4px) saturate(1.08);
    transform: scale(1.03);
}

.detail-bg-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.98), rgba(15, 23, 42, 0.72), rgba(15, 23, 42, 0.22));
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 310px minmax(0, 1fr);
    gap: 44px;
    align-items: center;
    min-height: 620px;
    padding: 54px 0;
}

.detail-cover {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 24px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.45);
}

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

.detail-copy {
    color: #ffffff;
}

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

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

.detail-copy h1 {
    margin: 18px 0 16px;
    font-size: clamp(38px, 5vw, 64px);
    line-height: 1.08;
    font-weight: 950;
}

.detail-copy p {
    max-width: 860px;
    color: #e2e8f0;
    font-size: 19px;
    line-height: 1.8;
}

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

.detail-tags span {
    background: rgba(245, 158, 11, 0.16);
    color: #fde68a;
}

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

.detail-main,
.detail-aside {
    display: grid;
    gap: 20px;
}

.player-card {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #000000;
    box-shadow: var(--shadow);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.42));
    color: #ffffff;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.player-overlay span {
    display: grid;
    place-items: center;
    width: 82px;
    height: 82px;
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.94);
    font-size: 34px;
    box-shadow: 0 20px 50px rgba(245, 158, 11, 0.35);
}

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

.article-card,
.aside-card {
    border: 1px solid #e2e8f0;
    border-radius: 22px;
    background: #ffffff;
    padding: 24px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
}

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

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

.aside-card dl {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 12px 10px;
    margin: 0;
}

.aside-card dt {
    color: #64748b;
}

.aside-card dd {
    margin: 0;
    font-weight: 700;
}

.aside-card dd a {
    color: #b45309;
}

.mini-card {
    display: grid;
    grid-template-columns: 74px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
}

.mini-card img {
    width: 74px;
    height: 52px;
    border-radius: 10px;
    object-fit: cover;
}

.mini-card span {
    font-weight: 750;
    line-height: 1.4;
}

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

.footer-inner {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 36px;
    padding: 48px 0;
}

.footer-brand {
    color: #ffffff;
    font-size: 20px;
}

.site-footer p {
    color: #94a3b8;
    line-height: 1.7;
}

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

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

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

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

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

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

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

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

@media (max-width: 760px) {
    .hero {
        min-height: 560px;
    }

    .hero-content {
        left: 18px;
        right: 18px;
        bottom: 72px;
    }

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

    .search-band-inner,
    .detail-hero-inner {
        grid-template-columns: 1fr;
    }

    .movie-grid,
    .compact-grid,
    .full-grid,
    .feature-grid,
    .category-grid,
    .footer-inner {
        grid-template-columns: 1fr;
    }

    .movie-card-horizontal {
        grid-template-columns: 132px minmax(0, 1fr);
    }

    .detail-hero-inner {
        min-height: auto;
    }

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

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

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

    .hero-arrow {
        display: none;
    }

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

    .movie-card-horizontal {
        grid-template-columns: 1fr;
    }

    .horizontal-thumb {
        aspect-ratio: 16 / 10;
    }
}
