* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body.site-body {
    margin: 0;
    color: #1f2937;
    background: linear-gradient(180deg, #fff1f2 0%, #fffbeb 45%, #ffffff 100%);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "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;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(90deg, rgba(136, 19, 55, 0.97), rgba(120, 53, 15, 0.97), rgba(136, 19, 55, 0.97));
    box-shadow: 0 12px 30px rgba(80, 23, 38, 0.22);
    backdrop-filter: blur(10px);
}

.nav-wrap {
    min-height: 72px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-size: 20px;
    font-weight: 800;
    white-space: nowrap;
}

.brand-icon {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #e11d48, #d97706);
    box-shadow: 0 12px 25px rgba(225, 29, 72, 0.35);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    color: rgba(255, 255, 255, 0.92);
    font-weight: 600;
}

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

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-nav a:hover,
.mobile-nav a.is-active {
    color: #fcd34d;
}

.site-search {
    margin-left: auto;
    width: min(290px, 32vw);
    display: flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.45);
}

.site-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    padding: 11px 4px 11px 16px;
    color: #374151;
    background: transparent;
}

.site-search button {
    border: 0;
    cursor: pointer;
    padding: 10px 15px;
    color: #881337;
    background: transparent;
    font-weight: 800;
}

.mobile-menu-button {
    display: none;
    border: 0;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 8px 11px;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    padding: 0 16px 16px;
    color: #ffffff;
}

.mobile-nav a {
    display: block;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
    margin-top: 8px;
}

.hero {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    background: #111827;
}

.hero-slide {
    display: none;
    min-height: 600px;
    position: relative;
}

.hero-slide.is-active {
    display: block;
}

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.12));
}

.hero-content {
    position: relative;
    min-height: 600px;
    display: flex;
    align-items: center;
    padding: 80px 0;
}

.hero-text {
    max-width: 720px;
    color: #ffffff;
}

.kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #fbbf24;
    font-weight: 800;
    margin-bottom: 16px;
}

.hero h1,
.hero h2 {
    margin: 0 0 18px;
    font-size: clamp(38px, 6vw, 70px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero p {
    max-width: 650px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 20px;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 0 0 30px;
}

.hero-meta span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 8px 14px;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
}

.hero-meta span:first-child {
    background: #e11d48;
    color: #ffffff;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    padding: 13px 22px;
    cursor: pointer;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
    color: #ffffff;
    background: linear-gradient(90deg, #e11d48, #d97706);
    box-shadow: 0 15px 35px rgba(225, 29, 72, 0.35);
}

.btn-light {
    color: #881337;
    background: rgba(255, 255, 255, 0.92);
}

.hero-controls {
    position: absolute;
    left: 50%;
    bottom: 28px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 10px;
    transform: translateX(-50%);
}

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

.hero-dot.is-active {
    width: 32px;
    background: #fbbf24;
}

main {
    display: block;
}

.page-section {
    padding: 62px 0;
}

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

.section-heading span {
    color: #e11d48;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.section-heading h1,
.section-heading h2 {
    margin: 6px 0 0;
    color: #1f2937;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
    font-weight: 900;
}

.section-heading p {
    max-width: 720px;
    margin: 10px 0 0;
    color: #6b7280;
}

.section-more {
    color: #9f1239;
    font-weight: 800;
}

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

.movie-card {
    border-radius: 22px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(80, 23, 38, 0.1);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 48px rgba(80, 23, 38, 0.18);
}

.movie-card-link {
    display: block;
    height: 100%;
}

.poster-wrap {
    position: relative;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #fee2e2, #fef3c7);
}

.poster-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.7));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.movie-card:hover .poster-shade {
    opacity: 1;
}

.poster-badge,
.poster-year {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
    font-weight: 800;
}

.poster-badge {
    top: 12px;
    left: 12px;
    color: #ffffff;
    background: #e11d48;
}

.poster-year {
    right: 12px;
    bottom: 12px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.7);
}

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

.movie-card-body h3 {
    min-height: 48px;
    margin: 0 0 8px;
    color: #1f2937;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 900;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-card:hover h3 {
    color: #9f1239;
}

.movie-card-body p {
    min-height: 44px;
    margin: 0 0 12px;
    color: #6b7280;
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-meta-line {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: #6b7280;
    font-size: 12px;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 190px;
    border-radius: 24px;
    padding: 24px;
    color: #ffffff;
    background: linear-gradient(135deg, #be123c, #d97706);
    box-shadow: 0 20px 45px rgba(136, 19, 55, 0.18);
}

.category-card:after {
    content: "";
    position: absolute;
    right: -40px;
    bottom: -45px;
    width: 140px;
    height: 140px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
}

.category-card h3 {
    position: relative;
    margin: 0 0 10px;
    font-size: 24px;
    font-weight: 900;
}

.category-card p {
    position: relative;
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.86);
}

.category-card span {
    position: relative;
    display: inline-flex;
    border-radius: 999px;
    padding: 7px 12px;
    color: #7f1d1d;
    background: rgba(255, 255, 255, 0.9);
    font-weight: 800;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1.5fr 0.8fr 0.8fr;
    gap: 14px;
    margin: 0 0 24px;
    padding: 16px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 12px 28px rgba(80, 23, 38, 0.08);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid #fecdd3;
    border-radius: 999px;
    padding: 12px 16px;
    color: #374151;
    background: #ffffff;
    outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18);
}

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

