:root {
    --orange: #f97316;
    --orange-dark: #ea580c;
    --amber: #f59e0b;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --panel: #ffffff;
    --soft: #fff7ed;
    --page: #f9fafb;
    --shadow: 0 20px 45px rgba(17, 24, 39, 0.10);
}

* {
    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(--ink);
    background: var(--page);
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 80;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    backdrop-filter: blur(18px);
    box-shadow: 0 6px 20px rgba(17, 24, 39, 0.06);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--orange-dark);
    font-size: 22px;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.brand-mark {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    box-shadow: 0 10px 22px rgba(249, 115, 22, 0.32);
    font-size: 15px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
    color: #374151;
    font-weight: 600;
}

.nav-link {
    position: relative;
    padding: 8px 0;
    transition: color 0.2s ease;
}

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

.nav-link.active::after,
.nav-link:hover::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--orange), var(--amber));
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    background: var(--soft);
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    margin: 5px auto;
    border-radius: 2px;
    background: var(--orange-dark);
}

.mobile-menu {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 16px;
    flex-direction: column;
    gap: 10px;
}

.mobile-menu.open {
    display: flex;
}

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

.hero-track,
.hero-slide {
    position: absolute;
    inset: 0;
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.05);
    filter: saturate(1.08) contrast(1.04);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 75% 25%, rgba(249, 115, 22, 0.42), transparent 32%),
        linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.44), rgba(0, 0, 0, 0.16)),
        linear-gradient(0deg, rgba(17, 24, 39, 0.92), transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 620px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    padding: 96px 0 120px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 18px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    color: #fed7aa;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    font-weight: 700;
}

.hero-content h1 {
    max-width: 780px;
    margin: 0;
    font-size: clamp(42px, 7vw, 78px);
    line-height: 1.03;
    letter-spacing: -0.05em;
}

.hero-content h2 {
    margin: 20px 0 8px;
    font-size: clamp(24px, 4vw, 42px);
    line-height: 1.15;
}

.hero-content p {
    max-width: 720px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.90);
    font-size: 19px;
}

.hero-meta,
.movie-meta-line,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.hero-meta span,
.movie-meta-line span,
.detail-meta span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #fff7ed;
    color: #c2410c;
    font-size: 12px;
    font-weight: 700;
}

.hero-meta span {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
}

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

.btn {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 22px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    box-shadow: 0 16px 30px rgba(249, 115, 22, 0.32);
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 38px rgba(249, 115, 22, 0.42);
}

.btn.secondary {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.36);
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(12px);
    box-shadow: none;
}

.hero-dots {
    position: absolute;
    z-index: 4;
    left: 50%;
    bottom: 34px;
    width: min(1180px, calc(100% - 32px));
    transform: translateX(-50%);
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
}

.hero-dot {
    min-height: 56px;
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 16px;
    color: rgba(255, 255, 255, 0.76);
    background: rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(10px);
    cursor: pointer;
    text-align: left;
    overflow: hidden;
}

.hero-dot.is-active {
    border-color: rgba(249, 115, 22, 0.86);
    color: #ffffff;
    background: rgba(249, 115, 22, 0.22);
}

