:root {
    --blue-950: #172554;
    --blue-900: #1e3a8a;
    --blue-800: #1e40af;
    --blue-700: #1d4ed8;
    --blue-600: #2563eb;
    --slate-950: #020617;
    --slate-900: #0f172a;
    --slate-800: #1e293b;
    --slate-700: #334155;
    --slate-600: #475569;
    --slate-500: #64748b;
    --slate-400: #94a3b8;
    --slate-300: #cbd5e1;
    --slate-200: #e2e8f0;
    --slate-100: #f1f5f9;
    --slate-50: #f8fafc;
    --white: #ffffff;
    --amber: #f59e0b;
    --red: #ef4444;
    --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.10);
    --shadow-card: 0 8px 24px rgba(15, 23, 42, 0.08);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 12px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    color: var(--slate-900);
    background: linear-gradient(180deg, #ffffff 0%, var(--slate-50) 35%, #eef4ff 100%);
    line-height: 1.65;
}

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

img {
    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: 50;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid var(--slate-200);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    backdrop-filter: blur(16px);
}

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

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--slate-900);
    white-space: nowrap;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-900), var(--blue-600));
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.22);
}

.logo-text {
    font-size: 21px;
    letter-spacing: -0.03em;
}

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

.nav-links a {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    color: var(--slate-700);
    font-size: 15px;
    font-weight: 650;
    transition: background 0.2s ease, color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--blue-900);
    background: #dbeafe;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-form {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input {
    width: 240px;
    height: 40px;
    padding: 0 42px 0 16px;
    border: 1px solid var(--slate-300);
    border-radius: 12px;
    color: var(--slate-800);
    background: var(--white);
    outline: none;
    transition: border 0.2s ease, box-shadow 0.2s ease;
}

.search-input:focus {
    border-color: var(--blue-600);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.search-button {
    position: absolute;
    right: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 10px;
    color: var(--white);
    background: var(--blue-900);
    cursor: pointer;
}

.menu-button {
    display: none;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: var(--slate-800);
    background: var(--slate-100);
    cursor: pointer;
}

.mobile-panel {
    display: none;
    padding: 0 0 16px;
}

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

.mobile-nav {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 12px;
}

.mobile-nav a {
    padding: 12px 14px;
    border-radius: 14px;
    color: var(--slate-700);
    background: var(--slate-100);
    font-weight: 650;
}

.hero {
    position: relative;
    overflow: hidden;
    min-height: 560px;
    background: radial-gradient(circle at 10% 10%, rgba(59, 130, 246, 0.38), transparent 36%), linear-gradient(135deg, var(--slate-950), var(--blue-950));
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.78) 44%, rgba(30, 58, 138, 0.42) 100%);
    pointer-events: none;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.6s ease;
}

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

.hero-bg {
    position: absolute;
    inset: 0 0 0 auto;
    width: 58%;
    height: 100%;
    object-fit: cover;
    opacity: 0.55;
    filter: saturate(1.04) contrast(1.04);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) 360px;
    align-items: center;
    gap: 44px;
    min-height: 560px;
    padding: 70px 0;
    color: var(--white);
}

.hero-kicker {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    gap: 8px;
    padding: 7px 13px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    color: #dbeafe;
    background: rgba(255, 255, 255, 0.10);
    backdrop-filter: blur(12px);
    font-size: 14px;
    font-weight: 700;
}

.hero-title {
    margin: 22px 0 14px;
    max-width: 720px;
    font-size: clamp(38px, 6vw, 68px);
    line-height: 1.05;
    letter-spacing: -0.06em;
    font-weight: 900;
}

.hero-desc {
    max-width: 680px;
    margin: 0 0 28px;
    color: #dbeafe;
    font-size: 18px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
}

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 13px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600));
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover,
.btn-secondary:hover {
    transform: translateY(-2px);
}

.btn-secondary {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.10);
}

.hero-card {
    align-self: stretch;
    display: grid;
    align-content: end;
    min-height: 430px;
    padding: 22px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 30px 90px rgba(2, 6, 23, 0.32);
    backdrop-filter: blur(18px);
}

