:root {
    color-scheme: dark;
    --bg: #09090b;
    --bg-soft: #111827;
    --panel: rgba(17, 24, 39, 0.82);
    --panel-solid: #151b27;
    --line: rgba(255, 255, 255, 0.12);
    --text: #f9fafb;
    --muted: #a1a1aa;
    --amber: #f59e0b;
    --orange: #ea580c;
    --red: #dc2626;
    --radius: 22px;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.35);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    margin: 0;
    background:
        radial-gradient(circle at 10% -10%, rgba(245, 158, 11, 0.20), transparent 34rem),
        radial-gradient(circle at 90% 5%, rgba(220, 38, 38, 0.18), transparent 28rem),
        linear-gradient(180deg, #050505 0%, #0b1020 38%, #0a0a0a 100%);
    color: var(--text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid var(--line);
    background: rgba(9, 9, 11, 0.78);
    backdrop-filter: blur(18px);
}

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

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

.logo-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 10px 30px rgba(245, 158, 11, 0.32);
}

.logo-text {
    font-size: 20px;
    white-space: nowrap;
}

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

.nav-link {
    color: rgba(255, 255, 255, 0.74);
    font-weight: 600;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--amber);
}

.nav-search {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.nav-search input {
    width: 150px;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text);
    padding: 8px 4px 8px 12px;
}

.nav-search button,
.wide-search button {
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    color: white;
    font-weight: 700;
    padding: 8px 16px;
    cursor: pointer;
}

.menu-toggle {
    display: none;
    margin-left: auto;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 2px;
    background: white;
    margin: 5px 0;
    border-radius: 999px;
}

.mobile-panel {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: rgba(17, 24, 39, 0.96);
    padding: 12px;
}

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

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

.mobile-panel a:hover {
    background: rgba(245, 158, 11, 0.15);
    color: var(--amber);
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.55s ease, visibility 0.55s ease;
    background-image: var(--hero-image);
    background-size: cover;
    background-position: center;
}

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

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.88) 0%, rgba(0, 0, 0, 0.62) 43%, rgba(0, 0, 0, 0.18) 100%),
        linear-gradient(0deg, #09090b 0%, rgba(9, 9, 11, 0.34) 44%, rgba(9, 9, 11, 0.16) 100%);
}

.hero-content {
    position: relative;
    z-index: 1;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding-top: 32px;
}

.hero-copy {
    max-width: 670px;
}

.eyebrow,
.section-kicker {
    margin: 0 0 12px;
    color: var(--amber);
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-copy h1 {
    margin: 0;
    font-size: clamp(42px, 7vw, 78px);
    line-height: 0.98;
    letter-spacing: -0.06em;
}

.hero-summary {
    margin: 24px 0 0;
    color: rgba(255, 255, 255, 0.80);
    font-size: clamp(17px, 2vw, 21px);
    line-height: 1.8;
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.hero-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 12px;
    border: 1px solid rgba(245, 158, 11, 0.38);
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.11);
    color: #fde68a;
    font-size: 13px;
}

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

.primary-btn,
.ghost-btn,
.section-more,
.row-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.primary-btn {
    min-height: 48px;
    padding: 0 24px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    color: white;
    box-shadow: 0 18px 40px rgba(234, 88, 12, 0.28);
}

.ghost-btn {
    min-height: 48px;
    padding: 0 22px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.10);
    color: white;
}

.primary-btn:hover,
.ghost-btn:hover,
.section-more:hover,
.row-action:hover {
    transform: translateY(-2px);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.13);
    color: white;
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
    backdrop-filter: blur(12px);
}

.hero-arrow.prev {
    left: 22px;
}

.hero-arrow.next {
    right: 22px;
}

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

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

.hero-dot.active {
    width: 34px;
    background: white;
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.45fr) minmax(300px, 0.55fr);
    gap: 24px;
    margin-top: -70px;
    position: relative;
    z-index: 4;
}

