* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: #1f2937;
    background: #f8fafc;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(16px);
}

.header-inner {
    width: min(1180px, calc(100% - 32px));
    min-height: 64px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

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

.brand-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #ffffff;
    background: linear-gradient(135deg, #0891b2, #0d9488, #059669);
    box-shadow: 0 12px 24px rgba(8, 145, 178, 0.28);
}

.brand-short {
    display: none;
}

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

.nav-link,
.mobile-link {
    display: inline-flex;
    align-items: center;
    padding: 9px 14px;
    border-radius: 12px;
    font-weight: 600;
    color: #4b5563;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.mobile-link:hover,
.nav-link.is-active,
.mobile-link.is-active {
    color: #ffffff;
    background: #0891b2;
}

.nav-toggle {
    width: 42px;
    height: 42px;
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    border: 0;
    border-radius: 12px;
    color: #0f172a;
    background: #eef2f7;
    cursor: pointer;
}

.nav-toggle span {
    width: 20px;
    height: 2px;
    margin: 0 auto;
    background: #0f172a;
    border-radius: 99px;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 16px;
}

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

.hero-slider {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    color: #ffffff;
    background: #042f2e;
}

.hero-track {
    position: relative;
    min-height: 620px;
}

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

.hero-image::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(3, 7, 18, 0.92) 0%, rgba(12, 74, 110, 0.75) 48%, rgba(5, 150, 105, 0.32) 100%);
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 620px;
    margin: 0 auto;
    padding: 86px 0 90px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.eyebrow {
    display: inline-flex;
    margin-bottom: 14px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: #cffafe;
    background: rgba(8, 145, 178, 0.28);
    border: 1px solid rgba(207, 250, 254, 0.28);
    text-transform: uppercase;
}

.hero-content h1 {
    max-width: 760px;
    margin: 0 0 12px;
    font-size: clamp(38px, 7vw, 76px);
    line-height: 1.04;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.hero-content h2 {
    max-width: 680px;
    margin: 0 0 18px;
    font-size: clamp(28px, 4vw, 52px);
    line-height: 1.1;
    font-weight: 800;
    color: #a5f3fc;
}

.hero-content p {
    max-width: 680px;
    margin: 0 0 22px;
    font-size: 18px;
    color: #ecfeff;
}

.hero-tags,
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.tag-list span {
    display: inline-flex;
    padding: 5px 11px;
    border-radius: 999px;
    color: #0e7490;
    background: #ecfeff;
    font-size: 13px;
    font-weight: 700;
}

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

.primary-btn,
.ghost-btn,
.section-more,
.site-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 22px;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-btn,
.site-search button {
    color: #ffffff;
    background: linear-gradient(135deg, #0891b2, #0d9488);
    box-shadow: 0 16px 30px rgba(8, 145, 178, 0.28);
}

.primary-btn:hover,
.site-search button:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 40px rgba(8, 145, 178, 0.35);
}

.ghost-btn {
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.75);
    background: rgba(255, 255, 255, 0.06);
}

.ghost-btn:hover {
    background: rgba(255, 255, 255, 0.16);
}

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

.hero-dot {
    width: 12px;
    height: 12px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
}

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

.search-band {
    padding: 0 16px;
    margin-top: -48px;
    position: relative;
    z-index: 8;
}

.search-panel {
    width: min(1180px, 100%);
    margin: 0 auto;
    padding: 28px;
    display: grid;
    grid-template-columns: 1fr minmax(280px, 520px);
    align-items: center;
    gap: 22px;
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 22px 50px rgba(15, 23, 42, 0.12);
}

.search-panel h2 {
    margin: 0 0 4px;
    font-size: 26px;
    color: #0f172a;
}

.search-panel p {
    margin: 0;
    color: #64748b;
}

.site-search {
    display: flex;
    gap: 10px;
}

.site-search input,
.filter-bar input,
.filter-bar select {
    min-height: 48px;
    width: 100%;
    padding: 0 16px;
    border: 1px solid #d1d5db;
    border-radius: 14px;
    color: #111827;
    background: #ffffff;
    outline: none;
}

.site-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: #0891b2;
    box-shadow: 0 0 0 4px rgba(8, 145, 178, 0.14);
}

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

