:root {
    --bg: #f8fafc;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --dark: #0f172a;
    --dark-soft: #1e293b;
    --emerald: #10b981;
    --emerald-deep: #059669;
    --cyan: #06b6d4;
    --rose: #f43f5e;
    --card: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body.site-body {
    margin: 0;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
    color: var(--ink);
    background: var(--bg);
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    color: #fff;
    background: linear-gradient(90deg, #0f172a, #1e293b, #0f172a);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.35);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand-icon {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #052e2b;
    background: linear-gradient(135deg, var(--emerald), var(--cyan));
    box-shadow: 0 0 26px rgba(16, 185, 129, 0.55);
}

.brand-name,
.footer-brand {
    font-size: 22px;
    background: linear-gradient(90deg, #34d399, #22d3ee);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    font-size: 15px;
    white-space: nowrap;
}

.main-nav a,
.mobile-panel a,
.footer-links a {
    transition: color 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.mobile-panel a:hover,
.footer-links a:hover {
    color: #34d399;
}

.header-search {
    margin-left: auto;
    display: flex;
    align-items: center;
    min-width: 300px;
    border-radius: 999px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.header-search input {
    flex: 1;
    min-width: 0;
    padding: 12px 14px;
    color: #fff;
    background: transparent;
    outline: none;
}

.header-search input::placeholder {
    color: rgba(255, 255, 255, 0.62);
}

.header-search button,
.hero-search button,
.search-panel button,
.primary-button,
.watch-link {
    border: 0;
    color: #052e2b;
    font-weight: 800;
    background: linear-gradient(135deg, #34d399, #22d3ee);
    cursor: pointer;
}

.header-search button {
    padding: 12px 18px;
}

.mobile-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    margin-left: auto;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.08);
}

.mobile-menu-button span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 5px auto;
    background: #fff;
}

.mobile-panel {
    display: none;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    background: #0f172a;
}

.mobile-panel nav {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 16px 0 22px;
    display: grid;
    gap: 14px;
}

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

.hero {
    position: relative;
    overflow: hidden;
    min-height: 680px;
    color: #fff;
    background: radial-gradient(circle at top left, rgba(16, 185, 129, 0.32), transparent 35%), linear-gradient(135deg, #020617 0%, #0f172a 55%, #064e3b 100%);
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.95), rgba(15, 23, 42, 0.68), rgba(2, 6, 23, 0.92));
    z-index: 1;
}

.hero-slider {
    position: relative;
    z-index: 2;
    min-height: 680px;
}

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

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

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

.hero-content {
    position: relative;
    z-index: 3;
    width: min(1180px, calc(100% - 32px));
    min-height: 680px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) 420px;
    align-items: center;
    gap: 48px;
    padding: 72px 0 86px;
}

.hero-copy {
    max-width: 760px;
}

.eyebrow,
.section-eyebrow,
.poster-badge,
.rank-number {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-weight: 800;
}

.eyebrow {
    margin-bottom: 18px;
    padding: 8px 14px;
    color: #a7f3d0;
    background: rgba(16, 185, 129, 0.14);
    border: 1px solid rgba(52, 211, 153, 0.28);
}

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

.hero h1 span {
    display: block;
    color: #5eead4;
}

.hero-desc {
    max-width: 680px;
    margin: 0 0 24px;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.85;
}

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

.primary-button,
.secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 999px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button:hover,
.watch-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px rgba(16, 185, 129, 0.28);
}

.secondary-button {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.22);
    background: rgba(255, 255, 255, 0.08);
}

.secondary-button:hover {
    background: rgba(255, 255, 255, 0.15);
}

.hero-search {
    width: min(620px, 100%);
    display: flex;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(12px);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    padding: 18px 20px;
    color: #fff;
    background: transparent;
    outline: none;
}

.hero-search input::placeholder {
    color: rgba(255, 255, 255, 0.65);
}

.hero-search button {
    padding: 0 26px;
}

