:root {
    --page-bg: #f7f8fb;
    --card-bg: #ffffff;
    --text-main: #111827;
    --text-soft: #4b5563;
    --text-muted: #6b7280;
    --line: #e5e7eb;
    --red: #dc2626;
    --red-dark: #b91c1c;
    --pink: #db2777;
    --orange: #f97316;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --soft-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text-main);
    background: linear-gradient(135deg, #f8fafc 0%, #eef2f7 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.65;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    backdrop-filter: blur(16px);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.header-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 68px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
}

.brand-mark {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    color: #fff;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--red), var(--pink));
    box-shadow: 0 10px 25px rgba(220, 38, 38, 0.25);
}

.brand-text {
    display: grid;
    line-height: 1.15;
}

.brand-text strong {
    font-size: 20px;
    letter-spacing: -0.02em;
}

.brand-text small {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 600;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    color: #374151;
    font-weight: 700;
}

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

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

.menu-button {
    display: none;
    width: 42px;
    height: 42px;
    padding: 9px;
    border: 0;
    border-radius: 12px;
    background: #f3f4f6;
}

.menu-button span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: #111827;
    border-radius: 99px;
}

.mobile-nav {
    display: none;
    padding: 0 16px 14px;
    border-top: 1px solid var(--line);
}

.mobile-nav a {
    display: block;
    padding: 12px 10px;
    border-radius: 12px;
    color: #374151;
    font-weight: 700;
}

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

.hero-slider {
    position: relative;
    min-height: 72vh;
    overflow: hidden;
    background: #111827;
}

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

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

.hero-slide > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(220, 38, 38, 0.42), transparent 32%),
        linear-gradient(90deg, rgba(0, 0, 0, 0.86) 0%, rgba(0, 0, 0, 0.54) 46%, rgba(0, 0, 0, 0.12) 100%),
        linear-gradient(0deg, rgba(0, 0, 0, 0.82) 0%, transparent 48%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    min-height: 72vh;
    align-items: flex-end;
    padding: 0 0 82px;
}

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

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

.hero-badges span {
    padding: 6px 12px;
    border-radius: 999px;
    color: #fff;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
    font-size: 14px;
    font-weight: 800;
}

.hero-badges span:first-child {
    background: linear-gradient(135deg, var(--red), var(--pink));
}

.hero-copy h1 {
    margin: 18px 0 16px;
    font-size: clamp(40px, 7vw, 78px);
    line-height: 1.04;
    letter-spacing: -0.06em;
    text-shadow: 0 14px 38px rgba(0, 0, 0, 0.42);
}

.hero-copy p {
    max-width: 660px;
    margin: 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
}

.hero-actions,
.detail-actions,
.center-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-top: 26px;
}

.primary-button,
.secondary-button,
.ghost-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: #fff;
    background: linear-gradient(135deg, var(--red), var(--pink));
    box-shadow: 0 16px 32px rgba(220, 38, 38, 0.26);
}

.primary-button:hover,
.secondary-button:hover,
.ghost-button:hover {
    transform: translateY(-2px);
}

.ghost-button {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.36);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
}

.ghost-button.light {
    color: #fff;
}

.secondary-button {
    color: var(--red);
    border: 1px solid #fecaca;
    background: #fff;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 4;
    display: grid;
    width: 52px;
    height: 52px;
    place-items: center;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
    cursor: pointer;
    font-size: 38px;
    transform: translateY(-50%);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

.hero-dots {
    position: absolute;
    right: max(22px, calc((100% - 1180px) / 2));
    bottom: 34px;
    z-index: 5;
    display: flex;
    gap: 8px;
}

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

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

.section {
    padding: 64px 0;
}

.intro-section {
    padding-bottom: 28px;
}

.section-heading {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 26px;
}

.section-heading > span {
    width: 5px;
    height: 34px;
    margin-top: 8px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--red), var(--orange));
}

.section-heading h2,
.page-hero h1,
.detail-copy h1 {
    margin: 0;
    color: var(--text-main);
    font-size: clamp(28px, 4vw, 46px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.section-heading p,
.page-hero p {
    margin: 8px 0 0;
    color: var(--text-muted);
}

.wide-heading {
    justify-content: space-between;
}

.search-panel {
    padding: 18px;
    border: 1px solid rgba(229, 231, 235, 0.9);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.78);
    box-shadow: var(--soft-shadow);
}

.search-box input {
    width: 100%;
    height: 48px;
    padding: 0 18px;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    outline: none;
    background: #fff;
}

.search-box input:focus {
    border-color: #fca5a5;
    box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.15);
}

