:root {
    --bg: #fff8ed;
    --panel: #ffffff;
    --ink: #1f2937;
    --muted: #6b7280;
    --line: #f1d7ae;
    --brand: #d97706;
    --brand-dark: #b45309;
    --brand-soft: #fff3dc;
    --accent: #ea580c;
    --shadow: 0 20px 55px rgba(120, 53, 15, 0.14);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 42%, #fff7ed 100%);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: linear-gradient(90deg, rgba(180, 83, 9, 0.96), rgba(234, 88, 12, 0.96));
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(120, 53, 15, 0.22);
    backdrop-filter: blur(14px);
}

.header-inner {
    max-width: 1280px;
    min-height: 72px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

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

.logo-mark {
    width: 42px;
    height: 42px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    background: #ffffff;
    color: var(--brand-dark);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.14);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-link {
    padding: 10px 16px;
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 700;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #78350f;
    background: #ffffff;
    transform: translateY(-1px);
}

.menu-button {
    width: 44px;
    height: 44px;
    display: none;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.18);
    cursor: pointer;
}

.menu-button span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    background: #ffffff;
    border-radius: 2px;
}

.mobile-nav {
    display: none;
    padding: 0 24px 18px;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.mobile-nav a {
    display: block;
    padding: 12px 0;
    font-weight: 700;
}

.mobile-nav.open {
    display: block;
}

.section-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

.hero-section {
    background: #111827;
}

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

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    min-height: 620px;
    object-fit: cover;
    transform: scale(1.03);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 75% 35%, rgba(251, 191, 36, 0.28), transparent 32%),
        linear-gradient(90deg, rgba(17, 24, 39, 0.94) 0%, rgba(17, 24, 39, 0.74) 45%, rgba(17, 24, 39, 0.22) 100%),
        linear-gradient(0deg, rgba(17, 24, 39, 0.92), transparent 48%);
}

.hero-content {
    position: absolute;
    left: calc(50% - 640px + 24px);
    bottom: 86px;
    width: min(680px, calc(100% - 48px));
    color: #ffffff;
}

.hero-kicker,
.page-hero span,
.section-heading span {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    border-radius: 999px;
    color: #92400e;
    background: #fffbeb;
    font-size: 13px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.09em;
}

.hero-content h2 {
    margin: 18px 0;
    font-size: clamp(42px, 6vw, 78px);
    line-height: 0.98;
    letter-spacing: -0.05em;
    font-weight: 950;
    text-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.hero-content p {
    max-width: 620px;
    margin: 0 0 22px;
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.75;
}

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

.tag-pill {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 12px;
    border-radius: 999px;
    color: #92400e;
    background: #fef3c7;
    font-size: 13px;
    font-weight: 800;
}

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

.primary-button,
.ghost-button,
.home-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border: 0;
    border-radius: 999px;
    font-weight: 900;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--accent));
    box-shadow: 0 16px 34px rgba(217, 119, 6, 0.32);
}

.primary-button:hover,
.home-search button:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 40px rgba(217, 119, 6, 0.4);
}

.primary-button.full {
    width: 100%;
}

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

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

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

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

.hero-dots button.active {
    background: #fbbf24;
}

.search-band {
    margin-top: -44px;
    position: relative;
    z-index: 8;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 470px);
    gap: 24px;
    align-items: center;
    padding-top: 30px;
    padding-bottom: 30px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.search-panel h1 {
    margin: 0 0 10px;
    font-size: clamp(28px, 3vw, 42px);
    letter-spacing: -0.04em;
}

.search-panel p {
    margin: 0;
    color: var(--muted);
    line-height: 1.8;
}

.home-search {
    display: flex;
    min-height: 56px;
    border-radius: 999px;
    padding: 6px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
}

.home-search input,
.filter-toolbar input,
.filter-toolbar select {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--ink);
}

.home-search input {
    padding: 0 16px;
}

.home-search button {
    min-height: 44px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--accent));
}

