:root {
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-500: #f59e0b;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --amber-800: #92400e;
    --amber-900: #78350f;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    --teal-600: #0d9488;
    --white: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--slate-800);
    background: linear-gradient(180deg, var(--amber-50) 0%, var(--white) 34%, var(--slate-50) 100%);
}

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

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

main {
    min-height: 70vh;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: var(--white);
    background: linear-gradient(90deg, var(--amber-800), var(--amber-700), var(--amber-900));
    box-shadow: 0 12px 30px rgba(120, 53, 15, 0.25);
}

.nav-shell {
    max-width: 1280px;
    height: 64px;
    margin: 0 auto;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: var(--amber-900);
    background: linear-gradient(135deg, var(--amber-100), var(--white));
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.brand-text {
    font-size: 21px;
    letter-spacing: 0.03em;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    font-weight: 650;
}

.nav-link {
    position: relative;
    padding: 8px 0;
    color: rgba(255, 255, 255, 0.88);
    transition: color 0.2s ease;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    transform: scaleX(0);
    transform-origin: center;
    background: var(--amber-100);
    transition: transform 0.2s ease;
}

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

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

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

.mobile-menu-button span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--white);
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    padding: 12px 22px 18px;
    background: var(--amber-800);
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

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

.mobile-link {
    padding: 10px 12px;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.92);
}

.mobile-link.active,
.mobile-link:hover {
    background: rgba(255, 255, 255, 0.12);
}

.hero {
    position: relative;
    overflow: hidden;
    min-height: 640px;
    color: var(--white);
    background: radial-gradient(circle at 15% 15%, rgba(253, 230, 138, 0.24), transparent 32%), linear-gradient(135deg, var(--amber-900), var(--amber-700) 50%, #7f1d1d);
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.22;
    background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.8) 1px, transparent 0);
    background-size: 34px 34px;
}

.hero-slider {
    position: relative;
    max-width: 1280px;
    margin: 0 auto;
    padding: 72px 22px 60px;
}

.hero-slide {
    display: none;
    grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.95fr);
    align-items: center;
    gap: 44px;
    min-height: 500px;
}

.hero-slide.active {
    display: grid;
}

.hero-copy {
    position: relative;
    z-index: 2;
}

.hero-eyebrow {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: var(--amber-100);
    font-weight: 700;
    backdrop-filter: blur(10px);
}

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

.hero p {
    max-width: 720px;
    margin: 0 0 28px;
    color: rgba(255, 251, 235, 0.88);
    font-size: clamp(17px, 2vw, 22px);
    line-height: 1.8;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
}

.button-primary,
.button-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 13px;
    font-weight: 800;
    box-shadow: 0 14px 28px rgba(15, 23, 42, 0.18);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button-primary {
    color: var(--amber-900);
    background: var(--white);
}

.button-secondary {
    color: var(--white);
    background: rgba(120, 53, 15, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.35);
}

.button-primary:hover,
.button-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 36px rgba(15, 23, 42, 0.24);
}

.hero-visual {
    position: relative;
    z-index: 2;
}

.hero-poster {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    min-height: 430px;
    box-shadow: 0 28px 80px rgba(15, 23, 42, 0.34);
    background: rgba(255, 255, 255, 0.12);
}

.hero-poster img {
    width: 100%;
    height: 430px;
    object-fit: cover;
    transform: scale(1.02);
}

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(15, 23, 42, 0.82), transparent 55%);
}

.poster-caption {
    position: absolute;
    left: 22px;
    right: 22px;
    bottom: 22px;
    z-index: 2;
}

.poster-caption strong {
    display: block;
    font-size: 28px;
    margin-bottom: 8px;
}

.poster-caption span {
    color: rgba(255, 255, 255, 0.82);
}

.hero-dots {
    display: flex;
    gap: 10px;
    margin-top: 18px;
}

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

.hero-dot.active {
    background: var(--white);
}

.section,
.page-hero,
.detail-shell {
    max-width: 1280px;
    margin: 0 auto;
    padding: 64px 22px;
}

.page-hero {
    padding-top: 54px;
    padding-bottom: 42px;
}

.page-hero.compact {
    padding-bottom: 22px;
}

