:root {
    --cyan: #06b6d4;
    --cyan-dark: #0891b2;
    --blue: #2563eb;
    --pink: #db2777;
    --yellow: #facc15;
    --text: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --panel: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.14);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background: linear-gradient(135deg, #ecfeff 0%, #ffffff 48%, #fdf2f8 100%);
    min-height: 100vh;
}

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

img,
video {
    display: block;
    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: linear-gradient(90deg, rgba(236, 254, 255, 0.96), rgba(239, 246, 255, 0.96), rgba(253, 242, 248, 0.96));
    backdrop-filter: blur(16px);
    box-shadow: 0 10px 28px rgba(8, 15, 30, 0.08);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.brand-icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 14px;
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--pink));
    box-shadow: 0 10px 24px rgba(6, 182, 212, 0.3);
}

.brand-name {
    font-size: 1.28rem;
    background: linear-gradient(90deg, var(--cyan-dark), var(--pink));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

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

.desktop-nav a,
.mobile-nav a {
    font-weight: 700;
    color: #374151;
    transition: color 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
    color: var(--cyan-dark);
}

.top-search,
.mobile-search {
    display: flex;
    align-items: center;
}

.top-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select,
.search-page-form input {
    border: 1px solid #d1d5db;
    outline: none;
    background: rgba(255, 255, 255, 0.88);
    color: var(--text);
}

.top-search input {
    width: 235px;
    padding: 10px 14px;
    border-radius: 999px 0 0 999px;
}

.top-search button,
.mobile-search button,
.search-page-form button {
    border: 0;
    color: white;
    background: var(--cyan);
    padding: 11px 18px;
    border-radius: 0 999px 999px 0;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.top-search button:hover,
.mobile-search button:hover,
.search-page-form button:hover {
    background: var(--cyan-dark);
}

.menu-toggle {
    display: none;
    border: 0;
    background: transparent;
    font-size: 1.7rem;
    color: #374151;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
    border-top: 1px solid rgba(148, 163, 184, 0.28);
}

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

.mobile-nav nav {
    display: grid;
    gap: 12px;
    padding: 16px 0;
}

.mobile-search input {
    flex: 1;
    padding: 10px 14px;
    border-radius: 999px 0 0 999px;
}

.home-hero {
    position: relative;
    min-height: 600px;
    overflow: hidden;
    background: #020617;
}

.hero-title-card {
    position: absolute;
    z-index: 4;
    top: 34px;
    left: max(24px, calc((100% - 1180px) / 2));
    max-width: 440px;
    color: #fff;
    padding: 20px 22px;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 28px;
    background: rgba(15, 23, 42, 0.34);
    backdrop-filter: blur(16px);
}

.hero-title-card p,
.section-head p,
.page-hero p {
    margin: 0 0 8px;
    color: var(--cyan);
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-title-card h1 {
    margin: 0 0 8px;
    font-size: clamp(2.2rem, 5vw, 4.6rem);
    line-height: 1;
}

.hero-title-card span {
    display: block;
    color: #dbeafe;
    line-height: 1.7;
}

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

.hero-slide {
    display: grid;
    align-items: end;
    opacity: 0;
    visibility: hidden;
    background-size: cover;
    background-position: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
}

.hero-content {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 82px;
    color: #fff;
}

.hero-kicker {
    display: inline-flex;
    margin: 0 0 16px;
    color: var(--yellow);
    font-weight: 900;
}

.hero-content h2 {
    margin: 0;
    max-width: 780px;
    font-size: clamp(2.4rem, 5.8vw, 5.2rem);
    line-height: 1.05;
    letter-spacing: -0.05em;
}

.hero-summary {
    max-width: 780px;
    margin: 18px 0 0;
    color: #e5e7eb;
    font-size: 1.12rem;
    line-height: 1.8;
}

.hero-tags,
.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.hero-tags span,
.tag-list span {
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
    font-size: 0.9rem;
}

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

.btn-primary,
.btn-glass,
.btn-light,
.btn-card {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 22px;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
    color: #fff;
    background: var(--cyan);
    box-shadow: 0 15px 30px rgba(6, 182, 212, 0.28);
}

.btn-primary:hover,
.btn-card:hover {
    transform: translateY(-2px) scale(1.02);
    background: var(--cyan-dark);
}

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

.btn-light {
    color: var(--cyan-dark);
    background: #fff;
    box-shadow: var(--shadow);
}

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

.hero-dots button {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.55);
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
    width: 34px;
    background: #fff;
}

.category-strip {
    padding: 26px 0 10px;
}

.chip-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
}

.chip-row a {
    padding: 10px 18px;
    border-radius: 999px;
    color: #374151;
    background: #fff;
    box-shadow: 0 8px 25px rgba(15, 23, 42, 0.08);
    font-weight: 800;
    transition: transform 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.chip-row a:hover {
    color: #fff;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
    transform: translateY(-2px);
}

.section-block {
    padding: 54px 0;
}

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

.section-head h2 {
    margin: 0;
    font-size: clamp(1.7rem, 3vw, 2.4rem);
    letter-spacing: -0.03em;
}

.section-head a {
    color: var(--cyan-dark);
    font-weight: 900;
}

.movie-grid {
    display: grid;
    gap: 22px;
}

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

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

.movie-card {
    display: block;
    overflow: hidden;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, #dbeafe, #ecfeff);
}

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

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

.poster-year,
.poster-play {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    font-weight: 900;
}

.poster-year {
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    background: rgba(2, 6, 23, 0.72);
    font-size: 0.82rem;
}

.poster-play {
    right: 12px;
    bottom: 12px;
    width: 40px;
    height: 40px;
    background: rgba(6, 182, 212, 0.9);
    box-shadow: 0 10px 20px rgba(6, 182, 212, 0.28);
}

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

.movie-card-body h3 {
    margin: 0 0 10px;
    font-size: 1.05rem;
    line-height: 1.35;
    transition: color 0.2s ease;
}

.movie-card:hover h3 {
    color: var(--cyan-dark);
}

.movie-card-body p {
    margin: 0 0 14px;
    color: var(--muted);
    line-height: 1.7;
    font-size: 0.94rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: #64748b;
    font-size: 0.82rem;
}

.movie-card-large .poster-frame {
    aspect-ratio: 16 / 9;
}

.movie-card-large .movie-card-body h3 {
    font-size: 1.28rem;
}

.movie-card-horizontal {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr);
    border-radius: 20px;
}

.movie-card-horizontal .poster-frame {
    height: 100%;
    min-height: 145px;
    aspect-ratio: auto;
}

.horizontal-list {
    display: grid;
    gap: 16px;
}

.wide-panel {
    padding: 54px 0;
    background: rgba(255, 255, 255, 0.82);
}

.explore-banner {
    padding: 74px 0;
    color: #fff;
    text-align: center;
    background: linear-gradient(135deg, var(--cyan-dark), var(--blue));
}

.explore-banner h2 {
    margin: 0 0 12px;
    font-size: clamp(2rem, 4vw, 3rem);
}

.explore-banner p {
    margin: 0 auto 26px;
    max-width: 680px;
    color: #cffafe;
    line-height: 1.8;
}

.sub-page {
    min-height: 70vh;
}

.page-hero {
    padding: 74px 0;
    color: #fff;
    background: linear-gradient(135deg, #0f172a, #0e7490 52%, #1d4ed8);
}

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

.page-hero span {
    display: block;
    max-width: 760px;
    color: #dbeafe;
    line-height: 1.8;
}

.category-overview,
.filter-section,
.rank-list,
.search-results-section,
.detail-wrap {
    padding: 42px 0 64px;
}

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

.category-card {
    min-height: 320px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 24px;
    border-radius: 28px;
    color: #fff;
    background-size: cover;
    background-position: center;
    box-shadow: var(--shadow);
    overflow: hidden;
}

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

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

.category-samples {
    display: grid;
    gap: 8px;
    margin-bottom: 18px;
}

.category-samples a {
    color: #cffafe;
    font-size: 0.94rem;
}

.btn-card {
    align-self: flex-start;
    color: #fff;
    background: var(--cyan);
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    align-items: center;
    margin-bottom: 24px;
    color: #64748b;
    font-size: 0.95rem;
}

.breadcrumb a {
    color: var(--cyan-dark);
    font-weight: 800;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px;
    gap: 14px;
    padding: 18px;
    margin-bottom: 28px;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
}

.empty-state {
    padding: 42px;
    text-align: center;
    color: #64748b;
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.08);
}

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

.rank-card {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr);
    align-items: stretch;
    gap: 16px;
}

