* {
    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: #111827;
    background: linear-gradient(135deg, #f8fafc 0%, #f3f4f6 52%, #f5f5f4 100%);
}

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

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

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

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

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

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

.brand-icon {
    width: 36px;
    height: 36px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, #111827, #374151);
    box-shadow: 0 12px 28px rgba(17, 24, 39, 0.22);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

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

.brand-text em {
    margin-top: 3px;
    font-size: 12px;
    color: #6b7280;
    font-style: normal;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    font-size: 15px;
    font-weight: 600;
    color: #374151;
}

.desktop-nav a {
    position: relative;
    padding: 8px 0;
}

.desktop-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 2px;
    width: 0;
    height: 2px;
    background: #111827;
    transition: width 0.2s ease;
}

.desktop-nav a:hover::after {
    width: 100%;
}

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

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 4px auto;
    background: #111827;
}

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

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

.mobile-nav a:hover {
    background: #f3f4f6;
}

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

.hero {
    padding: 24px 0 10px;
}

.hero-shell {
    position: relative;
    width: min(1180px, calc(100% - 32px));
    min-height: 520px;
    margin: 0 auto;
    border-radius: 34px;
    overflow: hidden;
    background: #111827;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.32);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) 340px;
    gap: 42px;
    align-items: center;
    padding: 66px;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-bg {
    position: absolute;
    inset: 0;
    opacity: 0.28;
    filter: blur(2px);
}

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

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 70% 30%, rgba(255,255,255,0.24), transparent 28%), linear-gradient(120deg, rgba(17,24,39,0.96), rgba(31,41,55,0.84), rgba(17,24,39,0.62));
}

.hero-content,
.hero-poster {
    position: relative;
    z-index: 2;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    margin-bottom: 14px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #e5e7eb;
    background: rgba(255,255,255,0.14);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.eyebrow.dark {
    color: #374151;
    background: #e5e7eb;
}

.hero-content h1 {
    max-width: 720px;
    margin: 0 0 18px;
    color: #ffffff;
    font-size: clamp(38px, 6vw, 70px);
    line-height: 1.02;
    letter-spacing: -0.05em;
}

.hero-content p {
    max-width: 660px;
    margin: 0 0 22px;
    color: #d1d5db;
    font-size: 18px;
    line-height: 1.75;
}

.hero-tags,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 26px;
}

.hero-tags span,
.detail-meta span {
    padding: 8px 12px;
    border: 1px solid rgba(255,255,255,0.22);
    border-radius: 999px;
    color: #f9fafb;
    background: rgba(255,255,255,0.12);
    font-size: 13px;
}

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

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

.primary-button {
    color: #111827;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(255,255,255,0.18);
}

.primary-button.dark {
    color: #ffffff;
    background: #111827;
}

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

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

.hero-poster {
    aspect-ratio: 2 / 3;
    border-radius: 22px;
    overflow: hidden;
    background: linear-gradient(135deg, #374151, #111827);
    box-shadow: 0 22px 48px rgba(0,0,0,0.34);
}

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

.hero-controls {
    position: absolute;
    left: 66px;
    bottom: 34px;
    z-index: 5;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 28px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255,255,255,0.32);
    cursor: pointer;
}

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

.home-search-block,
.content-section,
.page-main {
    padding: 34px 0;
}

.home-search-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 430px);
    gap: 28px;
    align-items: center;
    padding: 28px;
    border-radius: 26px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15,23,42,0.08);
}

.home-search-inner h2,
.page-title h1,
.category-hero h1,
.ranking-hero h1 {
    margin: 0 0 10px;
    font-size: clamp(30px, 4vw, 48px);
    letter-spacing: -0.04em;
}

.home-search-inner p,
.page-title p,
.category-hero p,
.ranking-hero p,
.section-head p {
    margin: 0;
    color: #6b7280;
    line-height: 1.7;
}

.quick-search,
.search-panel {
    display: flex;
    gap: 10px;
}

