* {
    box-sizing: border-box;
}

:root {
    --bg: #f6fbfb;
    --surface: rgba(255, 255, 255, 0.9);
    --surface-strong: #ffffff;
    --text: #111827;
    --muted: #64748b;
    --line: rgba(15, 118, 110, 0.14);
    --teal: #0d9488;
    --teal-dark: #0f766e;
    --blue: #2563eb;
    --shadow: 0 24px 70px rgba(15, 23, 42, 0.14);
    --radius: 28px;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    background:
        radial-gradient(circle at 10% 0%, rgba(20, 184, 166, 0.18), transparent 30%),
        radial-gradient(circle at 100% 10%, rgba(37, 99, 235, 0.12), transparent 34%),
        var(--bg);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 10px 30px rgba(15, 118, 110, 0.06);
}

.header-inner {
    max-width: 1280px;
    height: 76px;
    margin: 0 auto;
    padding: 0 22px;
    display: flex;
    align-items: center;
    gap: 24px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    white-space: nowrap;
}

.brand-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    color: white;
    background: linear-gradient(135deg, var(--teal), var(--blue));
    border-radius: 14px;
    box-shadow: 0 14px 28px rgba(13, 148, 136, 0.28);
}

.brand-text {
    font-size: 22px;
    background: linear-gradient(135deg, var(--teal-dark), var(--blue));
    -webkit-background-clip: text;
    color: transparent;
}

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

.nav-link {
    color: #334155;
    font-weight: 700;
    font-size: 15px;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--teal-dark);
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-search input,
.filter-bar input,
.filter-bar select {
    border: 1px solid rgba(15, 118, 110, 0.18);
    background: white;
    color: var(--text);
    border-radius: 999px;
    padding: 12px 16px;
    outline: none;
    min-width: 220px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: rgba(13, 148, 136, 0.55);
    box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.12);
}

.header-search button,
.primary-button,
.ghost-button {
    border: 0;
    border-radius: 999px;
    padding: 12px 22px;
    font-weight: 800;
    cursor: pointer;
}

.header-search button,
.primary-button {
    color: white;
    background: linear-gradient(135deg, var(--teal), var(--blue));
    box-shadow: 0 14px 28px rgba(13, 148, 136, 0.22);
}

.ghost-button {
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(255, 255, 255, 0.13);
    backdrop-filter: blur(10px);
}

.menu-button {
    display: none;
    border: 0;
    color: var(--text);
    background: rgba(15, 118, 110, 0.08);
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 22px;
}

.mobile-nav {
    display: none;
    padding: 12px 22px 22px;
    border-top: 1px solid var(--line);
}

.mobile-nav.open {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.mobile-nav a {
    padding: 12px 14px;
    background: rgba(20, 184, 166, 0.08);
    border-radius: 14px;
    font-weight: 800;
}

.hero {
    max-width: 1280px;
    margin: 28px auto 0;
    padding: 0 22px;
}

.hero-stage {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    border-radius: 36px;
    box-shadow: var(--shadow);
    background: #0f172a;
}

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

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

.hero-media,
.detail-bg {
    position: absolute;
    inset: 0;
}

.hero-media img,
.detail-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-shade,
.detail-bg::after {
    position: absolute;
    inset: 0;
    content: "";
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.92) 0%, rgba(15, 23, 42, 0.78) 42%, rgba(15, 23, 42, 0.18) 100%),
        linear-gradient(0deg, rgba(15, 23, 42, 0.88), transparent 44%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(680px, 92%);
    padding: 110px 72px;
    color: white;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    color: #5eead4;
    font-weight: 900;
    letter-spacing: 0.08em;
}

.hero-content h1,
.page-hero h1,
.detail-intro h1 {
    margin: 0;
    font-size: clamp(38px, 6vw, 70px);
    line-height: 1.06;
    letter-spacing: -0.04em;
}

.hero-content p,
.page-hero p,
.detail-line {
    margin: 24px 0 0;
    color: rgba(255, 255, 255, 0.88);
    font-size: 20px;
    line-height: 1.75;
}

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

.hero-tags {
    margin-top: 26px;
}

.hero-tags span,
.tag-row span,
.detail-tags a {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    color: #0f766e;
    background: rgba(20, 184, 166, 0.1);
    font-size: 13px;
    font-weight: 800;
}

