:root {
    --bg: #f7f4ed;
    --surface: #ffffff;
    --surface-soft: #f0fdfa;
    --ink: #1f2937;
    --muted: #6b7280;
    --line: #e5e7eb;
    --primary: #059669;
    --primary-dark: #047857;
    --accent: #e11d48;
    --gold: #f59e0b;
    --slate: #0f172a;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(135deg, rgba(5, 150, 105, 0.94), rgba(20, 184, 166, 0.92));
    color: #ffffff;
    box-shadow: 0 12px 30px rgba(4, 120, 87, 0.24);
    backdrop-filter: blur(18px);
}

.header-inner {
    width: min(1240px, calc(100% - 32px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 900;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.logo-mark {
    width: 34px;
    height: 34px;
    display: inline-grid;
    place-items: center;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.22);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    font-weight: 700;
    font-size: 15px;
}

.main-nav a,
.mobile-nav a {
    opacity: 0.94;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.main-nav a:hover,
.mobile-nav a:hover {
    opacity: 1;
    transform: translateY(-1px);
}

.nav-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    font-size: 24px;
}

.mobile-nav {
    display: none;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
    gap: 12px;
    flex-direction: column;
    font-weight: 700;
}

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

.hero {
    position: relative;
    height: 580px;
    min-height: 520px;
    overflow: hidden;
    color: #ffffff;
    background: #000000;
}

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

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.04);
}

.hero-slide::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 78% 18%, rgba(16, 185, 129, 0.30), transparent 34%),
        linear-gradient(90deg, rgba(0, 0, 0, 0.82), rgba(0, 0, 0, 0.48) 46%, rgba(0, 0, 0, 0.18)),
        linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 44%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1240px, calc(100% - 32px));
    height: 100%;
    margin: 0 auto;
    display: flex;
    align-items: flex-end;
    padding: 0 0 70px;
}

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

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(5, 150, 105, 0.88);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.hero h1 {
    margin: 20px 0 14px;
    font-size: clamp(34px, 7vw, 70px);
    line-height: 1.05;
    letter-spacing: -0.06em;
    text-shadow: 0 12px 38px rgba(0, 0, 0, 0.45);
}

.hero p {
    max-width: 680px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.88);
    font-size: clamp(16px, 2.4vw, 22px);
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 26px;
}

.hero-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 12px 20px;
    border-radius: 999px;
    border: 0;
    font-weight: 900;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.btn-primary {
    color: #ffffff;
    background: var(--accent);
    box-shadow: 0 15px 35px rgba(225, 29, 72, 0.35);
}

.btn-primary:hover {
    background: #be123c;
}

.btn-secondary {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.30);
    backdrop-filter: blur(14px);
}

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

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

.hero-dot.active {
    background: #ffffff;
}

.page-shell {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 46px 0 70px;
}

.page-title {
    margin: 0 0 26px;
}

.page-title h1 {
    margin: 0 0 10px;
    font-size: clamp(30px, 5vw, 48px);
    line-height: 1.15;
    letter-spacing: -0.04em;
}

.page-title p {
    max-width: 840px;
    margin: 0;
    color: var(--muted);
    font-size: 17px;
}

.section-block {
    margin: 0 0 56px;
}

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

.section-head h2 {
    margin: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: clamp(24px, 4vw, 34px);
    letter-spacing: -0.04em;
}

.section-head h2::before {
    content: "";
    width: 8px;
    height: 32px;
    border-radius: 999px;
    background: var(--accent);
}

.section-head a {
    color: var(--primary-dark);
    font-weight: 900;
}

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

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

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: #111827;
}

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

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

