:root {
    --page-bg: #f9fafb;
    --paper: #ffffff;
    --paper-soft: #fff7f7;
    --text: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --red: #dc2626;
    --red-dark: #7f1d1d;
    --red-deep: #450a0a;
    --gold: #facc15;
    --shadow: 0 18px 45px rgba(15, 23, 42, .12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

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

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, .92);
    border-bottom: 1px solid rgba(229, 231, 235, .86);
    backdrop-filter: blur(18px);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 24px;
    width: min(1200px, calc(100% - 32px));
    min-height: 72px;
    margin: 0 auto;
}

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #111827;
    font-size: 22px;
    font-weight: 800;
    white-space: nowrap;
}

.logo-mark {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    color: #ffffff;
    background: linear-gradient(135deg, #ef4444, #991b1b);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(220, 38, 38, .28);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-left: auto;
}

.desktop-nav > a,
.nav-dropdown > button {
    color: #374151;
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: color .2s ease;
}

.desktop-nav > a:hover,
.desktop-nav > a.active,
.nav-dropdown > button:hover {
    color: var(--red);
}

.nav-dropdown {
    position: relative;
}

.dropdown-panel {
    position: absolute;
    top: 34px;
    right: 0;
    display: grid;
    width: 180px;
    padding: 10px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: .2s ease;
}

.dropdown-panel a {
    padding: 9px 10px;
    color: #374151;
    border-radius: 10px;
}

.dropdown-panel a:hover {
    color: var(--red);
    background: #fef2f2;
}

.nav-dropdown:hover .dropdown-panel,
.nav-dropdown:focus-within .dropdown-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.header-search {
    display: flex;
    align-items: center;
    width: 288px;
    border: 1px solid #d1d5db;
    border-radius: 999px;
    overflow: hidden;
    background: #ffffff;
}

.header-search input {
    width: 100%;
    padding: 10px 12px 10px 16px;
    border: 0;
    outline: 0;
    background: transparent;
}

.header-search button {
    height: 40px;
    padding: 0 16px;
    color: #ffffff;
    border: 0;
    background: var(--red);
    cursor: pointer;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #ffffff;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: #111827;
}

.mobile-nav {
    display: none;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 12px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.mobile-nav a {
    display: block;
    padding: 11px 12px;
    color: #374151;
    border-radius: 12px;
}

.mobile-nav a:hover {
    color: var(--red);
    background: #fef2f2;
}

.hero-slider {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(120deg, var(--red-deep), var(--red-dark) 48%, #111827);
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 18%, rgba(248, 113, 113, .28), transparent 28%),
        radial-gradient(circle at 78% 20%, rgba(250, 204, 21, .22), transparent 24%),
        linear-gradient(90deg, rgba(69, 10, 10, .96), rgba(127, 29, 29, .72));
}

.hero-inner {
    position: relative;
    width: min(1200px, calc(100% - 32px));
    min-height: 620px;
    margin: 0 auto;
    padding: 72px 0 86px;
}

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

.hero-slide.is-active {
    display: grid;
    animation: fadeSlide .42s ease both;
}

@keyframes fadeSlide {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fee2e2;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.eyebrow {
    color: var(--red);
}

.hero-copy h1 {
    max-width: 820px;
    margin: 16px 0;
    font-size: clamp(38px, 6vw, 68px);
    line-height: 1.05;
    letter-spacing: -.04em;
}

.hero-copy p {
    max-width: 720px;
    margin: 0;
    color: #fee2e2;
    font-size: 20px;
}

.hero-tags,
.detail-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags {
    margin: 24px 0 30px;
}

.hero-tags span,
.detail-meta span,
.card-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    color: #fee2e2;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 999px;
    font-size: 13px;
}

.card-meta span {
    color: #6b7280;
    background: #f3f4f6;
    border-color: #f3f4f6;
}

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

.primary-btn,
.ghost-btn,
.card-action,
.section-link,
.rank-play {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 18px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.primary-btn,
.card-action,
.rank-play {
    color: #ffffff;
    background: linear-gradient(135deg, #ef4444, #b91c1c);
    box-shadow: 0 14px 26px rgba(220, 38, 38, .25);
}

.ghost-btn {
    color: #ffffff;
    background: rgba(255, 255, 255, .14);
    border: 1px solid rgba(255, 255, 255, .28);
}

.ghost-btn.light {
    color: #ffffff;
}

.primary-btn:hover,
.ghost-btn:hover,
.card-action:hover,
.section-link:hover,
.rank-play:hover {
    transform: translateY(-2px);
}

.hero-poster {
    position: relative;
    display: block;
    padding: 14px;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 32px;
    box-shadow: 0 28px 80px rgba(0, 0, 0, .42);
}

.hero-poster img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    background: rgba(255, 255, 255, .08);
    border-radius: 24px;
}

.hero-controls {
    position: absolute;
    right: 0;
    bottom: 34px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-arrow,
.hero-dot {
    border: 0;
    cursor: pointer;
}

.hero-arrow {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: #ffffff;
    background: rgba(255, 255, 255, .16);
    border-radius: 999px;
    font-size: 30px;
}

.hero-dot {
    width: 12px;
    height: 12px;
    padding: 0;
    background: rgba(255, 255, 255, .35);
    border-radius: 999px;
}

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

.quick-search-section,
.content-section {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
}

.quick-search-section {
    transform: translateY(-34px);
}

.quick-search-card {
    display: grid;
    grid-template-columns: 1fr minmax(280px, 520px);
    gap: 24px;
    align-items: center;
    padding: 26px;
    background: rgba(255, 255, 255, .96);
    border: 1px solid rgba(229, 231, 235, .88);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.quick-search-card h2 {
    margin: 6px 0 0;
    font-size: clamp(24px, 3vw, 34px);
    line-height: 1.2;
}

.quick-search-form,
.filter-bar {
    display: flex;
    gap: 12px;
}

.quick-search-form input,
.filter-bar input,
.filter-bar select {
    width: 100%;
    min-height: 48px;
    padding: 0 16px;
    color: var(--text);
    background: #ffffff;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    outline: 0;
}

.quick-search-form input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--red);
    box-shadow: 0 0 0 4px rgba(220, 38, 38, .1);
}

.quick-search-form button {
    min-width: 110px;
    color: #ffffff;
    background: var(--red);
    border: 0;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 800;
}

.content-section {
    padding: 54px 0;
}

.muted-section {
    width: 100%;
    padding: 64px max(16px, calc((100% - 1200px) / 2));
    background: #fff1f2;
}

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

.section-heading h2 {
    margin: 8px 0;
    font-size: clamp(26px, 4vw, 40px);
    line-height: 1.15;
}

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

.section-link {
    color: var(--red);
    background: #ffffff;
    border: 1px solid #fecaca;
    box-shadow: none;
    white-space: nowrap;
}

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

.movie-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(229, 231, 235, .9);
    border-radius: 20px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, .08);
    transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: #fecaca;
    box-shadow: 0 24px 46px rgba(127, 29, 29, .16);
}

.poster-link {
    display: block;
    padding: 12px 12px 0;
}

.poster-frame {
    display: block;
    overflow: hidden;
    background: linear-gradient(135deg, #991b1b, #111827);
    border-radius: 16px;
}

.poster-frame img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform .28s ease, opacity .2s ease;
}

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

.card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 16px;
}

