* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
    background: #102a43;
    color: #ffffff;
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    scroll-behavior: smooth;
}

body {
    min-height: 100%;
    margin: 0;
    overflow-x: hidden;
    background:
        radial-gradient(circle at top left, rgba(45, 130, 133, 0.32), transparent 34rem),
        linear-gradient(180deg, #102a43 0%, #0b1f33 46%, #081928 100%);
    color: #ffffff;
}

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

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

button,
input {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(51, 78, 104, 0.9);
    background: rgba(16, 42, 67, 0.94);
    backdrop-filter: blur(18px);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: min(1200px, calc(100% - 2rem));
    min-height: 72px;
    margin: 0 auto;
}

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 999px;
    background: linear-gradient(135deg, #2d8285, #164b51);
    box-shadow: 0 18px 48px rgba(45, 130, 133, 0.32);
}

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

.desktop-nav a,
.mobile-nav a {
    border-radius: 999px;
    padding: 0.55rem 0.9rem;
    color: #bcccdc;
    transition: color 0.2s ease, background 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
    background: rgba(45, 130, 133, 0.22);
    color: #ffffff;
}

.header-search {
    display: flex;
    align-items: center;
    overflow: hidden;
    width: min(310px, 28vw);
    border: 1px solid rgba(51, 78, 104, 0.92);
    border-radius: 999px;
    background: rgba(36, 59, 83, 0.72);
}

.header-search input,
.mobile-nav input,
.page-filter input,
.hero-search-card input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #ffffff;
}

.header-search input {
    padding: 0.75rem 0 0.75rem 1rem;
}

.header-search button,
.mobile-nav button,
.page-filter button,
.hero-search-card button {
    flex: none;
    border: 0;
    color: #ffffff;
    background: #2d8285;
    transition: background 0.2s ease, transform 0.2s ease;
}

.header-search button {
    padding: 0.75rem 1rem;
}

.header-search button:hover,
.mobile-nav button:hover,
.page-filter button:hover,
.hero-search-card button:hover,
.primary-button:hover {
    background: #20656a;
}

.menu-button {
    display: none;
    flex-direction: column;
    gap: 0.3rem;
    border: 1px solid rgba(51, 78, 104, 0.9);
    border-radius: 0.85rem;
    padding: 0.65rem;
    background: rgba(36, 59, 83, 0.7);
}

.menu-button span {
    display: block;
    width: 1.3rem;
    height: 2px;
    border-radius: 99px;
    background: #ffffff;
}

.mobile-nav {
    display: none;
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 0 0 1rem;
}

.mobile-nav.is-open {
    display: grid;
    gap: 0.6rem;
}

.mobile-nav form {
    display: flex;
    overflow: hidden;
    border: 1px solid rgba(51, 78, 104, 0.92);
    border-radius: 1rem;
    background: rgba(36, 59, 83, 0.72);
}

.mobile-nav input {
    padding: 0.8rem 1rem;
}

.mobile-nav button {
    padding: 0.8rem 1rem;
}

.hero-section {
    position: relative;
    min-height: 650px;
    overflow: hidden;
    border-bottom: 1px solid rgba(51, 78, 104, 0.72);
    background: #102a43;
}

.hero-slides,
.hero-slide {
    position: absolute;
    inset: 0;
}

.hero-slide {
    display: grid;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.01);
    transition: opacity 0.6s ease, transform 0.8s ease;
}

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

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.55;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(16, 42, 67, 0.98) 0%, rgba(16, 42, 67, 0.72) 42%, rgba(16, 42, 67, 0.24) 100%),
        linear-gradient(0deg, rgba(16, 42, 67, 0.96) 0%, transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 6rem 0 9rem;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(123, 184, 186, 0.35);
    border-radius: 999px;
    padding: 0.35rem 0.75rem;
    color: #7bb8ba;
    background: rgba(45, 130, 133, 0.16);
    font-size: 0.86rem;
    font-weight: 700;
}

.hero-content h1,
.page-hero h1,
.detail-copy h1 {
    max-width: 820px;
    margin: 0;
    font-size: clamp(2.6rem, 6vw, 5.7rem);
    line-height: 0.98;
    letter-spacing: -0.06em;
}

.hero-content p,
.page-hero p,
.detail-copy p {
    max-width: 680px;
    margin: 1.2rem 0 0;
    color: #bcccdc;
    font-size: clamp(1rem, 2vw, 1.2rem);
    line-height: 1.8;
}

