:root {
    color-scheme: dark;
    --bg: #140804;
    --bg-soft: #241007;
    --panel: rgba(55, 25, 9, 0.86);
    --panel-strong: rgba(83, 36, 12, 0.92);
    --line: rgba(251, 191, 36, 0.18);
    --text: #fff7ed;
    --muted: #fcd9a5;
    --dim: #d6a867;
    --primary: #f59e0b;
    --primary-2: #fb923c;
    --danger: #ef4444;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--text);
    background:
        radial-gradient(circle at 10% 0%, rgba(245, 158, 11, 0.2), transparent 28rem),
        radial-gradient(circle at 90% 12%, rgba(194, 65, 12, 0.24), transparent 30rem),
        linear-gradient(135deg, #0c0503 0%, #1c0b05 40%, #3b1608 100%);
}

body::before {
    position: fixed;
    inset: 0;
    z-index: -1;
    content: "";
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.75), transparent 86%);
}

img {
    max-width: 100%;
}

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    border-bottom: 1px solid var(--line);
    background: rgba(16, 6, 3, 0.82);
    backdrop-filter: blur(24px);
}

.header-inner,
.footer-inner,
.page-shell,
.section-block,
.hero {
    width: min(1200px, calc(100% - 32px));
    margin-inline: auto;
}

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

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

.brand-mark {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border-radius: 14px;
    color: #441600;
    background: linear-gradient(135deg, #facc15, #fb923c 68%, #ef4444);
    box-shadow: 0 12px 30px rgba(251, 146, 60, 0.32);
}

.brand-name {
    font-size: 1.22rem;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 6px;
}

.site-nav a {
    padding: 10px 15px;
    border-radius: 999px;
    color: var(--muted);
    transition: 0.2s ease;
}

.site-nav a:hover,
.site-nav a.active {
    color: var(--text);
    background: rgba(245, 158, 11, 0.16);
}

.nav-toggle {
    display: none;
    padding: 9px 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
}

.hero {
    position: relative;
    padding-top: 32px;
}

.hero-stage {
    position: relative;
    overflow: hidden;
    min-height: 620px;
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow);
    background: #180803;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    opacity: 0;
    visibility: hidden;
    transform: scale(1.015);
    transition: opacity 0.65s ease, transform 0.65s ease, visibility 0.65s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
}

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.08);
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(11, 5, 3, 0.95) 0%, rgba(25, 10, 4, 0.84) 42%, rgba(28, 12, 5, 0.28) 100%),
        linear-gradient(0deg, rgba(12, 5, 3, 0.86), rgba(12, 5, 3, 0.05));
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) 360px;
    align-items: center;
    gap: 48px;
    width: 100%;
    padding: 72px;
}

.eyebrow,
.kicker,
.card-meta,
.breadcrumb {
    color: var(--primary);
    font-size: 0.88rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero h1 {
    max-width: 780px;
    margin: 14px 0 10px;
    font-size: clamp(2.6rem, 6vw, 5.9rem);
    line-height: 0.96;
    font-weight: 950;
    letter-spacing: -0.075em;
}

.hero h2 {
    margin: 0 0 18px;
    font-size: clamp(1.55rem, 3vw, 3rem);
    line-height: 1.08;
    color: #ffedd5;
}

.hero-summary {
    max-width: 680px;
    margin: 0;
    color: var(--muted);
    font-size: 1.08rem;
    line-height: 1.85;
}

.hero-tags,
.detail-tags,
.tag-line,
.filter-row,
.hero-actions,
.category-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-tags span,
.detail-tags span,
.tag-line span,
.filter-btn,
.meta-pill {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 11px;
    border: 1px solid rgba(251, 191, 36, 0.22);
    border-radius: 999px;
    color: #ffedd5;
    background: rgba(67, 28, 9, 0.62);
}

.hero-tags {
    margin-top: 24px;
}

.hero-actions {
    margin-top: 32px;
}

.primary-btn,
.ghost-btn,
.hero-search button,
.search-box button,
.load-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 999px;
    font-weight: 900;
    transition: 0.2s ease;
}

