:root {
    --color-slate-950: #020617;
    --color-slate-900: #0f172a;
    --color-slate-800: #1e293b;
    --color-slate-700: #334155;
    --color-slate-100: #f1f5f9;
    --color-gray-50: #f9fafb;
    --color-gray-100: #f3f4f6;
    --color-gray-500: #6b7280;
    --color-gray-600: #4b5563;
    --color-gray-800: #1f2937;
    --color-gray-900: #111827;
    --color-orange-50: #fff7ed;
    --color-orange-500: #f97316;
    --color-orange-600: #ea580c;
    --color-amber-400: #fbbf24;
    --color-amber-500: #f59e0b;
    --shadow-card: 0 18px 40px rgba(15, 23, 42, 0.12);
    --shadow-soft: 0 10px 28px rgba(15, 23, 42, 0.10);
    --radius-lg: 18px;
    --radius-md: 14px;
    --container: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--color-gray-900);
    background: linear-gradient(135deg, #f8fafc 0%, #fff7ed 48%, #fef3c7 100%);
    line-height: 1.6;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #ffffff;
    background: linear-gradient(90deg, var(--color-slate-900), var(--color-slate-800), var(--color-slate-900));
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.28);
}

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

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

.brand-mark {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-orange-500), var(--color-amber-500));
    box-shadow: 0 10px 26px rgba(249, 115, 22, 0.35);
    font-size: 14px;
}

.brand-copy {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-copy strong {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 0.02em;
    background: linear-gradient(90deg, #fb923c, #fbbf24);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-copy small {
    margin-top: 4px;
    color: #cbd5e1;
    font-size: 12px;
}

.header-search,
.inline-search,
.mobile-search {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-search {
    flex: 1 1 420px;
    max-width: 460px;
}

.header-search input,
.mobile-search input {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.38);
    color: #ffffff;
    background: rgba(51, 65, 85, 0.9);
    border-radius: 999px;
    padding: 10px 16px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.header-search input::placeholder,
.mobile-search input::placeholder {
    color: #94a3b8;
}

.header-search input:focus,
.mobile-search input:focus {
    border-color: var(--color-orange-500);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.20);
    background: rgba(30, 41, 59, 1);
}

.header-search button,
.mobile-search button {
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-orange-500), var(--color-amber-500));
    border-radius: 999px;
    padding: 10px 15px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    font-weight: 650;
}

.desktop-nav a,
.mobile-panel nav a {
    color: #f8fafc;
    transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-panel nav a:hover,
.mobile-panel nav a.is-active {
    color: #fb923c;
}

.nav-toggle {
    display: none;
    border: 0;
    color: #ffffff;
    background: rgba(51, 65, 85, 0.9);
    border-radius: 10px;
    padding: 9px 12px;
}

.mobile-panel {
    display: none;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
    padding: 16px;
    background: var(--color-slate-900);
}

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

.mobile-panel nav {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}

.category-strip {
    background: rgba(15, 23, 42, 0.72);
    border-top: 1px solid rgba(148, 163, 184, 0.22);
}

.category-strip-inner {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    scrollbar-width: none;
    padding: 10px 0;
}

.category-strip-inner::-webkit-scrollbar {
    display: none;
}

.category-strip a {
    color: #cbd5e1;
    white-space: nowrap;
    font-size: 14px;
}

.category-strip a:hover {
    color: #fb923c;
}

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

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

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

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.52) 46%, rgba(0, 0, 0, 0.18) 100%);
}

.hero-content {
    position: absolute;
    left: 50%;
    bottom: 76px;
    transform: translateX(-50%);
    z-index: 2;
    max-width: var(--container);
    color: #ffffff;
}

.hero-kicker,
.section-kicker {
    display: inline-flex;
    width: fit-content;
    color: #ffffff;
    background: linear-gradient(90deg, var(--color-orange-500), var(--color-amber-500));
    border-radius: 999px;
    padding: 5px 14px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero h1 {
    max-width: 760px;
    margin: 18px 0 14px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.hero p {
    max-width: 700px;
    margin: 0 0 22px;
    color: #e5e7eb;
    font-size: 18px;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 22px;
    color: #f8fafc;
    margin-bottom: 30px;
}

.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: 10px 24px;
    border: 0;
    font-weight: 800;
    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(--color-orange-500), var(--color-amber-500));
    box-shadow: 0 14px 30px rgba(249, 115, 22, 0.28);
}

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

.hero-dots {
    position: absolute;
    right: clamp(24px, 7vw, 80px);
    bottom: 38px;
    z-index: 3;
    display: flex;
    gap: 8px;
}

.hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    border: 0;
    background: rgba(255, 255, 255, 0.45);
    transition: width 0.25s ease, background 0.25s ease;
}

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

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

