:root {
    --orange: #f97316;
    --orange-dark: #ea580c;
    --red: #ef4444;
    --amber: #f59e0b;
    --green: #16a34a;
    --purple: #7c3aed;
    --text: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --surface: #ffffff;
    --soft: #f8fafc;
    --dark: #111827;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --shadow-soft: 0 12px 28px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    background: #f3f4f6;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    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: 50;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(16px);
}

.header-inner {
    max-width: 1240px;
    height: 66px;
    margin: 0 auto;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.logo {
    font-size: 24px;
    color: #111827;
}

.logo:hover {
    color: var(--orange-dark);
}

.logo-mark {
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    border-radius: 12px;
    color: #fff;
    font-size: 14px;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 10px 24px rgba(249, 115, 22, 0.35);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    color: #374151;
    font-size: 15px;
    font-weight: 650;
}

.main-nav a,
.mobile-nav a {
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.main-nav > a:hover,
.main-nav > a.is-active,
.nav-categories a:hover {
    color: var(--orange-dark);
}

.nav-categories {
    display: flex;
    align-items: center;
    gap: 14px;
    padding-left: 10px;
    border-left: 1px solid var(--line);
}

.nav-categories a {
    color: #4b5563;
    font-size: 14px;
}

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: #f3f4f6;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 22px 18px;
}

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

.mobile-nav a {
    padding: 10px 12px;
    border-radius: 12px;
    color: #374151;
    background: #f8fafc;
}

.mobile-nav a:hover {
    color: var(--orange-dark);
    background: #fff7ed;
}

.hero {
    position: relative;
    min-height: 640px;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(135deg, #fb923c 0%, #f97316 42%, #ef4444 100%);
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 18% 22%, rgba(255, 255, 255, 0.28), transparent 26%),
        radial-gradient(circle at 86% 10%, rgba(255, 214, 165, 0.28), transparent 22%),
        linear-gradient(135deg, rgba(17, 24, 39, 0.12), rgba(17, 24, 39, 0.42));
}

.hero-slider {
    position: relative;
    max-width: 1240px;
    min-height: 640px;
    margin: 0 auto;
    padding: 84px 22px 76px;
}

.hero-slide {
    position: absolute;
    inset: 0 22px;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.72fr);
    align-items: center;
    gap: 48px;
    opacity: 0;
    transform: translateY(18px);
    pointer-events: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.hero-copy {
    max-width: 720px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.eyebrow.dark {
    color: var(--orange-dark);
}

.hero h1 {
    margin: 0 0 20px;
    font-size: clamp(40px, 7vw, 74px);
    line-height: 1.03;
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 680px;
    margin: 0 0 26px;
    color: rgba(255, 255, 255, 0.92);
    font-size: clamp(18px, 2.4vw, 25px);
}

.hero-tags,
.detail-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.hero-tags span,
.detail-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 5px 10px;
    border-radius: 999px;
    color: #fff;
    background: rgba(17, 24, 39, 0.68);
    font-size: 12px;
    font-weight: 700;
}

.tag-row span {
    color: #9a3412;
    background: #ffedd5;
}

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

.primary-button,
.ghost-button,
.tile-link,
.rank-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: #fff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 14px 32px rgba(234, 88, 12, 0.32);
}

.primary-button:hover,
.ghost-button:hover,
.tile-link:hover,
.rank-action:hover {
    transform: translateY(-2px);
}

.primary-button.small {
    min-height: 38px;
    padding: 0 16px;
    font-size: 14px;
}

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

.ghost-button.light {
    background: rgba(255, 255, 255, 0.18);
}

.hero-poster {
    position: relative;
    display: block;
    justify-self: end;
    width: min(420px, 100%);
    aspect-ratio: 3 / 4;
    border-radius: 32px;
    overflow: hidden;
    box-shadow: 0 36px 90px rgba(15, 23, 42, 0.45);
    transform: rotate(2deg);
}

.hero-poster::before {
    content: "";
    position: absolute;
    inset: 18px;
    z-index: -1;
    border-radius: 32px;
    background: rgba(255, 255, 255, 0.22);
    transform: rotate(-7deg);
}

