:root {
    --bg: #fafaf9;
    --panel: #ffffff;
    --panel-soft: #f8fafc;
    --text: #0f172a;
    --muted: #64748b;
    --line: #e7e5e4;
    --accent: #d97706;
    --accent-strong: #b45309;
    --accent-soft: #fef3c7;
    --blue: #334155;
    --blue-deep: #0f172a;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
    --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(--text);
    background: var(--bg);
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(231, 229, 228, 0.9);
}

.header-inner {
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 22px;
    color: var(--blue-deep);
}

.brand-mark {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--accent));
    box-shadow: 0 12px 24px rgba(217, 119, 6, 0.25);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}

.nav-link {
    font-weight: 700;
    color: var(--blue);
    transition: color 0.25s ease;
}

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

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: var(--accent-soft);
    padding: 10px;
}

.menu-toggle span {
    display: block;
    height: 2px;
    margin: 5px 0;
    background: var(--accent-strong);
    border-radius: 8px;
}

.hero {
    position: relative;
    min-height: 70vh;
    overflow: hidden;
    background: var(--blue-deep);
}

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

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s ease;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
    align-items: center;
    gap: 48px;
    padding: 92px max(32px, calc((100vw - 1180px) / 2)) 70px;
    background-image:
        linear-gradient(90deg, rgba(15, 23, 42, 0.95), rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)),
        var(--hero-image);
    background-size: cover;
    background-position: center;
}

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

.hero-backdrop {
    position: absolute;
    inset: 12% 8% auto auto;
    width: 360px;
    height: 360px;
    border-radius: 50%;
    background: rgba(217, 119, 6, 0.30);
    filter: blur(80px);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: #ffffff;
    max-width: 720px;
}

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    margin-bottom: 14px;
    padding: 6px 12px;
    border-radius: 999px;
    color: var(--accent-strong);
    background: var(--accent-soft);
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.hero-content h1 {
    margin: 0;
    font-size: clamp(40px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-content p {
    max-width: 650px;
    margin: 24px 0 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.85;
}

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

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

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

.btn.primary {
    color: #ffffff;
    background: var(--accent);
    box-shadow: 0 18px 34px rgba(217, 119, 6, 0.32);
}

.btn.ghost {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.32);
    background: rgba(255, 255, 255, 0.12);
}

.hero-poster {
    position: relative;
    z-index: 3;
    width: min(370px, 100%);
    justify-self: end;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
    aspect-ratio: 2 / 3;
    background: linear-gradient(135deg, #334155, #d97706);
}

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

.hero-poster img.is-missing,
.poster-frame img.is-missing {
    opacity: 0;
}

.hero-controls {
    position: absolute;
    right: max(24px, calc((100vw - 1180px) / 2));
    bottom: 30px;
    z-index: 8;
    display: flex;
    gap: 10px;
}

.hero-controls button {
    width: 48px;
    height: 48px;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    cursor: pointer;
    font-size: 30px;
    line-height: 1;
}

.search-band {
    margin-top: -38px;
    position: relative;
    z-index: 10;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 440px);
    gap: 28px;
    align-items: center;
    padding: 28px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow);
}

.search-band h2,
.section-heading h2,
.page-hero h1,
.content-card h2 {
    margin: 0;
    color: var(--blue-deep);
}

.search-band p,
.page-hero p,
.content-card p,
.movie-card p,
.category-card p,
.site-footer p {
    color: var(--muted);
    line-height: 1.8;
}

.quick-search,
.search-page-form {
    display: flex;
    gap: 10px;
    padding: 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
}

.quick-search input,
.search-page-form input,
.filter-box input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: none;
    padding: 0 16px;
    color: var(--text);
    background: transparent;
}

.quick-search button,
.search-page-form button {
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: var(--accent);
    padding: 10px 20px;
    font-weight: 800;
    cursor: pointer;
}

.channel-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 34px;
}

.channel-strip a {
    padding: 12px 18px;
    border-radius: 999px;
    background: #ffffff;
    color: var(--blue);
    font-weight: 800;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
    transition: color 0.25s ease, transform 0.25s ease;
}

.channel-strip a:hover {
    color: var(--accent);
    transform: translateY(-2px);
}

.section-block,
.ranking-preview,
.category-preview,
.page-shell,
.detail-shell {
    margin-top: 54px;
}

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

.section-heading h2 {
    font-size: clamp(26px, 3vw, 38px);
}

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

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

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

.category-movie-grid {
    align-items: stretch;
}

.movie-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    border-radius: 22px;
    background: #ffffff;
    overflow: hidden;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.07);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 46px rgba(15, 23, 42, 0.12);
}

.poster-frame {
    position: relative;
    display: block;
    overflow: hidden;
    background:
        radial-gradient(circle at top left, rgba(245, 158, 11, 0.42), transparent 34%),
        linear-gradient(145deg, #0f172a, #334155 48%, #d97706);
}

.movie-card .poster-frame {
    aspect-ratio: 2 / 3;
}

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

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

.movie-card-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 16px;
    flex: 1;
}

.movie-card-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 48px;
    color: var(--blue-deep);
    font-weight: 900;
    line-height: 1.45;
}

.movie-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 13px;
}

.movie-meta span,
.detail-meta span {
    padding: 4px 9px;
    border-radius: 999px;
    background: var(--panel-soft);
}

.movie-card p {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
    font-size: 14px;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: auto;
}

.tag-row span {
    padding: 5px 9px;
    border-radius: 999px;
    color: var(--accent-strong);
    background: var(--accent-soft);
    font-size: 12px;
    font-weight: 700;
}