.quick-search input,
.search-panel input,
.search-panel select {
    min-height: 48px;
    border: 1px solid #d1d5db;
    border-radius: 16px;
    padding: 0 16px;
    background: #ffffff;
    font-size: 15px;
    outline: none;
}

.quick-search input {
    flex: 1;
}

.quick-search button {
    min-height: 48px;
    border: 0;
    border-radius: 16px;
    padding: 0 20px;
    color: #ffffff;
    background: #111827;
    font-weight: 800;
    cursor: pointer;
}

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

.section-head h2 {
    margin: 0 0 6px;
    font-size: 28px;
    letter-spacing: -0.03em;
}

.section-more {
    color: #4b5563;
    font-weight: 800;
}

.horizontal-list {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding-bottom: 14px;
    scrollbar-width: thin;
}

.movie-card {
    min-width: 178px;
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.poster {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #d1d5db, #6b7280);
}

.poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.72), transparent 48%);
    opacity: 0;
    transition: opacity 0.2s ease;
}

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

.poster img {
    transition: transform 0.3s ease;
}

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

.play-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    color: #ffffff;
    background: rgba(255,255,255,0.22);
    border: 1px solid rgba(255,255,255,0.36);
    border-radius: 999px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
    backdrop-filter: blur(10px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

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

.rank-badge {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 3;
    padding: 5px 9px;
    border-radius: 999px;
    color: #111827;
    background: #ffffff;
    font-size: 12px;
    font-weight: 900;
}

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

.movie-card h3 {
    margin: 0 0 7px;
    font-size: 16px;
    line-height: 1.35;
}

.movie-meta {
    margin-bottom: 8px;
    color: #6b7280;
    font-size: 12px;
}

.movie-card p {
    margin: 0 0 10px;
    color: #4b5563;
    font-size: 13px;
    line-height: 1.55;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-row span {
    padding: 4px 8px;
    border-radius: 999px;
    color: #4b5563;
    background: #f3f4f6;
    font-size: 12px;
}

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

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

.page-title {
    padding: 26px 0 16px;
}

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

.category-card {
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 16px 38px rgba(15,23,42,0.08);
    overflow: hidden;
}

.category-card > a {
    display: block;
    min-height: 190px;
    padding: 28px;
    color: #ffffff;
    background: linear-gradient(135deg, #111827, #374151);
}

.category-count {
    display: inline-flex;
    margin-bottom: 16px;
    padding: 6px 12px;
    border-radius: 999px;
    color: #111827;
    background: #ffffff;
    font-weight: 900;
}

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

.category-card p {
    margin: 0;
    color: #d1d5db;
    line-height: 1.7;
}

.category-card ul {
    margin: 0;
    padding: 18px 28px 24px;
    list-style: none;
}

.category-card li + li {
    margin-top: 10px;
}

.category-card li a {
    color: #374151;
    font-weight: 700;
}

.category-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 34px;
    border-radius: 28px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(15,23,42,0.08);
}

.two-column-layout,
.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 26px;
    align-items: start;
    margin-top: 28px;
}

.side-panel {
    position: sticky;
    top: 92px;
    padding: 22px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(15,23,42,0.08);
}

.side-panel h2 {
    margin: 0 0 16px;
}

.hot-list {
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: hot;
}

.hot-list li + li {
    border-top: 1px solid #f3f4f6;
}

.hot-list a {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 0;
    color: #374151;
    font-weight: 700;
}

.hot-list span {
    color: #9ca3af;
    font-size: 12px;
}

.ranking-hero {
    margin-bottom: 30px;
    padding: 46px 0;
    color: #ffffff;
    background: linear-gradient(135deg, #111827, #1f2937 55%, #374151);
}

.ranking-inner {
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
    gap: 34px;
    align-items: start;
}

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

.ranking-top a {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 10px;
    min-height: 62px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(255,255,255,0.1);
}

.ranking-top strong {
    grid-row: span 2;
    display: grid;
    place-items: center;
    color: #111827;
    background: #ffffff;
    border-radius: 12px;
}

.ranking-top em {
    color: #d1d5db;
    font-size: 12px;
    font-style: normal;
}

.search-panel {
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 24px;
    padding: 18px;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(15,23,42,0.08);
}

.search-panel input {
    flex: 1 1 300px;
}

.search-count {
    margin-left: auto;
    color: #4b5563;
    font-weight: 800;
}

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

.detail-bg {
    position: absolute;
    inset: 0;
    opacity: 0.25;
    filter: blur(4px);
}

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

.detail-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(17,24,39,0.98), rgba(17,24,39,0.78));
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 36px;
    align-items: center;
    padding: 54px 0;
}

