* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
    color: #111827;
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 45%, #f9fafb 100%);
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    backdrop-filter: blur(18px);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 22px;
    min-height: 72px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: #0f172a;
    white-space: nowrap;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    color: #ffffff;
    border-radius: 14px;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.25);
}

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

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}

.nav-link,
.mobile-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 14px;
    color: #475569;
    border-radius: 999px;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    color: #0369a1;
    background: #e0f2fe;
}

.header-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    width: min(300px, 26vw);
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    background: #ffffff;
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    padding: 10px 12px 10px 16px;
    color: #0f172a;
    background: transparent;
}

.header-search button,
.large-search button,
.search-controls button {
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
    cursor: pointer;
}

.header-search button {
    align-self: stretch;
    padding: 0 16px;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
}

.menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    margin: 4px auto;
    background: #0f172a;
    border-radius: 999px;
}

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

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

.hero-slider {
    position: relative;
    color: #ffffff;
    background: #020617;
}

.hero-stage {
    position: relative;
    min-height: 560px;
    overflow: hidden;
}

.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-backdrop {
    position: absolute;
    inset: 0;
}

.hero-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.56;
    filter: saturate(1.15) contrast(1.05);
}

.hero-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 72% 30%, rgba(14, 165, 233, 0.35), transparent 34%),
        linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.74) 48%, rgba(2, 6, 23, 0.42) 100%),
        linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.88));
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: center;
    gap: 56px;
    min-height: 560px;
    padding: 72px 0;
}

.hero-copy {
    max-width: 720px;
}

.hero-kicker,
.section-kicker {
    margin: 0 0 12px;
    color: #0284c7;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero-kicker {
    color: #bae6fd;
}

.hero-copy h1,
.page-hero h1,
.detail-info-card h1 {
    margin: 0;
    font-size: clamp(34px, 6vw, 66px);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.hero-summary {
    max-width: 680px;
    margin: 22px 0 0;
    color: #e0f2fe;
    font-size: 18px;
    line-height: 1.8;
}

.hero-meta,
.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #64748b;
    font-size: 14px;
}

.hero-meta {
    margin-top: 22px;
    color: #cbd5e1;
}

.hero-meta span {
    padding: 7px 12px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.1);
}

.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.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.movie-card:hover,
.category-tile:hover,
.rank-card:hover {
    transform: translateY(-3px);
}

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
    box-shadow: 0 18px 40px rgba(37, 99, 235, 0.36);
}

.btn-glass {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
}

.hero-poster {
    display: block;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 28px;
    box-shadow: 0 30px 80px rgba(2, 6, 23, 0.48);
    transform: rotate(2deg);
}

.hero-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 5;
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.42);
    cursor: pointer;
    transform: translateY(-50%);
    backdrop-filter: blur(10px);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

.hero-dots button {
    width: 34px;
    height: 8px;
    overflow: hidden;
    color: transparent;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.36);
    cursor: pointer;
}

.hero-dots button.is-active {
    background: #38bdf8;
}

.search-band {
    padding: 28px 0;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.search-band-inner,
.large-search,
.search-controls,
.inline-filter {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-band h2,
.search-band p {
    margin: 0;
}

.search-band h2 {
    font-size: 24px;
    letter-spacing: -0.03em;
}

.search-band p {
    margin-top: 6px;
    color: #64748b;
}

.large-search {
    flex: 1;
    overflow: hidden;
    max-width: 560px;
    margin-left: auto;
    border: 1px solid #dbeafe;
    border-radius: 999px;
    background: #eff6ff;
}

.large-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 15px 18px;
    background: transparent;
}

.large-search button {
    align-self: stretch;
    padding: 0 24px;
}

.content-section {
    padding: 56px 0;
}

.content-section > .movie-grid,
.content-section > .section-head {
    width: min(1180px, calc(100% - 32px));
    margin-left: auto;
    margin-right: auto;
}

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

.section-head h2 {
    margin: 0;
    color: #0f172a;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.section-head.compact h2 {
    font-size: 24px;
}

.section-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    padding: 0 15px;
    color: #0369a1;
    font-weight: 700;
    border-radius: 999px;
    background: #e0f2fe;
}

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