.hero-tags span {
    color: white;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.16);
}

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

.hero-tabs {
    position: relative;
    z-index: 4;
    margin: -84px 28px 0;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 12px;
}

.hero-tab {
    min-height: 72px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    color: rgba(255, 255, 255, 0.86);
    background: rgba(15, 23, 42, 0.54);
    backdrop-filter: blur(18px);
    border-radius: 20px;
    text-align: left;
    padding: 14px;
    font-weight: 900;
    cursor: pointer;
}

.hero-tab span {
    display: block;
    color: #5eead4;
    font-size: 12px;
    margin-bottom: 4px;
}

.hero-tab.active {
    background: linear-gradient(135deg, rgba(13, 148, 136, 0.94), rgba(37, 99, 235, 0.9));
}

.category-strip {
    max-width: 1280px;
    margin: 34px auto 0;
    padding: 0 22px;
}

.category-strip-inner {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
}

.category-strip a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px;
    border-radius: 22px;
    background: var(--surface);
    border: 1px solid var(--line);
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.06);
    font-weight: 900;
}

.category-strip span {
    color: var(--teal-dark);
}

.content-section {
    max-width: 1280px;
    margin: 62px auto;
    padding: 0 22px;
}

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

.section-heading h2 {
    margin: 0;
    font-size: clamp(28px, 4vw, 44px);
    letter-spacing: -0.04em;
}

.section-heading p {
    margin: 10px 0 0;
    color: var(--muted);
    line-height: 1.7;
}

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

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface-strong);
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 28px 64px rgba(15, 23, 42, 0.15);
}

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

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

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

.poster-badge,
.play-badge {
    position: absolute;
    z-index: 2;
    border-radius: 999px;
    padding: 7px 10px;
    font-size: 12px;
    font-weight: 900;
}

.poster-badge {
    top: 12px;
    left: 12px;
    color: white;
    background: rgba(15, 23, 42, 0.7);
    backdrop-filter: blur(8px);
}

.play-badge {
    right: 12px;
    bottom: 12px;
    color: white;
    background: linear-gradient(135deg, var(--teal), var(--blue));
}

.card-body {
    padding: 18px;
}

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

.card-body p {
    display: -webkit-box;
    min-height: 66px;
    margin: 10px 0 14px;
    overflow: hidden;
    color: var(--muted);
    line-height: 1.65;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.card-meta,
.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    color: var(--muted);
    font-size: 13px;
    font-weight: 800;
}

.accent-panel {
    padding-top: 46px;
    padding-bottom: 46px;
    border-radius: 36px;
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.12), rgba(37, 99, 235, 0.1));
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    margin: 28px auto 0;
    max-width: 1280px;
    border-radius: 36px;
    background: linear-gradient(135deg, #0f766e, #1d4ed8);
    color: white;
    box-shadow: var(--shadow);
}

.page-hero {
    padding: 74px 64px;
}

.compact-hero h1,
.category-hero h1 {
    max-width: 780px;
}

.compact-hero p,
.category-hero p {
    max-width: 780px;
}

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

.category-card {
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 28px;
    background: var(--surface-strong);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.category-title {
    color: #0f172a;
    font-size: 26px;
    font-weight: 950;
}

.category-card p {
    color: var(--muted);
    line-height: 1.7;
}

.category-count {
    width: max-content;
    margin: 18px 0;
    padding: 8px 12px;
    border-radius: 999px;
    color: var(--teal-dark);
    background: rgba(20, 184, 166, 0.1);
    font-weight: 900;
}

.category-samples {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.category-samples a {
    padding: 8px 10px;
    border-radius: 999px;
    background: #f1f5f9;
    color: #334155;
    font-size: 13px;
    font-weight: 800;
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 26px;
}

.large-filter input {
    min-width: min(560px, 100%);
}

.empty-state {
    display: none;
    color: var(--muted);
    font-weight: 900;
}

.detail-hero {
    min-height: 560px;
    background: #0f172a;
}

.detail-wrap {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 42px;
    padding: 72px;
    align-items: end;
}

.detail-poster {
    overflow: hidden;
    aspect-ratio: 3 / 4;
    border: 10px solid rgba(255, 255, 255, 0.18);
    border-radius: 28px;
    background: #e2e8f0;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.35);
}

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

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

.detail-tags {
    margin-top: 24px;
}

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

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

.play-layer {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 8px;
    border: 0;
    color: white;
    background: linear-gradient(135deg, rgba(2, 6, 23, 0.35), rgba(13, 148, 136, 0.34));
    cursor: pointer;
    text-align: center;
}

.play-layer.hidden {
    display: none;
}

.play-circle {
    width: 92px;
    height: 92px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--teal), var(--blue));
    box-shadow: 0 20px 48px rgba(13, 148, 136, 0.38);
    font-size: 34px;
}