.quick-categories {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.quick-categories a {
    padding: 9px 14px;
    border-radius: 999px;
    color: #92400e;
    background: #fffbeb;
    font-weight: 800;
    border: 1px solid #fde68a;
}

.content-section {
    padding-top: 70px;
    padding-bottom: 70px;
}

.warm-section {
    padding: 76px 0;
    background: linear-gradient(135deg, #fffbeb, #fff7ed);
}

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

.section-heading.centered {
    align-items: center;
    justify-content: center;
    text-align: center;
}

.section-heading h2,
.page-hero h1,
.detail-article h1 {
    margin: 12px 0 0;
    font-size: clamp(30px, 4vw, 48px);
    font-weight: 950;
    letter-spacing: -0.05em;
}

.section-heading p,
.page-hero p {
    max-width: 760px;
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.85;
}

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

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

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

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

.movie-card {
    overflow: hidden;
    border-radius: 22px;
    background: var(--panel);
    box-shadow: 0 12px 34px rgba(146, 64, 14, 0.12);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 22px 46px rgba(146, 64, 14, 0.2);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #451a03, #92400e);
}

.poster-link img {
    height: 100%;
    object-fit: cover;
    transition: transform 0.34s ease, filter 0.34s ease;
}

.movie-card:hover .poster-link img {
    transform: scale(1.06);
    filter: saturate(1.08) contrast(1.05);
}

.card-badge,
.rank-badge,
.play-chip {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
}

.card-badge,
.rank-badge {
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    color: #92400e;
    background: #ffffff;
}

.rank-badge {
    color: #ffffff;
    background: linear-gradient(135deg, #dc2626, #f97316);
}

.play-chip {
    right: 12px;
    bottom: 12px;
    padding: 8px 12px;
    color: #ffffff;
    background: rgba(17, 24, 39, 0.76);
    backdrop-filter: blur(12px);
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-chip {
    opacity: 1;
    transform: translateY(0);
}

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

.movie-card-body h2 {
    margin: 0 0 9px;
    font-size: 18px;
    font-weight: 900;
    line-height: 1.35;
}

.movie-card-body p {
    margin: 12px 0 0;
    color: var(--muted);
    line-height: 1.75;
    font-size: 14px;
}

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #9a3412;
    font-size: 13px;
    font-weight: 800;
}

.movie-meta-line span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #fff7ed;
}

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

.category-tile {
    min-height: 190px;
    padding: 24px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 36px rgba(146, 64, 14, 0.12);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 48px rgba(146, 64, 14, 0.19);
}

.category-tile strong {
    display: block;
    margin-bottom: 12px;
    font-size: 22px;
    color: var(--brand-dark);
}

.category-tile p {
    margin: 0 0 16px;
    color: var(--muted);
    line-height: 1.75;
}

.category-tile small {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-tile small span {
    padding: 5px 8px;
    border-radius: 999px;
    color: #92400e;
    background: #fffbeb;
    font-weight: 800;
}

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

.mini-card {
    display: grid;
    grid-template-columns: auto 68px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    padding: 12px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(146, 64, 14, 0.1);
}

.mini-rank {
    width: 32px;
    height: 32px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--brand), var(--accent));
    font-weight: 950;
}

.mini-card img {
    aspect-ratio: 2 / 3;
    border-radius: 12px;
    object-fit: cover;
    background: #92400e;
}

.mini-card strong,
.mini-card em {
    display: block;
}

.mini-card strong {
    margin-bottom: 6px;
    font-size: 16px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

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

.page-main {
    min-height: 70vh;
}

.page-hero {
    padding: 92px 0 74px;
    color: #ffffff;
    background:
        radial-gradient(circle at 70% 20%, rgba(251, 191, 36, 0.38), transparent 28%),
        linear-gradient(135deg, #78350f, #c2410c 52%, #f59e0b);
}

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

.page-hero span {
    color: #78350f;
}

.page-hero p {
    color: rgba(255, 255, 255, 0.88);
}

.filter-toolbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 210px;
    gap: 14px;
    margin-bottom: 28px;
    padding: 14px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 12px 32px rgba(146, 64, 14, 0.1);
}

.filter-toolbar input,
.filter-toolbar select {
    min-height: 48px;
    padding: 0 14px;
    border-radius: 14px;
    background: #fff7ed;
    border: 1px solid #fed7aa;
}

.category-overview {
    padding-top: 70px;
    padding-bottom: 70px;
}

.category-overview-block {
    margin-bottom: 70px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 32px;
    padding-top: 42px;
    padding-bottom: 36px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 18px;
    color: var(--muted);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--brand-dark);
    font-weight: 800;
}

.player-card,
.detail-article,
.poster-panel,
.info-panel {
    border-radius: 24px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.player-shell {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.player-video {
    width: 100%;
    height: 100%;
    display: block;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    color: #ffffff;
    border: 0;
    background: radial-gradient(circle, rgba(251, 191, 36, 0.24), rgba(2, 6, 23, 0.68));
    cursor: pointer;
    transition: opacity 0.22s ease;
}

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

.player-icon {
    width: 76px;
    height: 76px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--brand), var(--accent));
    box-shadow: 0 20px 42px rgba(234, 88, 12, 0.36);
    font-size: 30px;
    padding-left: 4px;
}

.player-overlay span:last-child {
    font-size: 20px;
    font-weight: 900;
}

.detail-article {
    margin-top: 24px;
    padding: 28px;
}

.detail-article h1 {
    margin-top: 0;
}

.lead-text {
    margin: 18px 0;
    color: #78350f;
    font-size: 20px;
    line-height: 1.8;
    font-weight: 800;
}

.detail-article h2 {
    margin: 30px 0 12px;
    font-size: 24px;
    font-weight: 950;
}

.detail-article p {
    color: #374151;
    line-height: 2;
}

.detail-sidebar {
    position: sticky;
    top: 96px;
    align-self: start;
}

.poster-panel img {
    aspect-ratio: 2 / 3;
    object-fit: cover;
    background: #92400e;
}

.info-panel {
    margin-top: 20px;
    padding: 22px;
}

.info-panel h2 {
    margin: 0 0 16px;
    font-size: 22px;
    font-weight: 950;
}

.info-panel dl {
    margin: 0 0 22px;
}

.info-panel dt {
    margin-top: 12px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

.info-panel dd {
    margin: 5px 0 0;
    font-weight: 800;
    line-height: 1.6;
}

.site-footer {
    color: #fde68a;
    background: #111827;
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 56px 24px 36px;
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr;
    gap: 32px;
}

.footer-logo {
    color: #ffffff;
}

.site-footer p {
    max-width: 520px;
    color: #d1d5db;
    line-height: 1.9;
}

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

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

.footer-links a {
    padding: 8px 10px;
    border-radius: 999px;
    color: #d1d5db;
    background: rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding: 18px 24px 28px;
    color: #9ca3af;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

[data-movie-card].is-hidden {
    display: none;
}

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

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

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

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

    .detail-sidebar {
        position: static;
        display: grid;
        grid-template-columns: 240px minmax(0, 1fr);
        gap: 20px;
    }

    .info-panel {
        margin-top: 0;
    }
}

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

    .menu-button {
        display: block;
    }

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

    .hero-content {
        left: 24px;
        bottom: 76px;
    }

    .search-panel,
    .filter-toolbar,
    .footer-inner,
    .detail-sidebar {
        grid-template-columns: 1fr;
    }

    .movie-grid,
    .featured-grid,
    .compact-grid,
    .category-grid,
    .ranking-list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

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

    .movie-card-body h2 {
        font-size: 16px;
    }

    .movie-card-body p {
        display: none;
    }
}

@media (max-width: 460px) {
    .header-inner,
    .section-inner {
        padding-left: 16px;
        padding-right: 16px;
    }

    .site-logo {
        font-size: 18px;
    }

    .logo-mark {
        width: 38px;
        height: 38px;
    }

    .hero-carousel,
    .hero-slide img {
        min-height: 520px;
    }

    .hero-content {
        left: 16px;
        width: calc(100% - 32px);
    }

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

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