:root {
    --cyan: #0891b2;
    --cyan-dark: #0e7490;
    --teal: #0d9488;
    --emerald: #059669;
    --ink: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --soft: #f8fafc;
    --white: #ffffff;
    --shadow: 0 20px 55px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--ink);
    background: linear-gradient(180deg, #f8fafc 0%, #eef9fb 48%, #f8fafc 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
    backdrop-filter: blur(14px);
}

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

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 800;
    color: var(--cyan-dark);
    white-space: nowrap;
}

.logo-mark {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--emerald));
    box-shadow: 0 10px 25px rgba(8, 145, 178, 0.25);
    font-size: 14px;
}

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

.nav-link,
.mobile-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border-radius: 12px;
    color: #374151;
    font-weight: 650;
    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: #fff;
    background: var(--cyan);
}

.nav-search {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 8px;
}

.nav-search input {
    width: 150px;
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 9px 13px;
    outline: none;
    background: #f9fafb;
}

.nav-search input:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(8, 145, 178, 0.12);
}

.nav-search button,
.btn,
.search-box button {
    border: 0;
    border-radius: 999px;
    padding: 10px 18px;
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--teal));
    font-weight: 750;
    cursor: pointer;
    box-shadow: 0 12px 24px rgba(8, 145, 178, 0.22);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.nav-search button:hover,
.btn:hover,
.search-box button:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 30px rgba(8, 145, 178, 0.28);
}

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

.btn-ghost {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: none;
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.menu-toggle {
    display: none;
    margin-left: auto;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 12px;
    background: #eef9fb;
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: var(--cyan-dark);
    border-radius: 999px;
}

.mobile-menu {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 10px;
    border-top: 1px solid var(--line);
}

.mobile-menu.is-open {
    display: grid;
    gap: 6px;
}

.hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background: radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.22), transparent 28%), linear-gradient(135deg, #0891b2 0%, #0d9488 48%, #059669 100%);
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.13);
    filter: blur(4px);
}

.hero::before {
    width: 280px;
    height: 280px;
    right: 10%;
    top: 8%;
}

.hero::after {
    width: 220px;
    height: 220px;
    left: 4%;
    bottom: 8%;
}

.hero-inner {
    position: relative;
    z-index: 1;
    width: min(1180px, calc(100% - 32px));
    min-height: 640px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
    gap: 52px;
    align-items: center;
    padding: 70px 0;
}

.hero-content h1 {
    margin: 0 0 18px;
    font-size: clamp(42px, 6vw, 74px);
    line-height: 1.03;
    letter-spacing: -0.04em;
}

.hero-content h1 span {
    display: block;
    color: #cffafe;
}

.hero-content p {
    margin: 0 0 28px;
    max-width: 720px;
    color: #ecfeff;
    font-size: 19px;
}

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

.search-box {
    max-width: 620px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
}

.search-box input {
    border: 0;
    border-radius: 999px;
    padding: 0 16px;
    color: #fff;
    background: transparent;
    outline: none;
}

.search-box input::placeholder {
    color: rgba(255, 255, 255, 0.75);
}

.hero-slider {
    position: relative;
}

.hero-slide {
    display: none;
    animation: fadeUp 0.45s ease both;
}

.hero-slide.is-active {
    display: block;
}

.hero-card {
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 32px;
    background: rgba(255, 255, 255, 0.14);
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.26);
    backdrop-filter: blur(16px);
}

.hero-poster {
    position: relative;
    height: 420px;
    overflow: hidden;
}

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

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 30%, rgba(0, 0, 0, 0.72) 100%);
}

.hero-caption {
    position: absolute;
    left: 24px;
    right: 24px;
    bottom: 22px;
    z-index: 1;
}

.hero-caption h2 {
    margin: 0 0 8px;
    font-size: 30px;
    line-height: 1.18;
}

.hero-caption p {
    margin: 0;
    color: #e0f2fe;
}

.hero-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 22px 22px;
}

.hero-dots {
    display: flex;
    gap: 8px;
    margin-top: 18px;
    justify-content: center;
}

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

.hero-dot.is-active {
    width: 28px;
    background: #fff;
}

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

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

.section-title h1,
.section-title h2 {
    margin: 0;
    font-size: clamp(28px, 4vw, 42px);
    line-height: 1.15;
}

.section-title p {
    margin: 8px 0 0;
    color: var(--muted);
    max-width: 680px;
}