.rank-item a {
    display: grid;
    grid-template-columns: 52px 74px 1fr;
    gap: 14px;
    align-items: center;
    min-height: 116px;
    border-radius: 22px;
    padding: 12px;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(80, 23, 38, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item a:hover {
    transform: translateY(-3px);
    box-shadow: 0 22px 40px rgba(80, 23, 38, 0.16);
}

.rank-number {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #e11d48, #d97706);
    font-size: 20px;
    font-weight: 900;
}

.rank-item img {
    width: 74px;
    height: 96px;
    border-radius: 14px;
    object-fit: cover;
    background: #fef3c7;
}

.rank-item h3 {
    margin: 0 0 6px;
    color: #1f2937;
    font-size: 18px;
    font-weight: 900;
}

.rank-item p,
.rank-meta {
    margin: 0;
    color: #6b7280;
    font-size: 13px;
}

.rank-item p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.detail-hero {
    padding: 36px 0 64px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0 0 18px;
    color: #9f1239;
    font-size: 14px;
    font-weight: 800;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #020617;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.34);
}

.player-video {
    position: relative;
    z-index: 1;
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    cursor: pointer;
    background: #000000;
}

.player-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.56;
}

.player-cover.is-hidden {
    display: none;
}

.play-ring {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 92px;
    height: 92px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #e11d48, #d97706);
    box-shadow: 0 20px 50px rgba(225, 29, 72, 0.45);
    transform: translate(-50%, -50%);
    font-size: 34px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 30px;
    margin-top: 30px;
}

.detail-card {
    border-radius: 28px;
    padding: 28px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 16px 38px rgba(80, 23, 38, 0.1);
}

.detail-card h1 {
    margin: 0 0 12px;
    color: #111827;
    font-size: clamp(30px, 5vw, 48px);
    line-height: 1.12;
    font-weight: 900;
}

.detail-intro {
    margin: 0 0 18px;
    color: #4b5563;
    font-size: 18px;
}

.info-chips,
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 16px 0 0;
}

.info-chips span,
.tag-list span {
    display: inline-flex;
    border-radius: 999px;
    padding: 7px 12px;
    color: #9f1239;
    background: #ffe4e6;
    font-size: 13px;
    font-weight: 800;
}

.detail-text h2 {
    margin: 28px 0 10px;
    color: #111827;
    font-size: 24px;
    font-weight: 900;
}

.detail-text p {
    margin: 0;
    color: #374151;
    line-height: 1.9;
}

.side-poster {
    border-radius: 28px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 16px 38px rgba(80, 23, 38, 0.1);
}

.side-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    background: #fef3c7;
}

.side-poster div {
    padding: 18px;
}

.side-poster h2 {
    margin: 0 0 10px;
    color: #111827;
    font-size: 22px;
    font-weight: 900;
}

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

.compact-card .movie-card-body h3 {
    min-height: 42px;
    font-size: 16px;
}

.compact-card .movie-card-body p {
    display: none;
}

.site-footer {
    margin-top: 50px;
    padding: 34px 0;
    color: rgba(255, 255, 255, 0.86);
    background: linear-gradient(90deg, #881337, #78350f, #881337);
}

.footer-grid {
    display: flex;
    justify-content: space-between;
    gap: 24px;
}

.site-footer strong {
    color: #ffffff;
    font-size: 22px;
}

.site-footer p {
    max-width: 660px;
    margin: 8px 0 0;
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 16px;
    font-weight: 800;
}

.hidden {
    display: none !important;
}

.empty-result {
    display: none;
    margin: 20px 0;
    border-radius: 20px;
    padding: 18px;
    color: #9f1239;
    background: #ffe4e6;
    font-weight: 800;
}

.empty-result.is-visible {
    display: block;
}

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

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

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

    .side-poster {
        max-width: 360px;
    }
}

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

    .mobile-menu-button {
        display: inline-flex;
        margin-left: auto;
    }

    .mobile-nav.is-open {
        display: block;
    }

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

    .hero p {
        font-size: 17px;
    }

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

    .section-heading,
    .footer-grid {
        align-items: flex-start;
        flex-direction: column;
    }

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

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

    .brand span:last-child {
        font-size: 17px;
    }

    .hero h1,
    .hero h2 {
        font-size: 38px;
    }

    .movie-grid,
    .category-grid,
    .rank-list,
    .related-grid {
        grid-template-columns: 1fr;
    }

    .rank-item a {
        grid-template-columns: 44px 66px 1fr;
    }

    .detail-card {
        padding: 20px;
    }
}