.filter-row {
    margin-top: 14px;
}

.filter-button {
    padding: 8px 14px;
    color: #374151;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    background: #fff;
    cursor: pointer;
}

.filter-button.active,
.filter-button:hover {
    color: #fff;
    border-color: var(--red);
    background: linear-gradient(135deg, var(--red), var(--pink));
}

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

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

.category-card {
    display: grid;
    gap: 16px;
    min-height: 260px;
    padding: 18px;
    border: 1px solid rgba(229, 231, 235, 0.86);
    border-radius: 26px;
    background: #fff;
    box-shadow: var(--soft-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-posters {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    min-height: 118px;
}

.category-posters img {
    width: 100%;
    height: 118px;
    object-fit: cover;
    border-radius: 16px;
}

.category-card h3 {
    margin: 0 0 8px;
    font-size: 22px;
}

.category-card p {
    margin: 0;
    color: var(--text-soft);
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(229, 231, 235, 0.85);
    border-radius: 22px;
    background: #fff;
    box-shadow: var(--soft-shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.card-poster {
    position: relative;
    display: block;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #e5e7eb;
}

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

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

.card-poster::after {
    position: absolute;
    inset: 0;
    content: "";
    opacity: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.78), transparent 70%);
    transition: opacity 0.25s ease;
}

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

.card-year {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    padding: 4px 8px;
    color: #fff;
    border-radius: 8px;
    background: rgba(220, 38, 38, 0.86);
    font-size: 12px;
    font-weight: 800;
}

.card-play {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 2;
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    color: var(--text-main);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.8);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.movie-card:hover .card-play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.card-body {
    padding: 16px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 700;
}

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

.compact-card .card-body h3 {
    font-size: 16px;
}

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

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

.card-tags span,
.detail-tags span,
.rank-meta span {
    padding: 3px 8px;
    color: #7f1d1d;
    border-radius: 999px;
    background: #fee2e2;
    font-size: 12px;
    font-weight: 700;
}

.feature-band {
    background: linear-gradient(135deg, #fff7ed, #fff1f2);
}

.feature-shell {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    align-items: center;
    gap: 34px;
}

.feature-copy span,
.eyebrow {
    color: var(--red);
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.08em;
}

.feature-copy h2 {
    margin: 12px 0 14px;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.feature-copy p {
    color: var(--text-soft);
}

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

.mini-link {
    display: grid;
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--soft-shadow);
}

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

.mini-link span {
    padding: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 800;
}

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

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

.rank-row {
    display: grid;
    grid-template-columns: 92px 52px 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 12px;
}

.rank-cover {
    overflow: hidden;
    border-radius: 16px;
}

.rank-cover img {
    width: 92px;
    height: 70px;
    object-fit: cover;
}

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

.rank-info h3 {
    margin: 0 0 6px;
    font-size: 18px;
}

.rank-info p {
    margin: 0 0 8px;
    color: var(--text-soft);
    font-size: 14px;
}

.heat-badge {
    padding: 8px 12px;
    color: #9a3412;
    border-radius: 12px;
    background: #ffedd5;
    font-weight: 900;
}

.page-hero {
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: 28px;
    padding: 72px 0 34px;
}

.page-hero h1 {
    margin-top: 8px;
}

.hero-mini-posters {
    display: grid;
    grid-template-columns: repeat(3, 86px);
    gap: 10px;
}

.hero-mini-posters img {
    width: 86px;
    height: 86px;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: var(--soft-shadow);
}

.detail-hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background: #111827;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    opacity: 0.36;
    filter: blur(5px);
    transform: scale(1.03);
}

.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.detail-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 10%, rgba(220, 38, 38, 0.48), transparent 30%),
        linear-gradient(90deg, rgba(17, 24, 39, 0.96), rgba(17, 24, 39, 0.76));
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 32px;
    align-items: end;
    padding: 66px 0;
}

.detail-poster {
    overflow: hidden;
    border: 6px solid rgba(255, 255, 255, 0.16);
    border-radius: 26px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.42);
}

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

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 14px;
    font-weight: 700;
}

.breadcrumbs a:hover {
    color: #fff;
}

.detail-copy h1 {
    margin: 16px 0;
    color: #fff;
    font-size: clamp(38px, 6vw, 68px);
}