.play-badge {
    position: absolute;
    right: 12px;
    bottom: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(225, 29, 72, 0.92);
    font-size: 13px;
    font-weight: 900;
    opacity: 0;
    transform: translateY(6px);
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.movie-card:hover .play-badge {
    opacity: 1;
    transform: translateY(0);
}

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

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

.movie-meta-line span {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 2px 8px;
    border-radius: 999px;
    background: #f3f4f6;
}

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

.movie-card p {
    margin: 0 0 12px;
    color: var(--muted);
    font-size: 14px;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-row span {
    padding: 4px 8px;
    border-radius: 999px;
    color: var(--primary-dark);
    background: #d1fae5;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    min-height: 200px;
    padding: 22px;
    border-radius: var(--radius);
    background: linear-gradient(135deg, #ffffff, #ecfdf5);
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(5, 150, 105, 0.10);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card strong {
    display: block;
    margin-bottom: 8px;
    font-size: 22px;
}

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

.category-count {
    color: var(--accent);
    font-weight: 900;
}

.search-panel {
    display: grid;
    grid-template-columns: 1.7fr 1fr 1fr 1fr;
    gap: 14px;
    padding: 18px;
    margin-bottom: 28px;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.search-panel input,
.search-panel select {
    width: 100%;
    height: 46px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 14px;
    color: var(--ink);
    background: #ffffff;
    font: inherit;
    outline: none;
}

.search-panel input:focus,
.search-panel select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(5, 150, 105, 0.14);
}

.result-note {
    margin: -10px 0 20px;
    color: var(--muted);
    font-weight: 700;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 70px 100px 1fr;
    gap: 18px;
    align-items: center;
    padding: 16px;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

.rank-num {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    border-radius: 18px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--accent), var(--gold));
    font-size: 20px;
    font-weight: 900;
}

.rank-cover {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 14px;
    background: #111827;
}

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

.rank-info h3 {
    margin: 0 0 8px;
    font-size: 22px;
}

.rank-info p {
    margin: 0 0 12px;
    color: var(--muted);
}

.detail-hero {
    color: #ffffff;
    background:
        radial-gradient(circle at 80% 10%, rgba(16, 185, 129, 0.30), transparent 36%),
        linear-gradient(135deg, #0f172a, #111827 58%, #064e3b);
}

.detail-hero-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 38px 0 48px;
    display: grid;
    grid-template-columns: 290px 1fr;
    gap: 34px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.34);
    background: #111827;
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 14px;
    font-weight: 800;
}

.breadcrumb a:hover {
    color: #ffffff;
}

.detail-copy h1 {
    margin: 0 0 16px;
    font-size: clamp(34px, 6vw, 62px);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.detail-copy p {
    max-width: 820px;
    margin: 0 0 20px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
}

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

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

.player-card {
    overflow: hidden;
    border-radius: 28px;
    background: #020617;
    box-shadow: var(--shadow);
}

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

.player-box video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: grid;
    place-items: center;
    border: 0;
    color: #ffffff;
    background: radial-gradient(circle, rgba(225, 29, 72, 0.22), rgba(0, 0, 0, 0.68));
    cursor: pointer;
}

.player-overlay.hidden {
    display: none;
}

.play-circle {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    background: rgba(225, 29, 72, 0.92);
    font-size: 38px;
    box-shadow: 0 18px 38px rgba(225, 29, 72, 0.34);
    transition: transform 0.2s ease;
}

.player-overlay:hover .play-circle {
    transform: scale(1.08);
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 28px;
    align-items: start;
}

.content-card {
    padding: 28px;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

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

.content-card p {
    margin: 0 0 18px;
    color: #374151;
    font-size: 16px;
}

.side-card {
    padding: 22px;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.08);
}

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

.side-item {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 12px;
    align-items: center;
}

.side-item img {
    width: 64px;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    border-radius: 12px;
    background: #111827;
}

.side-item strong {
    display: block;
    line-height: 1.35;
}

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

.pagination-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}

.pagination-links a {
    padding: 10px 14px;
    border-radius: 999px;
    color: var(--primary-dark);
    background: #d1fae5;
    font-weight: 900;
}

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

.footer-grid {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 48px 0;
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1fr;
    gap: 32px;
}

.footer-logo {
    margin-bottom: 14px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 900;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: #ffffff;
}

.site-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer li {
    margin-bottom: 8px;
}

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

.footer-bottom {
    padding: 18px 0;
    text-align: center;
    color: #9ca3af;
    border-top: 1px solid rgba(255, 255, 255, 0.10);
}

.empty-state {
    display: none;
    padding: 28px;
    border-radius: var(--radius);
    background: #ffffff;
    color: var(--muted);
    font-weight: 800;
    text-align: center;
}

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

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

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

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

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

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

@media (max-width: 760px) {
    .hero {
        height: 620px;
    }

    .hero-content {
        padding-bottom: 80px;
    }

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

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

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

    .rank-row {
        grid-template-columns: 54px 76px 1fr;
        gap: 12px;
        padding: 12px;
    }

    .rank-num {
        width: 46px;
        height: 46px;
        font-size: 16px;
    }

    .rank-info h3 {
        font-size: 17px;
    }

    .rank-info p {
        display: none;
    }

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

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

    .content-card,
    .side-card {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    .header-inner,
    .mobile-nav,
    .page-shell,
    .hero-content,
    .detail-hero-inner,
    .footer-grid {
        width: min(100% - 22px, 1240px);
    }

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

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

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