.primary-btn,
.hero-search button,
.search-box button,
.load-btn {
    border: 0;
    color: #3b1301;
    background: linear-gradient(135deg, #facc15, #fb923c 72%, #ef4444);
    box-shadow: 0 18px 35px rgba(251, 146, 60, 0.28);
}

.ghost-btn {
    border: 1px solid rgba(251, 191, 36, 0.25);
    color: var(--text);
    background: rgba(255, 255, 255, 0.08);
}

.primary-btn:hover,
.ghost-btn:hover,
.hero-search button:hover,
.search-box button:hover,
.load-btn:hover {
    transform: translateY(-2px);
}

.hero-card {
    overflow: hidden;
    align-self: center;
    border: 1px solid rgba(251, 191, 36, 0.2);
    border-radius: 30px;
    background: rgba(12, 5, 3, 0.45);
    box-shadow: 0 26px 80px rgba(0, 0, 0, 0.45);
}

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

.hero-card span {
    display: block;
    padding: 18px 20px;
    color: var(--muted);
    font-weight: 700;
}

.hero-controls {
    position: absolute;
    right: 28px;
    bottom: 28px;
    z-index: 5;
    display: flex;
    gap: 10px;
}

.hero-controls button,
.hero-dot {
    border: 1px solid rgba(251, 191, 36, 0.25);
    color: var(--text);
    background: rgba(0, 0, 0, 0.32);
    backdrop-filter: blur(10px);
}

.hero-controls button {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-size: 1.7rem;
    line-height: 1;
}

.hero-dots {
    position: absolute;
    left: 72px;
    bottom: 44px;
    z-index: 5;
    display: flex;
    gap: 9px;
}

.hero-dot {
    width: 28px;
    height: 7px;
    border-radius: 999px;
    opacity: 0.62;
}

.hero-dot.is-active {
    width: 52px;
    opacity: 1;
    background: var(--primary);
}

.hero-search,
.search-box {
    position: relative;
    z-index: 8;
    display: grid;
    gap: 10px;
    width: min(760px, calc(100% - 36px));
    margin: -38px auto 0;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: rgba(29, 12, 5, 0.92);
    box-shadow: 0 18px 70px rgba(0, 0, 0, 0.38);
    backdrop-filter: blur(20px);
}

.hero-search label,
.search-box label {
    color: var(--muted);
    font-size: 0.94rem;
    font-weight: 700;
}

.hero-search div,
.search-box div {
    display: flex;
    gap: 12px;
}

.hero-search input,
.search-box input {
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    border: 1px solid rgba(251, 191, 36, 0.18);
    border-radius: 999px;
    color: var(--text);
    outline: none;
    background: rgba(255, 255, 255, 0.07);
}

.page-shell {
    padding: 46px 0 0;
}

.page-hero,
.section-block,
.detail-layout,
.player-wrap,
.category-card,
.ranking-panel,
.empty-state {
    border: 1px solid var(--line);
    border-radius: var(--radius-xl);
    background: linear-gradient(145deg, rgba(45, 18, 7, 0.82), rgba(18, 7, 3, 0.9));
    box-shadow: var(--shadow);
}

.page-hero {
    padding: clamp(28px, 5vw, 56px);
}

.page-hero h1,
.section-title h2,
.detail-title h1 {
    margin: 0;
    font-size: clamp(2rem, 4vw, 4rem);
    line-height: 1.08;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.page-hero p,
.section-title p,
.category-card p,
.detail-intro,
.article-text p,
.empty-state {
    color: var(--muted);
    line-height: 1.86;
}

.section-block {
    margin-top: 34px;
    padding: clamp(24px, 4vw, 38px);
}

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

.section-title p {
    max-width: 640px;
    margin: 10px 0 0;
}

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

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

.movie-card {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border: 1px solid rgba(251, 191, 36, 0.16);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.055);
    transition: 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(251, 191, 36, 0.42);
    background: rgba(245, 158, 11, 0.11);
}

.movie-poster {
    position: relative;
    overflow: hidden;
    margin: 0;
    background: #271006;
}

.movie-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: 0.32s ease;
}

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

.poster-shade {
    position: absolute;
    inset: auto 0 0;
    height: 48%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.76), transparent);
}

.play-dot {
    position: absolute;
    right: 12px;
    bottom: 12px;
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 50%;
    color: #3b1301;
    background: var(--primary);
    box-shadow: 0 10px 28px rgba(245, 158, 11, 0.32);
}

.rank-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 12px;
    color: #431407;
    font-weight: 950;
    background: linear-gradient(135deg, #fde68a, #fb923c);
}

.movie-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 8px;
    padding: 15px;
}

