:root {
    --sky-50: #f0f9ff;
    --sky-100: #e0f2fe;
    --sky-500: #0ea5e9;
    --sky-600: #0284c7;
    --blue-50: #eff6ff;
    --blue-100: #dbeafe;
    --blue-600: #2563eb;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-900: #0f172a;
    --white: #ffffff;
    --shadow-sm: 0 10px 30px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 25px 70px rgba(15, 23, 42, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--slate-900);
    background: linear-gradient(180deg, var(--sky-50), var(--white) 42%, var(--blue-50));
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid rgba(14, 165, 233, 0.16);
    background: rgba(240, 249, 255, 0.88);
    backdrop-filter: blur(18px);
    box-shadow: 0 8px 28px rgba(2, 132, 199, 0.08);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 66px;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: max-content;
}

.brand-icon {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--sky-500), var(--blue-600));
    box-shadow: 0 12px 24px rgba(14, 165, 233, 0.24);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.brand-text strong,
.footer-logo {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: transparent;
    background: linear-gradient(90deg, var(--sky-600), var(--blue-600));
    -webkit-background-clip: text;
    background-clip: text;
}

.brand-text small {
    margin-top: 3px;
    color: var(--slate-500);
    font-size: 12px;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--slate-700);
    font-weight: 600;
    transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--sky-600);
    background: rgba(14, 165, 233, 0.10);
    transform: translateY(-1px);
}

.menu-button {
    display: none;
    border: 0;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: var(--sky-600);
    background: var(--white);
    box-shadow: var(--shadow-sm);
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    background: var(--slate-900);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.9s ease;
}

.hero-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.02);
}

.hero-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.88), rgba(2, 6, 23, 0.48) 44%, rgba(2, 132, 199, 0.12));
}

.hero-content {
    position: absolute;
    left: 50%;
    bottom: 72px;
    transform: translateX(-50%);
    color: var(--white);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    width: max-content;
    margin-bottom: 16px;
    padding: 6px 14px;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(90deg, var(--sky-500), var(--blue-600));
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.hero-content h1,
.page-hero h1,
.detail-content h1 {
    margin: 0 0 16px;
    letter-spacing: -0.04em;
    line-height: 1.08;
}

.hero-content h1 {
    max-width: 780px;
    font-size: clamp(38px, 6vw, 64px);
}

.hero-content p {
    max-width: 760px;
    margin: 0 0 22px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
}

.hero-tags,
.hero-actions,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-tags a,
.tag-pill,
.tag-cloud a {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    transition: transform 0.25s ease, background 0.25s ease, box-shadow 0.25s ease;
}

.hero-tags a {
    padding: 7px 13px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
}

.hero-actions {
    margin-top: 26px;
}

.primary-button,
.ghost-button,
.search-form button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    border-radius: 999px;
    padding: 0 24px;
    font-weight: 800;
    transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.primary-button,
.search-form button {
    border: 0;
    color: var(--white);
    background: linear-gradient(90deg, var(--sky-500), var(--blue-600));
    box-shadow: 0 16px 30px rgba(37, 99, 235, 0.24);
}

.ghost-button {
    color: var(--white);
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
}

.primary-button:hover,
.ghost-button:hover,
.search-form button:hover,
.tag-cloud a:hover,
.hero-tags a:hover {
    transform: translateY(-2px) scale(1.02);
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 5;
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border: 0;
    border-radius: 50%;
    color: var(--white);
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
    font-size: 34px;
    line-height: 1;
    transform: translateY(-50%);
}

.hero-prev {
    left: 22px;
}

.hero-next {
    right: 22px;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.52);
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dot.active {
    width: 34px;
    background: var(--white);
}

.quick-search {
    margin-top: -42px;
    position: relative;
    z-index: 10;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 24px;
    align-items: center;
    border: 1px solid rgba(14, 165, 233, 0.16);
    border-radius: 28px;
    padding: 28px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(16px);
}

.search-panel h2,
.section-heading h2,
.category-strip-head h3,
.ranking-copy h2,
.text-panel h2,
.side-card h2 {
    margin: 0;
    color: var(--slate-900);
    font-weight: 850;
    letter-spacing: -0.03em;
}

.search-panel p,
.page-hero p,
.ranking-copy p,
.text-panel p,
.side-card p {
    color: var(--slate-600);
}

.search-form,
.inline-filter {
    display: flex;
    gap: 10px;
}

.search-form input,
.inline-filter input {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--slate-200);
    border-radius: 999px;
    padding: 0 18px;
    outline: none;
    color: var(--slate-900);
    background: var(--white);
    box-shadow: inset 0 0 0 1px transparent;
    transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.search-form input:focus,
.inline-filter input:focus {
    border-color: rgba(14, 165, 233, 0.55);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.14);
}

.page-sections,
.content-section {
    padding-top: 58px;
}

