:root {
    --bg: #fff7ed;
    --bg-soft: #fffbeb;
    --card: rgba(255, 255, 255, 0.86);
    --text: #1f2937;
    --muted: #6b7280;
    --line: rgba(251, 146, 60, 0.25);
    --brand: #f97316;
    --brand-dark: #c2410c;
    --gold: #f59e0b;
    --shadow: 0 22px 60px rgba(154, 52, 18, 0.14);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 10% 0%, rgba(251, 191, 36, 0.18), transparent 34rem),
        linear-gradient(180deg, #fff7ed 0%, #fff 42%, #fffbeb 100%);
    min-height: 100vh;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 247, 237, 0.84);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(251, 146, 60, 0.2);
    box-shadow: 0 10px 34px rgba(154, 52, 18, 0.08);
}

.nav-wrap {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

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

.brand-mark {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, #fbbf24, #f97316);
    box-shadow: 0 14px 28px rgba(249, 115, 22, 0.28);
}

.brand-text strong,
.footer-brand {
    display: block;
    font-size: 24px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -0.03em;
    background: linear-gradient(90deg, #b45309, #ea580c, #f59e0b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.brand-text em {
    display: block;
    font-size: 12px;
    color: var(--muted);
    font-style: normal;
    margin-top: 3px;
}

.nav-panel {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-link,
.nav-cat-button {
    border: 0;
    background: transparent;
    color: #374151;
    font-weight: 700;
    cursor: pointer;
    padding: 10px 0;
    position: relative;
}

.nav-link::after,
.nav-cat-button::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 2px;
    height: 2px;
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: center;
    background: var(--brand);
    transition: transform 0.24s ease;
}

.nav-link:hover::after,
.nav-link.active::after,
.nav-cat-button:hover::after {
    transform: scaleX(1);
}

.nav-link:hover,
.nav-link.active,
.nav-cat-button:hover {
    color: var(--brand-dark);
}

.nav-cats {
    position: relative;
}

.nav-cat-menu {
    position: absolute;
    right: 0;
    top: calc(100% + 14px);
    width: 220px;
    padding: 12px;
    display: grid;
    gap: 6px;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
    opacity: 0;
    pointer-events: none;
    transform: translateY(-8px);
    transition: 0.22s ease;
}

.nav-cats:hover .nav-cat-menu,
.nav-cats.open .nav-cat-menu {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.nav-cat-menu a {
    padding: 10px 12px;
    border-radius: 12px;
    color: #4b5563;
}

.nav-cat-menu a:hover {
    background: #fff7ed;
    color: var(--brand-dark);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    color: #7c2d12;
    background: #ffedd5;
}

.hero-carousel {
    width: min(1240px, calc(100% - 32px));
    margin: 34px auto 0;
    border-radius: 34px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 30px 80px rgba(124, 45, 18, 0.22);
    background: #431407;
}

.hero-stage {
    position: relative;
    min-height: 620px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 40px;
    align-items: center;
    padding: 72px;
    transition: opacity 0.5s ease, transform 0.5s ease;
    transform: scale(1.015);
}

.hero-slide.active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-bg,
.detail-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: saturate(1.12);
}

.hero-bg::after,
.detail-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 78% 20%, rgba(255, 255, 255, 0.18), transparent 18rem);
}

.hero-content,
.hero-poster,
.detail-copy,
.detail-poster {
    position: relative;
    z-index: 1;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--brand-dark);
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-content .eyebrow,
.detail-copy .eyebrow {
    color: #fed7aa;
}

.hero-content h1,
.page-hero h1,
.detail-copy h1 {
    margin: 0;
    font-size: clamp(40px, 7vw, 76px);
    line-height: 0.98;
    letter-spacing: -0.06em;
    font-weight: 1000;
}

.hero-content h1,
.detail-copy h1 {
    color: #fff;
    text-shadow: 0 18px 46px rgba(0, 0, 0, 0.25);
}

.hero-line,
.detail-line {
    color: rgba(255, 255, 255, 0.88);
    font-size: 20px;
    line-height: 1.8;
    margin: 24px 0;
    max-width: 700px;
}

.hero-tags,
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.tag-list span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    color: #9a3412;
    background: #ffedd5;
}

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

.primary-btn,
.ghost-btn,
.text-link,
.side-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 16px;
    font-weight: 900;
    transition: 0.24s ease;
}

.primary-btn {
    color: #fff;
    background: linear-gradient(135deg, #f97316, #f59e0b);
    box-shadow: 0 16px 38px rgba(249, 115, 22, 0.34);
}

.primary-btn:hover,
.movie-card:hover,
.ranking-row:hover {
    transform: translateY(-4px);
}

.ghost-btn {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.46);
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(12px);
}

.hero-poster,
.detail-poster {
    display: block;
    border-radius: 28px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.35);
    box-shadow: 0 24px 54px rgba(0, 0, 0, 0.36);
}

