:root {
    --page-bg: #fff7ed;
    --panel: #ffffff;
    --panel-soft: #fffbeb;
    --text: #1f2937;
    --muted: #6b7280;
    --line: rgba(146, 64, 14, 0.16);
    --amber: #d97706;
    --amber-deep: #92400e;
    --orange: #ea580c;
    --dark: #431407;
    --radius: 24px;
    --shadow: 0 18px 50px rgba(146, 64, 14, 0.14);
}

* {
    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(--text);
    background:
        radial-gradient(circle at top left, rgba(251, 191, 36, 0.24), transparent 34rem),
        linear-gradient(180deg, #fffbeb 0%, var(--page-bg) 34%, #ffffff 100%);
    min-height: 100vh;
}

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

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

button,
input {
    font: inherit;
}

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

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

.header-inner {
    min-height: 74px;
    display: flex;
    align-items: center;
    gap: 22px;
}

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

.brand-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 15px;
    color: #ffffff;
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    box-shadow: 0 12px 25px rgba(217, 119, 6, 0.28);
}

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

.brand-text strong {
    font-size: 20px;
    color: var(--amber-deep);
    letter-spacing: 0.04em;
}

.brand-text em {
    margin-top: 4px;
    color: var(--amber);
    font-size: 12px;
    font-style: normal;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    flex: 1;
    white-space: nowrap;
}

.nav-link {
    color: #5f4a2a;
    font-weight: 650;
    transition: color 0.2s ease, transform 0.2s ease;
}

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

.top-search,
.mobile-search {
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 4px;
    box-shadow: 0 10px 30px rgba(146, 64, 14, 0.08);
}

.top-search input,
.mobile-search input {
    width: 210px;
    border: 0;
    outline: 0;
    padding: 9px 12px 9px 16px;
    background: transparent;
    color: var(--text);
}

.top-search button,
.mobile-search button {
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    padding: 9px 16px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 700;
}

.menu-toggle {
    display: none;
    margin-left: auto;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 10px 22px rgba(146, 64, 14, 0.12);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: var(--amber-deep);
    border-radius: 4px;
}

.mobile-panel {
    display: none;
    border-top: 1px solid var(--line);
    padding: 16px;
    background: rgba(255, 251, 235, 0.98);
}

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

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

.hero-carousel {
    position: relative;
    min-height: 580px;
    overflow: hidden;
    color: #ffffff;
    background: var(--dark);
}

.hero-track {
    position: relative;
    min-height: 580px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s ease;
    background:
        radial-gradient(circle at 72% 22%, rgba(251, 191, 36, 0.26), transparent 22rem),
        linear-gradient(115deg, rgba(67, 20, 7, 0.96) 0%, rgba(67, 20, 7, 0.75) 48%, rgba(67, 20, 7, 0.24) 100%),
        var(--hero-image) center / cover no-repeat;
}

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

.hero-content {
    min-height: 580px;
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 44px;
    align-items: center;
    padding: 64px 0;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fde68a;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.hero-title {
    margin: 18px 0 20px;
    max-width: 760px;
    font-size: clamp(44px, 7vw, 78px);
    line-height: 0.96;
    font-weight: 950;
    letter-spacing: -0.045em;
}

.hero-desc {
    max-width: 700px;
    color: #ffedd5;
    font-size: 20px;
    line-height: 1.8;
}

.hero-meta,
.detail-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.hero-meta span,
.detail-meta span {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #fffbeb;
    font-weight: 700;
}

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

.btn-primary,
.btn-secondary,
.btn-soft {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    padding: 14px 24px;
    box-shadow: 0 18px 35px rgba(234, 88, 12, 0.34);
}

.btn-secondary {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.28);
    background: rgba(255, 255, 255, 0.12);
    padding: 13px 22px;
}

