:root {
    --page-bg: #f8fafc;
    --card-bg: #ffffff;
    --soft-bg: #ecfeff;
    --line: #dff8ff;
    --text: #0f172a;
    --muted: #64748b;
    --cyan: #06b6d4;
    --blue: #2563eb;
    --deep: #0e7490;
    --shadow: 0 24px 80px rgba(14, 116, 144, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(34, 211, 238, 0.2), transparent 34rem),
        linear-gradient(180deg, #f0fdff 0%, #ffffff 28rem, #f8fafc 100%);
    color: var(--text);
    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 {
    display: block;
    max-width: 100%;
}

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.86);
    border-bottom: 1px solid rgba(14, 165, 233, 0.16);
    backdrop-filter: blur(18px);
}

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

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 24px;
    letter-spacing: -0.04em;
    background: linear-gradient(90deg, var(--deep), var(--blue));
    background-clip: text;
    -webkit-background-clip: text;
    color: transparent;
}

.logo-mark {
    display: inline-grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 12px 30px rgba(37, 99, 235, 0.3);
    font-size: 18px;
    letter-spacing: 0;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 28px;
    color: #334155;
    font-weight: 700;
}

.site-nav a {
    position: relative;
    padding: 8px 0;
}

.site-nav a::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 2px;
    content: "";
    transform: scaleX(0);
    transform-origin: center;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
    transition: transform 0.25s ease;
}

.site-nav a:hover {
    color: var(--deep);
}

.site-nav a:hover::after {
    transform: scaleX(1);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    color: var(--deep);
    background: #ecfeff;
    cursor: pointer;
}

.hero-carousel {
    position: relative;
    overflow: hidden;
    padding: 56px 0 34px;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 84% 12%, rgba(37, 99, 235, 0.2), transparent 24rem),
        radial-gradient(circle at 18% 72%, rgba(6, 182, 212, 0.18), transparent 28rem);
    pointer-events: none;
}

.hero-shell {
    position: relative;
    min-height: 620px;
}

.hero-slide {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.75fr);
    align-items: center;
    gap: 48px;
    min-height: 590px;
    padding: 34px;
    border: 1px solid rgba(14, 165, 233, 0.16);
    border-radius: 36px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(236, 254, 255, 0.84)),
        linear-gradient(45deg, rgba(6, 182, 212, 0.12), rgba(37, 99, 235, 0.12));
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(18px) scale(0.98);
    transition: opacity 0.55s ease, visibility 0.55s ease, transform 0.55s ease;
    position: absolute;
    inset: 0;
}

.hero-slide.is-active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    position: relative;
}

.hero-copy h1 {
    margin: 16px 0 18px;
    max-width: 780px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.05;
    letter-spacing: -0.06em;
}

.hero-copy p {
    max-width: 680px;
    margin: 0 0 26px;
    color: #475569;
    font-size: clamp(17px, 2vw, 22px);
}

.hero-kicker,
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--deep);
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-tags span,
.tag-row span {
    padding: 6px 12px;
    border: 1px solid rgba(6, 182, 212, 0.22);
    border-radius: 999px;
    color: var(--deep);
    background: rgba(236, 254, 255, 0.86);
    font-size: 13px;
    font-weight: 700;
}

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

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

.primary-button,
.home-search button {
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 18px 38px rgba(37, 99, 235, 0.25);
    border: 0;
    cursor: pointer;
}

.ghost-button {
    border: 1px solid rgba(6, 182, 212, 0.24);
    color: var(--deep);
    background: rgba(255, 255, 255, 0.75);
}

.primary-button:hover,
.ghost-button:hover,
.home-search button:hover {
    transform: translateY(-2px);
}

.hero-poster {
    position: relative;
    overflow: hidden;
    min-height: 500px;
    border-radius: 30px;
    box-shadow: 0 30px 70px rgba(15, 23, 42, 0.22);
    background: linear-gradient(135deg, rgba(14, 116, 144, 0.14), rgba(37, 99, 235, 0.22));
}