.hero-tags,
.detail-tags,
.tag-row,
.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hero-tags,
.detail-tags {
    margin-top: 1.3rem;
}

.hero-tags span,
.detail-tags span,
.tag-row span,
.filter-chips button {
    border: 1px solid rgba(51, 78, 104, 0.9);
    border-radius: 999px;
    background: rgba(36, 59, 83, 0.64);
    color: #bcccdc;
}

.hero-tags span,
.detail-tags span {
    padding: 0.45rem 0.75rem;
}

.tag-row span {
    padding: 0.24rem 0.5rem;
    font-size: 0.78rem;
}

.hero-actions,
.detail-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    margin-top: 1.8rem;
}

.primary-button,
.secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 3rem;
    border-radius: 999px;
    padding: 0.85rem 1.25rem;
    font-weight: 800;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, border 0.2s ease;
}

.primary-button {
    background: #2d8285;
    color: #ffffff;
    box-shadow: 0 18px 48px rgba(45, 130, 133, 0.28);
}

.secondary-button {
    border: 1px solid rgba(188, 204, 220, 0.24);
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.primary-button:hover,
.secondary-button:hover,
.movie-card:hover,
.category-card:hover,
.category-overview-card:hover,
.compact-card:hover,
.rank-item:hover {
    transform: translateY(-3px);
}

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

.hero-dots button {
    width: 0.72rem;
    height: 0.72rem;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.38);
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dots button.is-active {
    width: 2.2rem;
    background: #52a0a3;
}

.hero-search-card {
    position: absolute;
    z-index: 5;
    right: max(1rem, calc((100vw - 1200px) / 2));
    bottom: 5.7rem;
    width: min(390px, calc(100% - 2rem));
    border: 1px solid rgba(51, 78, 104, 0.86);
    border-radius: 1.4rem;
    padding: 1rem;
    background: rgba(16, 42, 67, 0.72);
    box-shadow: 0 22px 80px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(18px);
}

.hero-search-card strong {
    display: block;
    margin-bottom: 0.8rem;
}

.hero-search-card form,
.page-filter {
    display: flex;
    overflow: hidden;
    border: 1px solid rgba(51, 78, 104, 0.9);
    border-radius: 999px;
    background: rgba(36, 59, 83, 0.8);
}

.hero-search-card input,
.page-filter input {
    padding: 0.9rem 1rem;
}

.hero-search-card button,
.page-filter button {
    padding: 0.9rem 1.1rem;
}

.section-wrap {
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 4rem 0;
}

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

.section-heading span {
    display: block;
    color: #52a0a3;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.section-heading h2 {
    margin: 0.18rem 0 0;
    font-size: clamp(1.6rem, 3vw, 2.45rem);
    letter-spacing: -0.03em;
}

.section-heading a {
    color: #7bb8ba;
    font-weight: 800;
}

.compact-heading {
    align-items: center;
    margin-bottom: 1rem;
}

.category-grid,
.movie-grid,
.category-overview-grid {
    display: grid;
    gap: 1rem;
}

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

.category-card,
.category-overview-card,
.movie-card,
.content-card,
.player-card,
.ranking-panel {
    border: 1px solid rgba(51, 78, 104, 0.86);
    background: rgba(36, 59, 83, 0.52);
    box-shadow: 0 18px 65px rgba(0, 0, 0, 0.2);
}

.category-card {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    border-radius: 1.2rem;
    padding: 1rem;
    transition: transform 0.2s ease, border 0.2s ease;
}

.category-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.28;
    transition: transform 0.5s ease;
}

.category-card:hover img {
    transform: scale(1.07);
}

.category-card span,
.category-card p {
    position: relative;
    z-index: 2;
}

.category-card span {
    display: block;
    margin-top: 6.8rem;
    font-size: 1.25rem;
    font-weight: 900;
}

.category-card p {
    margin: 0.45rem 0 0;
    color: #bcccdc;
    line-height: 1.65;
}

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

.catalog-grid {
    align-items: stretch;
}