.quick-search-card,
.rank-panel,
.content-card,
.page-hero,
.category-overview-row {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.quick-search-card {
    padding: 34px;
}

.quick-search-card h2,
.page-hero h1,
.section-head h2,
.content-card h2,
.ranking-copy h2,
.detail-copy h1 {
    margin: 0;
    letter-spacing: -0.04em;
}

.quick-search-card h2 {
    font-size: clamp(28px, 4vw, 46px);
}

.quick-search-card p,
.page-hero p,
.category-card p,
.content-card p,
.detail-line,
.ranking-copy p,
.category-overview-row p {
    color: var(--muted);
    line-height: 1.75;
}

.wide-search {
    display: flex;
    gap: 10px;
    margin-top: 24px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 7px;
    background: rgba(255, 255, 255, 0.08);
}

.wide-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: white;
    padding: 0 16px;
}

.rank-panel {
    padding: 22px;
}

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

.section-head.compact {
    align-items: center;
    margin-bottom: 14px;
}

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

.section-more,
.section-head.compact a {
    color: var(--amber);
    font-weight: 800;
}

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

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.065);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(245, 158, 11, 0.44);
    background: rgba(255, 255, 255, 0.10);
}

.poster-frame {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 3 / 4;
    background:
        radial-gradient(circle at 50% 15%, rgba(245, 158, 11, 0.38), transparent 42%),
        linear-gradient(135deg, #1f2937, #09090b);
}

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

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

.poster-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.62);
    color: #fde68a;
    font-size: 12px;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

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

.movie-card h3 {
    margin: 0 0 8px;
    font-size: 17px;
    line-height: 1.4;
}

.movie-card h3 a:hover,
.ranking-copy h2 a:hover,
.category-overview-row h2 a:hover {
    color: var(--amber);
}

.movie-meta {
    margin: 0;
    color: rgba(255, 255, 255, 0.52);
    font-size: 13px;
}

.movie-line {
    min-height: 48px;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
}

.movie-card.small .movie-card-body {
    padding: 13px;
}

.movie-card.small h3 {
    font-size: 15px;
}

.movie-card.small .movie-line,
.movie-card.small .tag-row {
    display: none;
}

.compact-card {
    display: grid;
    grid-template-columns: auto 54px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px 0;
    border-top: 1px solid var(--line);
}

.compact-card:first-of-type {
    border-top: 0;
}

.rank-num {
    color: var(--amber);
    font-size: 18px;
    font-weight: 900;
}

.compact-poster {
    display: block;
    overflow: hidden;
    width: 54px;
    aspect-ratio: 3 / 4;
    border-radius: 10px;
    background: linear-gradient(135deg, #1f2937, #09090b);
}

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

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

.compact-info strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.compact-info em {
    margin-top: 4px;
    color: var(--muted);
    font-size: 13px;
    font-style: normal;
}

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

.category-card {
    min-height: 178px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background:
        linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(234, 88, 12, 0.04)),
        rgba(255, 255, 255, 0.065);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: rgba(245, 158, 11, 0.45);
}

.category-card span {
    display: block;
    font-size: 22px;
    font-weight: 900;
}

.category-card em {
    display: inline-flex;
    margin-top: 14px;
    color: var(--amber);
    font-style: normal;
    font-weight: 800;
}

.page-main {
    padding: 34px 0 80px;
}

.page-hero {
    padding: 38px;
}

.page-hero.slim {
    margin-top: 16px;
}

.page-hero h1 {
    font-size: clamp(32px, 5vw, 56px);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin: 12px 0 18px;
    color: rgba(255, 255, 255, 0.62);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--amber);
}

.filter-bar {
    display: grid;
    gap: 14px;
    margin-bottom: 24px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
}

.page-filter-input {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: 0;
    background: rgba(0, 0, 0, 0.25);
    color: white;
    padding: 14px 16px;
}

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

.filter-chip {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: white;
    padding: 8px 14px;
    cursor: pointer;
}

.filter-chip.active,
.filter-chip:hover {
    border-color: rgba(245, 158, 11, 0.7);
    background: rgba(245, 158, 11, 0.18);
    color: #fde68a;
}

.empty-state {
    display: none;
    padding: 26px;
    text-align: center;
    color: var(--muted);
}

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