.card-body h3 {
    margin: 12px 0 8px;
    font-size: 18px;
    line-height: 1.35;
}

.card-body h3 a:hover {
    color: var(--red);
}

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

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 14px 0;
}

.tag-list span {
    padding: 4px 9px;
    color: #991b1b;
    background: #fef2f2;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.card-action {
    min-height: 38px;
    margin-top: auto;
    font-size: 14px;
}

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

.category-tile {
    position: relative;
    overflow: hidden;
    min-height: 210px;
    padding: 22px;
    color: #ffffff;
    background: #111827;
    border-radius: 24px;
    box-shadow: var(--shadow);
}

.category-tile img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: .36;
    transition: transform .28s ease;
}

.category-tile:hover img {
    transform: scale(1.06);
}

.category-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(17, 24, 39, .1), rgba(69, 10, 10, .92));
}

.category-tile span,
.category-tile p {
    position: relative;
    z-index: 1;
}

.category-tile span {
    display: block;
    margin-top: 74px;
    font-size: 24px;
    font-weight: 900;
}

.category-tile p {
    margin: 8px 0 0;
    color: #fee2e2;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 70px 92px minmax(0, 1fr) auto;
    gap: 18px;
    align-items: center;
    padding: 14px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: 0 10px 24px rgba(15, 23, 42, .06);
}

.rank-number {
    color: var(--red);
    font-size: 28px;
    font-weight: 900;
    text-align: center;
}