.hero-poster img,
.detail-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.hero-controls {
    position: absolute;
    left: 72px;
    bottom: 38px;
    display: flex;
    gap: 10px;
    z-index: 3;
}

.hero-dot {
    width: 42px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.35);
    cursor: pointer;
}

.hero-dot.active {
    background: #fff;
}

.quick-entry,
.section-wrap,
.page-hero,
.detail-layout {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.quick-entry {
    margin-top: 40px;
    padding: 28px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.section-wrap {
    padding: 64px 0 0;
}

.section-head {
    margin-bottom: 24px;
}

.section-head h2,
.detail-main h2,
.detail-side h2,
.site-footer h2 {
    margin: 0;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.08;
    letter-spacing: -0.04em;
    font-weight: 1000;
    color: #1f2937;
}

.between {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 24px;
}

.text-link {
    min-height: 40px;
    color: var(--brand-dark);
    background: #ffedd5;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 14px;
}

.site-search,
.year-filter {
    width: 100%;
    min-height: 54px;
    border: 2px solid rgba(251, 146, 60, 0.28);
    border-radius: 18px;
    outline: 0;
    padding: 0 18px;
    color: #374151;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.site-search:focus,
.year-filter:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 5px rgba(249, 115, 22, 0.12);
}

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

.category-card,
.category-overview-card {
    position: relative;
    overflow: hidden;
    min-height: 210px;
    border-radius: 24px;
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.category-card img,
.category-overview-card img {
    width: 100%;
    height: 210px;
    object-fit: cover;
    filter: brightness(0.72) saturate(1.12);
    transition: transform 0.35s ease;
}

.category-card:hover img,
.category-overview-card:hover img,
.movie-card:hover img {
    transform: scale(1.06);
}

.category-card span,
.category-card em,
.category-overview-card span {
    position: absolute;
    left: 18px;
    right: 18px;
    color: #fff;
    z-index: 2;
}

.category-card span,
.category-overview-card span {
    bottom: 62px;
    font-size: 22px;
    font-weight: 1000;
}

.category-card em {
    bottom: 18px;
    font-size: 13px;
    line-height: 1.5;
    font-style: normal;
    color: rgba(255, 255, 255, 0.84);
}

.category-overview-card {
    min-height: auto;
}

.category-overview-card p,
.mini-links {
    padding: 0 18px;
}

.category-overview-card p {
    color: var(--muted);
    line-height: 1.7;
}

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

.mini-links a {
    padding: 7px 10px;
    border-radius: 999px;
    background: #fff7ed;
    color: #9a3412;
    font-size: 12px;
    font-weight: 800;
}

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

.full-grid {
    margin-top: 24px;
}

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 18px 45px rgba(154, 52, 18, 0.11);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
    box-shadow: 0 26px 62px rgba(154, 52, 18, 0.18);
}

.poster-link {
    display: block;
    position: relative;
    overflow: hidden;
    background: #431407;
}

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

.poster-play,
.rank-badge {
    position: absolute;
    color: #fff;
    font-weight: 1000;
}

.poster-play {
    left: 12px;
    bottom: 12px;
    padding: 7px 10px;
    border-radius: 999px;
    font-size: 12px;
    background: rgba(249, 115, 22, 0.92);
}

.rank-badge {
    top: 10px;
    left: 10px;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #ef4444, #f59e0b);
}

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

.movie-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 44px;
    font-size: 16px;
    font-weight: 1000;
    line-height: 1.35;
}

.movie-title:hover {
    color: var(--brand-dark);
}

.movie-meta,
.movie-line {
    color: var(--muted);
    font-size: 13px;
    line-height: 1.6;
}

.movie-line {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 62px;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 48px 66px minmax(0, 1fr) 70px;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border-radius: 20px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.86);
    box-shadow: 0 10px 30px rgba(154, 52, 18, 0.08);
    transition: transform 0.2s ease, background 0.2s ease;
}

.ranking-index {
    color: #ea580c;
    font-size: 20px;
    font-weight: 1000;
}

.ranking-row img {
    width: 66px;
    height: 88px;
    object-fit: cover;
    border-radius: 14px;
}

.ranking-copy strong,
.ranking-copy em {
    display: block;
}

.ranking-copy strong {
    font-weight: 1000;
}

.ranking-copy em {
    margin-top: 6px;
    color: var(--muted);
    font-style: normal;
    font-size: 13px;
}

