:root {
    --deepblue-950: #000c13;
    --deepblue-900: #00151f;
    --deepblue-800: #002d3d;
    --deepblue-700: #00445a;
    --ocean-50: #e6f7f9;
    --ocean-100: #cceef3;
    --ocean-300: #66cbdb;
    --ocean-500: #00a9c3;
    --ocean-600: #00879c;
    --ocean-700: #006575;
    --ocean-800: #00444e;
    --coral-50: #fff0ed;
    --coral-400: #ff876f;
    --coral-500: #ff694b;
    --coral-600: #cc543c;
    --seagreen-50: #e8f5f1;
    --seagreen-100: #d1ebe3;
    --seagreen-600: #147c5c;
    --seagreen-700: #0f5d45;
    --sand-50: #faf8f4;
    --sand-100: #f5f1e9;
    --sand-200: #ebe3d3;
    --sand-800: #524a3a;
    --white: #ffffff;
    --shadow-ocean: 0 18px 45px rgba(0, 68, 78, 0.13);
    --shadow-ocean-lg: 0 25px 70px rgba(0, 68, 78, 0.21);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--deepblue-900);
    background:
        radial-gradient(circle at 10% 0%, rgba(0, 169, 195, 0.16), transparent 28rem),
        linear-gradient(180deg, var(--ocean-50) 0%, var(--sand-50) 100%);
}

body.nav-open {
    overflow: hidden;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(0, 21, 31, 0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

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

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--white);
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.logo-icon {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--coral-500), var(--ocean-500));
    box-shadow: 0 12px 30px rgba(255, 105, 75, 0.32);
    font-size: 14px;
}

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

.nav-link {
    color: var(--ocean-50);
    padding: 10px 15px;
    border-radius: 12px;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.11);
    transform: translateY(-1px);
}

.header-search {
    display: flex;
    align-items: center;
    width: 280px;
    padding: 4px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 14px;
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    color: var(--white);
    background: transparent;
    padding: 8px 10px;
}

.header-search input::placeholder {
    color: rgba(230, 247, 249, 0.72);
}

.header-search button,
.primary-button,
.ghost-button,
.section-more {
    border: 0;
    cursor: pointer;
    border-radius: 999px;
    font-weight: 700;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.header-search button,
.primary-button {
    color: var(--white);
    background: var(--coral-500);
    box-shadow: 0 14px 30px rgba(255, 105, 75, 0.26);
}

.header-search button {
    padding: 8px 14px;
}

.primary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 24px;
}

.primary-button:hover,
.header-search button:hover {
    background: var(--coral-600);
    transform: translateY(-2px);
}

.ghost-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.36);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
}

.ghost-button:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: translateY(-2px);
}

.mobile-nav-button {
    display: none;
    color: var(--white);
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 12px;
    padding: 9px 12px;
}

.hero {
    position: relative;
    height: min(72vh, 760px);
    min-height: 520px;
    overflow: hidden;
    color: var(--white);
    background: linear-gradient(180deg, var(--deepblue-900), var(--ocean-800));
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: none;
}

.hero-slide.is-active {
    display: block;
    animation: heroFade 0.75s ease both;
}

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.42;
    transform: scale(1.03);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 78% 28%, rgba(255, 105, 75, 0.28), transparent 22rem),
        linear-gradient(90deg, rgba(0, 21, 31, 0.96), rgba(0, 21, 31, 0.68) 42%, rgba(0, 21, 31, 0.12)),
        linear-gradient(0deg, var(--deepblue-900), transparent 45%);
}

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

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    color: var(--coral-400);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.hero h1 {
    max-width: 760px;
    margin: 16px 0 12px;
    font-size: clamp(2.1rem, 5vw, 4.9rem);
    line-height: 1.03;
    letter-spacing: -0.04em;
}

.hero h2 {
    margin: 0 0 14px;
    color: var(--ocean-100);
    font-size: clamp(1.3rem, 2.8vw, 2.4rem);
}

.hero p {
    max-width: 700px;
    color: var(--ocean-50);
    margin: 0 0 24px;
    font-size: clamp(1rem, 1.6vw, 1.25rem);
    line-height: 1.8;
}

.hero-tags,
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 26px;
}

.hero-tags span {
    padding: 9px 14px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(0, 135, 156, 0.28);
    border: 1px solid rgba(102, 203, 219, 0.36);
    backdrop-filter: blur(10px);
}

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

.hero-dot {
    width: 42px;
    height: 5px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.28);
    cursor: pointer;
}

.hero-dot.is-active {
    background: var(--coral-500);
}

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

.section-tight {
    padding-top: 42px;
}

.section-stack {
    display: grid;
    gap: 34px;
}

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

.section-head h2,
.category-overview-head h2 {
    margin: 6px 0 0;
    font-size: clamp(1.55rem, 3vw, 2.35rem);
    color: var(--deepblue-900);
}

.section-head p,
.category-overview-head p {
    margin: 8px 0 0;
    color: var(--ocean-700);
    line-height: 1.7;
}

.small-head h2 {
    font-size: 1.8rem;
}