.play-layer strong {
    font-size: 24px;
}

.play-layer em {
    color: rgba(255, 255, 255, 0.76);
    font-style: normal;
}

.detail-grid-section {
    display: grid;
    grid-template-columns: 1fr 1fr 320px;
    gap: 22px;
}

.text-panel,
.info-panel {
    border: 1px solid var(--line);
    border-radius: 28px;
    background: white;
    padding: 26px;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.07);
}

.text-panel h2,
.info-panel h2 {
    margin: 0 0 16px;
    font-size: 24px;
}

.text-panel p {
    margin: 0;
    color: #334155;
    line-height: 1.9;
}

.info-panel dl {
    display: grid;
    grid-template-columns: 76px 1fr;
    gap: 12px 14px;
    margin: 0;
}

.info-panel dt {
    color: var(--muted);
    font-weight: 900;
}

.info-panel dd {
    margin: 0;
    color: #0f172a;
    font-weight: 800;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 72px 92px 1fr 140px;
    align-items: center;
    gap: 18px;
    padding: 14px;
}

.rank-number {
    color: var(--teal-dark);
    font-size: 24px;
    font-weight: 950;
    text-align: center;
}

.rank-poster {
    height: 118px;
    overflow: hidden;
    border-radius: 18px;
    background: #e2e8f0;
}

.rank-info a {
    font-size: 20px;
    font-weight: 950;
}

.rank-info p {
    color: var(--muted);
    line-height: 1.6;
}

.rank-stat {
    text-align: right;
}

.rank-stat strong {
    display: block;
    color: #0f172a;
    font-size: 20px;
}

.rank-stat span {
    color: var(--muted);
    font-weight: 900;
}

.site-footer {
    margin-top: 70px;
    color: #cbd5e1;
    background: linear-gradient(135deg, #0f172a, #115e59, #1e3a8a);
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 54px 22px;
    display: grid;
    grid-template-columns: 1.6fr 1fr 1fr;
    gap: 32px;
}

.footer-logo {
    color: white;
    font-size: 24px;
    font-weight: 950;
}

.footer-brand p {
    max-width: 520px;
    line-height: 1.8;
}

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

.footer-column h2 {
    margin: 0 0 8px;
    color: white;
    font-size: 18px;
}

.footer-column a:hover {
    color: #5eead4;
}

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

    .menu-button {
        display: block;
    }

    .header-search {
        margin-left: auto;
    }

    .hero-tabs,
    .category-strip-inner,
    .movie-grid,
    .small-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .detail-wrap,
    .detail-grid-section,
    .footer-inner {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 720px) {
    .header-inner {
        height: auto;
        min-height: 68px;
        flex-wrap: wrap;
        padding: 12px 16px;
    }

    .header-search {
        order: 3;
        width: 100%;
    }

    .header-search input {
        min-width: 0;
        flex: 1;
    }

    .hero,
    .content-section,
    .category-strip {
        padding: 0 16px;
    }

    .hero-stage {
        min-height: 560px;
        border-radius: 26px;
    }

    .hero-content {
        padding: 74px 26px;
    }

    .hero-tabs,
    .category-strip-inner,
    .movie-grid,
    .small-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .hero-tabs {
        margin: 14px 0 0;
    }

    .hero-tab {
        color: #0f172a;
        background: white;
        border-color: var(--line);
    }

    .hero-tab.active {
        color: white;
    }

    .page-hero {
        margin-left: 16px;
        margin-right: 16px;
        padding: 48px 26px;
        border-radius: 26px;
    }

    .detail-hero {
        margin-left: 16px;
        margin-right: 16px;
        border-radius: 26px;
    }

    .detail-wrap {
        padding: 42px 24px;
    }

    .rank-row {
        grid-template-columns: 56px 76px 1fr;
    }

    .rank-stat {
        grid-column: 2 / -1;
        text-align: left;
    }
}
