* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-height: 100vh;
    color: #111827;
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 48%, #fef2f2 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,
video {
    display: block;
    max-width: 100%;
}

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(229, 231, 235, 0.8);
    box-shadow: 0 10px 30px rgba(17, 24, 39, 0.08);
    backdrop-filter: blur(16px);
}

.nav-shell {
    width: min(1280px, calc(100% - 32px));
    height: 64px;
    margin: 0 auto;
    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: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: linear-gradient(135deg, #fb923c, #ef4444);
    border-radius: 12px;
    box-shadow: 0 12px 24px rgba(234, 88, 12, 0.25);
    transition: transform 0.3s ease;
}

.brand:hover .brand-mark {
    transform: scale(1.08);
}

.brand-text {
    max-width: 280px;
    color: transparent;
    background: linear-gradient(90deg, #ea580c, #dc2626);
    -webkit-background-clip: text;
    background-clip: text;
    font-size: 20px;
    line-height: 1.2;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-link {
    color: #374151;
    font-weight: 700;
    transition: color 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: #ea580c;
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    border: 0;
    border-radius: 12px;
    background: transparent;
}

.mobile-toggle span {
    width: 22px;
    height: 2px;
    background: #374151;
    border-radius: 999px;
}

.mobile-toggle:hover {
    background: #f3f4f6;
}

.mobile-nav {
    display: none;
    padding: 10px 20px 18px;
    border-top: 1px solid #e5e7eb;
    background: #ffffff;
}

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

.mobile-link {
    display: block;
    padding: 11px 14px;
    color: #374151;
    border-radius: 12px;
    font-weight: 700;
}

.mobile-link:hover,
.mobile-link.active {
    color: #ea580c;
    background: #fff7ed;
}

.page-main {
    padding-top: 64px;
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(90deg, #ea580c, #ef4444, #eab308);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.44), rgba(0, 0, 0, 0.18));
}

.hero-slide::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 55%;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.75), transparent);
}

.hero-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 18px;
    padding: 48px 0;
}

.hero-kicker {
    width: max-content;
    padding: 8px 14px;
    color: #fed7aa;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 999px;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.hero h1,
.hero h2 {
    max-width: 820px;
    margin: 0;
    font-size: clamp(38px, 7vw, 76px);
    line-height: 1.02;
    font-weight: 900;
    letter-spacing: -0.04em;
    text-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
}

.hero h2 {
    font-size: clamp(34px, 5vw, 62px);
}

.hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: clamp(17px, 2vw, 24px);
    text-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-meta span,
.detail-tags span,
.card-tags span {
    display: inline-flex;
    align-items: center;
    padding: 6px 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
}

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

.button-primary,
.button-secondary,
.button-light {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 24px;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.button-primary,
.button-light {
    color: #ea580c;
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

.button-primary:hover,
.button-light:hover,
.button-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.22);
}

.button-secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

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

.hero-dot {
    width: 11px;
    height: 11px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.5);
    transition: width 0.25s ease, background 0.25s ease;
}

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

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

.hero + .container,
.page-hero + .container {
    padding-top: 56px;
}

.page-hero {
    color: #ffffff;
    background: linear-gradient(90deg, #ea580c, #dc2626);
    padding: 86px 0;
    text-align: center;
}

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

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(34px, 5vw, 56px);
    line-height: 1.08;
    font-weight: 900;
}

.page-hero p {
    margin: 0 auto;
    max-width: 860px;
    color: #ffedd5;
    font-size: 20px;
}

.stats-grid,
.category-grid,
.feature-grid {
    display: grid;
    gap: 24px;
}

.stats-grid {
    grid-template-columns: repeat(4, 1fr);
    margin-bottom: 72px;
}

.stat-card {
    padding: 28px;
    text-align: center;
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
}

.stat-card strong {
    display: block;
    color: #ea580c;
    font-size: 42px;
    line-height: 1;
}

.stat-card span {
    display: block;
    margin-top: 12px;
    color: #4b5563;
    font-weight: 700;
}

.section-block {
    margin-bottom: 76px;
}

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

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    color: #111827;
    font-size: 32px;
    line-height: 1.2;
    font-weight: 900;
}

.section-title span {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: linear-gradient(135deg, #fb923c, #ef4444);
    border-radius: 12px;
    font-size: 19px;
}

.section-link {
    color: #ea580c;
    font-weight: 900;
}

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

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

.movie-grid.search-grid {
    grid-template-columns: repeat(5, 1fr);
}

.movie-card {
    overflow: hidden;
    background: #ffffff;
    border-radius: 18px;
    box-shadow: 0 10px 26px rgba(17, 24, 39, 0.08);
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.movie-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 24px 50px rgba(17, 24, 39, 0.16);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #fed7aa, #fecaca);
}

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

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

.card-badge,
.rank-number {
    position: absolute;
    top: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 5px 9px;
    color: #ffffff;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 900;
}

.card-badge {
    left: 12px;
    background: #f97316;
}

.rank-number {
    right: 12px;
    min-width: 30px;
    background: #eab308;
}

.card-body {
    padding: 14px;
}

.card-body h2 {
    margin: 0 0 8px;
    display: -webkit-box;
    overflow: hidden;
    color: #111827;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 900;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color 0.25s ease;
}

.movie-card:hover .card-body h2 {
    color: #ea580c;
}

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

.card-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #6b7280;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    position: relative;
    min-height: 280px;
    overflow: hidden;
    color: #ffffff;
    background: #111827;
    border-radius: 24px;
    box-shadow: 0 18px 44px rgba(17, 24, 39, 0.14);
}

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.category-card:hover img {
    transform: scale(1.1);
}

