* {
    box-sizing: border-box;
}

:root {
    --page-bg: #f8fafc;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --line: #e2e8f0;
    --card: #ffffff;
    --emerald: #10b981;
    --emerald-dark: #059669;
    --teal: #0d9488;
    --slate: #1e293b;
    --shadow-soft: 0 18px 50px rgba(15, 23, 42, 0.08);
    --shadow-card: 0 10px 30px rgba(15, 23, 42, 0.10);
    --radius-xl: 24px;
    --radius-lg: 18px;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text-main);
    background: var(--page-bg);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(18px);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.05);
}

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

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

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--slate);
    white-space: nowrap;
}

.logo-mark {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 12px 26px rgba(16, 185, 129, 0.28);
}

.logo-mark svg {
    width: 21px;
    height: 21px;
    fill: currentColor;
}

.logo-text {
    background: linear-gradient(135deg, var(--emerald-dark), var(--teal));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 21px;
    letter-spacing: -0.03em;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    color: #334155;
    font-size: 15px;
    font-weight: 650;
}

.desktop-nav a {
    transition: color 0.2s ease;
}

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

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 13px;
    color: #334155;
    background: #f1f5f9;
}

.menu-toggle span,
.menu-toggle::before,
.menu-toggle::after {
    display: block;
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: currentColor;
    transition: transform 0.2s ease, opacity 0.2s ease;
    content: "";
}

.menu-toggle {
    flex-direction: column;
    gap: 5px;
}

.menu-toggle.is-open span {
    opacity: 0;
}

.menu-toggle.is-open::before {
    transform: translateY(7px) rotate(45deg);
}

.menu-toggle.is-open::after {
    transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
    display: none;
    border-top: 1px solid var(--line);
    background: #ffffff;
}

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

.mobile-menu nav {
    display: grid;
    gap: 6px;
    padding: 14px 0 18px;
}

.mobile-menu a {
    padding: 10px 2px;
    color: #334155;
    font-weight: 650;
}

.hero {
    position: relative;
    min-height: 610px;
    overflow: hidden;
    color: #ffffff;
    background: #020617;
}

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

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

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.92;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 72% 20%, rgba(16, 185, 129, 0.22), transparent 32%), linear-gradient(90deg, rgba(2, 6, 23, 0.88) 0%, rgba(2, 6, 23, 0.52) 48%, rgba(2, 6, 23, 0.15) 100%), linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.42) 54%, rgba(2, 6, 23, 0.18) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    min-height: 610px;
    align-items: flex-end;
    padding: 120px 0 80px;
}

.hero-copy {
    width: min(760px, 100%);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    color: #d1fae5;
    background: rgba(15, 23, 42, 0.36);
    backdrop-filter: blur(10px);
    font-size: 14px;
    font-weight: 750;
}

.hero h1 {
    margin: 0;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.02;
    letter-spacing: -0.055em;
    text-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
}

.hero-desc {
    max-width: 680px;
    margin: 22px 0 0;
    color: #dbeafe;
    font-size: clamp(16px, 2vw, 20px);
}

.hero-meta,
.meta-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 20px;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    font-size: 13px;
    font-weight: 750;
}

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

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 46px;
    padding: 0 20px;
    border: 0;
    border-radius: 14px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

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

.button-primary {
    color: #ffffff;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 16px 28px rgba(16, 185, 129, 0.32);
}

.button-light {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(12px);
}

.hero-dots {
    position: absolute;
    z-index: 4;
    right: max(20px, calc((100vw - 1180px) / 2));
    bottom: 44px;
    display: flex;
    gap: 10px;
}

.hero-dot {
    width: 12px;
    height: 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.5);
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 34px;
    background: #ffffff;
}

.main {
    padding: 48px 0 72px;
}

.section {
    margin-top: 46px;
}

.section:first-child {
    margin-top: 0;
}

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

.section-kicker {
    color: var(--emerald-dark);
    font-size: 13px;
    font-weight: 850;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

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

.section-desc {
    max-width: 650px;
    margin: 8px 0 0;
    color: var(--text-muted);
}

.section-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--emerald-dark);
    font-weight: 800;
    white-space: nowrap;
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.86);
    border-radius: var(--radius-lg);
    background: var(--card);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(16, 185, 129, 0.35);
    box-shadow: var(--shadow-card);
}

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

.poster-link {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #0f172a;
}

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

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

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

.card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 10px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(16, 185, 129, 0.92);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
    font-size: 12px;
    font-weight: 850;
}

.card-score {
    position: absolute;
    right: 12px;
    bottom: 12px;
    padding: 4px 9px;
    border-radius: 999px;
    color: #fef3c7;
    background: rgba(15, 23, 42, 0.78);
    font-size: 12px;
    font-weight: 850;
}

.card-body {
    padding: 16px;
}

.card-title {
    display: -webkit-box;
    min-height: 52px;
    margin: 0;
    overflow: hidden;
    color: #0f172a;
    font-size: 18px;
    font-weight: 850;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.card-title a:hover {
    color: var(--emerald-dark);
}

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

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 13px;
}

.card-meta span {
    padding: 4px 9px;
    border-radius: 999px;
    color: #047857;
    background: #ecfdf5;
    font-size: 12px;
    font-weight: 750;
}

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