.hero-poster {
    position: relative;
    border-radius: 32px;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 34px 80px rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.hero-poster img {
    width: 100%;
    height: 560px;
    object-fit: cover;
}

.hero-poster-info {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 90px 24px 24px;
    background: linear-gradient(transparent, rgba(2, 6, 23, 0.96));
}

.hero-poster-info strong {
    display: block;
    margin-bottom: 8px;
    font-size: 26px;
}

.hero-poster-info span {
    color: #cbd5e1;
}

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

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

.hero-dot.is-active {
    background: linear-gradient(135deg, #34d399, #22d3ee);
}

.section,
.page-hero,
.content-section {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
}

.section {
    padding: 72px 0;
}

.page-hero {
    padding: 70px 0 42px;
}

.page-hero h1,
.section-heading h2 {
    margin: 0;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.1;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.page-hero p,
.section-heading p {
    max-width: 760px;
    margin-top: 14px;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.85;
}

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

.section-eyebrow {
    margin-bottom: 10px;
    padding: 7px 12px;
    color: #047857;
    background: #d1fae5;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: var(--card);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    background: linear-gradient(135deg, #0f172a, #064e3b);
}

.poster-link img,
.mini-card img,
.detail-poster img,
.player-poster {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.poster-link img {
    transition: transform 0.35s ease;
}

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

.poster-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    padding: 6px 10px;
    color: #fff;
    font-size: 12px;
    background: rgba(15, 23, 42, 0.78);
    backdrop-filter: blur(10px);
}

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
}

.movie-card h2 {
    margin: 10px 0 8px;
    font-size: 20px;
    line-height: 1.28;
    font-weight: 900;
}

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

.movie-card p {
    min-height: 72px;
    color: #475569;
    font-size: 14px;
    line-height: 1.75;
}

.card-compact p {
    min-height: 52px;
}

.tag-row {
    min-height: 32px;
    margin: 12px 0 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.tag-row span {
    padding: 5px 9px;
    border-radius: 999px;
    color: #047857;
    background: #ecfdf5;
    font-size: 12px;
    font-weight: 700;
}

.watch-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 42px;
    border-radius: 14px;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    min-height: 210px;
    padding: 28px;
    border-radius: 26px;
    color: #fff;
    background: radial-gradient(circle at top right, rgba(34, 211, 238, 0.35), transparent 35%), linear-gradient(135deg, #0f172a, #064e3b);
    box-shadow: var(--shadow);
}

.category-card h2 {
    margin: 0 0 12px;
    font-size: 28px;
    font-weight: 900;
}

.category-card p {
    color: #d1fae5;
    line-height: 1.75;
}

.category-card a {
    display: inline-flex;
    margin-top: 20px;
    color: #67e8f9;
    font-weight: 800;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 56px 74px 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 12px;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}

.rank-number {
    width: 44px;
    height: 44px;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, var(--rose), #fb923c);
}

.rank-item img {
    width: 74px;
    height: 98px;
    object-fit: cover;
    border-radius: 14px;
    background: #0f172a;
}

.rank-copy h2 {
    margin: 0 0 7px;
    font-size: 20px;
    font-weight: 900;
}

.rank-copy p {
    margin: 0;
    color: var(--muted);
    line-height: 1.65;
}

.rank-link {
    padding: 10px 16px;
    border-radius: 999px;
    color: #047857;
    background: #d1fae5;
    font-weight: 800;
}

.detail-hero {
    color: #fff;
    background: radial-gradient(circle at top left, rgba(16, 185, 129, 0.34), transparent 32%), linear-gradient(135deg, #020617, #0f172a 58%, #064e3b);
}

.detail-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0 56px;
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 42px;
    align-items: center;
}

.detail-poster {
    overflow: hidden;
    aspect-ratio: 3 / 4;
    border-radius: 30px;
    background: #0f172a;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.42);
}

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

.detail-copy h1 {
    margin: 0 0 16px;
    font-size: clamp(34px, 5vw, 60px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.05em;
}

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

.detail-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    color: #d1fae5;
    background: rgba(255, 255, 255, 0.1);
}

.detail-copy p {
    color: #dbeafe;
    font-size: 17px;
    line-height: 1.85;
}

.player-section {
    width: min(1180px, calc(100% - 32px));
    margin: 46px auto;
}

.player-frame {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #020617;
    box-shadow: var(--shadow);
    aspect-ratio: 16 / 9;
}

.movie-player {
    width: 100%;
    height: 100%;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    border: 0;
    color: #fff;
    background: rgba(2, 6, 23, 0.28);
    cursor: pointer;
}

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

.player-overlay img {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.46;
}

.player-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.82));
}

.play-mark {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: #052e2b;
    font-size: 34px;
    background: linear-gradient(135deg, #34d399, #22d3ee);
    box-shadow: 0 20px 50px rgba(16, 185, 129, 0.38);
}

.detail-text {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 26px;
}

.text-card,
.search-panel,
.empty-state {
    padding: 28px;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.text-card h2 {
    margin: 0 0 14px;
    font-size: 26px;
    font-weight: 900;
}

.text-card p {
    color: #475569;
    line-height: 1.9;
}

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

.mini-card {
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.mini-card img {
    aspect-ratio: 3 / 4;
    background: #0f172a;
}

.mini-card span {
    display: block;
    padding: 12px;
    font-weight: 800;
    line-height: 1.35;
}

.search-panel {
    margin-bottom: 28px;
}

.search-panel form {
    display: flex;
    gap: 12px;
}

.search-panel input,
.search-panel select {
    min-height: 50px;
    padding: 0 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: none;
    background: #fff;
}

.search-panel input {
    flex: 1;
}

.search-panel button {
    min-width: 120px;
    border-radius: 14px;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin: 36px 0 6px;
}

.pagination a {
    min-width: 42px;
    padding: 10px 14px;
    border-radius: 12px;
    text-align: center;
    background: #fff;
    color: #047857;
    font-weight: 800;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.07);
}

.pagination a.active {
    color: #052e2b;
    background: linear-gradient(135deg, #34d399, #22d3ee);
}

.site-footer {
    margin-top: 70px;
    color: #cbd5e1;
    background: #0f172a;
}

.footer-inner {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 46px 0;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 34px;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: #fff;
    font-size: 18px;
    font-weight: 900;
}

.site-footer p {
    line-height: 1.8;
}

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

.footer-bottom {
    padding: 18px;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

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

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

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

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

    .category-grid,
    .detail-text,
    .footer-inner {
        grid-template-columns: 1fr;
    }

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

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

    .main-nav {
        display: none;
    }

    .mobile-menu-button {
        display: block;
    }

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

    .hero,
    .hero-slider,
    .hero-content {
        min-height: auto;
    }

    .hero-content {
        padding: 54px 0 84px;
    }

    .hero-poster img {
        height: 420px;
    }

    .hero-search,
    .search-panel form {
        flex-direction: column;
        border-radius: 22px;
    }

    .hero-search button,
    .search-panel button {
        min-height: 50px;
    }

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

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

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

    .movie-card h2 {
        font-size: 17px;
    }

    .movie-card p {
        min-height: auto;
    }

    .rank-item {
        grid-template-columns: 42px 64px 1fr;
    }

    .rank-link {
        grid-column: 2 / -1;
        text-align: center;
    }

    .detail-inner {
        padding-top: 28px;
    }

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

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