.hero-poster img,
.poster img,
.compact-poster img,
.rank-thumb img,
.detail-cover img,
.player-shell video,
.player-shell img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

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

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

.hero-dots button.is-active {
    width: 52px;
    background: #fff;
}

.section-wrap {
    max-width: 1240px;
    margin: 0 auto;
    padding: 54px 22px;
}

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

.section-heading h2,
.quick-search h2 {
    margin: 0;
    color: #111827;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.section-heading a {
    color: var(--orange-dark);
    font-weight: 800;
}

.quick-search {
    display: grid;
    grid-template-columns: 1fr minmax(260px, 440px);
    gap: 28px;
    align-items: center;
}

.home-search-box,
.filter-panel label {
    display: grid;
    gap: 8px;
    color: #374151;
    font-weight: 800;
}

.home-search-box input,
.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 48px;
    padding: 0 15px;
    border: 1px solid var(--line);
    border-radius: 16px;
    outline: none;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

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

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

.category-tile,
.category-overview-card,
.content-panel,
.filter-panel {
    border: 1px solid rgba(229, 231, 235, 0.92);
    border-radius: 26px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.category-tile {
    padding: 26px;
    display: grid;
    align-content: space-between;
    min-height: 250px;
    overflow: hidden;
    position: relative;
}

.category-tile::after {
    content: "";
    position: absolute;
    right: -36px;
    top: -36px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.16), rgba(239, 68, 68, 0.12));
}

.category-tile > span,
.category-card-top > span {
    color: var(--orange-dark);
    font-size: 13px;
    font-weight: 900;
}

.category-tile h3,
.category-card-top h2 {
    margin: 8px 0 10px;
    font-size: 26px;
    letter-spacing: -0.03em;
}

.category-tile p,
.category-card-top p {
    margin: 0 0 18px;
    color: var(--muted);
}

.category-sample-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.category-sample-links a {
    max-width: 100%;
    padding: 6px 10px;
    border-radius: 999px;
    color: #9a3412;
    background: #fff7ed;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tile-link,
.rank-action {
    justify-self: start;
    color: #fff;
    background: #111827;
}

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

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

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

.poster-link,
.poster {
    display: block;
}

.poster {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.poster img {
    transition: transform 0.35s ease;
}

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, 0.72));
}

.poster-score {
    position: absolute;
    right: 12px;
    top: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    color: #fff;
    background: rgba(17, 24, 39, 0.78);
    font-size: 12px;
    font-weight: 900;
}

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 700;
}

.movie-card h3,
.rank-content h3 {
    margin: 8px 0;
    color: #111827;
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h3 a:hover,
.rank-content h3 a:hover {
    color: var(--orange-dark);
}

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

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(135deg, #f97316, #ef4444 72%, #7c2d12);
}

.page-hero {
    padding: 82px 22px;
    text-align: center;
}

.page-hero h1 {
    max-width: 900px;
    margin: 0 auto 18px;
    font-size: clamp(38px, 6vw, 68px);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

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

.page-hero-actions {
    justify-content: center;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1.5fr) repeat(3, minmax(160px, 1fr)) auto;
    gap: 16px;
    align-items: end;
    margin-bottom: 30px;
    padding: 18px;
}

.filter-panel button {
    min-height: 48px;
    padding: 0 18px;
    border: 0;
    border-radius: 16px;
    color: #fff;
    background: #111827;
    cursor: pointer;
    font-weight: 800;
}

.category-overview-card {
    padding: 24px;
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 22px;
}

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

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

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

.compact-poster {
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border-radius: 12px;
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.compact-info strong,
.compact-info em {
    display: block;
}

.compact-info strong {
    margin-bottom: 4px;
    color: #111827;
}

.compact-info em {
    color: var(--muted);
    font-size: 12px;
    font-style: normal;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 56px 96px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 14px;
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--shadow-soft);
}

.rank-number {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, var(--orange), var(--red));
    font-weight: 900;
}

.rank-thumb {
    height: 124px;
    overflow: hidden;
    border-radius: 16px;
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.rank-content h3 {
    font-size: 20px;
}

.rank-action {
    min-height: 38px;
    padding: 0 16px;
    background: #fff7ed;
    color: #9a3412;
}

.detail-hero {
    padding: 36px 22px 58px;
}

.detail-hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 14% 20%, rgba(255, 255, 255, 0.24), transparent 25%),
        linear-gradient(135deg, rgba(17, 24, 39, 0.08), rgba(17, 24, 39, 0.54));
}