.category-card {
    min-height: 170px;
    padding: 22px;
    border: 1px solid rgba(226, 232, 240, 0.85);
    border-radius: var(--radius-xl);
    background: linear-gradient(145deg, #ffffff 0%, #f0fdfa 100%);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.category-card strong {
    display: block;
    color: #0f172a;
    font-size: 22px;
    letter-spacing: -0.035em;
}

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

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

.rank-item {
    display: grid;
    grid-template-columns: 68px 108px 1fr auto;
    gap: 18px;
    align-items: center;
    padding: 14px;
    border: 1px solid rgba(226, 232, 240, 0.85);
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 8px 22px rgba(15, 23, 42, 0.05);
}

.rank-no {
    display: grid;
    width: 48px;
    height: 48px;
    place-items: center;
    border-radius: 16px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    font-weight: 900;
}

.rank-poster {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 15px;
    background: #0f172a;
}

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

.rank-title {
    margin: 0;
    color: #0f172a;
    font-size: 18px;
    font-weight: 850;
}

.rank-summary {
    display: -webkit-box;
    margin: 5px 0 0;
    overflow: hidden;
    color: var(--text-muted);
    font-size: 14px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.rank-score {
    padding: 7px 12px;
    border-radius: 999px;
    color: #047857;
    background: #ecfdf5;
    font-weight: 900;
    white-space: nowrap;
}

.page-hero {
    padding: 72px 0 42px;
    color: #ffffff;
    background: radial-gradient(circle at 72% 10%, rgba(16, 185, 129, 0.23), transparent 32%), linear-gradient(135deg, #020617 0%, #0f172a 52%, #064e3b 100%);
}

.page-hero h1 {
    max-width: 880px;
    margin: 0;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.08;
    letter-spacing: -0.05em;
}

.page-hero p {
    max-width: 760px;
    margin: 18px 0 0;
    color: #cbd5e1;
    font-size: 18px;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px 150px;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px;
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.06);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 46px;
    border: 1px solid #dbe3ef;
    border-radius: 14px;
    outline: 0;
    padding: 0 14px;
    color: #0f172a;
    background: #f8fafc;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: rgba(16, 185, 129, 0.78);
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.12);
}

.empty-state {
    padding: 28px;
    border: 1px dashed #cbd5e1;
    border-radius: 20px;
    color: var(--text-muted);
    background: #ffffff;
    text-align: center;
}

.empty-state.is-hidden {
    display: none;
}

.detail-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 28px;
    align-items: start;
}

.player-card,
.detail-card,
.side-card {
    border: 1px solid rgba(226, 232, 240, 0.86);
    border-radius: var(--radius-xl);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
}

.player-card {
    overflow: hidden;
}

.player-box {
    position: relative;
    overflow: hidden;
    background: #000000;
}

.player-box video {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.12), rgba(2, 6, 23, 0.76));
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-cover img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.58;
}

.play-button {
    position: relative;
    z-index: 2;
    display: grid;
    width: 82px;
    height: 82px;
    place-items: center;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--emerald), var(--teal));
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.32);
    transition: transform 0.2s ease;
}

.play-button:hover {
    transform: scale(1.06);
}

.play-button svg {
    width: 34px;
    height: 34px;
    margin-left: 4px;
    fill: currentColor;
}

.player-caption {
    padding: 20px 22px 24px;
}

.player-caption h1 {
    margin: 0;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.12;
    letter-spacing: -0.045em;
}

.player-caption p {
    margin: 12px 0 0;
    color: var(--text-muted);
}

.detail-card {
    margin-top: 22px;
    padding: 26px;
}

.detail-card h2,
.side-card h2 {
    margin: 0 0 14px;
    color: #0f172a;
    font-size: 24px;
    line-height: 1.2;
    letter-spacing: -0.035em;
}

.detail-card p {
    margin: 0 0 18px;
    color: #334155;
}

.side-card {
    padding: 20px;
}

.side-card + .side-card {
    margin-top: 22px;
}

.meta-row {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid var(--line);
    color: #334155;
}

.meta-row:last-child {
    border-bottom: 0;
}

.meta-row strong {
    color: #0f172a;
}

.tag-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.tag-cloud span,
.tag-cloud a {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 999px;
    color: #047857;
    background: #ecfdf5;
    font-size: 13px;
    font-weight: 750;
}

.related-list {
    display: grid;
    gap: 13px;
}

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

.related-thumb {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 13px;
    background: #0f172a;
}

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

.related-title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: #0f172a;
    font-weight: 850;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.related-meta {
    margin: 4px 0 0;
    color: var(--text-muted);
    font-size: 13px;
}

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

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

.site-footer {
    border-top: 1px solid var(--line);
    background: #ffffff;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 30px 0;
    color: var(--text-muted);
    font-size: 14px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}

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

    .menu-toggle {
        display: inline-flex;
    }

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

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

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

@media (max-width: 760px) {
    .container {
        width: min(100% - 24px, 1180px);
    }

    .hero,
    .hero-content {
        min-height: 560px;
    }

    .hero-content {
        padding: 96px 0 72px;
    }

    .hero-dots {
        right: 16px;
        bottom: 22px;
    }

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

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

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

    .rank-item {
        grid-template-columns: 46px 86px 1fr;
        gap: 11px;
    }

    .rank-score {
        grid-column: 2 / 4;
        justify-self: start;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .logo-text {
        font-size: 18px;
    }

    .hero-actions {
        flex-direction: column;
    }

    .button {
        width: 100%;
    }

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

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

    .rank-poster {
        display: none;
    }

    .rank-score {
        grid-column: 2;
    }

    .detail-card,
    .side-card {
        padding: 18px;
    }
}