.highlight-panel {
    padding: 30px;
    border-radius: 30px;
    background: linear-gradient(135deg, #fff7ed, #ffffff 52%, #f8fafc);
    box-shadow: var(--shadow);
}

.ranking-card,
.category-card,
.content-card,
.page-hero,
.detail-hero,
.player-section {
    border-radius: 30px;
    background: #ffffff;
    box-shadow: var(--shadow);
}

.ranking-card {
    padding: 28px;
}

.compact-heading {
    margin-bottom: 18px;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 52px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #ffffff;
    transition: border-color 0.25s ease, transform 0.25s ease;
}

.rank-row:hover {
    border-color: var(--accent);
    transform: translateX(3px);
}

.rank-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 14px;
    color: #ffffff;
    background: var(--blue-deep);
    font-weight: 900;
}

.rank-title {
    overflow: hidden;
    color: var(--blue-deep);
    font-weight: 800;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.rank-meta {
    color: var(--muted);
    font-size: 13px;
}

.category-preview {
    display: grid;
    gap: 42px;
}

.page-shell {
    padding-bottom: 58px;
}

.page-hero {
    padding: 42px;
    background:
        radial-gradient(circle at 85% 10%, rgba(217, 119, 6, 0.18), transparent 28%),
        #ffffff;
}

.page-hero h1 {
    font-size: clamp(34px, 5vw, 56px);
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 760px;
    margin: 16px 0 0;
    font-size: 17px;
}

.small-hero {
    margin-bottom: 30px;
}

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

.category-card {
    padding: 26px;
    transition: transform 0.25s ease;
}

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

.category-card span {
    color: var(--accent);
    font-weight: 900;
}

.category-card h2 {
    margin: 10px 0;
    color: var(--blue-deep);
}

.category-card ul {
    display: grid;
    gap: 8px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
}

.category-card li a {
    color: var(--blue);
}

.filter-box {
    max-width: 520px;
    margin-top: 24px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 28px 0 20px;
    color: var(--muted);
    font-size: 14px;
}

.breadcrumb a {
    color: var(--accent);
    font-weight: 700;
}

.detail-shell {
    padding-bottom: 60px;
}

.detail-hero {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 34px;
    padding: 34px;
    align-items: center;
}

.detail-poster {
    aspect-ratio: 2 / 3;
    border-radius: 24px;
    box-shadow: 0 22px 48px rgba(15, 23, 42, 0.18);
}

.detail-info h1 {
    margin: 0;
    font-size: clamp(32px, 4vw, 54px);
    line-height: 1.12;
    letter-spacing: -0.04em;
}

.lead-text {
    max-width: 850px;
    color: var(--blue);
    font-size: 18px;
    line-height: 1.8;
}

.detail-tags {
    margin-top: 18px;
}

.player-section {
    margin-top: 28px;
    padding: 20px;
    background: var(--blue-deep);
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #020617;
    aspect-ratio: 16 / 9;
}

.player-video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #020617;
    cursor: pointer;
}

.player-button {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 5;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(217, 119, 6, 0.94);
    padding: 16px 30px;
    font-weight: 900;
    cursor: pointer;
    box-shadow: 0 18px 38px rgba(0, 0, 0, 0.32);
}

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

.detail-content-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    margin-top: 28px;
}

.content-card {
    padding: 28px;
}

.content-card p {
    margin-bottom: 0;
}

.search-page-form {
    max-width: 620px;
    margin-top: 24px;
}

.search-results {
    margin: 30px 0;
}

.search-results .movie-grid {
    margin-top: 18px;
}

.site-footer {
    margin-top: 68px;
    padding: 50px 0;
    color: #cbd5e1;
    background: var(--blue-deep);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.7fr 0.7fr;
    gap: 34px;
}

.footer-brand {
    color: #ffffff;
}

.site-footer h3 {
    margin: 0 0 16px;
    color: #ffffff;
}

.site-footer a:not(.brand) {
    display: block;
    margin: 10px 0;
    color: #cbd5e1;
}

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

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

    .hero-slide {
        grid-template-columns: 1fr;
        padding-top: 96px;
    }

    .hero-poster {
        display: none;
    }

    .search-band {
        grid-template-columns: 1fr;
    }

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

    .detail-poster {
        width: min(280px, 100%);
    }
}

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

    .menu-toggle {
        display: inline-block;
    }

    .main-nav {
        position: absolute;
        left: 12px;
        right: 12px;
        top: 76px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding: 14px;
        border: 1px solid var(--line);
        border-radius: 22px;
        background: #ffffff;
        box-shadow: var(--shadow);
    }

    .main-nav.open {
        display: flex;
    }

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

    .nav-link:hover,
    .nav-link.active {
        background: var(--accent-soft);
    }

    .hero,
    .hero-slider {
        min-height: 620px;
    }

    .hero-slide {
        min-height: 620px;
        padding: 92px 22px 72px;
    }

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

    .hero-content p {
        font-size: 16px;
    }

    .hero-controls {
        right: 22px;
    }

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

    .search-band,
    .highlight-panel,
    .ranking-card,
    .page-hero,
    .detail-hero,
    .content-card {
        padding: 20px;
        border-radius: 22px;
    }

    .quick-search,
    .search-page-form {
        border-radius: 22px;
        flex-direction: column;
        align-items: stretch;
    }

    .quick-search input,
    .search-page-form input {
        min-height: 42px;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .rank-row {
        grid-template-columns: 44px minmax(0, 1fr);
    }

    .rank-meta {
        grid-column: 2;
    }
}

@media (max-width: 460px) {
    .movie-grid,
    .compact-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .brand {
        font-size: 18px;
    }

    .brand-mark {
        width: 32px;
        height: 32px;
    }

    .detail-info h1,
    .page-hero h1 {
        font-size: 34px;
    }
}
