:root {
    --orange: #f97316;
    --orange-dark: #ea580c;
    --pink: #ec4899;
    --purple: #a855f7;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --soft: #fff7ed;
    --white: #ffffff;
    --shadow: 0 20px 50px rgba(17, 24, 39, 0.12);
    --radius: 24px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--ink);
    background: #ffffff;
}

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

img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, #ffedd5, #fce7f3);
}

button,
input {
    font: inherit;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(14px);
    box-shadow: 0 8px 24px rgba(17, 24, 39, 0.08);
}

.header-inner {
    max-width: 1180px;
    height: 76px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

.brand-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: white;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    box-shadow: 0 10px 26px rgba(236, 72, 153, 0.28);
    transition: transform 0.25s ease;
}

.brand:hover .brand-icon {
    transform: scale(1.08) rotate(3deg);
}

.brand-text {
    font-size: 24px;
    background: linear-gradient(90deg, var(--orange), var(--pink));
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

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

.nav-link,
.mobile-nav-link {
    color: #374151;
    font-weight: 650;
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-link:hover,
.nav-link.active,
.mobile-nav-link:hover,
.mobile-nav-link.active {
    color: var(--orange);
}

.mobile-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: #f3f4f6;
    cursor: pointer;
}

.mobile-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: #374151;
    border-radius: 10px;
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.98);
    padding: 12px 24px 18px;
}

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

.mobile-nav-link {
    padding: 12px 14px;
    border-radius: 12px;
}

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

.hero {
    position: relative;
    min-height: 92vh;
    overflow: hidden;
    background: linear-gradient(135deg, var(--orange), var(--pink), var(--purple));
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.18;
    background-image: radial-gradient(circle at 20% 20%, rgba(255,255,255,0.9) 0 2px, transparent 3px), radial-gradient(circle at 80% 40%, rgba(255,255,255,0.8) 0 3px, transparent 4px);
    background-size: 72px 72px, 110px 110px;
}

.hero::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 140px;
    background: linear-gradient(to top, white, transparent);
    pointer-events: none;
}

.hero-slider {
    position: relative;
    min-height: 92vh;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.7s ease, transform 0.7s ease;
    background-size: cover;
    background-position: center right;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-copy {
    max-width: 1180px;
    width: 100%;
    margin: 0 auto;
    padding: 130px 24px 170px;
    color: white;
}

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--orange);
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero .eyebrow {
    color: #ffedd5;
}

.hero h1 {
    max-width: 780px;
    margin: 16px 0 20px;
    font-size: clamp(42px, 8vw, 78px);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 680px;
    margin: 0 0 28px;
    font-size: clamp(18px, 2.6vw, 26px);
    line-height: 1.65;
    color: rgba(255, 255, 255, 0.92);
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hero-tags span,
.tag-row span {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.hero-tags span {
    color: white;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(8px);
}

.tag-row span {
    color: var(--orange-dark);
    background: #fff7ed;
}

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

.primary-button,
.ghost-button,
.text-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    min-height: 48px;
    padding: 0 26px;
    color: white;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    box-shadow: 0 16px 34px rgba(249, 115, 22, 0.3);
}

.hero .primary-button {
    color: var(--orange);
    background: white;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.2);
}

.ghost-button {
    min-height: 48px;
    padding: 0 26px;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.42);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

.ghost-button.light {
    color: var(--orange);
    border-color: #fed7aa;
    background: #fff7ed;
}

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

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

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

.hero-dot.active {
    width: 56px;
    background: white;
}

.hero-rail {
    position: absolute;
    right: max(24px, calc((100vw - 1180px) / 2));
    bottom: 150px;
    z-index: 4;
    display: grid;
    grid-template-columns: repeat(5, 94px);
    gap: 14px;
}

.hero-mini-card {
    height: 132px;
    overflow: hidden;
    border-radius: 18px;
    position: relative;
    box-shadow: 0 18px 40px rgba(17, 24, 39, 0.28);
    transform: translateY(0);
    transition: transform 0.25s ease;
}

.hero-mini-card:hover {
    transform: translateY(-6px);
}

.hero-mini-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.65), transparent 60%);
}

.hero-mini-card span {
    position: absolute;
    left: 8px;
    right: 8px;
    bottom: 8px;
    z-index: 2;
    color: white;
    font-size: 12px;
    font-weight: 800;
    line-height: 1.25;
}

.section-block {
    max-width: 1180px;
    margin: 0 auto;
    padding: 80px 24px;
}

