:root {
    --warm-50: #fff7ed;
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-400: #fbbf24;
    --amber-500: #f59e0b;
    --orange-400: #fb923c;
    --orange-500: #f97316;
    --red-500: #ef4444;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-900: #111827;
    --shadow: 0 18px 38px rgba(127, 72, 0, 0.13);
    --shadow-soft: 0 10px 24px rgba(127, 72, 0, 0.1);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--gray-900);
    background: linear-gradient(180deg, var(--amber-50), #fff 44%, var(--gray-50));
}

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

img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(251, 191, 36, 0.42);
    background: linear-gradient(90deg, rgba(255, 251, 235, 0.96), rgba(255, 247, 237, 0.96), rgba(255, 251, 235, 0.96));
    box-shadow: 0 8px 24px rgba(146, 64, 14, 0.09);
    backdrop-filter: blur(16px);
}

.nav-main {
    height: 66px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: max-content;
}

.brand-mark {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, var(--amber-400), var(--orange-500));
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.28);
}

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

.brand-text small {
    display: block;
    margin-top: 2px;
    color: var(--gray-600);
    font-size: 12px;
}

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

.nav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 16px;
    border-radius: 12px;
    color: var(--gray-700);
    transition: 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #fff;
    background: linear-gradient(90deg, var(--amber-400), var(--orange-400));
    box-shadow: 0 8px 18px rgba(249, 115, 22, 0.18);
}

.mobile-toggle {
    display: none;
    border: 0;
    border-radius: 12px;
    padding: 8px 12px;
    color: var(--gray-700);
    background: rgba(255, 255, 255, 0.7);
}

.category-strip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 0 12px;
    overflow-x: auto;
}

.category-strip a {
    flex: 0 0 auto;
    padding: 7px 14px;
    border: 1px solid var(--amber-200);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    color: var(--gray-700);
    font-size: 14px;
    transition: 0.2s ease;
}

.category-strip a:hover {
    color: #fff;
    background: linear-gradient(90deg, var(--amber-400), var(--orange-400));
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--amber-200);
    padding: 12px 16px 16px;
    background: #fff;
}

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

.hero {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    background: linear-gradient(90deg, var(--amber-100), #ffedd5, var(--amber-100));
}

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

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

.hero-bg {
    position: absolute;
    inset: 0;
}

.hero-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.06));
}

.hero-content {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: center;
    color: #fff;
}

.hero-copy {
    width: min(660px, 100%);
    padding: 78px 0;
}

.hero-label,
.section-kicker,
.quality-badge,
.time-badge,
.player-tag,
.chip-line span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
}

.hero-label {
    padding: 8px 18px;
    margin-bottom: 18px;
    font-weight: 700;
    background: linear-gradient(90deg, var(--amber-500), var(--orange-500));
}

.hero h1 {
    margin: 0 0 18px;
    font-size: clamp(42px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero p {
    margin: 0 0 24px;
    max-width: 620px;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(18px, 2vw, 22px);
    line-height: 1.7;
}

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

.hero-meta {
    margin-bottom: 28px;
}

.hero-meta span {
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
}

.primary-btn,
.secondary-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 24px;
    border-radius: 999px;
    font-weight: 700;
    transition: 0.2s ease;
}

.primary-btn {
    color: #fff;
    background: linear-gradient(90deg, var(--amber-500), var(--orange-500));
    box-shadow: 0 14px 26px rgba(249, 115, 22, 0.32);
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 34px rgba(249, 115, 22, 0.36);
}

.secondary-btn {
    border: 1px solid rgba(255, 255, 255, 0.38);
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 46px;
    height: 46px;
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: rgba(0, 0, 0, 0.52);
    transform: translateY(-50%);
}

.hero-control:hover {
    background: rgba(0, 0, 0, 0.76);
}

.hero-prev {
    left: 18px;
}

.hero-next {
    right: 18px;
}

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

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

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

.main-area {
    padding: 54px 0 72px;
}

.section {
    margin-bottom: 64px;
}

.section.panel {
    padding: 32px;
    border-radius: 28px;
    box-shadow: var(--shadow-soft);
}

.panel-blue {
    background: linear-gradient(120deg, #eff6ff, #ecfeff);
}

.panel-green {
    background: linear-gradient(120deg, #ecfdf5, #f0fdfa);
}

.panel-amber {
    background: linear-gradient(120deg, #fefce8, #fff7ed);
}

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

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.section-icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--amber-400), var(--orange-500));
}

.section h2,
.page-title h1 {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.16;
    letter-spacing: -0.03em;
}

.section-head p,
.page-title p {
    margin: 5px 0 0;
    color: var(--gray-600);
}

.view-more {
    color: #d97706;
    font-weight: 700;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(251, 191, 36, 0.2);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 14px 28px rgba(120, 53, 15, 0.08);
    transition: 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.poster-wrap {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, var(--amber-100), #fed7aa);
}

.poster-wrap img,
.row-cover img,
.rank-item img,
.category-card img {
    transition: transform 0.35s ease;
}

.movie-card:hover .poster-wrap img,
.movie-row:hover .row-cover img,
.rank-item:hover img,
.category-card:hover img {
    transform: scale(1.08);
}

.quality-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    background: linear-gradient(90deg, var(--amber-500), var(--orange-500));
}

.time-badge {
    position: absolute;
    right: 10px;
    bottom: 10px;
    padding: 5px 9px;
    color: #fff;
    font-size: 12px;
    background: rgba(0, 0, 0, 0.72);
}

.card-body {
    padding: 16px;
}

.card-title,
.row-title {
    display: -webkit-box;
    overflow: hidden;
    color: var(--gray-900);
    font-weight: 800;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-title:hover,
.row-title:hover {
    color: #d97706;
}

.card-body p,
.row-body p {
    display: -webkit-box;
    overflow: hidden;
    margin: 10px 0 12px;
    color: var(--gray-600);
    font-size: 14px;
    line-height: 1.62;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.chip-line {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
}

.chip-line span {
    padding: 4px 9px;
    color: #b45309;
    background: #fffbeb;
    border: 1px solid var(--amber-200);
    font-size: 12px;
}

.meta-line {
    color: var(--gray-500);
    font-size: 13px;
}

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

.movie-row {
    display: flex;
    gap: 16px;
    overflow: hidden;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 12px 24px rgba(30, 64, 175, 0.08);
}

.row-cover {
    position: relative;
    width: 42%;
    min-width: 180px;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #fed7aa;
}

.row-cover span {
    position: absolute;
    right: 8px;
    bottom: 8px;
    padding: 4px 8px;
    border-radius: 8px;
    color: #fff;
    font-size: 12px;
    background: rgba(0, 0, 0, 0.74);
}

.row-body {
    flex: 1;
    padding: 16px 16px 16px 0;
    min-width: 0;
}

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

.category-card {
    position: relative;
    min-height: 170px;
    overflow: hidden;
    border-radius: 24px;
    color: #fff;
    background: #111827;
    box-shadow: var(--shadow-soft);
}

.category-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.78));
}

