:root {
    --primary: #dc2626;
    --primary-dark: #991b1b;
    --primary-soft: #fef2f2;
    --gold: #facc15;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --paper: #ffffff;
    --page: #f9fafb;
    --night: #0f172a;
    --radius: 18px;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--page);
    color: var(--ink);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: linear-gradient(90deg, #dc2626, #b91c1c, #991b1b);
    box-shadow: 0 12px 35px rgba(153, 27, 27, 0.28);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 900;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: var(--gold);
    color: #7f1d1d;
    box-shadow: 0 10px 24px rgba(250, 204, 21, 0.28);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 18px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 700;
}

.nav-links a {
    padding: 8px 0;
    transition: color 0.2s ease;
}

.nav-links a:hover {
    color: var(--gold);
}

.header-search {
    position: relative;
    width: min(280px, 28vw);
    margin-left: auto;
}

.header-search input,
.hero-search input,
.filter-bar input,
.filter-bar select {
    width: 100%;
    border: 1px solid rgba(255, 255, 255, 0.28);
    outline: none;
    border-radius: 999px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    backdrop-filter: blur(12px);
}

.header-search input::placeholder,
.hero-search input::placeholder {
    color: rgba(255, 255, 255, 0.72);
}

.search-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    display: none;
    overflow: hidden;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: var(--shadow);
    border: 1px solid var(--line);
    z-index: 80;
}

.search-panel.is-open {
    display: block;
}

.search-panel a {
    display: block;
    padding: 12px 14px;
    color: var(--ink);
    border-bottom: 1px solid #f3f4f6;
}

.search-panel a:hover {
    color: var(--primary);
    background: var(--primary-soft);
}

.search-panel strong {
    display: block;
    font-size: 14px;
    line-height: 1.3;
}

.search-panel span {
    color: var(--muted);
    font-size: 12px;
}

.mobile-menu-toggle {
    display: none;
    margin-left: auto;
    border: 0;
    color: #ffffff;
    background: transparent;
    font-size: 28px;
    cursor: pointer;
}

.hero {
    position: relative;
    height: min(680px, calc(100vh - 68px));
    min-height: 560px;
    overflow: hidden;
    color: #ffffff;
    background: radial-gradient(circle at 20% 30%, #ef4444, #7f1d1d 48%, #111827 100%);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.015);
    transition: opacity 0.7s ease, transform 1.1s ease;
    pointer-events: none;
}

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

.hero-bg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.42;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(8, 13, 24, 0.92) 0%, rgba(127, 29, 29, 0.76) 52%, rgba(15, 23, 42, 0.48) 100%);
}

.hero-glow {
    position: absolute;
    width: 420px;
    height: 420px;
    right: 9%;
    top: 16%;
    border-radius: 50%;
    background: rgba(250, 204, 21, 0.18);
    filter: blur(48px);
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: min(1240px, calc(100% - 32px));
    height: 100%;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.62fr);
    align-items: center;
    gap: 44px;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: rgba(250, 204, 21, 0.18);
    color: #fde68a;
    font-size: 14px;
    font-weight: 800;
    border: 1px solid rgba(250, 204, 21, 0.28);
}

.hero h1 {
    margin: 0 0 20px;
    font-size: clamp(42px, 6vw, 76px);
    line-height: 1.04;
    font-weight: 950;
    letter-spacing: -0.04em;
}

.hero-title-accent {
    color: var(--gold);
}

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

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 20px;
    border-radius: 14px;
    border: 1px solid transparent;
    font-weight: 850;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    background: var(--gold);
    color: #431407;
    box-shadow: 0 16px 35px rgba(250, 204, 21, 0.25);
}

.btn-ghost {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(10px);
}

.hero-search {
    position: relative;
    width: min(520px, 100%);
}

.hero-poster {
    position: relative;
    align-self: center;
    justify-self: end;
    width: min(360px, 100%);
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 32px 80px rgba(0, 0, 0, 0.42);
    transform: rotate(2deg);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

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

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.54), transparent 58%);
}

.hero-poster-label {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 18px;
    z-index: 2;
    font-weight: 900;
    font-size: 18px;
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 5;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(0, 0, 0, 0.24);
    color: #ffffff;
    cursor: pointer;
    backdrop-filter: blur(8px);
}