.section-heading {
    margin-bottom: 34px;
}

.section-heading.centered {
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

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

.section-heading h2,
.page-hero h1,
.detail-info h1 {
    margin: 10px 0 0;
    color: var(--ink);
    font-size: clamp(30px, 4.4vw, 52px);
    letter-spacing: -0.04em;
    line-height: 1.1;
}

.section-heading p,
.page-hero p {
    color: var(--muted);
    font-size: 18px;
    line-height: 1.7;
}

.text-link {
    color: var(--orange);
    font-weight: 800;
}

.filter-panel {
    border-radius: var(--radius);
    padding: 22px;
    background: white;
    box-shadow: var(--shadow);
}

.search-box {
    display: flex;
    gap: 12px;
}

.search-box input {
    flex: 1;
    min-height: 52px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 0 20px;
    outline: none;
    transition: border 0.2s ease, box-shadow 0.2s ease;
}

.search-box input:focus {
    border-color: var(--orange);
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

.search-box button {
    border: 0;
    border-radius: 999px;
    padding: 0 20px;
    color: white;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    cursor: pointer;
}

.filter-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.filter-links a {
    display: inline-flex;
    padding: 10px 14px;
    border-radius: 999px;
    color: #374151;
    background: #f9fafb;
    border: 1px solid #f3f4f6;
    font-weight: 700;
}

.filter-links a:hover {
    color: var(--orange);
    background: #fff7ed;
    border-color: #fed7aa;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: white;
    box-shadow: 0 14px 32px rgba(17, 24, 39, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    height: 280px;
    overflow: hidden;
    background: linear-gradient(135deg, #ffedd5, #fce7f3);
}

.movie-card.compact-card .poster-link {
    height: 220px;
}

.poster-link img {
    transition: transform 0.45s ease;
}

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

.year-badge,
.play-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
}

.year-badge {
    top: 14px;
    right: 14px;
    padding: 7px 12px;
    color: var(--orange-dark);
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
}

.play-badge {
    left: 14px;
    bottom: 14px;
    padding: 8px 14px;
    color: white;
    background: linear-gradient(135deg, var(--orange), var(--pink));
    box-shadow: 0 10px 24px rgba(249, 115, 22, 0.28);
}

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

.movie-card-title {
    margin: 0 0 10px;
    font-size: 22px;
    line-height: 1.25;
}

.movie-card-title a:hover {
    color: var(--orange);
}

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

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: #4b5563;
    font-size: 14px;
    font-weight: 700;
}

.card-meta span:not(:last-child)::after {
    content: "·";
    margin-left: 8px;
    color: #d1d5db;
}

.tinted-section,
.intro-search {
    max-width: none;
    padding-left: max(24px, calc((100vw - 1180px) / 2));
    padding-right: max(24px, calc((100vw - 1180px) / 2));
    background: linear-gradient(135deg, #fff7ed, #fdf2f8, #faf5ff);
}

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

.category-card {
    display: block;
    border-radius: var(--radius);
    padding: 18px;
    background: white;
    box-shadow: 0 14px 32px rgba(17, 24, 39, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-images {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    height: 112px;
    margin-bottom: 16px;
}

.large-category .category-images {
    grid-template-columns: repeat(4, 1fr);
    height: 150px;
}

.category-images img {
    border-radius: 14px;
}

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

.category-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.6;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 40px;
    align-items: start;
}

.ranking-panel {
    position: sticky;
    top: 100px;
    border-radius: var(--radius);
    padding: 24px;
    background: linear-gradient(135deg, #fff7ed, #fdf2f8);
    box-shadow: var(--shadow);
}

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

.ranking-list.two-column {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ranking-row {
    min-height: 72px;
    display: grid;
    grid-template-columns: 42px 52px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(255, 255, 255, 0.9);
    transition: transform 0.2s ease, background 0.2s ease;
}

.ranking-row:hover {
    transform: translateX(4px);
    background: white;
}

.rank-num {
    color: var(--orange);
    font-weight: 900;
    font-size: 18px;
}

.ranking-row img {
    width: 52px;
    height: 52px;
    border-radius: 14px;
}

.rank-title {
    font-weight: 800;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.rank-meta {
    grid-column: 3;
    color: var(--muted);
    font-size: 13px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.wide-button {
    width: 100%;
    margin-top: 18px;
}

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

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: white;
    background: linear-gradient(135deg, var(--orange), var(--pink), var(--purple));
}

.small-hero {
    min-height: 360px;
    padding: 86px max(24px, calc((100vw - 1180px) / 2));
}

.page-hero h1,
.page-hero p,
.page-hero .section-kicker {
    color: white;
}

.page-hero p {
    max-width: 760px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.86);
    font-weight: 700;
}

.breadcrumb a:hover {
    color: white;
}

.detail-hero {
    max-width: 1180px;
    margin: 44px auto 0;
    border-radius: 0 0 36px 36px;
    padding: 64px 24px;
    display: grid;
    grid-template-columns: 330px minmax(0, 1fr);
    gap: 42px;
    color: white;
}

.detail-poster {
    overflow: hidden;
    border-radius: 28px;
    min-height: 460px;
    box-shadow: 0 30px 70px rgba(17, 24, 39, 0.32);
}

.detail-info h1 {
    color: white;
    font-size: clamp(38px, 5vw, 68px);
}

.detail-subtitle {
    max-width: 760px;
    color: rgba(255, 255, 255, 0.92);
    font-size: 20px;
    line-height: 1.75;
}

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

.meta-list li {
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(8px);
}

.meta-list strong {
    display: block;
    margin-bottom: 6px;
    color: #ffedd5;
}

.player-section {
    max-width: 1180px;
    margin: 0 auto;
    padding: 80px 24px 40px;
}

.movie-player {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #111827;
    box-shadow: 0 28px 70px rgba(17, 24, 39, 0.25);
    aspect-ratio: 16 / 9;
}

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

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 14px;
    border: 0;
    color: white;
    background: linear-gradient(135deg, rgba(17, 24, 39, 0.72), rgba(236, 72, 153, 0.38));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.movie-player.is-playing .player-cover,
.movie-player.is-ready .player-cover.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.play-circle {
    width: 82px;
    height: 82px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: var(--orange);
    background: white;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.3);
    font-size: 34px;
}

.player-cover strong {
    font-size: clamp(22px, 4vw, 38px);
}

.player-cover em {
    font-style: normal;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 700;
}

.detail-content {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 24px;
}

.content-card {
    border-radius: var(--radius);
    padding: 30px;
    background: white;
    box-shadow: 0 14px 32px rgba(17, 24, 39, 0.08);
}

.content-card:first-child {
    grid-row: span 2;
}

.content-card h2 {
    margin: 0 0 14px;
    font-size: 28px;
}

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

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

.site-footer {
    margin-top: 70px;
    padding: 64px 24px 24px;
    background: linear-gradient(135deg, #fff7ed, #fdf2f8, #faf5ff);
}

.footer-grid {
    max-width: 1180px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 38px;
}

.footer-brand p,
.site-footer a,
.footer-bottom {
    color: #6b7280;
}

.footer-logo {
    margin-bottom: 16px;
}

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

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

.site-footer a:hover {
    color: var(--orange);
}

.footer-bottom {
    max-width: 1180px;
    margin: 38px auto 0;
    padding-top: 22px;
    border-top: 1px solid rgba(229, 231, 235, 0.9);
    text-align: center;
}

[data-movie-card].is-hidden {
    display: none;
}

@media (max-width: 1080px) {
    .hero-rail {
        display: none;
    }

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

    .split-section,
    .detail-hero,
    .detail-content {
        grid-template-columns: 1fr;
    }

    .ranking-panel {
        position: static;
    }
}

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

    .mobile-toggle {
        display: block;
    }

    .header-inner {
        height: 66px;
        padding: 0 16px;
    }

    .brand-text {
        font-size: 20px;
    }

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

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

    .hero-copy {
        padding: 112px 18px 130px;
    }

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

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

    .hero-controls {
        bottom: 86px;
    }

    .section-block,
    .player-section {
        padding: 54px 18px;
    }

    .section-heading.between {
        display: block;
    }

    .movie-grid,
    .compact-grid,
    .category-grid,
    .footer-grid,
    .ranking-list.two-column,
    .meta-list {
        grid-template-columns: 1fr;
    }

    .poster-link,
    .movie-card.compact-card .poster-link {
        height: 260px;
    }

    .search-box {
        display: grid;
    }

    .small-hero {
        min-height: 330px;
        padding: 64px 18px;
    }

    .detail-hero {
        margin-top: 24px;
        padding: 34px 18px;
        border-radius: 0 0 26px 26px;
    }

    .detail-poster {
        min-height: 360px;
    }

    .player-cover strong {
        padding: 0 20px;
        text-align: center;
    }
}