.hero-poster {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 18px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.34);
}

.hero-card-title {
    margin: 18px 0 6px;
    font-size: 24px;
    font-weight: 850;
}

.hero-card-meta {
    color: #bfdbfe;
    font-size: 14px;
}

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

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

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

.section {
    padding: 54px 0;
}

.section-tight {
    padding: 36px 0;
}

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

.section-title {
    margin: 0;
    color: var(--slate-900);
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
    letter-spacing: -0.04em;
    font-weight: 900;
}

.section-desc {
    margin: 8px 0 0;
    max-width: 720px;
    color: var(--slate-600);
}

.link-more {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    color: var(--blue-900);
    font-weight: 800;
}

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    background: var(--white);
    box-shadow: var(--shadow-card);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    border-color: #bfdbfe;
    box-shadow: var(--shadow-soft);
}

.movie-cover-link {
    position: relative;
    display: block;
    overflow: hidden;
    background: var(--slate-100);
}

.movie-cover {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    transition: transform 0.28s ease;
}

.movie-card:hover .movie-cover {
    transform: scale(1.04);
}

.movie-year {
    position: absolute;
    left: 12px;
    bottom: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(15, 23, 42, 0.78);
    font-size: 12px;
    font-weight: 800;
    backdrop-filter: blur(8px);
}

.movie-type {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600));
    font-size: 12px;
    font-weight: 800;
}

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

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

.movie-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 8px 0 9px;
    color: var(--slate-500);
    font-size: 13px;
}

.movie-line {
    display: -webkit-box;
    min-height: 44px;
    margin: 0;
    overflow: hidden;
    color: var(--slate-600);
    font-size: 14px;
    line-height: 1.55;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.tag {
    display: inline-flex;
    align-items: center;
    min-height: 26px;
    padding: 0 9px;
    border-radius: 999px;
    color: var(--blue-900);
    background: #dbeafe;
    font-size: 12px;
    font-weight: 700;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 190px;
    padding: 24px;
    border-radius: var(--radius-xl);
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-950), var(--blue-700));
    box-shadow: var(--shadow-card);
}

.category-card::after {
    content: "";
    position: absolute;
    right: -40px;
    bottom: -48px;
    width: 170px;
    height: 170px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.10);
}

.category-card h3 {
    position: relative;
    z-index: 1;
    margin: 0 0 10px;
    font-size: 24px;
    font-weight: 850;
}

.category-card p {
    position: relative;
    z-index: 1;
    margin: 0;
    color: #dbeafe;
}

.category-card .category-open {
    position: relative;
    z-index: 1;
    display: inline-flex;
    margin-top: 18px;
    color: var(--white);
    font-weight: 850;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 50px 86px minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 14px;
    border: 1px solid var(--slate-200);
    border-radius: 18px;
    background: var(--white);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

.rank-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 14px;
    color: var(--white);
    background: var(--blue-900);
    font-weight: 900;
}

.rank-thumb {
    width: 86px;
    height: 118px;
    border-radius: 12px;
    object-fit: cover;
    background: var(--slate-100);
}

.rank-title {
    margin: 0 0 5px;
    font-size: 18px;
    font-weight: 850;
}

.rank-text {
    margin: 0;
    color: var(--slate-600);
    font-size: 14px;
}

.page-hero {
    padding: 64px 0 44px;
    color: var(--white);
    background: radial-gradient(circle at 8% 0%, rgba(59, 130, 246, 0.45), transparent 30%), linear-gradient(135deg, var(--slate-950), var(--blue-950));
}

.page-hero h1 {
    max-width: 920px;
    margin: 0;
    font-size: clamp(34px, 5vw, 56px);
    line-height: 1.1;
    letter-spacing: -0.05em;
    font-weight: 900;
}

.page-hero p {
    max-width: 780px;
    margin: 16px 0 0;
    color: #dbeafe;
    font-size: 18px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: #bfdbfe;
    font-size: 14px;
    font-weight: 700;
}

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

