:root {
    --bg: #ffffff;
    --text: #111827;
    --muted: #6b7280;
    --soft: #f3f4f6;
    --line: #e5e7eb;
    --primary: #0f766e;
    --primary-2: #0891b2;
    --blue: #2563eb;
    --dark: #111827;
    --card: #ffffff;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

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

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid rgba(229, 231, 235, 0.9);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.06);
    backdrop-filter: blur(18px);
}

.header-inner {
    min-height: 76px;
    display: flex;
    align-items: center;
    gap: 28px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--dark);
    font-weight: 800;
}

.brand-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--primary-2));
    box-shadow: 0 12px 28px rgba(8, 145, 178, 0.3);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-text strong {
    font-size: 18px;
    white-space: nowrap;
}

.brand-text em {
    margin-top: 4px;
    font-size: 12px;
    color: var(--muted);
    font-style: normal;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-left: auto;
}

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

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

.header-search {
    width: 260px;
    display: flex;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 999px;
    overflow: hidden;
    background: #f9fafb;
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    padding: 10px 12px 10px 16px;
    background: transparent;
}

.header-search button {
    border: 0;
    padding: 10px 16px;
    color: #ffffff;
    background: var(--blue);
    cursor: pointer;
}

.menu-button {
    display: none;
    border: 0;
    background: transparent;
    font-size: 28px;
    cursor: pointer;
}

.mobile-nav {
    display: none;
    padding: 8px 16px 18px;
    border-top: 1px solid var(--line);
    background: #ffffff;
}

.mobile-nav.open {
    display: grid;
    gap: 8px;
}

.mobile-nav .nav-link {
    padding: 10px 14px;
    border-radius: 12px;
}

.mobile-nav .nav-link.active,
.mobile-nav .nav-link:hover {
    background: #eff6ff;
}

.hero-slider {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(135deg, #0f766e 0%, #0891b2 48%, #2563eb 100%);
}

.hero-pattern {
    position: absolute;
    inset: 0;
    opacity: 0.17;
    background-image: radial-gradient(circle at 20% 20%, #ffffff 0 2px, transparent 3px), radial-gradient(circle at 80% 30%, #ffffff 0 2px, transparent 3px);
    background-size: 48px 48px, 72px 72px;
}

.hero-shell {
    position: relative;
    min-height: 620px;
    display: grid;
    align-items: center;
    padding: 72px 0 86px;
}

.hero-slide {
    display: none;
    grid-template-columns: minmax(0, 1.08fr) minmax(300px, 0.68fr);
    align-items: center;
    gap: 52px;
}

.hero-slide.active {
    display: grid;
    animation: fadeUp 0.55s ease both;
}

.hero-copy h1 {
    max-width: 780px;
    margin: 0 0 14px;
    font-size: clamp(36px, 6vw, 68px);
    line-height: 1.08;
    letter-spacing: -0.04em;
}

.hero-copy h2 {
    margin: 0 0 18px;
    color: #cffafe;
    font-size: clamp(22px, 3vw, 38px);
}

.hero-copy p {
    max-width: 700px;
    margin: 0 0 24px;
    color: #ecfeff;
    font-size: clamp(16px, 1.7vw, 21px);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: #0f766e;
    background: rgba(240, 253, 250, 0.95);
    border: 1px solid rgba(153, 246, 228, 0.7);
    border-radius: 999px;
    padding: 7px 13px;
    font-size: 13px;
    font-weight: 800;
}

.hero-tags,
.detail-meta,
.movie-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-tags span,
.detail-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    color: #e0f2fe;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 14px;
}

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

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

.primary-button {
    color: var(--blue);
    background: #ffffff;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.2);
}

.primary-button:hover,
.ghost-button:hover,
.movie-card:hover,
.category-card:hover,
.category-overview-card:hover {
    transform: translateY(-3px);
}

.ghost-button {
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.8);
}

.hero-poster {
    position: relative;
    display: block;
    border-radius: 30px;
    overflow: hidden;
    min-height: 430px;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.34);
}

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

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

.hero-poster span {
    position: absolute;
    right: 18px;
    bottom: 18px;
    color: #ffffff;
    background: rgba(37, 99, 235, 0.92);
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 800;
}

.hero-controls {
    position: absolute;
    left: 0;
    bottom: 26px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.hero-controls button {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: 50%;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    cursor: pointer;
}

.hero-dots {
    display: flex;
    align-items: center;
    gap: 8px;
}

.hero-dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border-radius: 999px;
    opacity: 0.62;
}

.hero-dot.active {
    width: 28px;
    opacity: 1;
    background: #ffffff;
}

.stats-strip {
    background: #ffffff;
    border-bottom: 1px solid var(--line);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 28px 0;
}