.detail-hero-inner {
    position: relative;
    max-width: 1240px;
    margin: 0 auto;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin: 8px 0 32px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #fff;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(260px, 340px) 1fr;
    gap: 36px;
    align-items: end;
}

.detail-cover {
    overflow: hidden;
    border-radius: 28px;
    aspect-ratio: 3 / 4;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.42);
    background: linear-gradient(135deg, #f97316, #ef4444);
}

.detail-info h1 {
    margin: 0 0 16px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.04;
    letter-spacing: -0.05em;
}

.detail-one-line {
    max-width: 850px;
    margin: 0 0 20px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 20px;
}

.detail-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.detail-stats span {
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-weight: 800;
}

.player-section {
    padding-top: 42px;
    padding-bottom: 30px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #020617;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.25);
    aspect-ratio: 16 / 9;
    cursor: pointer;
}

.player-shell video {
    display: block;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 10px;
    border: 0;
    color: #fff;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.28), rgba(2, 6, 23, 0.72));
    cursor: pointer;
}

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

.play-icon {
    width: 74px;
    height: 74px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--orange), var(--red));
    box-shadow: 0 16px 40px rgba(249, 115, 22, 0.42);
    font-size: 30px;
}

.player-overlay strong {
    font-size: 20px;
}

.detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    padding-top: 20px;
}

.content-panel {
    padding: 28px;
}

.content-panel h2 {
    margin: 0 0 14px;
    font-size: 26px;
}

.content-panel p {
    margin: 0;
    color: #374151;
    font-size: 16px;
}

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

.site-footer {
    margin-top: 40px;
    color: #d1d5db;
    background: #111827;
}

.footer-grid {
    max-width: 1240px;
    margin: 0 auto;
    padding: 44px 22px;
    display: grid;
    grid-template-columns: 1.1fr 0.7fr 1.2fr;
    gap: 32px;
}

.footer-logo {
    margin-bottom: 12px;
    color: #fff;
    font-size: 24px;
}

.site-footer p {
    max-width: 420px;
    margin: 0;
    color: #9ca3af;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: #fff;
}

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

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

.footer-links a {
    color: #d1d5db;
}

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

.footer-bottom {
    max-width: 1240px;
    margin: 0 auto;
    padding: 18px 22px 28px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #9ca3af;
    text-align: center;
    font-size: 14px;
}

.is-hidden {
    display: none !important;
}

@media (max-width: 1100px) {
    .main-nav .nav-categories {
        display: none;
    }

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

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

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

    .menu-button {
        display: grid;
        place-items: center;
    }

    .hero,
    .hero-slider {
        min-height: 720px;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        align-content: center;
        gap: 26px;
    }

    .hero-poster {
        justify-self: start;
        width: 240px;
        aspect-ratio: 3 / 4;
    }

    .quick-search,
    .detail-layout,
    .detail-content,
    .category-overview-card,
    .footer-grid {
        grid-template-columns: 1fr;
    }

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

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

    .rank-action {
        display: none;
    }
}

@media (max-width: 560px) {
    .header-inner {
        height: 60px;
    }

    .logo {
        font-size: 19px;
    }

    .hero,
    .hero-slider {
        min-height: 690px;
    }

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

    .hero h1,
    .page-hero h1,
    .detail-info h1 {
        font-size: 36px;
    }

    .hero p,
    .detail-one-line {
        font-size: 17px;
    }

    .section-wrap {
        padding: 38px 16px;
    }

    .category-grid,
    .overview-grid,
    .movie-grid,
    .related-grid,
    .filter-panel {
        grid-template-columns: 1fr;
    }

    .rank-item {
        grid-template-columns: 38px 72px 1fr;
        gap: 10px;
        padding: 10px;
    }

    .rank-thumb {
        height: 96px;
    }

    .rank-content p,
    .tag-row {
        display: none;
    }

    .detail-cover {
        max-width: 240px;
    }
}
