:root {
    color-scheme: light;
    --page-bg: #f9fafb;
    --text-main: #111827;
    --text-muted: #6b7280;
    --line: #e5e7eb;
    --brand: #ea580c;
    --brand-dark: #c2410c;
    --brand-red: #dc2626;
    --brand-soft: #fff7ed;
    --card: #ffffff;
    --shadow: 0 12px 30px rgba(15, 23, 42, 0.10);
    --shadow-soft: 0 8px 24px rgba(15, 23, 42, 0.08);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--page-bg);
    color: var(--text-main);
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    color: #ffffff;
    background: linear-gradient(90deg, #ea580c, #dc2626);
    box-shadow: 0 10px 28px rgba(194, 65, 12, 0.28);
}

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

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

.site-logo {
    flex: 0 0 auto;
    font-size: 25px;
    white-space: nowrap;
}

.logo-mark {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.32);
}

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

.desktop-nav a,
.mobile-nav a {
    font-weight: 650;
    color: rgba(255, 255, 255, 0.92);
    transition: color 0.2s ease, transform 0.2s ease;
}

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

.top-search,
.mobile-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.top-search input,
.mobile-search input {
    width: 230px;
    border: 0;
    outline: 0;
    border-radius: 999px;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.92);
    color: #111827;
    transition: box-shadow 0.2s ease, background 0.2s ease;
}

.top-search input:focus,
.mobile-search input:focus {
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(254, 240, 138, 0.85);
}

.top-search button,
.mobile-search button,
.primary-button,
.secondary-button,
.filter-grid button {
    border: 0;
    cursor: pointer;
    border-radius: 999px;
    font-weight: 750;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.top-search button,
.mobile-search button,
.primary-button {
    color: #ffffff;
    background: #c2410c;
    padding: 10px 18px;
    box-shadow: 0 8px 18px rgba(124, 45, 18, 0.22);
}

.primary-button:hover,
.top-search button:hover,
.mobile-search button:hover {
    background: #9a3412;
    transform: translateY(-1px);
}

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

.secondary-button:hover {
    background: rgba(255, 255, 255, 0.24);
    transform: translateY(-1px);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: #ffffff;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    padding: 0 16px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.18);
}

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

.mobile-search input {
    width: 100%;
}

.hero-carousel {
    position: relative;
    height: clamp(430px, 62vw, 640px);
    overflow: hidden;
    background: #111827;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.65s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.03);
    transition: transform 5.5s ease;
}

.hero-slide.is-active img {
    transform: scale(1.0);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.48) 42%, rgba(0, 0, 0, 0.16));
}

.hero-content {
    position: absolute;
    left: 50%;
    bottom: 62px;
    transform: translateX(-50%);
    color: #ffffff;
}

.hero-copy {
    width: min(720px, 100%);
}

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

.hero-tags span:first-child {
    background: #f97316;
    color: #ffffff;
    padding: 5px 13px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 750;
}

.hero-tags span:not(:first-child) {
    color: rgba(255, 255, 255, 0.86);
    font-size: 14px;
}

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

.hero-copy p {
    width: min(660px, 100%);
    margin: 0 0 26px;
    font-size: clamp(16px, 2vw, 19px);
    color: rgba(255, 255, 255, 0.9);
}

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

.hero-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 4;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    cursor: pointer;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.34);
    backdrop-filter: blur(10px);
    font-size: 25px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.56);
    transform: translateY(-50%) scale(1.04);
}

.hero-arrow-prev {
    left: 20px;
}

.hero-arrow-next {
    right: 20px;
}

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

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

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

.main-sections {
    padding: 48px 0 64px;
}

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

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 11px;
}

.section-title span {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 18px;
}

.section-title h2,
.section-title h1 {
    margin: 0;
    font-size: clamp(24px, 3vw, 34px);
    line-height: 1.2;
}

.section-link {
    color: var(--brand);
    font-weight: 750;
}

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

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

.movie-card {
    min-width: 0;
}