.hero-poster img {
    width: 100%;
    height: 100%;
    min-height: 500px;
    object-fit: cover;
    transition: transform 0.8s ease;
}

.hero-poster:hover img {
    transform: scale(1.05);
}

.hero-poster span {
    position: absolute;
    right: 20px;
    bottom: 20px;
    left: 20px;
    padding: 14px 16px;
    border-radius: 16px;
    color: #ffffff;
    background: rgba(15, 23, 42, 0.62);
    backdrop-filter: blur(14px);
    font-size: 20px;
    font-weight: 800;
}

.hero-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 24px;
}

.hero-dots button {
    width: 34px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: #bae6fd;
    cursor: pointer;
    transition: width 0.25s ease, background 0.25s ease;
}

.hero-dots button.is-active {
    width: 56px;
    background: linear-gradient(90deg, var(--cyan), var(--blue));
}

.home-search,
.filter-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    margin-top: 30px;
    padding: 26px;
    border: 1px solid rgba(14, 165, 233, 0.16);
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow);
}

.home-search h2 {
    margin: 6px 0 0;
    font-size: clamp(24px, 3vw, 34px);
    letter-spacing: -0.04em;
}

.home-search form {
    display: flex;
    flex: 1;
    max-width: 520px;
    gap: 12px;
}

.home-search input,
.search-field input,
.filter-panel select {
    width: 100%;
    min-height: 50px;
    border: 2px solid #cffafe;
    border-radius: 16px;
    outline: none;
    color: var(--text);
    background: #ffffff;
    padding: 0 16px;
    transition: border 0.25s ease, box-shadow 0.25s ease;
}

.home-search input:focus,
.search-field input:focus,
.filter-panel select:focus {
    border-color: var(--cyan);
    box-shadow: 0 0 0 5px rgba(6, 182, 212, 0.13);
}

.content-section,
.split-section,
.category-overview-grid {
    margin-top: 54px;
}

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

.section-heading h2 {
    margin: 8px 0 0;
    font-size: clamp(28px, 3vw, 42px);
    line-height: 1.15;
    letter-spacing: -0.05em;
}

.section-heading a {
    color: var(--deep);
    font-weight: 800;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(14, 165, 233, 0.13);
    border-radius: 24px;
    background: var(--card-bg);
    box-shadow: 0 12px 35px rgba(14, 116, 144, 0.09);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.movie-card:hover {
    transform: translateY(-7px);
    box-shadow: 0 26px 60px rgba(14, 116, 144, 0.2);
}

.poster {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.16), rgba(37, 99, 235, 0.18));
}

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

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

.poster::after {
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    content: "";
    background: linear-gradient(180deg, transparent, rgba(15, 23, 42, 0.62));
}

.poster-badge,
.poster-score,
.rank-mark {
    position: absolute;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    backdrop-filter: blur(10px);
}

.poster-badge {
    top: 12px;
    left: 12px;
    background: rgba(6, 182, 212, 0.86);
}

.poster-score {
    top: 12px;
    right: 12px;
    background: rgba(15, 23, 42, 0.66);
}