.section-more {
    flex: 0 0 auto;
    color: var(--ocean-600);
    background: var(--white);
    padding: 10px 16px;
    box-shadow: 0 8px 26px rgba(0, 68, 78, 0.1);
}

.section-more:hover {
    color: var(--coral-500);
    transform: translateY(-2px);
}

.feature-panel,
.ranking-panel,
.latest-panel,
.category-overview-block,
.detail-card,
.side-card {
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 30px;
    box-shadow: var(--shadow-ocean);
}

.feature-panel,
.category-overview-block {
    padding: 34px;
}

.card-grid {
    display: grid;
    gap: 24px;
}

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

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

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

.movie-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    background: var(--white);
    border-radius: 20px;
    box-shadow: 0 10px 26px rgba(0, 68, 78, 0.1);
    transform: translateY(0);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-ocean-lg);
}

.poster-wrap {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, var(--deepblue-800), var(--ocean-600));
}

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

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

.poster-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 21, 31, 0.72), transparent 58%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

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

.play-mark,
.big-play {
    display: inline-grid;
    place-items: center;
    color: var(--white);
    background: var(--coral-500);
    box-shadow: 0 14px 34px rgba(255, 105, 75, 0.3);
}

.play-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    transform: translate(-50%, -50%) scale(0.78);
    opacity: 0;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.duration-badge,
.rank-badge {
    position: absolute;
    color: var(--white);
    background: rgba(0, 21, 31, 0.88);
    backdrop-filter: blur(10px);
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 700;
}

.duration-badge {
    top: 12px;
    right: 12px;
    padding: 5px 9px;
}

.rank-badge {
    left: 12px;
    top: 12px;
    min-width: 31px;
    height: 31px;
    display: inline-grid;
    place-items: center;
    background: var(--coral-500);
}

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

.card-title {
    color: var(--deepblue-900);
    font-size: 1.05rem;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-desc {
    color: var(--ocean-700);
    line-height: 1.58;
    font-size: 0.92rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--ocean-700);
    font-size: 0.78rem;
}

.card-meta span {
    padding: 5px 8px;
    border-radius: 999px;
    background: var(--ocean-50);
}

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

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

.category-card {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    border-radius: 26px;
    background: var(--deepblue-800);
    box-shadow: var(--shadow-ocean);
}

.category-card img {
    width: 100%;
    height: 100%;
    min-height: 210px;
    object-fit: cover;
    opacity: 0.72;
    transition: transform 0.45s ease;
}

.category-mask {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 75% 20%, rgba(255, 105, 75, 0.36), transparent 12rem),
        linear-gradient(0deg, rgba(0, 21, 31, 0.88), rgba(0, 21, 31, 0.12));
}

.category-content {
    position: absolute;
    inset: auto 18px 18px 18px;
    color: var(--white);
}

.category-content strong {
    display: block;
    font-size: 1.28rem;
    margin-bottom: 8px;
}

.category-content span {
    color: var(--ocean-50);
    line-height: 1.5;
    font-size: 0.93rem;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
    gap: 28px;
    align-items: start;
}

.ranking-panel,
.latest-panel {
    padding: 28px;
}

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

.movie-card-wide {
    display: grid;
    grid-template-columns: 168px minmax(0, 1fr);
    align-items: stretch;
}

.movie-card-wide .poster-wrap {
    height: 100%;
    min-height: 132px;
    aspect-ratio: auto;
}

.movie-card-wide .card-body {
    justify-content: center;
}

.page-hero {
    color: var(--white);
    background:
        radial-gradient(circle at 84% 20%, rgba(255, 105, 75, 0.35), transparent 18rem),
        linear-gradient(135deg, var(--deepblue-900), var(--ocean-800));
}

.slim-hero {
    padding: 78px 0;
}

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

.page-hero h1 {
    margin: 14px 0 14px;
    font-size: clamp(2.2rem, 5vw, 4rem);
    line-height: 1.1;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: var(--ocean-50);
    font-size: 1.08rem;
    line-height: 1.8;
}

.filter-panel,
.search-panel {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 18px;
    margin-bottom: 28px;
    background: rgba(255, 255, 255, 0.84);
    border-radius: 22px;
    box-shadow: var(--shadow-ocean);
}

.filter-panel input,
.filter-panel select,
.search-panel input {
    width: 100%;
    border: 1px solid rgba(0, 101, 117, 0.18);
    color: var(--deepblue-900);
    background: var(--white);
    border-radius: 14px;
    padding: 13px 15px;
    outline: 0;
}

.filter-panel select {
    max-width: 180px;
}

.search-panel input {
    flex: 1;
}

.empty-state {
    text-align: center;
    color: var(--ocean-700);
    padding: 42px;
    background: var(--white);
    border-radius: 20px;
    box-shadow: var(--shadow-ocean);
}

.player-section {
    padding: 34px 0;
    background: linear-gradient(180deg, var(--deepblue-900), var(--deepblue-800));
}

