:root {
    color-scheme: light;
    --bg: #fff7ed;
    --text: #111827;
    --muted: #64748b;
    --line: rgba(148, 163, 184, 0.28);
    --panel: rgba(255, 255, 255, 0.84);
    --panel-strong: #ffffff;
    --amber: #f59e0b;
    --rose: #e11d48;
    --sky: #0284c7;
    --teal: #0f766e;
    --slate: #0f172a;
    --shadow: 0 22px 60px rgba(15, 23, 42, 0.16);
    --radius: 26px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(251, 191, 36, 0.26), transparent 34rem),
        radial-gradient(circle at top right, rgba(56, 189, 248, 0.22), transparent 30rem),
        linear-gradient(135deg, #fff7ed 0%, #fff1f2 45%, #eff6ff 100%);
}

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

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

button,
input {
    font: inherit;
}

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(255, 255, 255, 0.58);
    background: linear-gradient(90deg, rgba(255, 251, 235, 0.92), rgba(255, 241, 242, 0.92), rgba(240, 249, 255, 0.92));
    backdrop-filter: blur(18px);
    box-shadow: 0 14px 40px rgba(15, 23, 42, 0.10);
}

.nav-shell {
    max-width: 1220px;
    height: 70px;
    margin: 0 auto;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    letter-spacing: -0.04em;
    color: transparent;
    background: linear-gradient(90deg, #d97706, #e11d48, #0284c7);
    -webkit-background-clip: text;
    background-clip: text;
}

.brand {
    font-size: 26px;
}

.brand-mark {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: white;
    font-size: 14px;
    background: linear-gradient(135deg, #f59e0b, #e11d48);
    box-shadow: 0 12px 25px rgba(225, 29, 72, 0.28);
}

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

.desktop-nav a,
.mobile-nav a {
    padding: 10px 16px;
    border-radius: 999px;
    color: #475569;
    font-size: 15px;
    font-weight: 700;
    transition: transform 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-nav a:hover,
.mobile-nav a.active {
    color: #be123c;
    background: rgba(255, 255, 255, 0.72);
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    color: #334155;
    background: rgba(255, 255, 255, 0.8);
    cursor: pointer;
}

.mobile-nav {
    display: none;
    padding: 0 22px 18px;
    max-width: 1220px;
    margin: 0 auto;
}

.mobile-nav.open {
    display: grid;
    gap: 8px;
}

main {
    padding-top: 70px;
}

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

.hero {
    position: relative;
    min-height: 720px;
    overflow: hidden;
    display: grid;
    align-items: center;
    background: #0f172a;
}

.hero-track {
    position: absolute;
    inset: 0;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
}

.hero-slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.08);
}

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(90deg, rgba(15, 23, 42, 0.92), rgba(127, 29, 29, 0.72), rgba(2, 132, 199, 0.42)),
        linear-gradient(0deg, rgba(15, 23, 42, 0.92), transparent 55%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1220px, calc(100% - 40px));
    margin: 0 auto;
    color: white;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
    align-items: center;
    gap: 48px;
}

.hero-kicker,
.section-kicker,
.detail-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    padding: 8px 13px;
    border-radius: 999px;
    color: #fde68a;
    background: rgba(251, 191, 36, 0.16);
    border: 1px solid rgba(251, 191, 36, 0.28);
    font-weight: 800;
}

.hero h1 {
    margin: 22px 0 20px;
    font-size: clamp(42px, 6vw, 82px);
    line-height: 0.98;
    font-weight: 950;
    letter-spacing: -0.07em;
}

.hero p {
    margin: 0 0 28px;
    max-width: 720px;
    color: #ffedd5;
    font-size: clamp(18px, 2.1vw, 25px);
    line-height: 1.75;
}

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