.rank-mark {
    right: 12px;
    bottom: 12px;
    min-width: 34px;
    background: linear-gradient(135deg, #f97316, #ef4444);
}

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

.movie-card h3 {
    margin: 0 0 8px;
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h3 a:hover {
    color: var(--deep);
}

.movie-card p {
    display: -webkit-box;
    min-height: 48px;
    margin: 0 0 14px;
    overflow: hidden;
    color: var(--muted);
    font-size: 14px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: #475569;
    font-size: 13px;
    font-weight: 700;
}

.movie-meta span,
.detail-meta span {
    padding: 4px 8px;
    border-radius: 999px;
    background: #f1f5f9;
}

.tag-row {
    margin-top: 12px;
}

.tag-row span {
    padding: 4px 9px;
    font-size: 12px;
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    gap: 24px;
}

.panel-card,
.category-overview-card,
.story-panel,
.detail-content,
.filter-panel,
.page-hero {
    border: 1px solid rgba(14, 165, 233, 0.14);
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow);
}

.panel-card {
    padding: 24px;
}

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

.rank-line {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 16px;
    background: #f8fafc;
    transition: background 0.2s ease, transform 0.2s ease;
}

.rank-line:hover {
    background: #ecfeff;
    transform: translateX(4px);
}

.rank-line span {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 50%;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    font-weight: 900;
}

.rank-line strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-line em {
    color: var(--deep);
    font-style: normal;
    font-weight: 900;
}

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

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

.category-tile {
    display: grid;
    gap: 8px;
    min-height: 116px;
    padding: 16px;
    border: 1px solid rgba(6, 182, 212, 0.18);
    border-radius: 20px;
    background: linear-gradient(135deg, #ffffff, #ecfeff);
    transition: transform 0.25s ease, border 0.25s ease;
}

.category-tile:hover {
    transform: translateY(-3px);
    border-color: rgba(6, 182, 212, 0.45);
}

.category-tile span {
    color: var(--deep);
    font-size: 18px;
    font-weight: 900;
}

.category-tile strong {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
}

.page-main {
    padding: 38px 0 72px;
}

.page-hero {
    padding: 34px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.92), rgba(236, 254, 255, 0.88)),
        radial-gradient(circle at 90% 10%, rgba(37, 99, 235, 0.16), transparent 28rem);
}

.small-hero h1,
.category-hero h1 {
    margin: 10px 0;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.08;
    letter-spacing: -0.06em;
}

.small-hero p,
.category-hero p {
    max-width: 780px;
    margin: 0;
    color: #475569;
    font-size: 18px;
}

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

.category-overview-card {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 20px;
    padding: 18px;
}

.category-cover {
    overflow: hidden;
    border-radius: 22px;
    aspect-ratio: 4 / 3;
    background: linear-gradient(135deg, rgba(6, 182, 212, 0.16), rgba(37, 99, 235, 0.18));
}

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

.category-overview-card h2 {
    margin: 0 0 8px;
    font-size: 24px;
}

.category-overview-card p {
    margin: 0 0 14px;
    color: var(--muted);
}

.mini-link-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.mini-link-list a,
.hero-link-strip a {
    padding: 6px 10px;
    border-radius: 999px;
    color: var(--deep);
    background: #ecfeff;
    font-size: 13px;
    font-weight: 800;
}

.hero-link-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.filter-panel {
    position: relative;
    display: grid;
    grid-template-columns: minmax(280px, 1fr) 180px 180px;
    margin-top: 28px;
}

.search-field {
    position: relative;
}

.search-field span {
    position: absolute;
    top: 50%;
    left: 16px;
    z-index: 2;
    transform: translateY(-50%);
    color: var(--deep);
    font-weight: 900;
}

.search-field input {
    padding-left: 44px;
}

.empty-state {
    display: none;
    grid-column: 1 / -1;
    padding: 18px;
    border-radius: 16px;
    color: var(--muted);
    background: #f8fafc;
    text-align: center;
    font-weight: 700;
}

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

.movie-card.is-hidden {
    display: none;
}

.detail-main {
    padding-top: 24px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    color: var(--muted);
    font-weight: 700;
}

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

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 24px;
}

.player-card {
    position: relative;
    overflow: hidden;
    min-height: 520px;
    border-radius: 32px;
    background: #020617;
    box-shadow: 0 32px 90px rgba(2, 6, 23, 0.32);
}

.movie-video {
    width: 100%;
    height: 100%;
    min-height: 520px;
    object-fit: cover;
    background: #020617;
    cursor: pointer;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 12px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.08), rgba(2, 6, 23, 0.56));
    cursor: pointer;
    transition: opacity 0.28s ease, visibility 0.28s ease;
}

.play-overlay span {
    display: grid;
    width: 86px;
    height: 86px;
    place-items: center;
    padding-left: 5px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 22px 60px rgba(37, 99, 235, 0.38);
    font-size: 34px;
}

.play-overlay strong {
    font-size: 24px;
    letter-spacing: 0.04em;
}

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

.detail-aside {
    display: grid;
    align-content: start;
    gap: 16px;
}