.intro-block {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 430px);
    align-items: center;
    gap: 28px;
    padding-top: 48px;
}

.intro-block h2,
.section-heading h2,
.page-hero h1 {
    margin: 10px 0 0;
    color: var(--color-gray-900);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.16;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.intro-block p,
.page-hero p {
    margin: 14px 0 0;
    color: var(--color-gray-600);
    font-size: 17px;
}

.inline-search {
    background: #ffffff;
    border: 1px solid rgba(249, 115, 22, 0.12);
    border-radius: 22px;
    padding: 12px;
    box-shadow: var(--shadow-soft);
}

.inline-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: none;
    padding: 12px 14px;
    color: var(--color-gray-900);
    background: transparent;
}

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

.section-heading.light h2 {
    color: #ffffff;
}

.text-link {
    color: var(--color-orange-600);
    font-weight: 800;
}

.text-link:hover {
    color: #c2410c;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.card-cover {
    position: relative;
    display: block;
    height: 246px;
    overflow: hidden;
    background: var(--color-slate-800);
}

.movie-card.compact .card-cover {
    height: 210px;
}

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

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

.card-badge,
.card-duration {
    position: absolute;
    z-index: 2;
    color: #ffffff;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    padding: 5px 10px;
}

.card-badge {
    left: 12px;
    top: 12px;
    background: linear-gradient(90deg, var(--color-orange-500), var(--color-amber-500));
}

.card-duration {
    right: 12px;
    bottom: 12px;
    background: rgba(0, 0, 0, 0.72);
}

.card-body {
    padding: 18px;
}

.card-body h2 {
    margin: 0 0 8px;
    color: var(--color-gray-900);
    font-size: 18px;
    line-height: 1.35;
    font-weight: 850;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-body h2 a:hover {
    color: var(--color-orange-600);
}

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

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 12px;
    color: var(--color-gray-500);
    font-size: 13px;
}

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

.tag-row span,
.detail-tags a {
    color: #9a3412;
    background: #ffedd5;
    border-radius: 999px;
    padding: 4px 9px;
    font-size: 12px;
    font-weight: 700;
}

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

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

.category-card {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 18px;
    overflow: hidden;
    border-radius: 22px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-slate-900), var(--color-slate-800));
    box-shadow: var(--shadow-soft);
}

.category-image {
    min-height: 210px;
    overflow: hidden;
}

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

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

.category-content {
    padding: 24px 22px 24px 0;
}

.category-content h2 {
    margin: 0 0 8px;
    font-size: 25px;
    font-weight: 900;
}

.category-content p {
    margin: 0 0 16px;
    color: #cbd5e1;
}

.category-mini-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.category-mini-links a {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
}

.ranking-preview,
.ranking-page-list {
    border-radius: 28px;
    background: linear-gradient(135deg, #0f172a, #1e293b 55%, #7c2d12);
    padding: 42px;
    box-shadow: var(--shadow-card);
}

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

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

.rank-card {
    display: grid;
    grid-template-columns: auto 86px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    border-radius: 16px;
    padding: 10px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.10);
    transition: background 0.2s ease, transform 0.2s ease;
}

.rank-card:hover {
    background: rgba(255, 255, 255, 0.18);
    transform: translateX(4px);
}

.rank-num {
    width: 32px;
    height: 32px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-orange-500), var(--color-amber-500));
    font-weight: 900;
}

.rank-card img {
    width: 86px;
    height: 60px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-info {
    min-width: 0;
}

.rank-info strong,
.side-card strong {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.rank-info small,
.side-card small {
    display: block;
    margin-top: 4px;
    color: #cbd5e1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.page-hero {
    color: #ffffff;
    background: radial-gradient(circle at top left, rgba(249, 115, 22, 0.42), transparent 34%), linear-gradient(135deg, var(--color-slate-900), var(--color-slate-800));
    padding: 78px 0;
}

.page-hero h1 {
    color: #ffffff;
}

.page-hero p {
    max-width: 780px;
    color: #d1d5db;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    color: #fed7aa;
    font-size: 14px;
}

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

.category-page-hero .inline-search,
.search-hero .inline-search {
    max-width: 680px;
    margin-top: 24px;
}

.empty-state {
    margin: 30px 0 0;
    padding: 24px;
    border-radius: 18px;
    text-align: center;
    color: var(--color-gray-600);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.detail-page {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc 0%, #fff7ed 52%, #f8fafc 100%);
}

.detail-backdrop {
    position: absolute;
    inset: 0 0 auto;
    height: 440px;
    overflow: hidden;
    pointer-events: none;
}

.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(24px) saturate(1.2);
    transform: scale(1.12);
    opacity: 0.36;
}

.detail-backdrop div {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.78), rgba(249, 250, 251, 0.96));
}