.category-card-body {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 18px;
    z-index: 2;
}

.category-card h3 {
    margin: 0 0 6px;
    font-size: 22px;
}

.category-card p {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.5;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 42px 62px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.82);
    transition: 0.2s ease;
}

.rank-item:hover {
    transform: translateX(4px);
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.rank-no {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    font-weight: 800;
    background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
}

.rank-item img {
    width: 62px;
    height: 80px;
    border-radius: 12px;
}

.rank-title {
    font-weight: 800;
}

.rank-score {
    color: #dc2626;
    font-weight: 900;
}

.page-title {
    margin: 0 0 30px;
    padding: 46px 0 8px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: var(--gray-600);
    font-size: 14px;
}

.breadcrumb a {
    color: #d97706;
    font-weight: 700;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1fr 180px 180px;
    gap: 12px;
    margin-bottom: 28px;
    padding: 18px;
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--amber-200);
    border-radius: 14px;
    padding: 0 14px;
    color: var(--gray-700);
    background: var(--amber-50);
    outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--orange-400);
    box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.15);
}

.detail-hero {
    padding: 46px 0 34px;
    background: radial-gradient(circle at 20% 20%, rgba(251, 191, 36, 0.22), transparent 28%), linear-gradient(135deg, #111827, #431407 70%, #7c2d12);
    color: #fff;
}

.detail-layout {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 32px;
    align-items: center;
}

.detail-cover {
    overflow: hidden;
    border-radius: 28px;
    aspect-ratio: 3 / 4;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

.detail-copy h1 {
    margin: 0 0 16px;
    font-size: clamp(36px, 5vw, 62px);
    line-height: 1.06;
}

.detail-copy p {
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.84);
    font-size: 18px;
    line-height: 1.75;
}

.player-tag {
    margin: 0 8px 8px 0;
    padding: 7px 12px;
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
}

.player-section {
    padding: 42px 0 72px;
}

.player-card {
    overflow: hidden;
    border-radius: 28px;
    background: #050505;
    box-shadow: 0 28px 60px rgba(0, 0, 0, 0.18);
}

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

.player-frame video {
    width: 100%;
    height: 100%;
    background: #000;
}

.play-mask {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: #fff;
    background: rgba(0, 0, 0, 0.38);
    cursor: pointer;
    transition: 0.2s ease;
}

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

.play-button {
    width: 86px;
    height: 86px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #fff;
    font-size: 34px;
    background: linear-gradient(135deg, var(--amber-500), var(--orange-500));
    box-shadow: 0 20px 36px rgba(249, 115, 22, 0.36);
}

.detail-text {
    display: grid;
    gap: 26px;
    margin-top: 34px;
}

.content-box {
    padding: 28px;
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.content-box h2 {
    margin: 0 0 14px;
    font-size: 28px;
}

.content-box p {
    margin: 0;
    color: var(--gray-700);
    line-height: 1.9;
}

.site-footer {
    border-top: 1px solid var(--gray-200);
    padding: 36px 0;
    background: #111827;
    color: rgba(255, 255, 255, 0.86);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 28px;
}

.site-footer strong {
    display: block;
    margin-bottom: 10px;
    color: #fff;
    font-size: 22px;
}

.site-footer p {
    margin: 0;
    line-height: 1.7;
}

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

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

.empty-state {
    display: none;
    padding: 36px;
    border-radius: 22px;
    text-align: center;
    color: var(--gray-600);
    background: #fff;
    box-shadow: var(--shadow-soft);
}

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

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

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

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

    .mobile-toggle {
        display: inline-flex;
    }

    .category-strip {
        padding-bottom: 10px;
    }

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

    .hero-control {
        display: none;
    }

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

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

    .movie-row {
        flex-direction: column;
    }

    .row-cover {
        width: 100%;
        min-width: 0;
    }

    .row-body {
        padding: 0 16px 16px;
    }

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

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

    .detail-cover {
        width: min(320px, 100%);
    }

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

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

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

    .brand-text strong {
        font-size: 18px;
    }

    .brand-text small {
        display: none;
    }

    .hero-copy {
        padding: 58px 0;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .primary-btn,
    .secondary-btn {
        width: 100%;
    }

    .movie-grid,
    .movie-grid.three,
    .category-grid,
    .row-grid {
        grid-template-columns: 1fr;
    }

    .section.panel,
    .content-box {
        padding: 22px;
    }

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

    .rank-score {
        grid-column: 3;
    }
}