.soft-bg {
    width: 100%;
    padding-left: max(16px, calc((100% - 1180px) / 2));
    padding-right: max(16px, calc((100% - 1180px) / 2));
    background: #eef7f8;
}

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

.section-head h2 {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.12;
    color: #0f172a;
    letter-spacing: -0.03em;
}

.section-head p {
    margin: 8px 0 0;
    color: #64748b;
}

.section-more {
    min-height: 40px;
    color: #0e7490;
    background: #ecfeff;
}

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

.category-tile,
.category-card-large {
    display: flex;
    min-height: 170px;
    flex-direction: column;
    justify-content: space-between;
    gap: 10px;
    padding: 22px;
    border-radius: 22px;
    color: #ffffff;
    background: linear-gradient(135deg, #0891b2, #0d9488, #059669);
    box-shadow: 0 18px 34px rgba(8, 145, 178, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile:hover,
.category-card-large:hover {
    transform: translateY(-4px);
    box-shadow: 0 24px 46px rgba(8, 145, 178, 0.28);
}

.category-tile span,
.category-mark {
    font-size: 13px;
    font-weight: 900;
    color: #cffafe;
}

.category-tile strong,
.category-card-large h2 {
    font-size: 24px;
    line-height: 1.15;
}

.category-tile em,
.category-card-large p {
    font-style: normal;
    color: #ecfeff;
}

.category-tile b,
.category-card-large b {
    font-size: 14px;
    color: #ffffff;
}

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

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

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

.movie-card {
    display: flex;
    min-width: 0;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 14px 26px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

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

.poster-box {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #e0f2fe, #ccfbf1);
}

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

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

.year-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(8, 145, 178, 0.92);
    font-size: 12px;
    font-weight: 800;
}

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

.card-meta {
    margin-bottom: 5px;
    font-size: 13px;
    color: #0891b2;
    font-weight: 800;
}

.card-body strong {
    color: #111827;
    font-size: 17px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-desc {
    margin-top: 8px;
    color: #64748b;
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.watch-link {
    margin-top: auto;
    padding-top: 14px;
    color: #0e7490;
    font-size: 14px;
    font-weight: 900;
}

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

.rank-panel,
.detail-card,
.info-card,
.player-card {
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.08);
}

.rank-panel {
    position: sticky;
    top: 86px;
    padding: 22px;
}

.rank-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.rank-head h2 {
    margin: 0;
    font-size: 24px;
}

.rank-head a {
    color: #0891b2;
    font-weight: 800;
}

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

.rank-item,
.ranking-row {
    display: grid;
    align-items: center;
    gap: 12px;
    color: #334155;
}

.rank-item {
    grid-template-columns: 32px 58px 1fr;
    padding: 9px;
    border-radius: 14px;
    background: #f8fafc;
}

.rank-item:hover,
.ranking-row:hover {
    background: #ecfeff;
}

.rank-num,
.ranking-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 10px;
    color: #ffffff;
    background: #0891b2;
    font-weight: 900;
}

.rank-item img,
.ranking-row img {
    width: 58px;
    height: 78px;
    object-fit: cover;
    border-radius: 10px;
    background: #e0f2fe;
}

.rank-info strong,
.ranking-row strong {
    display: block;
    color: #111827;
    font-weight: 800;
}

.rank-info em,
.ranking-row em {
    display: block;
    color: #64748b;
    font-size: 13px;
    font-style: normal;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(135deg, #0891b2, #0d9488, #059669);
}

.page-hero-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 74px 0;
}

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(38px, 6vw, 64px);
    line-height: 1.05;
}

.page-hero p {
    max-width: 760px;
    margin: 0;
    color: #ecfeff;
    font-size: 18px;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) 180px 180px;
    gap: 12px;
    margin-bottom: 26px;
    padding: 18px;
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.08);
}

.empty-state {
    padding: 60px 16px;
    text-align: center;
    color: #64748b;
    font-weight: 800;
}