.detail-layout {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 28px;
    padding: 34px 0 70px;
}

.detail-breadcrumb {
    color: #ffffff;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: #000000;
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.35);
    aspect-ratio: 16 / 9;
}

.player-shell video,
.player-cover,
.player-cover img {
    width: 100%;
    height: 100%;
}

.player-shell video {
    background: #000000;
    object-fit: contain;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: #000000;
    z-index: 2;
}

.player-cover img {
    position: absolute;
    inset: 0;
    object-fit: cover;
    opacity: 0.68;
}

.player-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, rgba(249, 115, 22, 0.20), rgba(0, 0, 0, 0.66));
}

.play-circle {
    position: relative;
    z-index: 3;
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-orange-500), var(--color-amber-500));
    box-shadow: 0 18px 44px rgba(249, 115, 22, 0.45);
    font-size: 30px;
    padding-left: 5px;
}

.player-cover.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.detail-card,
.side-panel {
    margin-top: 24px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-soft);
}

.detail-card {
    padding: 28px;
}

.detail-card h1 {
    margin: 0 0 14px;
    color: var(--color-gray-900);
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.16;
    font-weight: 900;
    letter-spacing: -0.03em;
}

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

.detail-meta span {
    color: #7c2d12;
    background: #ffedd5;
    border-radius: 999px;
    padding: 5px 11px;
    font-size: 13px;
    font-weight: 800;
}

.detail-lead {
    margin: 0 0 22px;
    color: var(--color-gray-800);
    font-size: 18px;
    font-weight: 650;
}

.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 26px;
}

.content-section {
    margin-top: 26px;
}

.content-section h2,
.side-panel h2 {
    margin: 0 0 14px;
    color: var(--color-gray-900);
    font-size: 24px;
    font-weight: 900;
}

.content-section p {
    margin: 0 0 14px;
    color: var(--color-gray-700);
    font-size: 16px;
    line-height: 1.9;
}

.detail-side {
    align-self: start;
    position: sticky;
    top: 105px;
}

.side-panel {
    padding: 20px;
}

.side-list {
    display: grid;
    gap: 13px;
}

.side-card {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    border-radius: 14px;
    padding: 8px;
    transition: background 0.2s ease;
}

.side-card:hover {
    background: var(--color-orange-50);
}

.side-card img {
    width: 112px;
    height: 72px;
    object-fit: cover;
    border-radius: 12px;
}

.side-card small {
    color: var(--color-gray-500);
}

.site-footer {
    color: #cbd5e1;
    background: #020617;
    padding: 52px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr;
    gap: 34px;
}

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

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

.site-footer p {
    margin: 14px 0 0;
    color: #94a3b8;
}

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

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

.footer-bottom {
    display: flex;
    justify-content: center;
    gap: 18px;
    border-top: 1px solid #1e293b;
    margin-top: 42px;
    padding: 18px;
    color: #64748b;
    font-size: 14px;
}

[hidden] {
    display: none !important;
}

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

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

    .detail-side {
        position: static;
    }

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

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

    .nav-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .hero {
        min-height: 520px;
        height: 72vh;
    }

    .hero-content {
        bottom: 88px;
    }

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

    .intro-block {
        grid-template-columns: 1fr;
    }

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

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

    .category-grid,
    .category-grid.large,
    .rank-list,
    .rank-list.full {
        grid-template-columns: 1fr;
    }

    .category-card {
        grid-template-columns: 150px minmax(0, 1fr);
    }

    .ranking-preview,
    .ranking-page-list {
        padding: 26px 18px;
    }
}

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

    .brand-copy strong {
        font-size: 19px;
    }

    .category-strip-inner {
        gap: 14px;
    }

    .hero {
        min-height: 500px;
    }

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

    .hero-meta {
        gap: 8px 14px;
        font-size: 14px;
    }

    .hero-dots {
        left: 16px;
        right: auto;
        bottom: 30px;
    }

    .inline-search {
        flex-direction: column;
        align-items: stretch;
        border-radius: 18px;
    }

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

    .card-cover,
    .movie-card.compact .card-cover {
        height: 230px;
    }

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

    .category-image {
        min-height: 210px;
    }

    .category-content {
        padding: 0 20px 22px;
    }

    .rank-card {
        grid-template-columns: auto 72px minmax(0, 1fr);
    }

    .rank-card img {
        width: 72px;
        height: 54px;
    }

    .detail-layout {
        padding-top: 22px;
    }

    .detail-card {
        padding: 22px;
    }

    .play-circle {
        width: 70px;
        height: 70px;
        font-size: 24px;
    }

    .side-card {
        grid-template-columns: 96px minmax(0, 1fr);
    }

    .side-card img {
        width: 96px;
        height: 64px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        align-items: center;
        gap: 6px;
    }
}