.page-kicker,
.section-kicker {
    display: inline-flex;
    margin-bottom: 14px;
    padding: 7px 13px;
    border-radius: 999px;
    color: var(--amber-800);
    background: var(--amber-100);
    font-weight: 800;
}

.page-hero h1,
.section-title h2,
.detail-info h1 {
    margin: 0;
    color: var(--slate-900);
    font-size: clamp(32px, 4vw, 52px);
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.page-hero p,
.section-title p {
    max-width: 820px;
    color: var(--slate-600);
    font-size: 17px;
    line-height: 1.8;
}

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

.section-title a {
    color: var(--amber-700);
    font-weight: 800;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--white);
    box-shadow: var(--shadow);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 25px 55px rgba(15, 23, 42, 0.18);
}

.card-cover {
    position: relative;
    display: block;
    overflow: hidden;
    height: 250px;
    background: linear-gradient(135deg, var(--amber-100), var(--slate-200));
}

.movie-grid.small .card-cover,
.movie-card.compact .card-cover {
    height: 210px;
}

.card-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

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

.card-year,
.rank-number {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 2;
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--white);
    background: var(--amber-600);
    font-size: 13px;
    font-weight: 800;
}

.rank-number {
    left: auto;
    right: 14px;
    background: rgba(15, 23, 42, 0.78);
}