.btn-soft {
    color: var(--amber-deep);
    background: #ffedd5;
    padding: 12px 18px;
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-soft:hover {
    transform: translateY(-2px);
}

.hero-card {
    position: relative;
    aspect-ratio: 3 / 4;
    border-radius: 32px;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(217, 119, 6, 0.45), rgba(67, 20, 7, 0.85));
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.hero-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-card span {
    position: absolute;
    inset: auto 18px 18px;
    color: #ffffff;
    font-weight: 900;
    font-size: 18px;
    text-shadow: 0 3px 14px rgba(0, 0, 0, 0.55);
}

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

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

.hero-dots button.is-active {
    width: 32px;
    background: #fbbf24;
}

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

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

.section-heading h1,
.section-heading h2 {
    margin: 0;
    color: #171717;
    font-size: clamp(30px, 4vw, 44px);
    font-weight: 950;
    letter-spacing: -0.035em;
}

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

.section-link {
    flex-shrink: 0;
    color: var(--orange);
    font-weight: 900;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--panel);
    border: 1px solid var(--line);
    box-shadow: 0 12px 36px rgba(146, 64, 14, 0.1);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(217, 119, 6, 0.34);
    box-shadow: var(--shadow);
}

.poster-box {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 18%, rgba(251, 191, 36, 0.55), transparent 36%),
        linear-gradient(135deg, #7c2d12, #111827);
}

.poster-box img,
.mini-poster img,
.detail-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.poster-fallback {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 22px;
    text-align: center;
    color: #fff7ed;
    font-size: 24px;
    font-weight: 950;
    line-height: 1.25;
}

.poster-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(217, 119, 6, 0.92);
    font-size: 12px;
    font-weight: 900;
}

.card-body {
    padding: 18px;
}

.card-tags,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    min-height: 25px;
}