.stats-grid div {
    padding: 24px;
    border-radius: 18px;
    background: linear-gradient(135deg, #f9fafb, #f3f4f6);
    text-align: center;
    transition: box-shadow 0.2s ease;
}

.stats-grid div:hover {
    box-shadow: var(--shadow);
}

.stats-grid strong {
    display: block;
    margin-bottom: 4px;
    color: #0f172a;
    font-size: 28px;
}

.stats-grid span {
    color: var(--muted);
}

.content-section,
.ranking-section,
.player-section {
    padding: 72px 0;
    background: #ffffff;
}

.light-section {
    background: #f9fafb;
}

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

.section-heading h2,
.ranking-page-grid h2,
.player-section h2,
.detail-article h2,
.side-panel h2 {
    margin: 0 0 8px;
    font-size: clamp(26px, 3vw, 38px);
    line-height: 1.15;
}

.section-heading p {
    margin: 0;
    color: var(--muted);
}

.section-more {
    color: var(--blue);
    font-weight: 800;
}

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

.category-card,
.category-overview-card,
.movie-card,
.side-panel,
.detail-article,
.filter-panel {
    background: var(--card);
    border: 1px solid rgba(229, 231, 235, 0.9);
    border-radius: var(--radius);
    box-shadow: 0 12px 34px rgba(15, 23, 42, 0.06);
}

.category-card {
    padding: 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-card:hover,
.movie-card:hover,
.category-overview-card:hover {
    box-shadow: var(--shadow);
}

.category-icon {
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    margin-bottom: 18px;
    border-radius: 18px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    font-size: 22px;
    font-weight: 900;
}

.category-card h3,
.movie-body h3 {
    margin: 0 0 10px;
    color: #111827;
}

.category-card p,
.movie-body p {
    color: var(--muted);
}

.category-card em {
    color: var(--blue);
    font-style: normal;
    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 {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-cover {
    position: relative;
    aspect-ratio: 2 / 2.85;
    overflow: hidden;
    background: linear-gradient(135deg, #e0f2fe, #f0fdfa);
}

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

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

.movie-year,
.movie-type {
    position: absolute;
    top: 12px;
    z-index: 2;
    padding: 5px 9px;
    border-radius: 999px;
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
}

.movie-year {
    left: 12px;
    background: rgba(37, 99, 235, 0.92);
}

.movie-type {
    right: 12px;
    background: rgba(15, 118, 110, 0.92);
}

.movie-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 16px;
}

.movie-body h3 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 18px;
    line-height: 1.35;
}

.movie-body p {
    display: -webkit-box;
    overflow: hidden;
    min-height: 48px;
    margin: 0 0 12px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 14px;
}

.movie-meta {
    margin-top: auto;
    color: #6b7280;
    font-size: 13px;
}

.movie-meta span + span::before {
    content: "·";
    margin-right: 10px;
    color: #9ca3af;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: 12px;
}

.tag-row span {
    padding: 4px 8px;
    border-radius: 999px;
    color: #0369a1;
    background: #eff6ff;
    font-size: 12px;
    font-weight: 700;
}

.ranking-section {
    color: #ffffff;
    background: #111827;
}

.ranking-section .section-heading h2,
.ranking-section .section-heading p {
    color: #ffffff;
}

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

.ranking-item {
    display: grid;
    grid-template-columns: 52px 58px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.08);
    transition: background 0.2s ease, transform 0.2s ease;
}

.ranking-item:hover {
    transform: translateX(4px);
    background: rgba(255, 255, 255, 0.14);
}

.ranking-number {
    color: #67e8f9;
    font-size: 22px;
    font-weight: 900;
}

.ranking-item img {
    width: 58px;
    height: 76px;
    border-radius: 10px;
    object-fit: cover;
}

.ranking-title {
    overflow: hidden;
    color: #ffffff;
    font-weight: 800;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.ranking-info {
    color: #d1d5db;
    font-size: 13px;
}

.cta-section {
    padding: 72px 0;
    color: #ffffff;
    background: linear-gradient(135deg, var(--blue), var(--primary-2));
}

.cta-box {
    text-align: center;
}

.cta-box h2 {
    margin: 0 0 10px;
    font-size: clamp(28px, 4vw, 42px);
}

.cta-box p {
    margin: 0 auto 24px;
    max-width: 680px;
    color: #ecfeff;
}

.page-hero,
.detail-hero {
    color: #ffffff;
    background: linear-gradient(135deg, #0f172a, #0f766e 55%, #0891b2);
}

.page-hero .container {
    padding: 72px 0;
}

.small-hero .container {
    padding: 56px 0;
}

.page-hero h1,
.detail-info h1 {
    max-width: 900px;
    margin: 0 0 16px;
    font-size: clamp(34px, 5vw, 56px);
    line-height: 1.12;
}

.page-hero p,
.detail-info .lead {
    max-width: 760px;
    margin: 0;
    color: #d1fae5;
    font-size: 18px;
}

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

.breadcrumb a {
    font-weight: 800;
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(260px, 1fr) auto;
    gap: 14px;
    margin-bottom: 28px;
    padding: 18px;
}

.filter-search input,
.filter-selects select {
    width: 100%;
    min-height: 46px;
    border: 1px solid var(--line);
    border-radius: 14px;
    outline: 0;
    padding: 0 14px;
    background: #f9fafb;
}

.filter-search input:focus,
.filter-selects select:focus {
    border-color: var(--blue);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.filter-selects {
    display: flex;
    gap: 10px;
}

.empty-state {
    display: none;
    padding: 40px;
    border-radius: 18px;
    background: #f9fafb;
    color: var(--muted);
    text-align: center;
}

.empty-state.show {
    display: block;
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin-top: 34px;
}

.pagination a,
.pagination span {
    min-width: 42px;
    padding: 10px 13px;
    border: 1px solid var(--line);
    border-radius: 12px;
    text-align: center;
}

.pagination a.active,
.pagination a:hover {
    color: #ffffff;
    background: var(--blue);
    border-color: var(--blue);
}

.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);
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-overview-card img {
    width: 100%;
    height: 100%;
    min-height: 230px;
    object-fit: cover;
}

.category-overview-card div {
    padding: 26px;
}

.category-overview-card span {
    color: var(--blue);
    font-weight: 900;
}

.category-overview-card h2 {
    margin: 8px 0 10px;
}

.category-overview-card p {
    color: var(--muted);
}

.category-overview-card em {
    color: var(--primary);
    font-style: normal;
    font-weight: 900;
}

.ranking-page-grid {
    display: grid;
    gap: 34px;
}

.ranking-page-grid section {
    padding: 26px;
    border-radius: var(--radius);
    background: #111827;
}

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

.detail-hero-grid {
    display: grid;
    grid-template-columns: 310px minmax(0, 1fr);
    align-items: center;
    gap: 42px;
    padding: 64px 0;
}

.detail-poster {
    overflow: hidden;
    border-radius: 28px;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.32);
}

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

.detail-info .lead {
    margin-bottom: 20px;
}

.detail-info .primary-button {
    margin-top: 24px;
}

.detail-tags span {
    color: #ecfeff;
    background: rgba(255, 255, 255, 0.13);
}

.player-section {
    background: #0b1220;
    color: #ffffff;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: #000000;
    box-shadow: 0 26px 70px rgba(0, 0, 0, 0.35);
}

.movie-video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 12px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.58));
    cursor: pointer;
}