.detail-aside img {
    width: 100%;
    border-radius: 26px;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    box-shadow: var(--shadow);
}

.score-card {
    display: grid;
    gap: 4px;
    padding: 18px;
    border-radius: 22px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--cyan), var(--blue));
    box-shadow: 0 18px 50px rgba(37, 99, 235, 0.24);
}

.score-card span,
.score-card em {
    opacity: 0.88;
    font-style: normal;
    font-weight: 700;
}

.score-card strong {
    font-size: 42px;
    line-height: 1;
}

.detail-content {
    margin-top: 28px;
    padding: 32px;
}

.detail-content h1 {
    margin: 8px 0 12px;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.1;
    letter-spacing: -0.05em;
}

.lead-text {
    max-width: 920px;
    margin: 0 0 20px;
    color: #475569;
    font-size: 20px;
}

.detail-tags {
    margin: 18px 0 26px;
}

.story-panel {
    padding: 24px;
    margin-top: 18px;
    box-shadow: none;
}

.story-panel h2 {
    margin: 0 0 12px;
    font-size: 26px;
}

.story-panel p {
    margin: 0;
    color: #334155;
    font-size: 17px;
}

.related-section {
    margin-top: 42px;
}

.site-footer {
    margin-top: 80px;
    padding: 48px 0 22px;
    border-top: 1px solid rgba(14, 165, 233, 0.14);
    background: rgba(255, 255, 255, 0.72);
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 180px;
    gap: 36px;
}

.footer-logo {
    margin-bottom: 14px;
}

.site-footer p {
    max-width: 520px;
    color: var(--muted);
}

.footer-links {
    display: grid;
    gap: 10px;
    align-content: start;
}

.footer-links a {
    color: #475569;
    font-weight: 700;
}

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

.footer-copy {
    width: min(1180px, calc(100% - 32px));
    margin: 28px auto 0;
    color: #64748b;
    font-size: 14px;
}

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

    .hero-slide {
        grid-template-columns: 1fr;
    }

    .hero-poster,
    .hero-poster img {
        min-height: 360px;
    }

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

    .detail-aside {
        grid-template-columns: 220px minmax(0, 1fr);
    }
}

@media (max-width: 820px) {
    .site-shell {
        width: min(100% - 24px, 1180px);
    }

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

    .site-nav {
        position: absolute;
        top: 72px;
        right: 12px;
        left: 12px;
        display: none;
        padding: 18px;
        border: 1px solid rgba(14, 165, 233, 0.16);
        border-radius: 22px;
        background: rgba(255, 255, 255, 0.96);
        box-shadow: var(--shadow);
    }

    .site-nav.is-open {
        display: grid;
        gap: 12px;
    }

    .hero-carousel {
        padding-top: 24px;
    }

    .hero-shell,
    .hero-slide {
        min-height: auto;
    }

    .hero-slide {
        padding: 22px;
        border-radius: 26px;
    }

    .home-search,
    .filter-panel,
    .split-section,
    .footer-grid,
    .category-overview-grid {
        grid-template-columns: 1fr;
    }

    .home-search,
    .filter-panel {
        display: grid;
    }

    .home-search form {
        max-width: none;
        width: 100%;
    }

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

    .category-overview-card {
        grid-template-columns: 140px minmax(0, 1fr);
    }

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

    .player-card,
    .movie-video {
        min-height: 360px;
    }
}

@media (max-width: 560px) {
    .site-logo {
        font-size: 20px;
    }

    .logo-mark {
        width: 34px;
        height: 34px;
        border-radius: 12px;
    }

    .hero-copy h1,
    .small-hero h1,
    .category-hero h1,
    .detail-content h1 {
        font-size: 34px;
    }

    .home-search form {
        display: grid;
    }

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

    .category-overview-card {
        grid-template-columns: 1fr;
    }

    .hero-poster,
    .hero-poster img,
    .player-card,
    .movie-video {
        min-height: 280px;
    }

    .detail-content,
    .page-hero,
    .panel-card {
        padding: 22px;
        border-radius: 24px;
    }
}