.movie-card-link {
    display: block;
    height: 100%;
    background: var(--card);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.movie-cover {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #111827;
}

.movie-card-small .movie-cover {
    aspect-ratio: 4 / 3;
}

.movie-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease, opacity 0.2s ease;
}

.movie-card-link:hover .movie-cover img {
    transform: scale(1.08);
    opacity: 0.82;
}

.movie-cover-play {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #ffffff;
    font-size: 42px;
    opacity: 0;
    transform: scale(0.82);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card-link:hover .movie-cover-play {
    opacity: 1;
    transform: scale(1);
}

.movie-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    max-width: calc(100% - 20px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 8px;
    color: #ffffff;
    background: #f97316;
    font-size: 12px;
    font-weight: 750;
}

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

.movie-card-body h3 {
    margin: 0 0 8px;
    min-height: 1.5em;
    color: #1f2937;
    font-size: 17px;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-card-small .movie-card-body h3 {
    font-size: 15px;
}

.movie-card-body p {
    margin: 0 0 13px;
    color: #4b5563;
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

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

.category-card {
    display: block;
    min-height: 132px;
    padding: 24px;
    border-radius: 20px;
    color: #ffffff;
    background: linear-gradient(135deg, #fb923c, #dc2626);
    box-shadow: 0 16px 34px rgba(234, 88, 12, 0.20);
    transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.category-card:hover {
    transform: translateY(-5px) scale(1.01);
    box-shadow: 0 20px 42px rgba(220, 38, 38, 0.28);
    filter: saturate(1.08);
}

.category-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 22px;
}

.category-card span {
    color: rgba(255, 255, 255, 0.84);
    font-size: 14px;
}

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

.latest-row,
.rank-item {
    display: grid;
    grid-template-columns: 52px 122px 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 14px;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: var(--shadow-soft);
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.latest-row:hover,
.rank-item:hover {
    background: #fff7ed;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.latest-number,
.rank-number {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: var(--brand);
    background: #ffedd5;
    font-weight: 850;
}

.latest-row img,
.rank-item img {
    width: 122px;
    height: 76px;
    object-fit: cover;
    border-radius: 12px;
}

.latest-copy,
.rank-copy {
    min-width: 0;
}

.latest-copy strong,
.rank-copy strong {
    display: block;
    margin-bottom: 4px;
    font-size: 17px;
    color: #1f2937;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.latest-copy em,
.rank-copy em {
    display: block;
    color: #6b7280;
    font-size: 14px;
    font-style: normal;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.rank-year {
    color: #6b7280;
    font-weight: 700;
}

.page-hero {
    padding: 64px 0;
    color: #ffffff;
    background: radial-gradient(circle at 18% 0%, rgba(251, 191, 36, 0.32), transparent 34%), linear-gradient(90deg, #ea580c, #dc2626);
}

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

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

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 26px 0;
    color: #6b7280;
    font-size: 14px;
}

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

.filter-panel {
    margin: 0 0 28px;
    padding: 20px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.filter-panel-title {
    margin-bottom: 14px;
    font-weight: 850;
    font-size: 18px;
}

.filter-grid {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px auto;
    gap: 14px;
    align-items: end;
}

.filter-grid label {
    display: grid;
    gap: 7px;
    color: #4b5563;
    font-size: 14px;
    font-weight: 700;
}

.filter-grid input,
.filter-grid select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 11px 12px;
    outline: 0;
    background: #ffffff;
    color: #111827;
}

.filter-grid input:focus,
.filter-grid select:focus {
    border-color: #fb923c;
    box-shadow: 0 0 0 3px #fed7aa;
}

.filter-grid button {
    padding: 12px 18px;
    color: #ffffff;
    background: #ea580c;
}

.filter-empty {
    margin: 18px 0 0;
    color: #6b7280;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 0.85fr);
    gap: 28px;
    margin: 0 0 58px;
}

.player-panel,
.detail-panel,
.side-panel {
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.player-panel {
    padding: 18px;
    margin-bottom: 22px;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: #0f172a;
    aspect-ratio: 16 / 9;
}

.video-player {
    width: 100%;
    height: 100%;
    display: block;
    background: #0f172a;
}

.player-cover {
    position: absolute;
    inset: 0;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: #0f172a;
}

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

.player-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.16));
}

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

.big-play {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    transform: translate(-50%, -50%);
    width: 82px;
    height: 82px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(234, 88, 12, 0.92);
    box-shadow: 0 18px 35px rgba(0, 0, 0, 0.35);
    font-size: 34px;
}

.detail-panel {
    padding: 26px;
}

.detail-panel h1 {
    margin: 0 0 16px;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.18;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    color: #4b5563;
}

.detail-meta span {
    padding: 7px 11px;
    border-radius: 999px;
    background: #f3f4f6;
    font-size: 14px;
    font-weight: 700;
}

.detail-lead {
    margin: 0 0 24px;
    color: #1f2937;
    font-size: 18px;
    font-weight: 700;
}

.detail-text-block {
    border-top: 1px solid var(--line);
    padding-top: 22px;
    margin-top: 22px;
}

.detail-text-block h2 {
    margin: 0 0 10px;
    font-size: 23px;
}

.detail-text-block p {
    margin: 0;
    color: #374151;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 18px;
}

.tag-list span {
    padding: 6px 10px;
    border-radius: 999px;
    color: #9a3412;
    background: #ffedd5;
    font-size: 13px;
    font-weight: 750;
}

.side-panel {
    padding: 18px;
    margin-bottom: 22px;
}

.side-panel img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 16px;
}

.side-panel h2 {
    margin: 0 0 12px;
    font-size: 22px;
}

.info-list {
    display: grid;
    gap: 9px;
    color: #4b5563;
    font-size: 14px;
}

.info-list div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid #f3f4f6;
    padding-bottom: 8px;
}

.info-list strong {
    color: #111827;
}

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

.compact-card {
    display: grid;
    grid-template-columns: 88px 1fr;
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.compact-card img {
    width: 88px;
    height: 60px;
    object-fit: cover;
    border-radius: 10px;
}

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

.compact-card span {
    display: block;
    color: #6b7280;
    font-size: 12px;
}

.search-shell {
    min-height: 280px;
}

.search-status {
    margin: 0 0 20px;
    color: #4b5563;
    font-weight: 700;
}

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

.footer-grid {
    display: flex;
    justify-content: space-between;
    gap: 30px;
    padding: 34px 0;
}

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

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

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

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

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

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

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

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

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

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

    .nav-bar {
        justify-content: space-between;
    }

    .menu-toggle {
        display: block;
    }

    .hero-content {
        bottom: 54px;
    }

    .hero-arrow {
        display: none;
    }

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

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

    .latest-row,
    .rank-item {
        grid-template-columns: 42px 92px 1fr;
    }

    .rank-year {
        display: none;
    }

    .latest-row img,
    .rank-item img {
        width: 92px;
        height: 62px;
    }

    .footer-grid {
        display: grid;
    }
}

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

    .site-logo {
        font-size: 20px;
    }

    .hero-carousel {
        height: 500px;
    }

    .hero-copy p {
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .movie-grid,
    .movie-grid.small,
    .category-grid,
    .related-grid {
        grid-template-columns: 1fr 1fr;
        gap: 14px;
    }

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

    .movie-card-body h3 {
        font-size: 15px;
    }

    .movie-card-body p {
        font-size: 13px;
    }

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

    .latest-row,
    .rank-item {
        grid-template-columns: 36px 1fr;
    }

    .latest-row img,
    .rank-item img {
        display: none;
    }

    .compact-card {
        grid-template-columns: 72px 1fr;
    }

    .compact-card img {
        width: 72px;
        height: 52px;
    }

    .big-play {
        width: 64px;
        height: 64px;
        font-size: 28px;
    }
}