.hero-dot strong,
.hero-dot span {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.hero-dot span {
    color: rgba(255, 255, 255, 0.72);
    font-size: 12px;
}

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

.section {
    padding: 56px 0 0;
}

.page-main {
    padding: 42px 0 0;
}

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

.section-title {
    margin: 0;
    color: var(--ink);
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.2;
}

.section-desc {
    max-width: 760px;
    margin: 8px 0 0;
    color: var(--muted);
}

.quick-search,
.search-panel {
    display: flex;
    gap: 10px;
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.quick-search {
    margin-top: -32px;
    position: relative;
    z-index: 10;
}

.search-panel {
    margin: 26px 0 24px;
}

.quick-search input,
.search-panel input,
.search-panel select {
    min-width: 0;
    flex: 1;
    height: 48px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0 18px;
    outline: none;
    color: var(--ink);
    background: #f9fafb;
}

.search-panel select {
    max-width: 210px;
    cursor: pointer;
}

.quick-search input:focus,
.search-panel input:focus,
.search-panel select:focus {
    border-color: var(--orange);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

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

.category-card {
    position: relative;
    min-height: 172px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
    border: 1px solid rgba(254, 215, 170, 0.9);
    border-radius: 22px;
    color: var(--ink);
    background: linear-gradient(135deg, #ffffff, #fff7ed);
    box-shadow: 0 12px 28px rgba(17, 24, 39, 0.07);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.category-card::after {
    content: "";
    position: absolute;
    width: 150px;
    height: 150px;
    right: -42px;
    top: -42px;
    border-radius: 999px;
    background: rgba(249, 115, 22, 0.12);
}

.category-card:hover {
    transform: translateY(-4px);
    border-color: var(--orange);
    box-shadow: 0 18px 40px rgba(17, 24, 39, 0.12);
}

.category-card h2 {
    position: relative;
    z-index: 1;
    margin: 0 0 8px;
    color: var(--orange-dark);
    font-size: 22px;
}

.category-card p {
    position: relative;
    z-index: 1;
    margin: 0;
    color: var(--muted);
}

.category-card span {
    position: relative;
    z-index: 1;
    color: var(--orange-dark);
    font-weight: 800;
}

.category-card img {
    position: absolute;
    right: -18px;
    bottom: -36px;
    width: 128px;
    height: 190px;
    border-radius: 18px;
    object-fit: cover;
    opacity: 0.18;
    transform: rotate(8deg);
}

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

.movie-card {
    border-radius: 22px;
    background: var(--panel);
    box-shadow: 0 12px 28px rgba(17, 24, 39, 0.08);
    overflow: hidden;
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 48px rgba(17, 24, 39, 0.14);
}

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

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

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

.poster-glow {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.42), transparent 45%);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.movie-card:hover .poster-glow {
    opacity: 1;
}

.card-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    font-size: 12px;
    font-weight: 800;
    box-shadow: 0 10px 22px rgba(249, 115, 22, 0.36);
}

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

.movie-meta-line {
    color: var(--muted);
    margin-bottom: 10px;
}

.movie-card h2 {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h2 a:hover,
.rank-item h2 a:hover,
.breadcrumb a:hover {
    color: var(--orange-dark);
}

.movie-card p {
    display: -webkit-box;
    min-height: 50px;
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 14px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 46px 84px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(17, 24, 39, 0.06);
}

.rank-number {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    font-weight: 900;
}

.rank-item img {
    width: 84px;
    height: 116px;
    border-radius: 14px;
    object-fit: cover;
}

.rank-item h2 {
    margin: 0 0 6px;
    font-size: 18px;
}

.rank-item p {
    display: -webkit-box;
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 14px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.page-hero {
    padding: 54px 0;
    color: #ffffff;
    background:
        radial-gradient(circle at 18% 12%, rgba(255, 255, 255, 0.18), transparent 28%),
        linear-gradient(135deg, var(--orange), var(--amber));
}

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

.page-hero h1 {
    max-width: 920px;
    margin: 0 0 14px;
    font-size: clamp(34px, 6vw, 56px);
    line-height: 1.12;
}

.page-hero p {
    max-width: 860px;
    margin: 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: 18px;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.16fr) minmax(320px, 0.84fr);
    gap: 28px;
    align-items: start;
}

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

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000000;
    overflow: hidden;
}

.movie-video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    background: #000000;
    cursor: pointer;
}

.play-overlay {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
    cursor: pointer;
}

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

.play-icon {
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding-left: 5px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--orange), var(--amber));
    font-size: 34px;
    box-shadow: 0 22px 44px rgba(249, 115, 22, 0.36);
}

.player-caption {
    padding: 18px 20px;
}

.player-caption h2 {
    margin: 0 0 8px;
    font-size: 22px;
}

.player-caption p {
    margin: 0;
    color: var(--muted);
}

.detail-card {
    padding: 26px;
}

.detail-card h1 {
    margin: 0 0 12px;
    font-size: clamp(30px, 5vw, 46px);
    line-height: 1.15;
}

.detail-lead {
    margin: 0 0 18px;
    color: var(--muted);
    font-size: 17px;
}

.detail-meta {
    margin-bottom: 18px;
}

.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 18px;
}

.detail-tags a,
.detail-tags span {
    padding: 7px 12px;
    border-radius: 999px;
    color: #9a3412;
    background: #ffedd5;
    font-size: 13px;
    font-weight: 700;
}

.text-card {
    padding: 28px;
    margin-top: 28px;
}

.text-card h2 {
    margin: 0 0 12px;
    color: var(--ink);
    font-size: 26px;
}

.text-card p {
    margin: 0 0 18px;
    color: #374151;
    font-size: 16px;
}

.text-card p:last-child {
    margin-bottom: 0;
}

.no-results {
    display: none;
    padding: 34px;
    border-radius: 20px;
    color: var(--muted);
    background: #ffffff;
    text-align: center;
}

.no-results.show {
    display: block;
}

.site-footer {
    margin-top: 68px;
    color: #ffffff;
    background: #111827;
}

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

.footer-logo {
    color: #fb923c;
}

.footer-brand p,
.site-footer li,
.site-footer a {
    color: #d1d5db;
}

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

.site-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer li {
    margin: 0 0 9px;
}

.site-footer a:hover {
    color: #fb923c;
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.10);
    color: #9ca3af;
    text-align: center;
    font-size: 14px;
}

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

    .nav-toggle {
        display: block;
    }

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

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

    .footer-inner {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .brand {
        font-size: 18px;
    }

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

    .hero-content {
        padding-top: 80px;
        padding-bottom: 170px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .hero-dots {
        grid-template-columns: 1fr;
        bottom: 18px;
    }

    .hero-dot {
        min-height: 44px;
    }

    .quick-search,
    .search-panel {
        flex-direction: column;
        border-radius: 18px;
    }

    .search-panel select {
        max-width: none;
    }

    .section-head {
        display: block;
    }

    .category-grid,
    .movie-grid,
    .rank-list {
        grid-template-columns: 1fr;
    }

    .rank-item {
        grid-template-columns: 40px 76px minmax(0, 1fr);
    }

    .rank-item img {
        width: 76px;
        height: 106px;
    }

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

@media (max-width: 480px) {
    .nav-shell,
    .section,
    .page-main,
    .page-hero-inner,
    .footer-inner,
    .footer-bottom,
    .hero-content,
    .hero-dots {
        width: min(100% - 24px, 1180px);
    }

    .movie-grid {
        gap: 16px;
    }

    .detail-card,
    .text-card {
        padding: 20px;
    }
}