.rank-cover {
    overflow: hidden;
    background: linear-gradient(135deg, #991b1b, #111827);
    border-radius: 14px;
}

.rank-cover img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

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

.rank-content h3 a:hover {
    color: var(--red);
}

.rank-content p {
    margin: 0 0 10px;
    color: var(--muted);
}

.rank-play {
    min-width: 86px;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(120deg, var(--red-deep), var(--red-dark), #111827);
}

.page-hero > div {
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 86px 0;
}

.page-hero h1 {
    max-width: 860px;
    margin: 12px 0;
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1.08;
}

.page-hero p {
    max-width: 760px;
    margin: 0;
    color: #fee2e2;
    font-size: 18px;
}

.filter-bar {
    margin-bottom: 24px;
}

.filter-bar select {
    max-width: 190px;
}

.category-overview-list {
    display: grid;
    gap: 24px;
}

.category-overview-card {
    padding: 24px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, .06);
}

.category-overview-head {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
}

.category-overview-head h2 {
    margin: 8px 0;
    font-size: 28px;
}

.category-overview-head p {
    margin: 0;
    color: var(--muted);
}

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

.mini-card {
    display: grid;
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    background: #f9fafb;
    border: 1px solid var(--line);
    border-radius: 16px;
}

.mini-poster {
    overflow: hidden;
    background: linear-gradient(135deg, #991b1b, #111827);
    border-radius: 12px;
}

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

.mini-info strong {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mini-info em {
    display: block;
    color: var(--muted);
    font-size: 13px;
    font-style: normal;
}

.detail-hero {
    min-height: 560px;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
}

.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(12px);
    opacity: .26;
    transform: scale(1.05);
}

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(69, 10, 10, .94), rgba(127, 29, 29, .76), rgba(17, 24, 39, .88));
}

.detail-hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 42px;
    align-items: center;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 70px 0;
}

.detail-poster {
    overflow: hidden;
    padding: 12px;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .22);
    border-radius: 28px;
    box-shadow: 0 28px 60px rgba(0, 0, 0, .36);
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 20px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: #fecaca;
}

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

.detail-summary h1 {
    margin: 0 0 18px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.05;
}

.detail-one-line {
    max-width: 820px;
    margin: 0 0 22px;
    color: #fee2e2;
    font-size: 20px;
}

.detail-tags {
    margin: 18px 0 28px;
}

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

.player-card {
    position: relative;
    overflow: hidden;
    min-height: 460px;
    background: #0f172a;
    border-radius: 26px;
    box-shadow: var(--shadow);
}

.video-element {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 460px;
    background: #000000;
    border: 0;
}

.player-curtain {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background-size: cover;
    background-position: center;
    cursor: pointer;
    transition: opacity .24s ease, visibility .24s ease;
}

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

.player-start {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-height: 64px;
    padding: 0 28px;
    color: #ffffff;
    background: linear-gradient(135deg, #ef4444, #991b1b);
    border: 0;
    border-radius: 999px;
    box-shadow: 0 24px 42px rgba(0, 0, 0, .3);
    cursor: pointer;
    font-size: 18px;
    font-weight: 900;
}

.play-icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    color: #991b1b;
    background: #ffffff;
    border-radius: 999px;
    font-size: 18px;
}

.detail-article {
    padding: 28px;
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, .06);
}

.detail-article h2 {
    margin: 0 0 12px;
    font-size: 24px;
}

.detail-article h2:not(:first-child) {
    margin-top: 28px;
}

.detail-article p {
    margin: 0;
    color: #374151;
    font-size: 17px;
}

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

.footer-inner {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.2fr;
    gap: 32px;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 46px 0;
}

.footer-logo {
    color: #ffffff;
}

.footer-inner p {
    max-width: 520px;
    color: #9ca3af;
}

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

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

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

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

.footer-bottom {
    padding: 18px 16px;
    color: #9ca3af;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, .08);
}

.is-filtered-out {
    display: none !important;
}

img.is-missing {
    opacity: 0;
}

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

    .header-search {
        margin-left: auto;
    }

    .menu-toggle {
        display: block;
    }

    .mobile-nav.is-open {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hero-slide,
    .detail-hero-inner,
    .detail-content {
        grid-template-columns: 1fr;
    }

    .hero-poster,
    .detail-poster {
        max-width: 360px;
    }

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

@media (max-width: 820px) {
    .header-inner {
        min-height: 64px;
    }

    .header-search {
        display: none;
    }

    .hero-inner {
        min-height: auto;
        padding: 48px 0 92px;
    }

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

    .quick-search-section {
        transform: none;
        padding-top: 20px;
    }

    .quick-search-card,
    .section-heading,
    .category-overview-head {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .quick-search-card,
    .section-heading,
    .category-overview-head {
        display: grid;
    }

    .quick-search-form,
    .filter-bar {
        flex-direction: column;
    }

    .filter-bar select {
        max-width: none;
    }

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

    .ranking-row {
        grid-template-columns: 52px 78px minmax(0, 1fr);
    }

    .rank-play {
        grid-column: 2 / -1;
        width: max-content;
    }

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

@media (max-width: 560px) {
    .movie-grid,
    .category-grid,
    .mini-card-grid,
    .mobile-nav.is-open {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .page-actions {
        flex-direction: column;
    }

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

    .hero-controls {
        left: 0;
        right: auto;
    }

    .page-hero > div,
    .detail-hero-inner {
        padding: 54px 0;
    }

    .video-element,
    .player-card {
        min-height: 280px;
    }
}