.content-section {
    margin-bottom: 64px;
}

.section-heading {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 28px;
}

.section-heading h2 {
    font-size: clamp(26px, 3vw, 36px);
}

.section-heading span {
    flex: 1;
    height: 4px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--sky-500), rgba(14, 165, 233, 0));
}

.section-link,
.category-strip-head a {
    color: var(--sky-600);
    font-weight: 800;
}

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

.compact-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
}

.movie-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: 18px;
    color: inherit;
    background: var(--white);
    box-shadow: var(--shadow-sm);
    transition: transform 0.28s ease, box-shadow 0.28s ease;
}

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

.poster-frame {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: linear-gradient(135deg, var(--sky-100), var(--blue-100));
}

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

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

.play-dot {
    position: absolute;
    left: 50%;
    top: 50%;
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    background: rgba(2, 6, 23, 0.45);
    box-shadow: 0 16px 38px rgba(2, 6, 23, 0.28);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.84);
    transition: transform 0.25s ease, opacity 0.25s ease;
}

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

.duration-badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    color: var(--white);
    background: rgba(2, 6, 23, 0.68);
    backdrop-filter: blur(10px);
    font-size: 12px;
    font-weight: 800;
}

.duration-badge {
    right: 10px;
    bottom: 10px;
    padding: 4px 8px;
}

.rank-badge {
    left: 10px;
    top: 10px;
    display: grid;
    min-width: 32px;
    height: 32px;
    place-items: center;
    background: linear-gradient(135deg, var(--sky-500), var(--blue-600));
}

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

.card-body h3 {
    display: -webkit-box;
    min-height: 48px;
    margin: 0 0 8px;
    overflow: hidden;
    color: var(--slate-900);
    font-size: 17px;
    font-weight: 800;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-body p {
    display: -webkit-box;
    margin: 0 0 14px;
    overflow: hidden;
    color: var(--slate-600);
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: auto;
    color: var(--slate-500);
    font-size: 12px;
    font-weight: 700;
}

.card-meta span {
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--slate-100);
}

.hot-scroll-section {
    border-radius: 28px;
    padding: 28px;
    background: linear-gradient(90deg, var(--sky-100), var(--blue-100));
    box-shadow: var(--shadow-sm);
}

.light-heading {
    margin-bottom: 20px;
}

.scroll-row {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding: 4px 4px 18px;
    scroll-snap-type: x proximity;
}

.scroll-card {
    flex: 0 0 318px;
    scroll-snap-align: start;
}

.category-strip {
    margin-bottom: 34px;
}

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

.category-strip-head h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
}

.category-strip-head h3::before {
    content: "";
    display: inline-block;
    width: 5px;
    height: 26px;
    border-radius: 999px;
    background: var(--sky-500);
}

.ranking-entry {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 28px;
    align-items: center;
    border-radius: 30px;
    padding: 34px;
    background: var(--white);
    box-shadow: var(--shadow-lg);
}

.ranking-mini-list,
.list-stack,
.side-list {
    display: grid;
    gap: 16px;
}

.horizontal-card {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    min-height: 128px;
}

.horizontal-card .card-body h3 {
    min-height: auto;
    -webkit-line-clamp: 1;
}

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

.page-main {
    min-height: 60vh;
}

.page-hero {
    position: relative;
    overflow: hidden;
    color: var(--white);
    background: radial-gradient(circle at top left, rgba(14, 165, 233, 0.55), transparent 34%), linear-gradient(135deg, #0f172a, #075985 60%, #2563eb);
}

.small-hero {
    padding: 74px 0 64px;
}

.page-hero h1 {
    max-width: 780px;
    font-size: clamp(34px, 5vw, 54px);
}

.page-hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
}

.page-hero .inline-filter {
    max-width: 620px;
    margin-top: 24px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 14px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    padding: 34px 0 0;
}

.detail-card,
.text-panel,
.side-card {
    overflow: hidden;
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--shadow-sm);
}

.detail-card {
    margin-bottom: 24px;
}

.player-shell {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #020617;
}

.player-video {
    width: 100%;
    height: 100%;
    background: #020617;
    object-fit: cover;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.62), rgba(2, 6, 23, 0.18));
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-cta {
    border: 0;
    border-radius: 999px;
    padding: 16px 30px;
    color: var(--white);
    background: linear-gradient(90deg, var(--sky-500), var(--blue-600));
    box-shadow: 0 24px 48px rgba(14, 165, 233, 0.35);
    font-size: 18px;
    font-weight: 900;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.play-cta:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 30px 58px rgba(14, 165, 233, 0.42);
}

.detail-content {
    padding: 28px;
}

.detail-content .eyebrow {
    margin-bottom: 14px;
}

.detail-content h1 {
    font-size: clamp(30px, 4vw, 48px);
}

.lead-text {
    margin: 0 0 20px;
    color: var(--slate-600);
    font-size: 18px;
}

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