.text-link {
    color: var(--cyan-dark);
    font-weight: 800;
}

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

.category-card {
    min-height: 178px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px;
    border-radius: var(--radius);
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--teal));
    box-shadow: var(--shadow);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:nth-child(2n) {
    background: linear-gradient(135deg, var(--teal), var(--emerald));
}

.category-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.18);
}

.category-card h2,
.category-card h3 {
    margin: 0 0 8px;
    font-size: 24px;
}

.category-card p {
    margin: 0;
    color: #ecfeff;
}

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

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

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

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

.poster-play,
.rank-badge {
    position: absolute;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.poster-play {
    right: 14px;
    bottom: 14px;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    color: var(--cyan-dark);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.18);
}

.rank-badge {
    top: 12px;
    left: 12px;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    border-radius: 999px;
    color: #fff;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    font-weight: 850;
}

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

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--cyan-dark);
    font-size: 13px;
    font-weight: 750;
}

.movie-card h3 {
    margin: 0 0 10px;
    font-size: 19px;
    line-height: 1.3;
}

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

.movie-card p {
    min-height: 54px;
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 14px;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.tag-row span,
.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 10px;
    color: var(--cyan-dark);
    background: #ecfeff;
    font-size: 12px;
    font-weight: 750;
}

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

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

.movie-card-compact h3 {
    font-size: 17px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 180px;
    gap: 12px;
    margin: 0 0 26px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 12px 14px;
    color: var(--ink);
    background: #fff;
    outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 4px rgba(8, 145, 178, 0.12);
}

.empty-state {
    padding: 24px;
    border-radius: 18px;
    color: var(--muted);
    background: #fff;
    text-align: center;
}

.page-hero,
.detail-hero {
    color: #fff;
    background: linear-gradient(135deg, #0891b2, #0d9488 54%, #059669);
}

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

.page-hero h1,
.detail-copy h1 {
    margin: 0 0 14px;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.08;
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 22px;
    color: #e0f2fe;
    font-size: 14px;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 36px;
    align-items: center;
}

.detail-poster {
    overflow: hidden;
    border-radius: 28px;
    box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

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

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 0;
}

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

.player-section h2,
.content-section h2,
.related-section h2 {
    margin: 0 0 20px;
    font-size: clamp(26px, 4vw, 36px);
}

.player-wrap {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #020617;
    box-shadow: 0 30px 90px rgba(2, 6, 23, 0.26);
}

.movie-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: #fff;
    background: radial-gradient(circle at center, rgba(8, 145, 178, 0.3), rgba(2, 6, 23, 0.72));
    cursor: pointer;
    transition: opacity 0.2s ease;
}

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

.player-icon {
    width: 84px;
    height: 84px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: var(--cyan-dark);
    background: #fff;
    font-size: 30px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

.player-title {
    font-size: 20px;
    font-weight: 800;
}

.content-box {
    display: grid;
    gap: 24px;
    padding: 28px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

.content-box p {
    margin: 0;
    color: #374151;
    font-size: 17px;
}

.site-footer {
    margin-top: 70px;
    color: #d1d5db;
    background: #111827;
}

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

.footer-logo {
    color: #fff;
    margin-bottom: 16px;
}

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

.site-footer p {
    max-width: 430px;
    margin: 0;
    color: #9ca3af;
}

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

.site-footer a:hover {
    color: #22d3ee;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding: 18px 16px;
    text-align: center;
    color: #9ca3af;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(14px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 980px) {
    .nav-links,
    .nav-search {
        display: none;
    }

    .menu-toggle {
        display: block;
    }

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

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

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

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

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

@media (max-width: 620px) {
    .site-nav {
        height: 64px;
    }

    .site-logo,
    .footer-logo {
        font-size: 19px;
    }

    .hero-inner {
        min-height: auto;
        padding: 46px 0;
        gap: 34px;
    }

    .search-box {
        grid-template-columns: 1fr;
        border-radius: 24px;
    }

    .search-box input {
        min-height: 46px;
    }

    .hero-poster {
        height: 340px;
    }

    .hero-card-footer,
    .section-title {
        align-items: flex-start;
        flex-direction: column;
    }

    .category-grid,
    .movie-grid,
    .ranking-list {
        grid-template-columns: 1fr;
    }

    .section,
    .player-section,
    .content-section,
    .related-section {
        padding-top: 44px;
    }
}
