:root {
    --fog-950: #06121f;
    --fog-900: #0b1726;
    --fog-850: #101d2f;
    --fog-800: #152337;
    --fog-700: #203149;
    --fog-600: #3d526f;
    --fog-300: #bcccdc;
    --fog-200: #d8e2ec;
    --fog-100: #eef3f8;
    --mist-700: #4b6078;
    --mist-600: #5f728a;
    --mist-50: #f7fafc;
    --cyan-600: #0891b2;
    --cyan-500: #06b6d4;
    --cyan-400: #22d3ee;
    --amber-400: #fbbf24;
    --white-soft: rgba(255, 255, 255, 0.92);
    --shadow-soft: 0 16px 38px rgba(8, 18, 32, 0.12);
    --shadow-strong: 0 22px 60px rgba(8, 18, 32, 0.22);
}

body {
    min-height: 100vh;
    margin: 0;
    color: var(--fog-900);
    background: var(--mist-50);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
}

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

.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(188, 204, 220, 0.72);
    background: rgba(247, 250, 252, 0.9);
    backdrop-filter: blur(16px);
}

.nav-wrap,
.footer-inner,
.section-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.nav-wrap {
    min-height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--fog-900);
    font-weight: 800;
    letter-spacing: -0.02em;
}

.logo-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: white;
    background: linear-gradient(135deg, var(--cyan-500), var(--fog-700));
    box-shadow: 0 10px 26px rgba(6, 182, 212, 0.34);
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

.desktop-nav a,
.mobile-menu a {
    border-radius: 999px;
    color: var(--mist-700);
    font-size: 14px;
    font-weight: 700;
    transition: color 0.2s ease, background 0.2s ease;
}

.desktop-nav a {
    padding: 10px 14px;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-menu a:hover {
    color: var(--cyan-600);
    background: rgba(6, 182, 212, 0.1);
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: var(--fog-900);
    background: white;
    box-shadow: var(--shadow-soft);
}

.mobile-menu {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 16px;
    padding: 12px;
    border-radius: 18px;
    background: white;
    box-shadow: var(--shadow-soft);
}

.mobile-menu.is-open {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.mobile-menu a {
    padding: 12px 14px;
}

main {
    flex: 1;
}

.hero {
    position: relative;
    min-height: 72vh;
    overflow: hidden;
    background: var(--fog-900);
}

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

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

.hero-backdrop {
    position: absolute;
    inset: 0;
    background-position: center;
    background-size: cover;
    transform: scale(1.03);
}

.hero-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(6, 18, 31, 0.96) 0%, rgba(6, 18, 31, 0.66) 48%, rgba(6, 18, 31, 0.18) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    min-height: 72vh;
    margin: 0 auto;
    display: flex;
    align-items: flex-end;
    padding: 110px 0 88px;
}

.hero-copy {
    max-width: 720px;
    color: white;
}

.hero-label,
.tag-pill {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.hero-label {
    margin-bottom: 18px;
    padding: 7px 12px;
    color: white;
    background: var(--cyan-500);
}

.hero h1 {
    margin: 0 0 16px;
    font-size: clamp(42px, 7vw, 78px);
    line-height: 0.98;
    font-weight: 900;
    letter-spacing: -0.06em;
}

.hero p {
    max-width: 620px;
    margin: 0 0 26px;
    color: var(--fog-200);
    font-size: clamp(16px, 2.2vw, 20px);
    line-height: 1.75;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 32px;
    color: var(--fog-300);
    font-size: 14px;
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn-primary,
.btn-ghost,
.btn-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
    padding: 15px 24px;
    color: white;
    background: var(--cyan-500);
    box-shadow: 0 18px 38px rgba(6, 182, 212, 0.32);
}

.btn-primary:hover,
.btn-small:hover {
    transform: translateY(-2px);
    background: var(--cyan-600);
    box-shadow: var(--shadow-strong);
}

.btn-ghost {
    padding: 15px 22px;
    color: white;
    background: rgba(255, 255, 255, 0.14);
    backdrop-filter: blur(12px);
}

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

.btn-small {
    padding: 10px 14px;
    color: white;
    background: var(--cyan-500);
}

.hero-arrow {
    position: absolute;
    z-index: 4;
    top: 50%;
    width: 46px;
    height: 46px;
    border-radius: 999px;
    color: white;
    background: rgba(0, 0, 0, 0.32);
    backdrop-filter: blur(12px);
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.54);
}

.hero-arrow.prev {
    left: 24px;
}

.hero-arrow.next {
    right: 24px;
}

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

.hero-dot {
    width: 9px;
    height: 9px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.48);
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 34px;
    background: white;
}

.section {
    padding: 70px 0;
}

.section.dark {
    color: white;
    background: var(--fog-900);
}

.section.alt {
    background: var(--fog-100);
}

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