.detail-meta {
    margin-bottom: 18px;
}

.detail-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    color: var(--slate-700);
    background: var(--slate-100);
    font-weight: 800;
}

.tag-pill,
.tag-cloud a {
    padding: 8px 13px;
    color: var(--slate-700);
    background: linear-gradient(90deg, var(--sky-100), var(--blue-100));
    font-size: 14px;
    font-weight: 700;
}

.text-panel {
    margin-bottom: 24px;
    padding: 28px;
}

.text-panel h2,
.side-card h2 {
    margin-bottom: 12px;
    font-size: 24px;
}

.text-panel p {
    margin: 0;
    font-size: 17px;
}

.detail-side {
    position: sticky;
    top: 92px;
    align-self: start;
}

.side-card {
    margin-bottom: 22px;
    padding: 18px;
}

.poster-side img {
    width: 100%;
    aspect-ratio: 16 / 10;
    border-radius: 18px;
    object-fit: cover;
    background: linear-gradient(135deg, var(--sky-100), var(--blue-100));
}

.poster-side h2 {
    margin-top: 16px;
}

.side-list .horizontal-card {
    grid-template-columns: 108px minmax(0, 1fr);
    min-height: 86px;
    border-radius: 14px;
}

.side-list .horizontal-card .poster-frame {
    min-height: 86px;
}

.side-list .card-body {
    padding: 10px;
}

.side-list .card-body p,
.side-list .card-meta {
    display: none;
}

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

.category-card {
    position: relative;
    min-height: 260px;
    overflow: hidden;
    border-radius: 28px;
    color: var(--white);
    background: var(--slate-900);
    box-shadow: var(--shadow-sm);
}

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

.category-card-mask {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.82), rgba(2, 6, 23, 0.24));
}

.category-card-body {
    position: absolute;
    left: 24px;
    right: 24px;
    bottom: 24px;
}

.category-card-body h2 {
    margin: 0 0 10px;
    font-size: 30px;
    letter-spacing: -0.03em;
}

.category-card-body p {
    max-width: 680px;
    margin: 0;
    color: rgba(255, 255, 255, 0.84);
}

.tag-cloud-section {
    border-radius: 28px;
    padding: 28px;
    background: var(--white);
    box-shadow: var(--shadow-sm);
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.site-footer {
    margin-top: 80px;
    padding: 54px 0 26px;
    border-top: 1px solid var(--slate-200);
    background: rgba(255, 255, 255, 0.78);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 0.8fr;
    gap: 32px;
}

.footer-grid p {
    max-width: 520px;
    margin: 14px 0 0;
    color: var(--slate-600);
}

.footer-grid h2 {
    margin: 0 0 12px;
    font-size: 18px;
}

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

.footer-links a {
    color: var(--slate-600);
}

.footer-links a:hover {
    color: var(--sky-600);
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 32px auto 0;
    padding-top: 22px;
    border-top: 1px solid var(--slate-200);
    color: var(--slate-500);
    font-size: 14px;
    text-align: center;
}

.is-hidden-card {
    display: none !important;
}

@media (max-width: 1100px) {
    .movie-grid,
    .compact-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .detail-layout,
    .ranking-entry {
        grid-template-columns: 1fr;
    }

    .detail-side {
        position: static;
    }
}

@media (max-width: 820px) {
    .main-nav {
        position: absolute;
        top: calc(100% + 1px);
        left: 16px;
        right: 16px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        border-radius: 18px;
        padding: 14px;
        background: rgba(255, 255, 255, 0.96);
        box-shadow: var(--shadow-lg);
    }

    .main-nav.open {
        display: flex;
    }

    .menu-button {
        display: grid;
        place-items: center;
    }

    .hero {
        height: 540px;
    }

    .hero-content {
        bottom: 62px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .hero-arrow {
        display: none;
    }

    .search-panel,
    .footer-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

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

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

    .horizontal-card {
        grid-template-columns: 132px minmax(0, 1fr);
    }
}

@media (max-width: 560px) {
    .container {
        width: min(100% - 22px, 1180px);
    }

    .brand-text strong {
        font-size: 18px;
    }

    .hero {
        height: 500px;
    }

    .hero-content h1 {
        font-size: 34px;
    }

    .hero-tags,
    .hero-actions {
        gap: 8px;
    }

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

    .search-panel,
    .hot-scroll-section,
    .ranking-entry,
    .tag-cloud-section,
    .text-panel,
    .detail-content {
        padding: 20px;
        border-radius: 22px;
    }

    .movie-grid,
    .compact-grid {
        grid-template-columns: 1fr;
    }

    .scroll-card {
        flex-basis: 82vw;
    }

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

    .horizontal-card .poster-frame {
        min-height: 112px;
    }

    .card-body h3 {
        min-height: auto;
    }

    .small-hero {
        padding: 50px 0;
    }
}