.overview-list {
    display: grid;
    gap: 18px;
}

.category-overview-row {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 22px;
    padding: 24px;
}

.category-overview-row h2 {
    margin: 0 0 10px;
    font-size: 28px;
}

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

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

.ranking-row {
    display: grid;
    grid-template-columns: 64px 104px minmax(0, 1fr) auto;
    gap: 20px;
    align-items: center;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.065);
}

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

.ranking-poster {
    overflow: hidden;
    aspect-ratio: 3 / 4;
    border-radius: 14px;
    background: linear-gradient(135deg, #1f2937, #09090b);
}

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

.ranking-copy h2 {
    margin-bottom: 8px;
    font-size: 24px;
}

.row-action {
    min-width: 92px;
    min-height: 42px;
    background: rgba(245, 158, 11, 0.16);
    color: #fde68a;
}

.detail-hero {
    display: grid;
    grid-template-columns: minmax(240px, 340px) minmax(0, 1fr);
    gap: 34px;
    align-items: center;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 28px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.13), rgba(255, 255, 255, 0.05));
    box-shadow: var(--shadow);
}

.detail-poster {
    border-radius: 24px;
}

.detail-copy h1 {
    font-size: clamp(34px, 5vw, 62px);
    line-height: 1.08;
}

.detail-line {
    margin: 18px 0 0;
    font-size: 18px;
}

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

.detail-meta span,
.detail-meta a {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.78);
}

.detail-meta a:hover {
    color: var(--amber);
}

.expanded {
    margin-bottom: 26px;
}

.player-section {
    margin-top: 34px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid var(--line);
    border-radius: 26px;
    background: #030303;
    box-shadow: var(--shadow);
}

.player-shell video {
    width: 100%;
    height: 100%;
    background: #000;
    object-fit: contain;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 14px;
    border: 0;
    background: radial-gradient(circle at center, rgba(245, 158, 11, 0.18), rgba(0, 0, 0, 0.44));
    color: white;
    cursor: pointer;
}

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

.play-icon {
    display: grid;
    place-items: center;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    font-size: 36px;
    box-shadow: 0 18px 50px rgba(234, 88, 12, 0.35);
}

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

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

.content-card {
    padding: 28px;
}

.content-card h2 {
    margin-bottom: 14px;
    font-size: 26px;
}

.site-footer {
    margin-top: 72px;
    border-top: 1px solid var(--line);
    background: rgba(3, 7, 18, 0.92);
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 40px;
    padding: 42px 0;
}

.footer-inner p {
    max-width: 540px;
    color: var(--muted);
    line-height: 1.75;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 18px;
    justify-content: flex-end;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.64);
}

.footer-links a:hover {
    color: var(--amber);
}

.footer-bottom {
    border-top: 1px solid var(--line);
    padding: 18px;
    text-align: center;
    color: rgba(255, 255, 255, 0.44);
}

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

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

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

    .menu-toggle {
        display: block;
    }

    .hero-carousel {
        min-height: 560px;
    }

    .hero-panel,
    .footer-inner,
    .detail-content,
    .category-overview-row,
    .detail-hero {
        grid-template-columns: 1fr;
    }

    .hero-panel {
        margin-top: -40px;
    }

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

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

    .row-action {
        grid-column: 2 / -1;
    }

    .footer-links {
        justify-content: flex-start;
    }
}

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

    .logo-text {
        font-size: 17px;
    }

    .hero-copy h1 {
        font-size: 40px;
    }

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

    .hero-arrow {
        display: none;
    }

    .quick-search-card,
    .page-hero,
    .detail-hero,
    .content-card {
        padding: 22px;
    }

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

    .wide-search input {
        min-height: 42px;
    }

    .movie-grid,
    .compact-grid,
    .category-grid,
    .mini-strip {
        grid-template-columns: 1fr;
    }

    .ranking-row {
        grid-template-columns: 42px 76px minmax(0, 1fr);
        gap: 12px;
        padding: 14px;
    }

    .ranking-copy h2 {
        font-size: 18px;
    }
}