.movie-card {
    overflow: hidden;
    border-radius: 1.15rem;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.movie-card:hover {
    border-color: rgba(82, 160, 163, 0.72);
    background: rgba(51, 78, 104, 0.7);
}

.movie-card-link {
    display: flex;
    min-height: 100%;
    flex-direction: column;
}

.poster-wrap {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: #243b53;
}

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

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

.poster-badge,
.poster-type {
    position: absolute;
    top: 0.7rem;
    border-radius: 999px;
    padding: 0.25rem 0.55rem;
    background: rgba(16, 42, 67, 0.78);
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
    backdrop-filter: blur(12px);
}

.poster-badge {
    left: 0.7rem;
}

.poster-type {
    right: 0.7rem;
}

.movie-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 0.65rem;
    padding: 1rem;
}

.movie-card-body h3 {
    margin: 0;
    font-size: 1.05rem;
    line-height: 1.32;
}

.movie-card-body p {
    flex: 1;
    margin: 0;
    color: #bcccdc;
    line-height: 1.68;
}

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    color: #9fb3c8;
    font-size: 0.86rem;
}

.horizontal-row {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(130px, 165px);
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 0.7rem;
    scrollbar-width: none;
}

.horizontal-row::-webkit-scrollbar {
    display: none;
}

.compact-card {
    display: grid;
    gap: 0.75rem;
    border-radius: 1rem;
    transition: transform 0.2s ease;
}

.compact-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    border: 1px solid rgba(51, 78, 104, 0.9);
    border-radius: 1rem;
    object-fit: cover;
}

.compact-card span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #e6f0f7;
    font-weight: 800;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 0.9fr);
    gap: 1.4rem;
    align-items: start;
}

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

.ranking-panel {
    position: sticky;
    top: 92px;
    border-radius: 1.2rem;
    padding: 1rem;
}

.rank-list {
    display: grid;
    gap: 0.7rem;
}

.rank-item {
    border-radius: 0.95rem;
    background: rgba(16, 42, 67, 0.56);
    transition: transform 0.2s ease, background 0.2s ease;
}

.rank-item:hover {
    background: rgba(51, 78, 104, 0.8);
}

.rank-item a {
    display: grid;
    grid-template-columns: 2.6rem 3.3rem minmax(0, 1fr);
    gap: 0.75rem;
    align-items: center;
    padding: 0.6rem;
}

.rank-number {
    color: #7bb8ba;
    font-size: 1.1rem;
    font-weight: 900;
    text-align: center;
}

.rank-item img {
    width: 3.3rem;
    aspect-ratio: 3 / 4;
    border-radius: 0.65rem;
    object-fit: cover;
}

.rank-copy {
    display: grid;
    gap: 0.25rem;
    min-width: 0;
}