.btn-primary,
.btn-ghost,
.btn-soft {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 0 22px;
    border-radius: 999px;
    font-weight: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
    color: white;
    background: linear-gradient(90deg, #f59e0b, #e11d48);
    box-shadow: 0 18px 38px rgba(225, 29, 72, 0.28);
}

.btn-ghost {
    color: white;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(14px);
}

.btn-soft {
    color: #be123c;
    background: white;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.10);
}

.btn-primary:hover,
.btn-ghost:hover,
.btn-soft:hover {
    transform: translateY(-2px) scale(1.01);
}

.hero-panel {
    padding: 22px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.22);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow);
}

.hero-panel img {
    position: static;
    width: 100%;
    height: 360px;
    border-radius: 22px;
    object-fit: cover;
    filter: none;
}

.hero-panel h2 {
    margin: 18px 0 8px;
    font-size: 26px;
    font-weight: 900;
}

.hero-panel p {
    margin: 0;
    font-size: 15px;
    line-height: 1.75;
    color: #ffedd5;
}

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

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

.hero-dot.active {
    background: linear-gradient(90deg, #f59e0b, #e11d48);
}

.search-shell {
    position: relative;
    width: min(100%, 620px);
    margin-top: 22px;
}

.search-shell input,
.page-search input {
    width: 100%;
    height: 54px;
    border: 1px solid rgba(255, 255, 255, 0.38);
    border-radius: 999px;
    padding: 0 24px;
    outline: none;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 16px 38px rgba(15, 23, 42, 0.15);
}

.search-results {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    z-index: 20;
    overflow: hidden;
    border-radius: 22px;
    background: white;
    box-shadow: var(--shadow);
    display: none;
}

.search-results.open {
    display: block;
}

.search-results a {
    display: block;
    padding: 14px 18px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.search-results strong {
    display: block;
    color: #0f172a;
}

.search-results span {
    display: block;
    margin-top: 3px;
    color: #64748b;
    font-size: 13px;
}

.section {
    padding: 70px 0;
}

.section.alt {
    background: rgba(255, 255, 255, 0.48);
    backdrop-filter: blur(12px);
}

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

.section-title {
    margin: 10px 0 0;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.12;
    font-weight: 950;
    letter-spacing: -0.05em;
    color: transparent;
    background: linear-gradient(90deg, #be123c, #d97706, #0284c7);
    -webkit-background-clip: text;
    background-clip: text;
}

.section-lead {
    max-width: 760px;
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.8;
}

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

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

.movie-card {
    overflow: hidden;
    border-radius: 24px;
    background: var(--panel-strong);
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.10);
    transform: translateY(0);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 24px 60px rgba(225, 29, 72, 0.18);
}

.movie-cover {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a, #7f1d1d, #075985);
}

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

.movie-grid.featured .movie-cover img,
.category-strip .movie-cover img {
    aspect-ratio: 16 / 10;
}

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

.movie-score,
.card-rank {
    position: absolute;
    top: 12px;
    z-index: 2;
    min-width: 44px;
    padding: 6px 10px;
    border-radius: 999px;
    color: white;
    font-weight: 900;
    font-size: 13px;
    text-align: center;
    backdrop-filter: blur(10px);
}

.movie-score {
    right: 12px;
    background: rgba(15, 23, 42, 0.72);
}

.card-rank {
    left: 12px;
    background: linear-gradient(90deg, #f59e0b, #e11d48);
}

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

.movie-card-content h3 {
    margin: 0 0 9px;
    font-size: 18px;
    line-height: 1.35;
    font-weight: 900;
}

.movie-card-content p {
    margin: 0 0 14px;
    color: #64748b;
    font-size: 14px;
    line-height: 1.65;
}

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #64748b;
    font-size: 13px;
}

.movie-meta-line span {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border-radius: 999px;
    background: rgba(241, 245, 249, 0.9);
}

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

.tag-row span,
.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 5px 9px;
    color: #be123c;
    background: #fff1f2;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 250px;
    padding: 26px;
    border-radius: 28px;
    color: white;
    background: linear-gradient(135deg, #0f172a, #be123c 55%, #d97706);
    box-shadow: var(--shadow);
}

.category-card:nth-child(3n + 2) {
    background: linear-gradient(135deg, #0f172a, #0369a1 55%, #0f766e);
}

.category-card:nth-child(3n) {
    background: linear-gradient(135deg, #1e1b4b, #7e22ce 55%, #e11d48);
}

.category-card h2,
.category-card h3 {
    position: relative;
    z-index: 2;
    margin: 0 0 14px;
    font-size: 28px;
    font-weight: 950;
}

.category-card p {
    position: relative;
    z-index: 2;
    margin: 0 0 20px;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.75;
}

.category-mini-list {
    position: relative;
    z-index: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.category-mini-list span {
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-size: 12px;
    font-weight: 800;
}

.category-strip {
    display: grid;
    gap: 48px;
}

.category-block-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.category-block-header h3 {
    margin: 0;
    font-size: 27px;
    font-weight: 950;
    color: #be123c;
}

.page-hero {
    padding: 150px 0 70px;
    color: white;
    background:
        linear-gradient(120deg, rgba(15, 23, 42, 0.92), rgba(127, 29, 29, 0.86), rgba(2, 132, 199, 0.76)),
        radial-gradient(circle at top right, rgba(251, 191, 36, 0.32), transparent 22rem);
}

.page-hero h1 {
    max-width: 900px;
    margin: 18px 0 16px;
    font-size: clamp(38px, 5vw, 68px);
    line-height: 1.04;
    font-weight: 950;
    letter-spacing: -0.06em;
}

.page-hero p {
    max-width: 820px;
    margin: 0;
    color: #ffedd5;
    font-size: 18px;
    line-height: 1.85;
}

.page-search {
    margin-top: 26px;
    max-width: 660px;
}

.page-search input {
    border-color: rgba(148, 163, 184, 0.34);
}

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

.ranking-row {
    display: grid;
    grid-template-columns: 76px 86px minmax(0, 1fr) 110px;
    gap: 18px;
    align-items: center;
    padding: 14px;
    border-radius: 24px;
    background: white;
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.ranking-row:hover {
    transform: translateX(5px);
    box-shadow: 0 20px 55px rgba(225, 29, 72, 0.14);
}

.ranking-number {
    font-size: 24px;
    font-weight: 950;
    color: transparent;
    background: linear-gradient(90deg, #f59e0b, #e11d48);
    -webkit-background-clip: text;
    background-clip: text;
    text-align: center;
}

.ranking-row img {
    width: 86px;
    height: 118px;
    border-radius: 16px;
    object-fit: cover;
    background: #0f172a;
}

.ranking-main h3 {
    margin: 0 0 7px;
    font-size: 20px;
    font-weight: 950;
}

.ranking-main p {
    margin: 0 0 10px;
    color: #64748b;
    line-height: 1.65;
}

.ranking-side {
    display: grid;
    justify-items: end;
    gap: 8px;
    color: #64748b;
}

.ranking-side strong {
    color: #be123c;
    font-size: 28px;
    line-height: 1;
}

.detail-hero {
    position: relative;
    overflow: hidden;
    min-height: 620px;
    padding: 140px 0 70px;
    color: white;
    background: #0f172a;
}

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

.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.42;
    filter: blur(2px) saturate(1.1);
}

.detail-backdrop::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(15, 23, 42, 0.96), rgba(127, 29, 29, 0.78), rgba(2, 132, 199, 0.48)),
        linear-gradient(0deg, #0f172a, transparent 72%);
}

.detail-layout {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 320px minmax(0, 1fr);
    align-items: center;
    gap: 42px;
}

.detail-poster {
    overflow: hidden;
    border-radius: 30px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.36);
    background: linear-gradient(135deg, #0f172a, #7f1d1d, #075985);
}

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

.detail-copy h1 {
    margin: 20px 0 18px;
    font-size: clamp(38px, 6vw, 70px);
    line-height: 1;
    font-weight: 950;
    letter-spacing: -0.06em;
}

.detail-copy p {
    max-width: 850px;
    margin: 0 0 24px;
    color: #ffedd5;
    font-size: 18px;
    line-height: 1.85;
}

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

.detail-meta span {
    padding: 8px 12px;
    border-radius: 999px;
    color: white;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-weight: 800;
}

.player-section {
    margin-top: -58px;
    position: relative;
    z-index: 4;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #020617;
    box-shadow: 0 30px 80px rgba(15, 23, 42, 0.28);
    cursor: pointer;
}

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

.play-layer {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: white;
    background: radial-gradient(circle, rgba(225, 29, 72, 0.20), rgba(2, 6, 23, 0.62));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.play-layer span {
    width: 88px;
    height: 88px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    padding-left: 6px;
    font-size: 34px;
    background: linear-gradient(135deg, #f59e0b, #e11d48);
    box-shadow: 0 20px 46px rgba(225, 29, 72, 0.36);
}

.player-shell.playing .play-layer {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.detail-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 32px;
    align-items: start;
}

.article-card,
.side-card {
    padding: 28px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 18px 46px rgba(15, 23, 42, 0.08);
}

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

.article-card p,
.side-card p {
    margin: 0 0 18px;
    color: #475569;
    line-height: 1.9;
}

.side-links {
    display: grid;
    gap: 12px;
}

.side-link {
    display: grid;
    grid-template-columns: 72px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 18px;
    background: #f8fafc;
}

.side-link img {
    width: 72px;
    height: 86px;
    border-radius: 12px;
    object-fit: cover;
    background: #0f172a;
}

.side-link strong {
    display: block;
    margin-bottom: 5px;
    font-size: 15px;
    line-height: 1.35;
}

.side-link span {
    color: #64748b;
    font-size: 12px;
}

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

.site-footer {
    color: #cbd5e1;
    background: linear-gradient(135deg, #020617, #111827 58%, #0f172a);
}

.footer-grid {
    width: min(1220px, calc(100% - 40px));
    margin: 0 auto;
    padding: 58px 0 36px;
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 34px;
}

.footer-brand {
    margin-bottom: 16px;
    font-size: 22px;
}

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

.site-footer h3 {
    margin: 0 0 16px;
    color: white;
    font-size: 17px;
    font-weight: 900;
}

.site-footer a,
.site-footer span {
    display: block;
    margin: 9px 0;
    color: #94a3b8;
    font-size: 14px;
}

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

.footer-bottom {
    width: min(1220px, calc(100% - 40px));
    margin: 0 auto;
    padding: 20px 0 26px;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
    color: #94a3b8;
    font-size: 14px;
}

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

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

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

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

    .hero-panel {
        display: none;
    }
}

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

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

    .brand {
        font-size: 21px;
    }

    .hero {
        min-height: 640px;
    }

    .hero-content {
        padding-top: 48px;
    }

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

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

    .movie-card-content {
        padding: 14px;
    }

    .movie-card-content h3 {
        font-size: 16px;
    }

    .movie-card-content p,
    .tag-row {
        display: none;
    }

    .ranking-row {
        grid-template-columns: 48px 70px minmax(0, 1fr);
    }

    .ranking-row img {
        width: 70px;
        height: 92px;
    }

    .ranking-side {
        display: none;
    }

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

    .article-card,
    .side-card {
        padding: 22px;
    }
}

@media (max-width: 480px) {
    .container {
        width: min(100% - 26px, 1220px);
    }

    .nav-shell {
        padding: 0 14px;
    }

    .hero h1,
    .page-hero h1,
    .detail-copy h1 {
        letter-spacing: -0.04em;
    }

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

    .ranking-main p {
        display: none;
    }
}