.heat-score {
    justify-self: end;
    color: #fff;
    background: linear-gradient(135deg, #f97316, #f59e0b);
    padding: 8px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 1000;
}

.all-ranking {
    margin-top: 30px;
}

.page-hero {
    margin-top: 34px;
    padding: 70px;
    border-radius: 34px;
    color: #fff;
    background:
        radial-gradient(circle at 82% 12%, rgba(255, 255, 255, 0.26), transparent 16rem),
        linear-gradient(135deg, #7c2d12, #ea580c 52%, #f59e0b);
    box-shadow: var(--shadow);
}

.page-hero p {
    max-width: 780px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.8;
}

.page-hero .eyebrow {
    color: #ffedd5;
}

.detail-hero {
    position: relative;
    width: min(1240px, calc(100% - 32px));
    margin: 34px auto 0;
    min-height: 620px;
    border-radius: 34px;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 42px;
    align-items: center;
    padding: 70px;
    background: #431407;
    box-shadow: 0 30px 80px rgba(124, 45, 18, 0.22);
}

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

.detail-meta span {
    padding: 8px 12px;
    border-radius: 999px;
    color: #fff7ed;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

.detail-tags span {
    background: rgba(255, 237, 213, 0.94);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 310px;
    gap: 28px;
    padding-top: 40px;
}

.detail-main,
.detail-side {
    border: 1px solid var(--line);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow);
}

.detail-main {
    overflow: hidden;
    padding-bottom: 28px;
}

.player-shell {
    position: relative;
    background: #0f172a;
}

.movie-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #0f172a;
    object-fit: contain;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.18), rgba(15, 23, 42, 0.44));
    cursor: pointer;
}

.play-overlay span {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #fff;
    background: linear-gradient(135deg, #f97316, #f59e0b);
    box-shadow: 0 20px 54px rgba(249, 115, 22, 0.42);
    font-size: 34px;
    padding-left: 6px;
}

.player-shell.playing .play-overlay {
    opacity: 0;
    pointer-events: none;
}

.detail-main h2,
.detail-main p,
.prev-next {
    margin-left: 28px;
    margin-right: 28px;
}

.detail-main h2 {
    margin-top: 28px;
    margin-bottom: 12px;
    font-size: 28px;
}

.detail-main p {
    color: #4b5563;
    line-height: 2;
    font-size: 16px;
}

.detail-side {
    padding: 24px;
    height: fit-content;
    position: sticky;
    top: 96px;
}

.detail-side dl {
    display: grid;
    gap: 12px;
    margin: 20px 0;
}

.detail-side dt {
    color: #9a3412;
    font-weight: 1000;
}

.detail-side dd {
    margin: -8px 0 8px;
    color: #4b5563;
    line-height: 1.7;
}

.side-link {
    width: 100%;
    margin-top: 10px;
    color: #9a3412;
    background: #ffedd5;
}

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

.prev-next a {
    padding: 14px;
    border-radius: 16px;
    background: #fff7ed;
    color: #9a3412;
    font-weight: 800;
}

.site-footer {
    margin-top: 74px;
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(255, 247, 237, 0.7), #ffedd5);
}

.footer-grid {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0 30px;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 1fr;
    gap: 34px;
}

.site-footer p,
.site-footer a {
    color: #6b7280;
    line-height: 1.8;
}

.site-footer a {
    display: block;
    margin-top: 8px;
}

.site-footer a:hover {
    color: var(--brand-dark);
}

.copyright {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 28px;
    font-size: 14px;
}

.hidden-by-search {
    display: none !important;
}

@media (max-width: 1080px) {
    .hero-slide,
    .detail-hero {
        grid-template-columns: 1fr 280px;
        padding: 48px;
    }

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

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

@media (max-width: 780px) {
    .menu-toggle {
        display: grid;
        place-items: center;
    }

    .nav-wrap {
        min-height: 68px;
    }

    .nav-panel {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 74px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        padding: 14px;
        border-radius: 22px;
        background: rgba(255, 255, 255, 0.96);
        border: 1px solid var(--line);
        box-shadow: var(--shadow);
    }

    .nav-panel.open {
        display: flex;
    }

    .nav-cat-menu {
        position: static;
        width: 100%;
        opacity: 1;
        pointer-events: auto;
        transform: none;
        box-shadow: none;
        background: #fff7ed;
        margin-top: 8px;
    }

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

    .hero-slide,
    .detail-hero {
        grid-template-columns: 1fr;
        padding: 28px;
    }

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

    .hero-controls {
        left: 28px;
        bottom: 24px;
    }

    .search-panel,
    .detail-layout,
    .footer-grid,
    .prev-next {
        grid-template-columns: 1fr;
    }

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

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

    .between {
        display: block;
    }

    .page-hero {
        padding: 34px;
    }

    .detail-side {
        position: static;
    }

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

    .heat-score {
        display: none;
    }
}

@media (max-width: 460px) {
    .brand-text strong {
        font-size: 20px;
    }

    .brand-mark {
        width: 40px;
        height: 40px;
    }

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

    .hero-carousel,
    .detail-hero,
    .page-hero,
    .quick-entry,
    .detail-main,
    .detail-side {
        border-radius: 22px;
    }

    .hero-content h1,
    .detail-copy h1 {
        font-size: 42px;
    }
}