.card-body {
    padding: 20px;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.card-meta span {
    padding: 4px 8px;
    border-radius: 8px;
    color: var(--slate-600);
    background: var(--slate-100);
    font-size: 12px;
    font-weight: 700;
}

.card-body h2 {
    margin: 0 0 8px;
    color: var(--slate-900);
    font-size: 20px;
    line-height: 1.35;
}

.card-body h2 a:hover {
    color: var(--amber-700);
}

.card-genre,
.card-desc {
    margin: 0 0 10px;
    color: var(--slate-600);
    line-height: 1.65;
}

.card-desc {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

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

.tag-row span {
    padding: 5px 8px;
    border-radius: 8px;
    color: var(--amber-800);
    background: var(--amber-50);
    font-size: 12px;
    font-weight: 700;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 178px;
    padding: 24px;
    border-radius: 22px;
    color: var(--white);
    background: linear-gradient(135deg, var(--slate-900), var(--amber-800));
    box-shadow: var(--shadow);
}

.category-card::after {
    content: "";
    position: absolute;
    width: 130px;
    height: 130px;
    right: -48px;
    bottom: -48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
}

.category-card h2 {
    position: relative;
    z-index: 1;
    margin: 0 0 10px;
    font-size: 24px;
}

.category-card p {
    position: relative;
    z-index: 1;
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
}

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

.filter-panel {
    max-width: 1280px;
    margin: 0 auto 20px;
    padding: 0 22px;
}

.filter-grid {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 16px;
    padding: 22px;
    border-radius: 20px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.filter-grid label {
    display: grid;
    gap: 8px;
    color: var(--slate-700);
    font-weight: 800;
}

.filter-grid input,
.filter-grid select {
    width: 100%;
    height: 44px;
    padding: 0 13px;
    border: 1px solid var(--slate-200);
    border-radius: 12px;
    color: var(--slate-800);
    background: var(--slate-50);
    outline: none;
}

.filter-grid input:focus,
.filter-grid select:focus {
    border-color: var(--amber-500);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.16);
}

.empty-state {
    display: none;
    max-width: 1280px;
    margin: 16px auto 0;
    padding: 30px 22px;
    text-align: center;
    color: var(--slate-600);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 54px 74px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 14px;
    border-radius: 18px;
    background: var(--white);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.rank-index {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: var(--white);
    background: var(--amber-600);
    font-weight: 900;
}

.rank-thumb {
    overflow: hidden;
    width: 74px;
    height: 98px;
    border-radius: 13px;
    background: var(--slate-100);
}

.rank-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rank-info h2 {
    margin: 0 0 8px;
    font-size: 18px;
}

.rank-info h2 a:hover {
    color: var(--amber-700);
}

.rank-info p {
    margin: 0;
    color: var(--slate-600);
}

.rank-score {
    padding: 7px 10px;
    border-radius: 999px;
    color: var(--amber-800);
    background: var(--amber-100);
    font-weight: 900;
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
    color: var(--slate-600);
    font-weight: 700;
}

.breadcrumbs a {
    color: var(--amber-700);
}

.detail-card {
    display: grid;
    grid-template-columns: 360px minmax(0, 1fr);
    gap: 34px;
    padding: 30px;
    border-radius: 28px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.detail-poster {
    overflow: hidden;
    border-radius: 22px;
    box-shadow: 0 22px 40px rgba(15, 23, 42, 0.18);
}

.detail-poster img {
    width: 100%;
    height: 520px;
    object-fit: cover;
}

.detail-info h1 {
    margin-bottom: 14px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.detail-meta span {
    padding: 7px 11px;
    border-radius: 999px;
    color: var(--slate-700);
    background: var(--slate-100);
    font-weight: 750;
}

.detail-lead {
    padding: 18px;
    border-left: 4px solid var(--amber-500);
    border-radius: 0 16px 16px 0;
    color: var(--slate-700);
    background: var(--amber-50);
    line-height: 1.8;
    font-size: 17px;
}

.detail-block {
    margin-top: 24px;
}

.detail-block h2 {
    margin: 0 0 12px;
    color: var(--slate-900);
    font-size: 24px;
}

.detail-block p {
    margin: 0;
    color: var(--slate-700);
    line-height: 1.9;
}

.player-section {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 22px 60px;
}

.player-wrap {
    overflow: hidden;
    border-radius: 28px;
    background: var(--slate-900);
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.28);
}

.video-box {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.video-box video {
    width: 100%;
    height: 100%;
    display: block;
    background: #000000;
}

.play-layer {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    color: var(--white);
    background: radial-gradient(circle at center, rgba(15, 23, 42, 0.16), rgba(15, 23, 42, 0.72));
    cursor: pointer;
    z-index: 3;
}

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

.play-icon {
    width: 84px;
    height: 84px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--amber-900);
    background: var(--white);
    font-size: 34px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

.player-title {
    padding: 22px 24px;
    color: var(--white);
    background: linear-gradient(90deg, rgba(146, 64, 14, 0.95), rgba(15, 23, 42, 0.98));
}

.player-title h2 {
    margin: 0;
    font-size: 24px;
}

.related-section {
    padding-top: 16px;
}

.site-footer {
    margin-top: 40px;
    color: #d1d5db;
    background: linear-gradient(180deg, var(--slate-900), #020617);
}

.footer-grid {
    max-width: 1280px;
    margin: 0 auto;
    padding: 48px 22px 28px;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
    gap: 30px;
}

.footer-grid h2 {
    margin: 0 0 14px;
    color: var(--white);
    font-size: 18px;
}

.footer-grid p {
    margin: 0;
    color: #cbd5e1;
    line-height: 1.8;
}

.footer-grid ul {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    gap: 10px;
}

.footer-grid a:hover {
    color: var(--amber-200);
}

.footer-bottom {
    max-width: 1280px;
    margin: 0 auto;
    padding: 18px 22px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.back-top {
    border: 0;
    border-radius: 12px;
    padding: 10px 14px;
    color: var(--white);
    background: var(--amber-700);
    cursor: pointer;
}

@media (max-width: 1024px) {
    .hero-slide,
    .detail-card {
        grid-template-columns: 1fr;
    }

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

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

    .detail-poster img {
        height: auto;
        max-height: 620px;
    }
}

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

    .mobile-menu-button {
        display: block;
    }

    .brand-text {
        display: inline-block;
        font-size: 19px;
    }

    .hero-slider {
        padding-top: 48px;
    }

    .hero-slide {
        min-height: auto;
    }

    .hero-poster,
    .hero-poster img {
        min-height: 300px;
        height: 300px;
    }

    .section-title,
    .footer-bottom {
        align-items: flex-start;
        flex-direction: column;
    }

    .movie-grid,
    .movie-grid.small,
    .category-grid,
    .footer-grid,
    .filter-grid {
        grid-template-columns: 1fr;
    }

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

    .rank-score {
        grid-column: 3;
        width: max-content;
    }

    .card-cover {
        height: 230px;
    }

    .detail-shell,
    .section,
    .page-hero {
        padding-left: 16px;
        padding-right: 16px;
    }

    .detail-card {
        padding: 18px;
        border-radius: 22px;
    }

    .play-icon {
        width: 68px;
        height: 68px;
        font-size: 28px;
    }
}
