:root {
    --color-bg: #f0fbff;
    --color-surface: #ffffff;
    --color-surface-soft: #ecfeff;
    --color-text: #172033;
    --color-muted: #64748b;
    --color-primary: #06b6d4;
    --color-primary-dark: #0891b2;
    --color-teal: #14b8a6;
    --color-line: rgba(8, 145, 178, 0.16);
    --shadow-soft: 0 18px 50px rgba(8, 145, 178, 0.14);
    --shadow-card: 0 16px 36px rgba(15, 23, 42, 0.10);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --max-width: 1180px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--color-text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    background:
        radial-gradient(circle at 15% 5%, rgba(20, 184, 166, 0.18), transparent 28rem),
        radial-gradient(circle at 85% 10%, rgba(6, 182, 212, 0.16), transparent 30rem),
        linear-gradient(180deg, #ecfeff 0%, #ffffff 44%, #f8fafc 100%);
    min-height: 100vh;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(236, 254, 255, 0.88);
    border-bottom: 1px solid var(--color-line);
    backdrop-filter: blur(18px);
    box-shadow: 0 8px 30px rgba(8, 145, 178, 0.08);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.brand-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-primary), var(--color-teal));
    border-radius: 50%;
    box-shadow: 0 10px 26px rgba(6, 182, 212, 0.32);
}

.brand-name {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: 0.02em;
    background: linear-gradient(135deg, #0891b2, #0f766e);
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
}

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

.desktop-nav a {
    color: #334155;
    font-weight: 700;
    position: relative;
    padding: 8px 0;
}

.desktop-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 100%;
    bottom: 2px;
    height: 2px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-teal));
    transition: right 0.24s ease;
}

.desktop-nav a:hover {
    color: var(--color-primary-dark);
}

.desktop-nav a:hover::after {
    right: 0;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 260px;
    padding: 5px;
    background: #ffffff;
    border: 1px solid rgba(6, 182, 212, 0.20);
    border-radius: 999px;
    box-shadow: 0 6px 20px rgba(8, 145, 178, 0.08);
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    padding: 8px 10px 8px 14px;
    background: transparent;
    color: var(--color-text);
}

.header-search button {
    border: 0;
    padding: 8px 13px;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-primary), var(--color-teal));
    cursor: pointer;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: rgba(6, 182, 212, 0.10);
    cursor: pointer;
}

.menu-toggle span {
    display: block;
    width: 19px;
    height: 2px;
    margin: 4px auto;
    background: #0f766e;
    border-radius: 2px;
}

.mobile-nav {
    display: none;
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto 14px;
    padding: 12px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--color-line);
    border-radius: 18px;
}

.mobile-nav a {
    display: block;
    padding: 12px;
    color: #334155;
    font-weight: 700;
    border-radius: 12px;
}

.mobile-nav a:hover {
    background: rgba(6, 182, 212, 0.10);
}

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

.hero {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    background: #0f172a;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.04);
    transition: opacity 0.9s ease, transform 1.2s ease;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

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

.hero-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.88) 0%, rgba(15, 23, 42, 0.64) 44%, rgba(15, 23, 42, 0.10) 100%),
        radial-gradient(circle at 25% 35%, rgba(6, 182, 212, 0.26), transparent 26rem);
}

.hero-content {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
}

.hero-content-inner {
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto;
}

.hero-copy {
    max-width: 670px;
    color: #ffffff;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: #facc15;
    font-weight: 800;
}

.hero h1 {
    margin: 0 0 18px;
    font-size: clamp(40px, 7vw, 72px);
    line-height: 1.03;
    letter-spacing: -0.04em;
}

.hero p {
    margin: 0;
    max-width: 620px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.8;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 24px 0 30px;
}

.hero-meta span {
    padding: 8px 14px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 999px;
    backdrop-filter: blur(10px);
}

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

.btn-primary,
.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 12px 22px;
    border-radius: 999px;
    font-weight: 800;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.btn-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-primary), var(--color-teal));
    box-shadow: 0 16px 36px rgba(6, 182, 212, 0.30);
}

.btn-secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

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

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

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

.hero-dots button.active {
    width: 38px;
    background: var(--color-primary);
}

.main-shell {
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto;
    padding: 56px 0 70px;
}

.section {
    margin-bottom: 68px;
}

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