.detail-one-line {
    max-width: 830px;
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.84);
    font-size: 18px;
}

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

.player-card,
.content-card,
.side-card {
    padding: 22px;
    border: 1px solid rgba(229, 231, 235, 0.85);
    border-radius: 24px;
    background: #fff;
    box-shadow: var(--soft-shadow);
}

.player-card h2,
.content-card h2,
.side-card h2 {
    margin: 0 0 16px;
    font-size: 24px;
}

.video-shell {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    background: #000;
    aspect-ratio: 16 / 9;
}

.movie-player {
    width: 100%;
    height: 100%;
    background: #000;
}

.play-toggle {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    color: #fff;
    border: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.18));
    cursor: pointer;
}

.play-toggle span {
    display: grid;
    width: 82px;
    height: 82px;
    place-items: center;
    padding-left: 6px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--red), var(--pink));
    box-shadow: 0 18px 36px rgba(0, 0, 0, 0.32);
    font-size: 34px;
}

.video-shell.is-playing .play-toggle {
    display: none;
}

.detail-main {
    display: grid;
    gap: 18px;
}

.content-card p {
    margin: 0;
    color: var(--text-soft);
    font-size: 17px;
}

.review-card {
    background: linear-gradient(135deg, #fff7ed, #fff);
}

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

.info-list div {
    padding: 14px;
    border-radius: 16px;
    background: #f9fafb;
}

.info-list dt {
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 800;
}

.info-list dd {
    margin: 4px 0 0;
    font-weight: 900;
}

.detail-side {
    position: sticky;
    top: 90px;
    display: grid;
    gap: 18px;
}

.side-links {
    display: grid;
    gap: 12px;
}

.side-links .mini-link,
.topic-list .mini-link {
    grid-template-columns: 76px 1fr;
    align-items: center;
}

.side-links .mini-link img,
.topic-list .mini-link img {
    width: 76px;
    height: 58px;
}

.topic-entry {
    display: block;
    padding: 12px 14px;
    margin-top: 10px;
    border-radius: 14px;
    background: #f9fafb;
    font-weight: 800;
}

.topic-entry:hover {
    color: var(--red);
    background: #fef2f2;
}

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

.topic-card {
    padding: 28px;
    border-radius: 26px;
    box-shadow: var(--soft-shadow);
}

.topic-card.warm {
    background: linear-gradient(135deg, #fff7ed, #ffe4e6);
}

.topic-card.cool {
    background: linear-gradient(135deg, #eff6ff, #ecfeff);
}

.topic-card h2 {
    margin: 0 0 10px;
    font-size: 28px;
}

.topic-card p {
    margin: 0 0 18px;
    color: var(--text-soft);
}

.topic-list {
    display: grid;
    gap: 12px;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.7fr 1fr;
    gap: 34px;
    padding: 44px 0;
}

.footer-brand .brand-text strong {
    color: #fff;
}

.footer-grid p {
    max-width: 420px;
    color: #9ca3af;
}

.footer-grid h2 {
    margin: 0 0 12px;
    color: #fff;
    font-size: 18px;
}

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

.footer-links a {
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.footer-links a:hover {
    background: rgba(255, 255, 255, 0.16);
}

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

.is-hidden {
    display: none !important;
}

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

    .menu-button {
        display: block;
    }

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

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

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

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

    .detail-side {
        position: static;
    }
}

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

    .brand-text strong {
        font-size: 17px;
    }

    .hero-slider,
    .hero-content {
        min-height: 76vh;
    }

    .hero-content {
        padding-bottom: 76px;
    }

    .hero-copy h1 {
        font-size: 42px;
    }

    .hero-arrow {
        display: none;
    }

    .hero-dots {
        left: 16px;
        right: auto;
    }

    .section {
        padding: 42px 0;
    }

    .category-grid,
    .large-category-grid,
    .movie-grid,
    .movie-grid-home,
    .all-movie-grid,
    .topic-columns,
    .feature-shell,
    .footer-grid {
        grid-template-columns: 1fr;
    }

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

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

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

    .hero-mini-posters img {
        width: 100%;
    }

    .detail-poster {
        width: min(260px, 72vw);
    }

    .rank-row {
        grid-template-columns: 76px 44px 1fr;
    }

    .rank-cover img {
        width: 76px;
        height: 58px;
    }

    .heat-badge {
        grid-column: 2 / 4;
        width: fit-content;
    }

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