.player-wrap {
    position: relative;
    width: min(1120px, calc(100% - 32px));
    aspect-ratio: 16 / 9;
    margin: 0 auto;
    overflow: hidden;
    background: #000000;
    border-radius: 26px;
    box-shadow: 0 28px 90px rgba(0, 0, 0, 0.38);
}

.video-core {
    width: 100%;
    height: 100%;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    overflow: hidden;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: #000000;
}

.player-cover[hidden] {
    display: none;
}

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.56;
}

.player-overlay {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 50% 42%, rgba(255, 105, 75, 0.25), transparent 18rem),
        linear-gradient(0deg, rgba(0, 21, 31, 0.88), rgba(0, 21, 31, 0.1));
}

.big-play {
    position: relative;
    z-index: 2;
    width: 82px;
    height: 82px;
    border-radius: 999px;
    font-size: 30px;
}

.player-title {
    position: absolute;
    left: 30px;
    right: 30px;
    bottom: 24px;
    z-index: 2;
    color: var(--white);
    font-size: clamp(1.4rem, 4vw, 2.5rem);
    font-weight: 800;
    text-align: left;
}

.player-message {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: var(--white);
    background: rgba(0, 21, 31, 0.92);
    font-weight: 700;
    text-align: center;
    padding: 24px;
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 9px;
    color: var(--ocean-700);
    margin-bottom: 18px;
}

.breadcrumb a:hover {
    color: var(--coral-500);
}

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

.detail-card h1 {
    margin: 0 0 16px;
    font-size: clamp(1.9rem, 4vw, 3rem);
    line-height: 1.16;
}

.detail-card h2,
.side-card h2 {
    margin: 28px 0 12px;
    color: var(--deepblue-900);
}

.detail-card p,
.side-card p {
    color: var(--ocean-800);
    line-height: 1.9;
}

.detail-meta,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
}

.detail-meta span,
.tag-pill {
    color: var(--ocean-700);
    background: var(--ocean-50);
    border-radius: 999px;
    padding: 8px 12px;
    font-size: 0.9rem;
    font-weight: 700;
}

.tag-pill:hover {
    color: var(--white);
    background: var(--ocean-600);
}

.detail-poster {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--deepblue-800), var(--ocean-600));
}

.full-button {
    width: 100%;
    margin-top: 18px;
}

.compact-list .movie-card-wide {
    grid-template-columns: 108px minmax(0, 1fr);
}

.compact-list .movie-card-wide .poster-wrap {
    min-height: 96px;
}

.compact-list .card-desc,
.compact-list .card-meta {
    display: none;
}

.site-footer {
    color: var(--ocean-100);
    background: var(--deepblue-900);
    margin-top: 30px;
    padding: 54px 0 24px;
}

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

.site-footer h3 {
    margin: 0 0 15px;
    color: var(--white);
}

.site-footer p {
    color: var(--ocean-300);
    line-height: 1.8;
}

.site-footer a,
.site-footer span {
    display: block;
    color: var(--ocean-300);
    margin: 9px 0;
}

.site-footer a:hover {
    color: var(--coral-400);
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 34px auto 0;
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--ocean-300);
    font-size: 0.92rem;
}

@keyframes heroFade {
    from {
        opacity: 0;
        transform: scale(1.02);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 1060px) {
    .header-search {
        width: 220px;
    }

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

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

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

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

@media (max-width: 820px) {
    .header-inner {
        height: auto;
        min-height: 66px;
        flex-wrap: wrap;
        padding: 12px 0;
    }

    .mobile-nav-button {
        display: inline-flex;
        margin-left: auto;
    }

    .site-nav {
        display: none;
        width: 100%;
        order: 4;
        flex-direction: column;
        align-items: stretch;
        background: rgba(255, 255, 255, 0.08);
        border-radius: 16px;
        padding: 10px;
    }

    .site-nav.is-open {
        display: flex;
    }

    .header-search {
        order: 3;
        width: 100%;
    }

    .hero {
        min-height: 620px;
        height: auto;
    }

    .hero-content {
        padding: 86px 0 96px;
    }

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

    .filter-panel,
    .search-panel {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-panel select {
        max-width: none;
    }

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

@media (max-width: 560px) {
    .grid-2,
    .grid-3,
    .grid-4,
    .category-grid,
    .category-grid-large,
    .detail-side {
        grid-template-columns: 1fr;
    }

    .section,
    .page-hero > div,
    .hero-content,
    .header-inner,
    .footer-grid,
    .footer-bottom {
        width: min(100% - 24px, 1180px);
    }

    .section {
        padding: 38px 0;
    }

    .feature-panel,
    .ranking-panel,
    .latest-panel,
    .category-overview-block,
    .detail-card,
    .side-card {
        padding: 20px;
        border-radius: 22px;
    }

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

    .movie-card-wide {
        grid-template-columns: 118px minmax(0, 1fr);
    }

    .movie-card-wide .poster-wrap {
        min-height: 124px;
    }

    .player-wrap {
        width: min(100% - 24px, 1120px);
        border-radius: 18px;
    }

    .player-title {
        left: 18px;
        right: 18px;
        bottom: 18px;
    }

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