.movie-card h3 {
    margin: 0;
    display: -webkit-box;
    overflow: hidden;
    color: #fff7ed;
    font-size: 1.04rem;
    font-weight: 900;
    line-height: 1.32;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-desc {
    display: -webkit-box;
    overflow: hidden;
    margin: 0;
    color: var(--dim);
    font-size: 0.9rem;
    line-height: 1.58;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-meta {
    margin: 0;
    font-size: 0.76rem;
}

.tag-line {
    margin-top: auto;
}

.tag-line span {
    min-height: 24px;
    padding: 3px 8px;
    font-size: 0.76rem;
}

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

.category-chip,
.category-card {
    display: grid;
    gap: 10px;
    min-height: 128px;
    padding: 18px;
    border: 1px solid rgba(251, 191, 36, 0.17);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.055);
    transition: 0.2s ease;
}

.category-chip:hover,
.category-card:hover {
    transform: translateY(-4px);
    border-color: rgba(251, 191, 36, 0.4);
}

.category-chip span,
.category-card h2 {
    color: #fff7ed;
    font-weight: 950;
    font-size: 1.2rem;
}

.category-chip small {
    color: var(--muted);
    line-height: 1.65;
}

.category-card h2,
.category-card p {
    margin: 0;
}

.category-links {
    margin-top: 14px;
}

.category-links a {
    color: var(--primary);
    font-weight: 800;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 58px 82px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 12px;
    border: 1px solid rgba(251, 191, 36, 0.14);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.05);
}

.ranking-row strong {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 14px;
    color: #431407;
    background: linear-gradient(135deg, #fde68a, #fb923c);
}

.ranking-row img {
    width: 82px;
    aspect-ratio: 3 / 4;
    border-radius: 14px;
    object-fit: cover;
}

.ranking-row h3,
.ranking-row p {
    margin: 0;
}

.ranking-row h3 {
    font-size: 1.08rem;
}

.ranking-row p {
    margin-top: 6px;
    color: var(--muted);
}

.ranking-row span {
    color: var(--primary);
    font-weight: 900;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) 360px;
    gap: 28px;
    padding: clamp(20px, 3.5vw, 34px);
}

.player-wrap {
    overflow: hidden;
    padding: 0;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: #050201;
}

.player-box video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    cursor: pointer;
    background: linear-gradient(rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.52));
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-wrap.is-playing .player-cover {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.big-play {
    display: grid;
    width: 86px;
    height: 86px;
    place-items: center;
    border: 0;
    border-radius: 50%;
    color: #431407;
    font-size: 2.1rem;
    background: linear-gradient(135deg, #fde68a, #fb923c);
    box-shadow: 0 18px 48px rgba(251, 146, 60, 0.36);
}

.detail-title {
    margin-top: 24px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
}

.detail-intro {
    margin: 18px 0 0;
    font-size: 1.08rem;
}

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

.meta-pill {
    justify-content: space-between;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.055);
}

.meta-pill b {
    color: var(--primary);
}

.detail-aside img {
    width: 100%;
    border-radius: 24px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    box-shadow: var(--shadow);
}

.detail-tags {
    margin-top: 18px;
}

.article-text {
    display: grid;
    gap: 18px;
    margin-top: 28px;
}

.article-text h2 {
    margin: 0;
    color: #ffedd5;
    font-size: 1.4rem;
}

.article-text p {
    margin: 0;
}

.empty-state {
    display: none;
    padding: 24px;
    text-align: center;
}

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

.site-footer {
    margin-top: 56px;
    border-top: 1px solid var(--line);
    background: rgba(10, 4, 2, 0.7);
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 30px;
    padding: 34px 0;
    color: var(--muted);
}

.footer-brand {
    margin-bottom: 10px;
    color: var(--text);
    font-size: 1.26rem;
}

.footer-inner p {
    margin: 0;
    line-height: 1.8;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    align-content: start;
    gap: 10px;
}

.footer-links a {
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
}

.copyright {
    grid-column: 1 / -1;
    padding-top: 18px;
    border-top: 1px solid rgba(251, 191, 36, 0.12);
}

@media (max-width: 1080px) {
    .hero-content,
    .detail-layout {
        grid-template-columns: 1fr;
    }

    .hero-card {
        display: none;
    }

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

@media (max-width: 760px) {
    .header-inner,
    .footer-inner,
    .page-shell,
    .section-block,
    .hero {
        width: min(100% - 22px, 1200px);
    }

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

    .site-nav {
        position: absolute;
        top: 72px;
        right: 11px;
        left: 11px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: 22px;
        background: rgba(16, 6, 3, 0.96);
    }

    .site-nav.is-open {
        display: flex;
    }

    .site-nav a {
        text-align: center;
    }

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

    .hero-content {
        padding: 34px 24px 92px;
    }

    .hero-dots {
        left: 24px;
        bottom: 36px;
    }

    .hero-controls {
        right: 22px;
        bottom: 24px;
    }

    .hero-search div,
    .search-box div,
    .section-title {
        flex-direction: column;
        align-items: stretch;
    }

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

    .ranking-row {
        grid-template-columns: 44px 68px minmax(0, 1fr);
    }

    .ranking-row span {
        display: none;
    }

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

@media (max-width: 460px) {
    .grid-cards,
    .grid-cards.large,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .brand-name {
        font-size: 1rem;
    }
}