.section-title {
    margin: 0;
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.section-subtitle {
    margin: 8px 0 0;
    color: var(--color-muted);
    line-height: 1.7;
}

.section-more {
    flex: 0 0 auto;
    color: var(--color-primary-dark);
    font-weight: 800;
}

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

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

.movie-card {
    overflow: hidden;
    background: var(--color-surface);
    border: 1px solid rgba(8, 145, 178, 0.12);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    transition: transform 0.26s ease, box-shadow 0.26s ease, border-color 0.26s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(6, 182, 212, 0.32);
    box-shadow: 0 24px 54px rgba(15, 23, 42, 0.16);
}

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.22), rgba(20, 184, 166, 0.22));
}

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

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(2, 6, 23, 0.72) 100%);
}

.play-chip {
    position: absolute;
    left: 14px;
    bottom: 14px;
    padding: 7px 12px;
    color: #ffffff;
    background: rgba(6, 182, 212, 0.88);
    border-radius: 999px;
    font-weight: 800;
}

.rank-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    display: grid;
    place-items: center;
    min-width: 34px;
    height: 34px;
    padding: 0 8px;
    color: #ffffff;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    border-radius: 999px;
    font-weight: 900;
    box-shadow: 0 10px 24px rgba(239, 68, 68, 0.28);
}

.movie-info {
    padding: 16px;
}

.movie-meta-line,
.ranking-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    color: var(--color-muted);
    font-size: 13px;
}

.movie-info h3 {
    min-height: 48px;
    margin: 10px 0 8px;
    font-size: 18px;
    line-height: 1.35;
}

.movie-info h3 a:hover,
.ranking-body h3 a:hover {
    color: var(--color-primary-dark);
}

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

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    min-height: 28px;
    margin-bottom: 13px;
}

.tag-row span {
    padding: 5px 9px;
    color: #0f766e;
    background: rgba(20, 184, 166, 0.11);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.score-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--color-muted);
    font-size: 13px;
}

.score-row strong {
    color: #f59e0b;
    font-size: 20px;
}

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

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

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

.category-card {
    position: relative;
    min-height: 158px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    background: #0f172a;
}

.category-card img {
    width: 100%;
    height: 100%;
    min-height: 158px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.category-card:hover img {
    transform: scale(1.08);
}

.category-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.84), rgba(2, 6, 23, 0.15));
}

.category-card-content {
    position: absolute;
    inset: auto 16px 16px;
    z-index: 2;
    color: #ffffff;
}

.category-card-content h3 {
    margin: 0 0 6px;
    font-size: 20px;
}

.category-card-content p {
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 13px;
    line-height: 1.5;
}

.gradient-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
    gap: 30px;
    align-items: center;
    padding: 34px;
    color: #ffffff;
    background:
        radial-gradient(circle at 85% 20%, rgba(255, 255, 255, 0.28), transparent 14rem),
        linear-gradient(135deg, var(--color-primary), var(--color-teal));
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-soft);
}

.gradient-panel h2 {
    margin: 0 0 14px;
    font-size: clamp(28px, 4vw, 44px);
}

.gradient-panel p {
    margin: 0;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1.8;
}

.panel-list {
    display: grid;
    gap: 12px;
}

.panel-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 14px 16px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.19);
    border-radius: 16px;
    backdrop-filter: blur(12px);
}

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

.page-hero-inner {
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto;
}

.page-hero h1 {
    max-width: 820px;
    margin: 0;
    font-size: clamp(34px, 6vw, 62px);
    line-height: 1.08;
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 760px;
    margin: 18px 0 0;
    color: var(--color-muted);
    font-size: 18px;
    line-height: 1.8;
}

.toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin: 0 0 24px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid var(--color-line);
    border-radius: 20px;
    box-shadow: 0 14px 36px rgba(8, 145, 178, 0.08);
}

.toolbar input,
.toolbar select {
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid rgba(8, 145, 178, 0.18);
    border-radius: 14px;
    outline: 0;
    background: #ffffff;
    color: var(--color-text);
}

.toolbar input {
    flex: 1 1 280px;
}

.toolbar select {
    flex: 0 0 170px;
}

.result-note {
    color: var(--color-muted);
    font-weight: 700;
}

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

.ranking-item {
    display: grid;
    grid-template-columns: 126px minmax(0, 1fr);
    gap: 18px;
    padding: 14px;
    background: #ffffff;
    border: 1px solid rgba(8, 145, 178, 0.12);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
}

.ranking-cover {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3 / 4;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.22), rgba(20, 184, 166, 0.22));
}

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

.ranking-cover span {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 2;
    display: grid;
    place-items: center;
    min-width: 32px;
    height: 32px;
    color: #ffffff;
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    border-radius: 999px;
    font-weight: 900;
}

.ranking-body h3 {
    margin: 4px 0 10px;
    font-size: 22px;
}