.rank-copy strong,
.rank-copy em {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-copy em {
    color: #9fb3c8;
    font-size: 0.84rem;
    font-style: normal;
}

.page-hero {
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid rgba(51, 78, 104, 0.72);
    padding: 6rem max(1rem, calc((100vw - 1200px) / 2)) 4rem;
    background:
        linear-gradient(135deg, rgba(45, 130, 133, 0.25), transparent 48%),
        linear-gradient(180deg, #102a43 0%, #0e263d 100%);
}

.slim-hero {
    padding-top: 5rem;
    padding-bottom: 3.5rem;
}

.page-filter {
    width: min(640px, 100%);
    margin-top: 1.5rem;
}

.filter-chips {
    margin-top: 0.9rem;
}

.filter-chips button {
    padding: 0.46rem 0.75rem;
    transition: background 0.2s ease, color 0.2s ease;
}

.filter-chips button:hover {
    background: rgba(45, 130, 133, 0.38);
    color: #ffffff;
}

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

.category-overview-card {
    overflow: hidden;
    border-radius: 1.25rem;
    transition: transform 0.2s ease, border 0.2s ease;
}

.category-overview-card a {
    display: grid;
    gap: 1rem;
    padding: 1rem;
}

.overview-covers {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.45rem;
}

.overview-covers img {
    width: 100%;
    aspect-ratio: 3 / 4;
    border-radius: 0.75rem;
    object-fit: cover;
}

.category-overview-card span {
    color: #52a0a3;
    font-size: 0.78rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.category-overview-card h2 {
    margin: 0.2rem 0 0;
}

.category-overview-card p {
    margin: 0.45rem 0 0;
    color: #bcccdc;
    line-height: 1.65;
}

.rank-page-wrap {
    padding-top: 2.4rem;
}

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

.detail-hero {
    display: grid;
    grid-template-columns: minmax(220px, 330px) minmax(0, 1fr);
    gap: clamp(1.2rem, 4vw, 3rem);
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 4rem 0 3rem;
}

.detail-poster {
    overflow: hidden;
    border: 1px solid rgba(51, 78, 104, 0.9);
    border-radius: 1.5rem;
    background: #243b53;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
}

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

.detail-copy {
    align-self: center;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-bottom: 1.2rem;
    color: #9fb3c8;
    font-size: 0.92rem;
}

.breadcrumb a:hover {
    color: #7bb8ba;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(280px, 0.8fr);
    gap: 1.2rem;
    align-items: start;
    padding-top: 1rem;
}

.detail-main,
.detail-side {
    display: grid;
    gap: 1rem;
}

.player-card,
.content-card {
    border-radius: 1.25rem;
    padding: 1rem;
}

.player-frame {
    position: relative;
    overflow: hidden;
    border-radius: 1rem;
    background: #06111d;
    aspect-ratio: 16 / 9;
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    background: radial-gradient(circle, rgba(16, 42, 67, 0.24), rgba(6, 17, 29, 0.62));
}

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

.player-overlay button {
    display: grid;
    place-items: center;
    width: clamp(4rem, 9vw, 6rem);
    height: clamp(4rem, 9vw, 6rem);
    border: 1px solid rgba(255, 255, 255, 0.32);
    border-radius: 999px;
    background: rgba(45, 130, 133, 0.88);
    box-shadow: 0 18px 60px rgba(45, 130, 133, 0.38);
}

.player-overlay button span {
    width: 0;
    height: 0;
    margin-left: 0.35rem;
    border-top: 0.9rem solid transparent;
    border-bottom: 0.9rem solid transparent;
    border-left: 1.35rem solid #ffffff;
}

.content-card h2 {
    margin: 0 0 0.8rem;
    font-size: 1.35rem;
}

.content-card p {
    margin: 0;
    color: #d9e6f2;
    line-height: 1.9;
}

.info-card dl {
    display: grid;
    gap: 0.8rem;
    margin: 0;
}

.info-card div {
    display: grid;
    grid-template-columns: 4rem minmax(0, 1fr);
    gap: 0.8rem;
    border-bottom: 1px solid rgba(51, 78, 104, 0.72);
    padding-bottom: 0.8rem;
}

.info-card dt {
    color: #9fb3c8;
}

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

.site-footer {
    border-top: 1px solid rgba(51, 78, 104, 0.84);
    background: rgba(8, 25, 40, 0.9);
}

.footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    width: min(1200px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 2rem 0;
    color: #bcccdc;
}

.footer-inner nav {
    display: flex;
    gap: 1rem;
}

.footer-inner a:hover {
    color: #7bb8ba;
}

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

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

    .menu-button {
        display: flex;
        margin-left: auto;
    }

    .hero-search-card {
        left: 1rem;
        right: 1rem;
        bottom: 4.8rem;
        width: auto;
    }

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

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

    .ranking-panel {
        position: static;
    }
}

@media (max-width: 760px) {
    .hero-section {
        min-height: 720px;
    }

    .hero-content {
        padding-top: 4.5rem;
        padding-bottom: 13rem;
    }

    .hero-content h1,
    .page-hero h1,
    .detail-copy h1 {
        font-size: clamp(2.25rem, 13vw, 4rem);
    }

    .section-wrap {
        padding: 2.7rem 0;
    }

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

    .category-grid,
    .movie-grid,
    .category-overview-grid,
    .rank-page-list,
    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .detail-hero {
        grid-template-columns: 1fr;
        padding-top: 2.4rem;
    }

    .detail-poster {
        max-width: 320px;
    }

    .page-filter,
    .hero-search-card form {
        border-radius: 1rem;
    }

    .rank-item a {
        grid-template-columns: 2.1rem 3rem minmax(0, 1fr);
    }
}

@media (max-width: 520px) {
    .header-inner {
        min-height: 64px;
    }

    .site-logo span:last-child {
        font-size: 0.96rem;
    }

    .hero-section {
        min-height: 760px;
    }

    .hero-actions,
    .detail-actions,
    .page-filter,
    .hero-search-card form {
        flex-direction: column;
    }

    .page-filter button,
    .hero-search-card button {
        width: 100%;
    }

    .category-grid,
    .movie-grid,
    .category-overview-grid,
    .rank-page-list,
    .feature-grid {
        grid-template-columns: 1fr;
    }

    .poster-wrap {
        aspect-ratio: 2 / 2.6;
    }

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