.detail-poster {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 24px;
    background: linear-gradient(135deg, #374151, #111827);
    box-shadow: 0 22px 54px rgba(0,0,0,0.35);
}

.detail-info h1 {
    margin: 0 0 16px;
    font-size: clamp(36px, 6vw, 68px);
    line-height: 1.04;
    letter-spacing: -0.05em;
}

.detail-info p {
    max-width: 760px;
    color: #d1d5db;
    font-size: 18px;
    line-height: 1.8;
}

.detail-tags span {
    color: #e5e7eb;
    background: rgba(255,255,255,0.12);
}

.player-section {
    margin-top: 32px;
}

.player-card {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    background: #000000;
    box-shadow: 0 24px 60px rgba(15,23,42,0.22);
}

.movie-player {
    width: 100%;
    min-height: 360px;
    max-height: 680px;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 10px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0,0,0,0.72), rgba(0,0,0,0.28));
    cursor: pointer;
}

.player-overlay span {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    border: 1px solid rgba(255,255,255,0.38);
    border-radius: 999px;
    background: rgba(255,255,255,0.18);
    font-size: 32px;
    backdrop-filter: blur(10px);
}

.player-overlay strong {
    font-size: 18px;
}

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

.detail-content {
    display: grid;
    gap: 20px;
}

.text-card {
    padding: 26px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(15,23,42,0.08);
}

.text-card h2 {
    margin: 0 0 14px;
}

.text-card p {
    margin: 0;
    color: #374151;
    line-height: 1.95;
    white-space: pre-line;
}

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

.detail-side dl {
    margin: 0;
}

.detail-side div {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f3f4f6;
}

.detail-side dt {
    color: #6b7280;
}

.detail-side dd {
    margin: 0;
    font-weight: 700;
}

.related-section {
    padding-bottom: 70px;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 30px;
}

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

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

.site-footer p {
    color: #9ca3af;
    line-height: 1.75;
}

.site-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer li + li {
    margin-top: 9px;
}

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

.footer-bottom {
    margin-top: 34px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.12);
}

.poster-missing {
    display: grid;
    place-items: center;
}

.poster-missing::before {
    content: "封面";
    color: rgba(255,255,255,0.74);
    font-weight: 800;
}

@media (max-width: 1040px) {
    .desktop-nav {
        gap: 12px;
        font-size: 14px;
    }

    .hero-slide {
        grid-template-columns: 1fr 260px;
        padding: 48px;
    }

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

    .two-column-layout,
    .detail-layout,
    .ranking-inner {
        grid-template-columns: 1fr;
    }

    .side-panel {
        position: static;
    }
}

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

    .menu-toggle {
        display: block;
    }

    .hero-shell {
        min-height: 690px;
        border-radius: 24px;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        align-content: center;
        padding: 34px;
    }

    .hero-poster {
        width: min(240px, 70vw);
        margin: 0 auto;
    }

    .hero-controls {
        left: 34px;
        bottom: 24px;
    }

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

    .category-grid,
    .footer-grid,
    .ranking-top {
        grid-template-columns: 1fr;
    }

    .category-hero {
        flex-direction: column;
        align-items: flex-start;
    }

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

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

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

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

    .movie-card {
        min-width: 150px;
    }

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

    .quick-search {
        flex-direction: column;
    }

    .movie-player {
        min-height: 240px;
    }
}


.sitemap-list {
    columns: 4 220px;
    padding: 24px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(15,23,42,0.08);
}

.sitemap-list li {
    break-inside: avoid;
    margin-bottom: 10px;
    color: #374151;
    font-weight: 700;
}