.rank-num {
    display: grid;
    place-items: center;
    border-radius: 20px;
    color: #fff;
    font-size: 1.6rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--cyan), var(--pink));
    box-shadow: 0 12px 26px rgba(6, 182, 212, 0.22);
}

.search-page-form {
    display: flex;
    max-width: 680px;
    margin-top: 24px;
}

.search-page-form input {
    flex: 1;
    padding: 15px 18px;
    border-radius: 999px 0 0 999px;
}

.search-page-form button {
    padding: 15px 28px;
}

.detail-page {
    background: linear-gradient(135deg, #f8fafc, #ecfeff);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 370px;
    gap: 30px;
}

.detail-main,
.detail-side {
    min-width: 0;
}

.player-card,
.detail-info,
.content-card,
.side-card {
    border-radius: 28px;
    background: #fff;
    box-shadow: var(--shadow);
}

.player-card {
    padding: 14px;
}

.player-box {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: 20px;
    background: #020617;
}

.player-box video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.1), rgba(2, 6, 23, 0.58));
    transition: opacity 0.25s ease, visibility 0.25s ease;
    pointer-events: none;
}

.player-box.is-started .player-cover {
    opacity: 0;
    visibility: hidden;
}

.play-trigger {
    pointer-events: auto;
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border: 0;
    border-radius: 50%;
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 20px 40px rgba(6, 182, 212, 0.32);
    font-size: 2rem;
    cursor: pointer;
}