.panel {
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-xl);
    background: var(--white);
    box-shadow: var(--shadow-card);
}

.panel-body {
    padding: 26px;
}

.player-wrap {
    overflow: hidden;
    background: var(--slate-950);
    border-radius: var(--radius-xl);
    box-shadow: 0 24px 60px rgba(2, 6, 23, 0.22);
}

.player-frame {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-frame video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    background: rgba(2, 6, 23, 0.54);
    z-index: 2;
}

.player-cover.is-hidden {
    display: none;
}

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

.player-button {
    position: relative;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 56px;
    padding: 0 24px;
    border: 0;
    border-radius: 999px;
    color: var(--white);
    background: linear-gradient(135deg, var(--blue-700), var(--blue-600));
    box-shadow: 0 18px 38px rgba(37, 99, 235, 0.38);
    font-weight: 900;
    cursor: pointer;
}

.detail-title {
    margin: 22px 0 8px;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.12;
    letter-spacing: -0.05em;
    font-weight: 900;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin: 0 0 16px;
}

.meta-pill {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    color: var(--slate-700);
    background: var(--slate-100);
    font-size: 13px;
    font-weight: 750;
}

.content-block h2 {
    margin: 0 0 16px;
    font-size: 24px;
    font-weight: 900;
}

.content-block p {
    margin: 0;
    color: var(--slate-700);
    font-size: 16px;
}

.content-block + .content-block {
    margin-top: 20px;
}

.sidebar-poster {
    width: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 18px;
    background: var(--slate-100);
}

.info-list {
    display: grid;
    gap: 10px;
    margin-top: 18px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--slate-100);
    color: var(--slate-600);
    font-size: 14px;
}

.info-row strong {
    color: var(--slate-900);
}

.search-page-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
    margin-top: 26px;
}

.search-page-input {
    min-height: 52px;
    padding: 0 18px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 15px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.10);
    outline: none;
}

.search-page-input::placeholder {
    color: #bfdbfe;
}

.empty-state {
    display: none;
    padding: 26px;
    border-radius: 18px;
    color: var(--slate-600);
    background: var(--white);
    box-shadow: var(--shadow-card);
}

.empty-state.is-visible {
    display: block;
}

.site-footer {
    margin-top: 58px;
    padding: 42px 0;
    color: #cbd5e1;
    background: var(--slate-950);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr repeat(3, 1fr);
    gap: 28px;
}

.footer-title {
    margin: 0 0 12px;
    color: var(--white);
    font-size: 20px;
    font-weight: 850;
}

.footer-text {
    margin: 0;
    color: #94a3b8;
    font-size: 14px;
}

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

.footer-links a {
    color: #cbd5e1;
    font-size: 14px;
}

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

.hidden-card {
    display: none;
}

@media (max-width: 960px) {
    .header-actions .search-form {
        display: none;
    }

    .nav-links {
        display: none;
    }

    .menu-button {
        display: inline-flex;
    }

    .hero-content {
        grid-template-columns: 1fr;
        gap: 28px;
        min-height: auto;
    }

    .hero-card {
        max-width: 420px;
    }

    .hero-bg {
        width: 100%;
        opacity: 0.26;
    }

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

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

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

    .hero,
    .hero-content {
        min-height: 660px;
    }

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

    .hero-title {
        font-size: 40px;
    }

    .hero-desc {
        font-size: 16px;
    }

    .hero-card {
        min-height: 0;
        padding: 16px;
    }

    .section {
        padding: 38px 0;
    }

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

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

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

    .movie-title {
        font-size: 15px;
    }

    .rank-item {
        grid-template-columns: 42px 70px minmax(0, 1fr);
    }

    .rank-item .btn-primary {
        grid-column: 1 / -1;
    }

    .rank-thumb {
        width: 70px;
        height: 96px;
    }

    .page-hero {
        padding: 44px 0 34px;
    }

    .panel-body {
        padding: 18px;
    }

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

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