.ranking-body p {
    margin: 0 0 14px;
    color: var(--color-muted);
    line-height: 1.8;
}

.ranking-meta strong {
    color: #f59e0b;
}

.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: #0f172a;
}

.detail-bg {
    position: absolute;
    inset: 0;
}

.detail-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(6px) saturate(1.08);
    transform: scale(1.04);
    opacity: 0.55;
}

.detail-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.92), rgba(15, 23, 42, 0.58)),
        radial-gradient(circle at 80% 12%, rgba(6, 182, 212, 0.28), transparent 24rem);
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 34px;
    padding: 64px 0;
}

.detail-poster {
    overflow: hidden;
    border-radius: var(--radius-xl);
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.34);
}

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

.detail-copy h1 {
    margin: 0 0 14px;
    font-size: clamp(36px, 5vw, 62px);
    line-height: 1.1;
}

.detail-copy p {
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.8;
}

.detail-meta {
    color: rgba(255, 255, 255, 0.76);
}

.detail-meta span,
.detail-score {
    padding: 7px 12px;
    background: rgba(255, 255, 255, 0.14);
    border-radius: 999px;
}

.detail-score {
    color: #facc15;
    font-weight: 900;
}

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

.player-card,
.content-card,
.side-card {
    background: #ffffff;
    border: 1px solid rgba(8, 145, 178, 0.12);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-card);
}

.player-card {
    overflow: hidden;
    margin-bottom: 26px;
}

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

.player-wrap video {
    width: 100%;
    height: 100%;
    display: block;
    background: #020617;
}

.video-cover {
    position: absolute;
    inset: 0;
    cursor: pointer;
}

.video-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.52;
}

.video-cover::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(6, 182, 212, 0.12), rgba(2, 6, 23, 0.72));
}

.play-button {
    position: absolute;
    inset: 50% auto auto 50%;
    z-index: 4;
    width: 78px;
    height: 78px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--color-primary), var(--color-teal));
    border-radius: 50%;
    box-shadow: 0 20px 46px rgba(6, 182, 212, 0.35);
    transform: translate(-50%, -50%);
    cursor: pointer;
    font-size: 30px;
    line-height: 1;
}

.player-status {
    padding: 14px 18px;
    color: var(--color-muted);
    border-top: 1px solid rgba(8, 145, 178, 0.12);
}

.content-card {
    padding: 28px;
    margin-bottom: 26px;
}

.content-card h2,
.side-card h2 {
    margin: 0 0 16px;
    font-size: 26px;
}

.content-card p {
    margin: 0 0 18px;
    color: #334155;
    line-height: 1.95;
    font-size: 16px;
}

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

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

.side-list a {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
}

.side-list img {
    width: 78px;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 12px;
}

.side-list strong {
    display: block;
    margin-bottom: 5px;
    line-height: 1.4;
}

.side-list span {
    color: var(--color-muted);
    font-size: 13px;
}

.hide {
    display: none !important;
}

.empty-state {
    padding: 28px;
    color: var(--color-muted);
    text-align: center;
    background: #ffffff;
    border: 1px dashed rgba(8, 145, 178, 0.28);
    border-radius: 18px;
}

.site-footer {
    color: #e2e8f0;
    background: linear-gradient(135deg, #0f172a, #1e293b);
}

.footer-inner {
    width: min(var(--max-width), calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 28px;
    padding: 42px 0;
}

.footer-brand {
    display: inline-block;
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: 900;
}

.site-footer p {
    max-width: 540px;
    margin: 0;
    color: #94a3b8;
    line-height: 1.8;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: end;
    align-content: start;
    max-width: 420px;
}

.footer-links a {
    padding: 8px 12px;
    color: #e2e8f0;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 999px;
}

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

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

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

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

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

    .hero {
        min-height: 560px;
    }

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

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

    .movie-card-horizontal .poster-link {
        aspect-ratio: 3 / 4;
        min-height: 0;
    }

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

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

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

    .footer-links {
        justify-content: start;
    }
}

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

    .brand-name {
        font-size: 20px;
    }

    .hero h1 {
        font-size: 38px;
    }

    .hero p,
    .page-hero p,
    .detail-copy p {
        font-size: 16px;
    }

    .main-shell {
        padding-top: 38px;
    }

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

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

    .ranking-item {
        grid-template-columns: 96px minmax(0, 1fr);
        gap: 12px;
    }

    .ranking-body h3 {
        font-size: 18px;
    }

    .detail-hero-inner {
        padding: 42px 0;
    }

    .content-card {
        padding: 22px;
    }
}