.eyebrow {
    margin-bottom: 8px;
    color: var(--cyan-600);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.section h2,
.page-hero h1,
.detail-title {
    margin: 0;
    color: var(--fog-900);
    font-weight: 900;
    letter-spacing: -0.04em;
}

.section.dark h2,
.section.dark .section-lead {
    color: white;
}

.section h2 {
    font-size: clamp(28px, 4vw, 40px);
}

.section-lead,
.page-hero p,
.category-intro,
.detail-summary,
.detail-review {
    color: var(--mist-600);
    line-height: 1.8;
}

.section.dark .card-title,
.section.dark .rank-title {
    color: white;
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border-radius: 20px;
    color: inherit;
    background: white;
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-frame {
    position: relative;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: var(--fog-800);
}

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

.movie-card:hover img,
.rank-card:hover img,
.related-card:hover img {
    transform: scale(1.07);
}

.card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    padding: 5px 9px;
    border-radius: 999px;
    color: white;
    background: rgba(6, 182, 212, 0.94);
    font-size: 12px;
    font-weight: 800;
}

.card-body {
    padding: 16px;
}

.card-title {
    margin: 0 0 8px;
    color: var(--fog-900);
    font-size: 17px;
    font-weight: 850;
    line-height: 1.35;
}

.card-desc {
    display: -webkit-box;
    min-height: 44px;
    overflow: hidden;
    margin: 0 0 12px;
    color: var(--mist-600);
    font-size: 14px;
    line-height: 1.6;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    color: var(--mist-600);
    font-size: 12px;
}

.tag-pill {
    padding: 5px 9px;
    color: var(--cyan-600);
    background: rgba(6, 182, 212, 0.1);
}

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

.category-card {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
    border-radius: 22px;
    color: white;
    background: linear-gradient(135deg, var(--fog-800), var(--fog-950));
    box-shadow: var(--shadow-soft);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.category-card h3 {
    margin: 0 0 10px;
    font-size: 22px;
    font-weight: 900;
}

.category-card p {
    margin: 0;
    color: var(--fog-300);
    line-height: 1.7;
}

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

.rank-card {
    display: grid;
    grid-template-columns: 116px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    overflow: hidden;
    padding: 12px;
    border-radius: 20px;
    color: inherit;
    background: rgba(255, 255, 255, 0.08);
    transition: transform 0.25s ease, background 0.25s ease;
}

.rank-card:hover {
    transform: translateY(-4px);
    background: rgba(255, 255, 255, 0.14);
}

.rank-index {
    color: var(--cyan-400);
    font-size: 26px;
    font-weight: 950;
}

.wide-poster {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 16px;
    background: var(--fog-700);
}

.rank-title {
    margin: 4px 0 8px;
    color: var(--fog-900);
    font-size: 18px;
    font-weight: 850;
}

.page-hero {
    padding: 78px 0 44px;
    background: radial-gradient(circle at 20% 20%, rgba(34, 211, 238, 0.2), transparent 32%), linear-gradient(135deg, white, var(--fog-100));
}

.page-hero h1 {
    font-size: clamp(34px, 5vw, 56px);
}

.page-hero p {
    max-width: 760px;
    margin-top: 14px;
    font-size: 17px;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    margin: 26px 0 0;
    padding: 10px;
    border-radius: 18px;
    background: white;
    box-shadow: var(--shadow-soft);
}

.search-input {
    min-height: 48px;
    width: 100%;
    padding: 0 16px;
    border: 1px solid var(--fog-200);
    border-radius: 14px;
    color: var(--fog-900);
    outline: none;
}

.search-input:focus {
    border-color: var(--cyan-500);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.14);
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: var(--mist-600);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--cyan-600);
}

.player-card {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: black;
    box-shadow: var(--shadow-strong);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.66), rgba(0, 0, 0, 0.12));
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-circle {
    width: 86px;
    height: 86px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: white;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(12px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.38);
    font-size: 34px;
}

.detail-card,
.side-card {
    border-radius: 24px;
    background: white;
    box-shadow: var(--shadow-soft);
}

.detail-card {
    margin-top: 24px;
    padding: 28px;
}

.detail-title {
    margin-bottom: 16px;
    font-size: clamp(30px, 4.2vw, 48px);
}

.detail-meta,
.detail-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 14px 0 24px;
}

.detail-meta span {
    padding: 7px 11px;
    border-radius: 999px;
    color: var(--mist-700);
    background: var(--fog-100);
    font-size: 13px;
    font-weight: 750;
}

.detail-card h2,
.side-card h2 {
    margin: 26px 0 10px;
    color: var(--fog-900);
    font-size: 22px;
    font-weight: 900;
}

.side-card {
    padding: 18px;
}

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

.related-card {
    display: grid;
    grid-template-columns: 88px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    color: inherit;
}

.related-card .wide-poster {
    aspect-ratio: 4 / 3;
    border-radius: 14px;
}

.related-card h3 {
    margin: 0 0 6px;
    color: var(--fog-900);
    font-size: 15px;
    font-weight: 850;
    line-height: 1.35;
}

.related-card p {
    margin: 0;
    color: var(--mist-600);
    font-size: 12px;
    line-height: 1.5;
}

.site-footer {
    color: var(--fog-300);
    background: var(--fog-950);
}

.footer-inner {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr;
    gap: 32px;
    padding: 46px 0;
}

.footer-inner h2,
.footer-inner h3 {
    margin: 0 0 14px;
    color: white;
    font-weight: 900;
}

.footer-inner p,
.footer-inner a {
    color: var(--fog-300);
    line-height: 1.8;
}

.footer-inner a:hover {
    color: var(--cyan-400);
}

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

.hide-card {
    display: none !important;
}

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

    .mobile-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

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

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

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

@media (max-width: 640px) {
    .hero,
    .hero-content {
        min-height: 76vh;
    }

    .hero-content {
        padding: 92px 0 76px;
    }

    .hero-arrow {
        display: none;
    }

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

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

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

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

    .card-body {
        padding: 13px;
    }

    .detail-card {
        padding: 20px;
    }
}