.detail-info,
.content-card,
.side-card {
    padding: 26px;
    margin-top: 22px;
}

.detail-info h1 {
    margin: 0 0 14px;
    font-size: clamp(1.9rem, 3vw, 3rem);
    line-height: 1.18;
}

.detail-lead {
    margin: 0 0 20px;
    color: #4b5563;
    font-size: 1.05rem;
    line-height: 1.85;
}

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

.detail-meta-grid div {
    padding: 14px;
    border-radius: 18px;
    background: #f8fafc;
}

.detail-meta-grid span {
    display: block;
    color: #64748b;
    font-size: 0.84rem;
    margin-bottom: 6px;
}

.detail-meta-grid strong {
    font-size: 1rem;
}

.detail-info .tag-list span {
    color: var(--cyan-dark);
    background: #ecfeff;
}

.content-card h2,
.side-card h2 {
    margin: 0 0 14px;
    font-size: 1.55rem;
}

.content-card p {
    margin: 0;
    color: #4b5563;
    line-height: 1.9;
    white-space: pre-line;
}

.detail-side {
    position: relative;
}

.side-card {
    position: sticky;
    top: 104px;
    margin-top: 0;
}

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

.side-list .movie-card {
    border-radius: 18px;
}

.side-list .poster-frame {
    aspect-ratio: 16 / 9;
}

.site-footer {
    color: #e5e7eb;
    background: linear-gradient(135deg, #111827, #172554, #111827);
}

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

.footer-brand {
    color: #fff;
    margin-bottom: 14px;
}

.footer-inner p {
    max-width: 430px;
    color: #cbd5e1;
    line-height: 1.8;
}

.footer-inner h2 {
    margin: 0 0 14px;
    color: #fff;
    font-size: 1.1rem;
}

.footer-links {
    display: grid;
    gap: 10px;
}

.footer-links a {
    color: #cbd5e1;
    transition: color 0.2s ease;
}

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

.footer-copy {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 20px 0 28px;
    border-top: 1px solid rgba(148, 163, 184, 0.25);
    color: #94a3b8;
    text-align: center;
}

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

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

    .home-hero {
        min-height: 540px;
    }

    .hero-title-card {
        top: 20px;
        left: 16px;
        right: 16px;
        max-width: none;
    }

    .hero-content {
        padding-bottom: 68px;
    }

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

    .detail-layout,
    .footer-inner {
        grid-template-columns: 1fr;
    }

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

    .side-card {
        position: static;
    }
}

@media (max-width: 680px) {
    .header-inner {
        height: 68px;
    }

    .brand-name {
        font-size: 1.08rem;
    }

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

    .hero-title-card {
        padding: 16px;
        border-radius: 22px;
    }

    .hero-content {
        padding: 210px 0 70px;
    }

    .hero-summary {
        font-size: 1rem;
    }

    .section-head,
    .rank-card {
        display: block;
    }

    .section-head a {
        display: inline-flex;
        margin-top: 10px;
    }

    .movie-grid-4,
    .movie-grid-3,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .movie-card-horizontal {
        grid-template-columns: 1fr;
    }

    .filter-panel {
        grid-template-columns: 1fr;
    }

    .rank-num {
        height: 56px;
        margin-bottom: 12px;
    }

    .search-page-form {
        display: grid;
        gap: 10px;
    }

    .search-page-form input,
    .search-page-form button {
        border-radius: 999px;
    }

    .detail-meta-grid {
        grid-template-columns: 1fr;
    }

    .player-card,
    .detail-info,
    .content-card,
    .side-card {
        border-radius: 22px;
        padding: 18px;
    }
}