.category-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0.22));
}

.category-content {
    position: absolute;
    inset: auto 0 0;
    z-index: 2;
    padding: 28px;
}

.category-content span {
    color: #fed7aa;
    font-weight: 900;
}

.category-content h2 {
    margin: 6px 0 8px;
    font-size: 28px;
    line-height: 1.15;
    font-weight: 900;
}

.category-content p {
    margin: 0;
    color: rgba(255, 255, 255, 0.86);
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(240px, 1.5fr) repeat(4, minmax(140px, 1fr));
    gap: 14px;
    margin: 0 0 30px;
    padding: 20px;
    background: #ffffff;
    border-radius: 22px;
    box-shadow: 0 14px 34px rgba(17, 24, 39, 0.08);
}

.filter-panel label {
    display: grid;
    gap: 7px;
    color: #6b7280;
    font-size: 13px;
    font-weight: 900;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 44px;
    padding: 0 13px;
    color: #111827;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: #fb923c;
    box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.16);
}

.empty-state {
    display: none;
    padding: 34px;
    text-align: center;
    color: #6b7280;
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 26px rgba(17, 24, 39, 0.08);
}

.empty-state.show {
    display: block;
}

.detail-hero {
    padding: 44px 0 54px;
    background: linear-gradient(90deg, #111827, #7f1d1d);
    color: #ffffff;
}

.detail-hero-inner {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 330px 1fr;
    gap: 34px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.34);
}

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

.breadcrumb {
    margin-bottom: 18px;
    color: #fed7aa;
    font-weight: 800;
}

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

.detail-info h1 {
    margin: 0 0 14px;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.06;
    font-weight: 900;
}

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

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

.detail-meta span {
    padding: 8px 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.14);
    border-radius: 999px;
    font-weight: 900;
}

.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.detail-page {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 56px 0 72px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(300px, 0.7fr);
    gap: 28px;
    align-items: start;
}

.content-card,
.player-panel,
.side-card {
    background: #ffffff;
    border-radius: 24px;
    box-shadow: 0 16px 40px rgba(17, 24, 39, 0.09);
    overflow: hidden;
}

.player-title {
    padding: 17px 22px;
    color: #ffffff;
    background: linear-gradient(90deg, #ea580c, #dc2626);
}

.player-title h2 {
    margin: 0;
    font-size: 21px;
    font-weight: 900;
}

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

.video-frame video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000000;
}

.play-layer {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.26));
    border: 0;
}

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

.play-icon {
    width: 78px;
    height: 78px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding-left: 5px;
    color: #ea580c;
    background: #ffffff;
    border-radius: 999px;
    font-size: 32px;
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.32);
    transition: transform 0.25s ease;
}

.play-layer:hover .play-icon {
    transform: scale(1.08);
}

.play-text {
    font-size: 18px;
    font-weight: 900;
}

.content-card {
    padding: 28px;
}

.content-card h2,
.side-card h2 {
    margin: 0 0 16px;
    color: #111827;
    font-size: 24px;
    font-weight: 900;
}

.content-card p {
    margin: 0 0 18px;
    color: #374151;
    font-size: 17px;
    line-height: 1.85;
}

.side-card {
    padding: 22px;
}

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

.related-item {
    display: grid;
    grid-template-columns: 74px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    background: #f9fafb;
    border-radius: 16px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.related-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px rgba(17, 24, 39, 0.1);
}

.related-item img {
    width: 74px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 12px;
}

.related-item strong {
    display: -webkit-box;
    overflow: hidden;
    color: #111827;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.related-item span {
    display: block;
    margin-top: 6px;
    color: #6b7280;
    font-size: 13px;
    font-weight: 800;
}

.site-footer {
    color: #d1d5db;
    background: linear-gradient(135deg, #111827, #1f2937, #111827);
}

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

.footer-brand {
    margin-bottom: 14px;
    color: #ffffff;
    font-size: 18px;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: #fb923c;
    font-size: 18px;
}

.site-footer p,
.site-footer li {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
}

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

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

.footer-bottom {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 22px 0;
    border-top: 1px solid rgba(156, 163, 175, 0.25);
    color: #9ca3af;
    font-size: 14px;
    text-align: center;
}

@media (max-width: 1100px) {
    .movie-grid,
    .movie-grid.search-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .movie-grid.wide,
    .category-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .filter-search {
        grid-column: 1 / -1;
    }

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

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

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

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

    .mobile-toggle {
        display: inline-flex;
    }

    .brand-text {
        max-width: 220px;
        font-size: 16px;
    }

    .hero {
        height: 640px;
    }

    .hero-content {
        justify-content: end;
        padding-bottom: 88px;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .button-primary,
    .button-secondary,
    .button-light {
        width: 100%;
    }

    .stats-grid,
    .category-grid,
    .feature-grid,
    .movie-grid,
    .movie-grid.wide,
    .movie-grid.search-grid {
        grid-template-columns: repeat(2, 1fr);
    }

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

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

    .detail-page {
        padding-top: 34px;
    }

    .content-card,
    .side-card {
        padding: 20px;
    }

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

@media (max-width: 520px) {
    .stats-grid,
    .movie-grid,
    .movie-grid.wide,
    .movie-grid.search-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .page-hero {
        padding: 64px 0;
    }

    .detail-hero-inner {
        gap: 24px;
    }
}