.ranking-row {
    grid-template-columns: 46px 74px 1fr auto;
    padding: 12px;
    border: 1px solid #e5e7eb;
    border-radius: 18px;
    background: #ffffff;
}

.ranking-row img {
    width: 74px;
    height: 96px;
}

.ranking-row b {
    color: #0e7490;
}

.detail-hero {
    min-height: 500px;
    background: #0f172a;
}

.detail-bg {
    position: absolute;
    inset: 0;
    opacity: 0.32;
}

.detail-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 118, 110, 0.68));
}

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

.detail-hero-inner {
    position: relative;
    z-index: 1;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 44px 0 64px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 28px;
    color: #cffafe;
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #ffffff;
}

.detail-topline {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr);
    gap: 30px;
    align-items: center;
}

.detail-poster {
    width: 230px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 28px 60px rgba(2, 6, 23, 0.35);
    background: #e0f2fe;
}

.detail-topline h1 {
    margin: 0 0 14px;
    font-size: clamp(34px, 6vw, 64px);
    line-height: 1.06;
}

.detail-topline p {
    max-width: 760px;
    margin: 0;
    color: #ecfeff;
    font-size: 18px;
}

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

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

.player-card {
    padding: 14px;
    background: #0f172a;
}

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: 18px;
    background: #000000;
}

.player-frame video,
.player-cover {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.player-frame video {
    z-index: 1;
    object-fit: contain;
    background: #000000;
}

.player-cover {
    z-index: 3;
    padding: 0;
    border: 0;
    cursor: pointer;
    background: #020617;
}

.player-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.58;
}

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

.play-pulse {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, #0891b2, #0d9488);
    box-shadow: 0 0 0 16px rgba(255, 255, 255, 0.16);
    font-size: 34px;
    font-weight: 900;
}

.detail-card,
.info-card {
    padding: 28px;
}

.detail-card h2,
.info-card h2 {
    margin: 0 0 14px;
    color: #0f172a;
    font-size: 24px;
}

.detail-card p {
    margin: 0 0 20px;
    color: #475569;
}

.lead-text {
    color: #0e7490 !important;
    font-weight: 800;
}

.info-card {
    position: sticky;
    top: 86px;
}

.info-card dl {
    display: grid;
    grid-template-columns: 70px 1fr;
    gap: 10px 12px;
    margin: 0 0 20px;
}

.info-card dt {
    color: #64748b;
    font-weight: 800;
}

.info-card dd {
    margin: 0;
    color: #111827;
}

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

.movie-card.compact .card-desc,
.movie-card.compact .card-meta,
.movie-card.compact .watch-link {
    display: none;
}

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

.movie-card.compact .card-body strong {
    font-size: 14px;
}

.site-footer {
    color: #cbd5e1;
    background: #0f172a;
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0;
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1fr;
    gap: 28px;
}

.footer-logo {
    color: #ffffff;
    margin-bottom: 14px;
}

.footer-brand p,
.footer-block p {
    margin: 0;
    color: #94a3b8;
    font-size: 14px;
}

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

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

.footer-block a:hover {
    color: #67e8f9;
}

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

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

    .nav-toggle {
        display: inline-flex;
    }

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

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

    .rank-panel,
    .info-card {
        position: static;
    }
}

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

    .brand-short {
        display: inline;
    }

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

    .hero-content {
        padding-top: 66px;
    }

    .search-panel,
    .filter-bar,
    .footer-inner,
    .detail-topline {
        grid-template-columns: 1fr;
    }

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

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

    .section-head {
        align-items: flex-start;
        flex-direction: column;
    }

    .detail-poster {
        width: 180px;
    }

    .ranking-row {
        grid-template-columns: 38px 64px 1fr;
    }

    .ranking-row b {
        display: none;
    }
}

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

    .content-section,
    .page-hero-inner,
    .detail-hero-inner,
    .header-inner,
    .mobile-nav,
    .footer-inner {
        width: min(100% - 24px, 1180px);
    }

    .hero-actions,
    .detail-actions {
        flex-direction: column;
        width: 100%;
    }

    .primary-btn,
    .ghost-btn {
        width: 100%;
    }
}