.movie-card {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    border-color: #bae6fd;
    box-shadow: 0 20px 46px rgba(15, 23, 42, 0.12);
}

.poster-wrap {
    position: relative;
    display: block;
    overflow: hidden;
    background: #e2e8f0;
}

.poster-wrap img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.quality-badge,
.poster-play {
    position: absolute;
    z-index: 2;
}

.quality-badge {
    top: 10px;
    left: 10px;
    padding: 4px 8px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    border-radius: 999px;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
}

.poster-play {
    right: 10px;
    bottom: 10px;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    color: #ffffff;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.68);
    backdrop-filter: blur(8px);
}

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

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

.movie-card h3 a:hover,
.rank-content h2 a:hover,
.prose-card a:hover {
    color: #0284c7;
}

.movie-desc {
    min-height: 42px;
    margin: 9px 0 12px;
    color: #64748b;
    font-size: 13px;
    line-height: 1.6;
}

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

.tag-list span {
    padding: 4px 8px;
    color: #0369a1;
    font-size: 12px;
    border-radius: 999px;
    background: #e0f2fe;
}

.category-overview {
    background: linear-gradient(180deg, #ffffff, #f8fafc);
}

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

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

.category-tile {
    display: block;
    min-height: 150px;
    padding: 24px;
    border: 1px solid #dbeafe;
    border-radius: 24px;
    background:
        radial-gradient(circle at top right, rgba(14, 165, 233, 0.16), transparent 34%),
        #ffffff;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.category-tile span {
    display: block;
    margin-bottom: 10px;
    color: #0f172a;
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.category-tile p {
    margin: 0;
    color: #64748b;
    line-height: 1.7;
}

.two-column-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 34px;
    align-items: start;
}

.ranking-panel {
    position: sticky;
    top: 92px;
    padding-top: 56px;
}

.ranking-card,
.prose-card,
.detail-info-card,
.player-panel {
    border: 1px solid #e5e7eb;
    border-radius: 26px;
    background: #ffffff;
    box-shadow: 0 16px 44px rgba(15, 23, 42, 0.08);
}

.ranking-card {
    padding: 22px;
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 8px 12px;
    align-items: center;
    padding: 12px;
    border-radius: 16px;
    background: #f8fafc;
}

.rank-num {
    grid-row: span 2;
    color: #0284c7;
    font-size: 20px;
    font-weight: 900;
}

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

.rank-meta {
    overflow: hidden;
    color: #64748b;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.page-hero {
    position: relative;
    overflow: hidden;
    padding: 88px 0;
    color: #ffffff;
    background:
        radial-gradient(circle at 78% 10%, rgba(56, 189, 248, 0.34), transparent 30%),
        linear-gradient(135deg, #0f172a 0%, #0c4a6e 56%, #1d4ed8 100%);
}

.page-hero::after {
    content: "";
    position: absolute;
    inset: auto -10% -45% auto;
    width: 420px;
    height: 420px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
}

.page-hero .container {
    position: relative;
    z-index: 2;
}

.page-hero p {
    max-width: 760px;
    color: #dbeafe;
    font-size: 18px;
    line-height: 1.8;
}

.compact-hero {
    padding: 60px 0;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    margin-bottom: 20px;
    color: #bae6fd;
    font-size: 14px;
}

.breadcrumb strong {
    color: #ffffff;
}

.inline-filter {
    max-width: 520px;
    margin-top: 24px;
}

.inline-filter input,
.search-controls input,
.search-controls select {
    width: 100%;
    min-height: 48px;
    border: 1px solid rgba(186, 230, 253, 0.72);
    border-radius: 16px;
    outline: 0;
    padding: 0 16px;
    color: #0f172a;
    background: rgba(255, 255, 255, 0.94);
}

.pagination,
.page-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 36px;
}

.pagination a,
.page-links a {
    display: grid;
    place-items: center;
    min-width: 38px;
    min-height: 38px;
    padding: 0 12px;
    color: #0369a1;
    border-radius: 999px;
    background: #e0f2fe;
    font-weight: 800;
}

.pagination a.is-active {
    color: #ffffff;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
}

.rank-grid {
    display: grid;
    gap: 16px;
}

.rank-card {
    display: grid;
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 18px;
    padding: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.rank-cover img {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.rank-content h2 {
    margin: 6px 0;
    font-size: 22px;
    letter-spacing: -0.03em;
}

.rank-content p {
    color: #64748b;
    line-height: 1.7;
}

.search-controls {
    flex-wrap: wrap;
    max-width: 860px;
    margin-top: 28px;
}

.search-controls input {
    flex: 2 1 280px;
}

.search-controls select {
    flex: 1 1 150px;
}

.search-controls button {
    min-height: 48px;
    padding: 0 20px;
    border-radius: 16px;
}

.detail-hero {
    padding: 34px 0 56px;
    color: #ffffff;
    background:
        radial-gradient(circle at 80% 12%, rgba(14, 165, 233, 0.36), transparent 28%),
        linear-gradient(135deg, #020617, #0f172a 52%, #082f49);
}

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

.player-panel {
    overflow: hidden;
    background: #020617;
}

.video-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.video-frame video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    gap: 12px;
    color: #ffffff;
    border: 0;
    background:
        radial-gradient(circle at center, rgba(14, 165, 233, 0.28), rgba(2, 6, 23, 0.72));
    cursor: pointer;
}

.play-overlay.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.play-icon {
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    padding-left: 5px;
    font-size: 34px;
    border-radius: 999px;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
    box-shadow: 0 20px 60px rgba(37, 99, 235, 0.48);
}

.detail-info-card {
    display: grid;
    grid-template-columns: 130px minmax(0, 1fr);
    gap: 18px;
    padding: 18px;
    color: #0f172a;
}

.detail-info-card img {
    width: 100%;
    border-radius: 18px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
}

.detail-info-card h1 {
    font-size: 28px;
}

.detail-info-card p {
    color: #475569;
    line-height: 1.75;
}

.detail-copy {
    padding-top: 44px;
}

.prose-card {
    padding: clamp(22px, 4vw, 42px);
}

.prose-card h2 {
    margin: 26px 0 12px;
    color: #0f172a;
    font-size: 26px;
    letter-spacing: -0.03em;
}

.prose-card h2:first-child {
    margin-top: 0;
}

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

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

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

.info-list dt {
    color: #64748b;
    font-size: 13px;
}

.info-list dd {
    margin: 5px 0 0;
    color: #0f172a;
    font-weight: 800;
}

.site-footer {
    margin-top: 40px;
    padding: 46px 0 24px;
    color: #cbd5e1;
    background: #020617;
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) 1fr 1fr;
    gap: 32px;
}

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

.site-footer p {
    max-width: 520px;
    color: #94a3b8;
    line-height: 1.8;
}

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

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

.footer-bottom {
    margin-top: 32px;
    padding-top: 22px;
    color: #94a3b8;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    font-size: 14px;
}

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

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

    .ranking-panel {
        position: static;
        padding-top: 0;
    }

    .detail-info-card {
        grid-template-columns: 110px minmax(0, 1fr);
    }
}

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

    .menu-toggle {
        display: block;
        margin-left: auto;
    }

    .hero-stage,
    .hero-content {
        min-height: 640px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 56px 0 72px;
    }

    .hero-poster {
        width: min(220px, 62vw);
        justify-self: start;
        transform: rotate(0deg);
    }

    .hero-control {
        display: none;
    }

    .search-band-inner,
    .large-search,
    .section-head {
        align-items: stretch;
        flex-direction: column;
    }

    .large-search {
        width: 100%;
        max-width: none;
        margin-left: 0;
    }

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

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

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

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

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

    .movie-desc {
        display: none;
    }

    .content-section {
        padding: 38px 0;
    }

    .page-hero,
    .compact-hero {
        padding: 46px 0;
    }

    .detail-info-card {
        grid-template-columns: 92px minmax(0, 1fr);
    }

    .detail-info-card h1 {
        font-size: 22px;
    }

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

    .play-icon {
        width: 62px;
        height: 62px;
        font-size: 28px;
    }
}