.card-tags span,
.detail-tags span,
.category-strip a {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    color: var(--amber-deep);
    background: #ffedd5;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

.card-body h3 {
    margin: 12px 0 9px;
    color: #111827;
    font-size: 20px;
    line-height: 1.28;
    font-weight: 900;
}

.card-body p {
    margin: 0;
    color: var(--muted);
    line-height: 1.72;
}

.card-meta {
    margin-top: 14px;
    color: #9a3412;
    font-size: 13px;
    font-weight: 750;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 26px;
    align-items: start;
}

.side-panel,
.content-panel {
    border-radius: var(--radius);
    background: var(--panel);
    border: 1px solid var(--line);
    box-shadow: 0 12px 34px rgba(146, 64, 14, 0.08);
}

.content-panel {
    padding: 28px;
}

.side-panel {
    padding: 22px;
    position: sticky;
    top: 96px;
}

.side-panel h2,
.side-panel h3,
.content-panel h2,
.content-panel h3 {
    margin: 0 0 18px;
    color: #111827;
    font-size: 22px;
    font-weight: 950;
}

.mini-list {
    display: grid;
    gap: 14px;
}

.mini-card {
    display: grid;
    grid-template-columns: 86px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 16px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.mini-card:hover {
    background: #fff7ed;
    transform: translateX(3px);
}

.mini-poster {
    position: relative;
    display: block;
    height: 64px;
    overflow: hidden;
    border-radius: 14px;
    background: linear-gradient(135deg, #92400e, #111827);
}

.mini-poster span {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #ffffff;
    font-size: 12px;
    font-weight: 850;
    text-align: center;
    padding: 8px;
}

.mini-info strong {
    display: block;
    color: #111827;
    font-weight: 900;
    line-height: 1.35;
}

.mini-info em {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
    line-height: 1.4;
}

.category-strip {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 8px 0 22px;
    margin-bottom: 16px;
}

.category-strip a {
    white-space: nowrap;
    border: 1px solid transparent;
}

.category-strip a:hover,
.category-strip a.is-current {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
}

.page-hero {
    padding: 62px 0 34px;
}

.page-card {
    border-radius: 34px;
    padding: 44px;
    color: #ffffff;
    background:
        radial-gradient(circle at 80% 0%, rgba(251, 191, 36, 0.32), transparent 30rem),
        linear-gradient(135deg, #431407, #9a3412 58%, #d97706);
    box-shadow: var(--shadow);
}

.page-card h1 {
    margin: 0;
    font-size: clamp(34px, 5vw, 56px);
    font-weight: 950;
    letter-spacing: -0.04em;
}

.page-card p {
    margin: 14px 0 0;
    max-width: 850px;
    color: #ffedd5;
    font-size: 18px;
    line-height: 1.8;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin: 38px 0 10px;
}

.pagination a,
.pagination strong,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 15px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid var(--line);
    color: var(--amber-deep);
    font-weight: 800;
}

.pagination strong {
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    border-color: transparent;
}

.detail-hero {
    position: relative;
    color: #ffffff;
    overflow: hidden;
    background:
        linear-gradient(115deg, rgba(67, 20, 7, 0.97), rgba(67, 20, 7, 0.72), rgba(67, 20, 7, 0.34)),
        var(--detail-image) center / cover no-repeat;
}

.detail-hero-inner {
    display: grid;
    grid-template-columns: 310px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
    padding: 64px 0;
}

.detail-poster {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 32px;
    background: linear-gradient(135deg, #92400e, #111827);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.detail-poster span {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 22px;
    text-align: center;
    color: #ffffff;
    font-size: 28px;
    font-weight: 950;
}

.detail-copy h1 {
    margin: 0 0 18px;
    font-size: clamp(40px, 6vw, 70px);
    line-height: 1;
    font-weight: 950;
    letter-spacing: -0.045em;
}

.detail-copy p {
    max-width: 790px;
    color: #ffedd5;
    font-size: 19px;
    line-height: 1.85;
}

.detail-tags {
    margin: 18px 0 24px;
}

.detail-player {
    padding: 48px 0 24px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 32px;
    background: #0f172a;
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.26);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    pointer-events: none;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.12), rgba(0, 0, 0, 0.5));
    transition: opacity 0.2s ease;
}

.player-shell.is-playing .player-overlay {
    opacity: 0;
}

.play-action {
    pointer-events: auto;
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    padding: 16px 28px;
    border-radius: 999px;
    font-size: 18px;
    font-weight: 950;
    box-shadow: 0 18px 50px rgba(234, 88, 12, 0.42);
    cursor: pointer;
}

.detail-body {
    padding-bottom: 64px;
}

.prose-block {
    color: #374151;
    line-height: 1.95;
    font-size: 17px;
}

.prose-block p {
    margin: 0 0 18px;
}

.rank-list {
    display: grid;
    gap: 14px;
}

.rank-item {
    display: grid;
    grid-template-columns: 48px 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 16px;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid var(--line);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.rank-no {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    color: #ffffff;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--amber), var(--orange));
    font-weight: 950;
}

.rank-main strong {
    display: block;
    color: #111827;
    font-size: 18px;
    font-weight: 950;
}

.rank-main span,
.rank-extra {
    color: var(--muted);
    font-size: 14px;
}

.search-empty {
    display: none;
    padding: 30px;
    border-radius: 22px;
    background: #ffffff;
    border: 1px solid var(--line);
    color: var(--muted);
    text-align: center;
    font-weight: 800;
}

.site-footer {
    margin-top: 28px;
    color: #ffedd5;
    background:
        radial-gradient(circle at 20% 0%, rgba(251, 191, 36, 0.18), transparent 24rem),
        linear-gradient(135deg, #431407, #7c2d12);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 34px;
    padding: 44px 0;
}

.footer-logo .brand-text strong {
    color: #ffffff;
}

.footer-logo .brand-text em,
.footer-brand p,
.footer-links a,
.footer-bottom {
    color: #fed7aa;
}

.footer-brand p {
    max-width: 420px;
    line-height: 1.8;
}

.footer-col h3 {
    margin: 0 0 16px;
    color: #ffffff;
    font-size: 18px;
    font-weight: 900;
}

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

.footer-links a:hover {
    color: #ffffff;
}

.footer-bottom {
    padding: 18px 0 28px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

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

    .menu-toggle {
        display: block;
    }

    .hero-content,
    .detail-hero-inner,
    .split-layout {
        grid-template-columns: 1fr;
    }

    .hero-card,
    .detail-poster {
        max-width: 340px;
    }

    .side-panel {
        position: static;
    }

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

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

    .brand-text em {
        display: none;
    }

    .hero-carousel,
    .hero-track,
    .hero-content {
        min-height: 650px;
    }

    .hero-content {
        padding: 44px 0 72px;
    }

    .hero-title {
        font-size: 44px;
    }

    .hero-desc,
    .detail-copy p,
    .page-card p {
        font-size: 16px;
    }

    .hero-card,
    .detail-poster {
        max-width: 240px;
    }

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

    .card-body {
        padding: 14px;
    }

    .card-body h3 {
        font-size: 17px;
    }

    .page-card,
    .content-panel {
        padding: 24px;
        border-radius: 24px;
    }

    .rank-item {
        grid-template-columns: 42px 1fr;
    }

    .rank-extra {
        grid-column: 2;
    }

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

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

    .mobile-panel nav {
        grid-template-columns: 1fr;
    }
}