.play-circle {
    width: 78px;
    height: 78px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--blue), var(--primary-2));
    box-shadow: 0 20px 46px rgba(37, 99, 235, 0.42);
    font-size: 32px;
}

.player-shell.is-playing .play-overlay,
.player-shell.is-ready .play-overlay {
    opacity: 0;
    pointer-events: none;
}

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

.detail-article,
.side-panel {
    padding: 28px;
}

.detail-article p {
    color: #374151;
    font-size: 17px;
}

.side-panel dl {
    margin: 0;
}

.side-panel dt {
    margin-top: 14px;
    color: var(--muted);
    font-size: 13px;
}

.side-panel dd {
    margin: 3px 0 0;
    color: #111827;
    font-weight: 800;
}

.site-footer {
    padding: 52px 0;
    color: #d1d5db;
    background: #111827;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr 1fr;
    gap: 32px;
}

.footer-brand {
    color: #ffffff;
    font-size: 20px;
}

.site-footer h2 {
    margin: 0 0 12px;
    color: #ffffff;
    font-size: 16px;
}

.site-footer a {
    display: block;
    margin: 8px 0;
    color: #d1d5db;
}

.site-footer p {
    margin: 10px 0 0;
    color: #9ca3af;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(18px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

    .menu-button {
        display: block;
        margin-left: auto;
    }

    .hero-slide,
    .detail-hero-grid,
    .detail-content-grid,
    .filter-panel {
        grid-template-columns: 1fr;
    }

    .hero-poster {
        min-height: auto;
    }

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

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

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

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

    .header-inner {
        min-height: 66px;
    }

    .brand-text strong {
        max-width: 220px;
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
    }

    .hero-shell {
        min-height: auto;
        padding: 48px 0 78px;
    }

    .hero-slide {
        gap: 28px;
    }

    .hero-controls {
        left: 0;
        right: 0;
        justify-content: center;
    }

    .stats-grid,
    .category-grid,
    .movie-grid,
    .large-grid,
    .ranking-list,
    .full-list,
    .category-overview-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

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

    .filter-selects {
        flex-direction: column;
    }

    .ranking-item {
        grid-template-columns: 42px 52px minmax(0, 1fr);
    }

    .ranking-info {
        display: none;
    }

    .content-section,
    .ranking-section,
    .player-section {
        padding: 48px 0;
    }

    .detail-hero-grid {
        padding: 44px 0;
    }

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