.hero-control:hover {
    background: rgba(250, 204, 21, 0.28);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

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

.hero-dot.is-active {
    width: 28px;
    background: var(--gold);
}

.section {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 58px 0;
}

.section-wide {
    padding: 64px 0;
    background: linear-gradient(135deg, #fff7ed, #fef2f2);
}

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

.section-kicker {
    margin: 0 0 8px;
    color: var(--primary);
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.section h2,
.section-title {
    margin: 0;
    font-size: clamp(30px, 4vw, 44px);
    line-height: 1.14;
    font-weight: 950;
    letter-spacing: -0.035em;
}

.section-desc {
    margin: 10px 0 0;
    max-width: 760px;
    color: var(--muted);
    font-size: 18px;
}

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

.feature-card,
.category-tile {
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover,
.category-tile:hover,
.movie-card:hover,
.rank-item:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
}

.feature-icon,
.category-icon {
    width: 54px;
    height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 14px;
    border-radius: 18px;
    background: var(--primary-soft);
    color: var(--primary);
    font-size: 26px;
}

.feature-card h3,
.category-tile h3 {
    margin: 0 0 8px;
    font-size: 21px;
    font-weight: 900;
}

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

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

.movie-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    border: 1px solid rgba(229, 231, 235, 0.9);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-cover {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #7f1d1d, #111827);
}

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

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

.movie-badge,
.rank-badge {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 2;
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(220, 38, 38, 0.92);
    color: #ffffff;
    font-size: 12px;
    font-weight: 900;
}

.play-float {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.34);
    color: #ffffff;
    font-size: 42px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.movie-card:hover .play-float {
    opacity: 1;
}

.movie-info {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 14px;
}

.movie-info h3 {
    margin: 0 0 8px;
    color: #1f2937;
    font-size: 16px;
    font-weight: 900;
    line-height: 1.32;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.movie-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    color: #6b7280;
    font-size: 12px;
}

.movie-meta span {
    padding: 3px 8px;
    border-radius: 999px;
    background: #f3f4f6;
}

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

.dark-block {
    background: linear-gradient(135deg, #111827, #7f1d1d 52%, #111827);
    color: #ffffff;
}

.dark-block .section-desc {
    color: rgba(255, 255, 255, 0.72);
}

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

.rank-item {
    display: grid;
    grid-template-columns: 68px 92px minmax(0, 1fr);
    align-items: center;
    gap: 16px;
    padding: 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.14);
    transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
    background: rgba(255, 255, 255, 0.16);
}

.rank-number {
    color: var(--gold);
    font-size: 34px;
    font-weight: 950;
    text-align: center;
}

.rank-thumb {
    width: 92px;
    border-radius: 12px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.rank-text h3 {
    margin: 0 0 8px;
    font-size: 18px;
    font-weight: 900;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.rank-text p {
    margin: 0;
    color: rgba(255, 255, 255, 0.72);
    font-size: 13px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.page-hero {
    color: #ffffff;
    background: linear-gradient(135deg, #991b1b, #dc2626 52%, #111827);
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--gold);
}

.page-hero h1 {
    margin: 0 0 14px;
    font-size: clamp(36px, 5vw, 58px);
    line-height: 1.08;
    font-weight: 950;
    letter-spacing: -0.035em;
}

.page-hero p {
    margin: 0;
    max-width: 850px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 19px;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 14px;
    margin-bottom: 26px;
}

.filter-bar input,
.filter-bar select {
    color: var(--ink);
    background: #ffffff;
    border-color: var(--line);
    backdrop-filter: none;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 32px;
    align-items: start;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #020617;
    box-shadow: var(--shadow);
}

.player-box video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 4;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #020617;
}

.player-cover.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.58;
}

.player-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(0, 0, 0, 0.18), rgba(0, 0, 0, 0.74));
}

.play-button {
    position: relative;
    z-index: 5;
    width: 88px;
    height: 88px;
    border: 0;
    border-radius: 50%;
    background: var(--gold);
    color: #7f1d1d;
    font-size: 34px;
    cursor: pointer;
    box-shadow: 0 20px 45px rgba(250, 204, 21, 0.28);
    transition: transform 0.18s ease;
}

.play-button:hover {
    transform: scale(1.06);
}

.detail-card,
.text-panel {
    border-radius: 24px;
    background: #ffffff;
    border: 1px solid var(--line);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
}

.detail-card {
    overflow: hidden;
}

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

.detail-card-body,
.text-panel {
    padding: 22px;
}

.detail-card h2,
.text-panel h2 {
    margin: 0 0 12px;
    font-size: 24px;
    font-weight: 950;
}

.detail-facts {
    display: grid;
    gap: 10px;
    margin: 16px 0 0;
    color: #374151;
}

.detail-facts div {
    display: flex;
    gap: 10px;
    border-bottom: 1px solid #f3f4f6;
    padding-bottom: 10px;
}

.detail-facts span {
    min-width: 54px;
    color: var(--muted);
}

.text-panel {
    margin-top: 22px;
}

.text-panel p {
    margin: 0 0 14px;
    color: #374151;
    font-size: 17px;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 14px;
}

.tag-cloud span {
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--primary-soft);
    color: var(--primary-dark);
    font-size: 13px;
    font-weight: 800;
}

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

.inline-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 18px;
}

.site-footer {
    margin-top: 34px;
    background: #111827;
    color: rgba(255, 255, 255, 0.78);
}

.footer-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 34px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.footer-brand {
    color: #ffffff;
    font-size: 20px;
    font-weight: 950;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-links a:hover {
    color: var(--gold);
}

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

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

    .detail-card {
        max-width: 420px;
    }
}

@media (max-width: 900px) {
    .nav-shell {
        flex-wrap: wrap;
        gap: 12px;
        padding: 10px 0;
    }

    .mobile-menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .nav-links {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 10px 0;
        border-top: 1px solid rgba(255, 255, 255, 0.18);
    }

    .nav-links.is-open {
        display: flex;
    }

    .header-search {
        order: 3;
        width: 100%;
        margin-left: 0;
    }

    .hero {
        height: auto;
        min-height: 760px;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        align-content: center;
        padding: 64px 0 92px;
    }

    .hero-poster {
        justify-self: start;
        width: 240px;
    }

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

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

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

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

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

    .hero {
        min-height: 720px;
    }

    .hero-control {
        display: none;
    }

    .hero h1 {
        font-size: 40px;
    }

    .section,
    .page-hero-inner {
        width: min(100% - 24px, 1240px);
    }

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

    .feature-strip,
    .category-grid,
    .filter-bar,
    .related-grid {
        grid-template-columns: 1fr;
    }

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

    .movie-info {
        padding: 12px;
    }

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

    .rank-thumb {
        width: 76px;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}
