* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: #020617;
    color: #ffffff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

body::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

body::-webkit-scrollbar-track {
    background: #0f172a;
}

body::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 999px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(15, 23, 42, 0.94);
    border-bottom: 1px solid rgba(30, 41, 59, 0.96);
    backdrop-filter: blur(14px);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1280px;
    height: 64px;
    padding: 0 24px;
    margin: 0 auto;
}

.logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    color: #ffffff;
    box-shadow: 0 16px 45px rgba(6, 182, 212, 0.28);
}

.logo-text,
.footer-logo span:last-child {
    background: linear-gradient(90deg, #22d3ee, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 21px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 20px;
    color: #cbd5e1;
    font-size: 14px;
    white-space: nowrap;
}

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

.desktop-nav a:hover,
.mobile-nav a:hover,
.footer-links a:hover {
    color: #22d3ee;
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    background: transparent;
    color: #cbd5e1;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: currentColor;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    padding: 10px 24px 22px;
    border-top: 1px solid #1e293b;
    background: rgba(15, 23, 42, 0.98);
}

.mobile-nav a {
    display: block;
    padding: 10px 0;
    color: #cbd5e1;
}

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

main {
    min-height: 70vh;
}

.hero {
    max-width: 1280px;
    padding: 32px 24px 0;
    margin: 0 auto 64px;
}

.hero-carousel {
    position: relative;
    min-height: 520px;
    overflow: hidden;
    border: 1px solid rgba(30, 41, 59, 0.86);
    border-radius: 28px;
    background: radial-gradient(circle at 20% 10%, rgba(34, 211, 238, 0.18), transparent 35%), #0f172a;
    box-shadow: 0 28px 80px rgba(0, 0, 0, 0.38);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transform: scale(1.02);
    transition: opacity 0.5s ease, transform 0.7s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.hero-image {
    width: 100%;
    height: 100%;
    min-height: 520px;
    object-fit: cover;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.96) 0%, rgba(2, 6, 23, 0.74) 44%, rgba(2, 6, 23, 0.18) 100%), linear-gradient(0deg, rgba(2, 6, 23, 0.96), transparent 54%);
}

.hero-content {
    position: absolute;
    left: clamp(24px, 6vw, 84px);
    bottom: clamp(34px, 8vw, 88px);
    max-width: 720px;
    z-index: 2;
}

.hero-eyebrow,
.section-kicker {
    margin: 0 0 10px;
    color: #22d3ee;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1,
.hero h2,
.page-hero h1 {
    margin: 0;
    line-height: 1.08;
    font-size: clamp(34px, 6vw, 68px);
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero h2 {
    margin-top: 12px;
    font-size: clamp(25px, 4vw, 44px);
}

.hero p,
.page-hero p,
.search-panel p,
.channel-card em,
.category-tile small {
    color: #cbd5e1;
}

.hero-content > p:not(.hero-eyebrow) {
    max-width: 620px;
    margin: 18px 0 0;
    font-size: 18px;
}

.hero-tags,
.detail-meta,
.tag-cloud,
.page-actions,
.hero-actions,
.hero-quick-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

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

.hero-tags span,
.detail-meta span,
.tag-cloud span {
    border: 1px solid rgba(51, 65, 85, 0.9);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.72);
    color: #e2e8f0;
    padding: 7px 13px;
    font-size: 13px;
}

.hero-actions,
.page-actions {
    margin-top: 28px;
}

.button,
.home-search button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 20px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.button.primary,
.home-search button {
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    color: #ffffff;
    box-shadow: 0 16px 36px rgba(37, 99, 235, 0.28);
}

.button.ghost {
    border-color: rgba(148, 163, 184, 0.28);
    background: rgba(15, 23, 42, 0.72);
    color: #e2e8f0;
}

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

.button.full {
    width: 100%;
    margin-top: 16px;
}

.hero-control {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 44px;
    height: 44px;
    transform: translateY(-50%);
    border: 0;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.78);
    color: #ffffff;
    font-size: 34px;
    line-height: 1;
    cursor: pointer;
}

.hero-control.prev {
    left: 18px;
}

.hero-control.next {
    right: 18px;
}

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

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

.hero-dot.is-active {
    width: 30px;
    background: #06b6d4;
}

.hero-quick-links {
    align-items: center;
    padding: 16px 4px 0;
}

.hero-quick-links a {
    border: 1px solid rgba(51, 65, 85, 0.85);
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.74);
    color: #cbd5e1;
    padding: 8px 14px;
    font-size: 14px;
}

.hero-quick-links a:hover {
    border-color: rgba(34, 211, 238, 0.7);
    color: #67e8f9;
}

.search-panel,
.content-section,
.page-hero,
.detail-wrap {
    max-width: 1280px;
    padding: 0 24px;
    margin: 0 auto 64px;
}

.search-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
    gap: 24px;
    align-items: center;
    padding-top: 32px;
    padding-bottom: 32px;
    border: 1px solid rgba(30, 41, 59, 0.85);
    border-radius: 24px;
    background: linear-gradient(135deg, rgba(8, 47, 73, 0.82), rgba(15, 23, 42, 0.96));
}

.search-panel h2,
.section-head h2,
.text-panel h2,
.site-footer h2 {
    margin: 0;
    font-size: 26px;
    line-height: 1.2;
}

.home-search,
.filter-bar {
    display: flex;
    gap: 10px;
}

.home-search input,
.filter-bar input,
.filter-bar select {
    width: 100%;
    min-height: 46px;
    border: 1px solid rgba(51, 65, 85, 0.9);
    border-radius: 12px;
    outline: none;
    background: rgba(2, 6, 23, 0.78);
    color: #ffffff;
    padding: 0 14px;
}

.home-search input:focus,
.filter-bar input:focus,
.filter-bar select:focus {
    border-color: #06b6d4;
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.14);
}

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

.section-head a {
    color: #67e8f9;
    font-weight: 700;
}

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

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

.movie-card {
    min-width: 0;
}

.card-link {
    display: block;
}

.poster-frame {
    position: relative;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    margin: 0;
    border: 1px solid rgba(51, 65, 85, 0.66);
    border-radius: 18px;
    background: #0f172a;
}

.poster-frame img,
.category-tile img,
.channel-card img,
.detail-poster img,
.rank-link img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.poster-frame img,
.category-tile img,
.channel-card img {
    transition: transform 0.5s ease, filter 0.5s ease;
}

.card-link:hover .poster-frame img,
.category-tile:hover img,
.channel-card a:hover img {
    transform: scale(1.08);
    filter: saturate(1.1);
}

.poster-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 45%, rgba(2, 6, 23, 0.88));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.card-link:hover .poster-frame::after {
    opacity: 1;
}

.card-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    max-width: calc(100% - 20px);
    padding: 5px 9px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.82);
    color: #dbeafe;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.play-mark {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border-radius: 999px;
    background: rgba(6, 182, 212, 0.92);
    color: #ffffff;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.88);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.card-link:hover .play-mark {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

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

.card-body h3 {
    display: -webkit-box;
    overflow: hidden;
    min-height: 44px;
    margin: 0 0 6px;
    color: #ffffff;
    font-size: 16px;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color 0.2s ease;
}

.card-link:hover h3 {
    color: #22d3ee;
}

.card-meta,
.card-desc {
    margin: 0;
    color: #94a3b8;
    font-size: 13px;
}

.card-desc {
    display: -webkit-box;
    overflow: hidden;
    margin-top: 6px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

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

.category-tile {
    position: relative;
    min-height: 210px;
    overflow: hidden;
    border: 1px solid rgba(51, 65, 85, 0.7);
    border-radius: 20px;
    background: #0f172a;
}

.category-tile::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.18));
}

.category-tile span,
.category-tile small {
    position: absolute;
    left: 18px;
    right: 18px;
    z-index: 2;
}

.category-tile span {
    bottom: 62px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 800;
}

.category-tile small {
    bottom: 18px;
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.accent-section {
    padding-top: 42px;
    padding-bottom: 42px;
    border: 1px solid rgba(30, 41, 59, 0.72);
    border-radius: 24px;
    background: rgba(15, 23, 42, 0.42);
}

.page-hero {
    margin-top: 32px;
    padding-top: 54px;
    padding-bottom: 54px;
    border: 1px solid rgba(30, 41, 59, 0.84);
    border-radius: 28px;
    background: radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 35%), linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(2, 6, 23, 0.98));
}

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

.slim-hero {
    padding-top: 42px;
    padding-bottom: 42px;
}

.rank-hero {
    background: radial-gradient(circle at 88% 20%, rgba(59, 130, 246, 0.22), transparent 36%), radial-gradient(circle at 5% 10%, rgba(6, 182, 212, 0.2), transparent 38%), #0f172a;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(130px, 180px) minmax(130px, 220px);
    margin-bottom: 26px;
}

.filter-bar label {
    display: grid;
    gap: 7px;
    color: #cbd5e1;
    font-size: 13px;
}

.empty-state {
    display: none;
    padding: 48px 0;
    color: #94a3b8;
    text-align: center;
}

.empty-state.is-visible {
    display: block;
}

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

.rank-link {
    display: grid;
    grid-template-columns: 64px 72px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 12px;
    border: 1px solid rgba(30, 41, 59, 0.86);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.7);
    transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.rank-link:hover {
    transform: translateY(-2px);
    border-color: rgba(34, 211, 238, 0.55);
    background: rgba(15, 23, 42, 0.94);
}

.rank-number {
    color: #22d3ee;
    font-size: 28px;
    font-weight: 900;
    text-align: center;
}

.rank-link img {
    aspect-ratio: 2 / 3;
    border-radius: 10px;
}

.rank-text {
    display: grid;
    gap: 5px;
}

.rank-text strong {
    color: #ffffff;
    font-size: 18px;
}

.rank-text em,
.rank-text small {
    color: #94a3b8;
    font-style: normal;
}

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

.channel-card {
    overflow: hidden;
    border: 1px solid rgba(30, 41, 59, 0.82);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.76);
}

.channel-card > a {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    min-height: 220px;
}

.channel-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
    padding: 26px;
}

.channel-info strong {
    font-size: 26px;
}

.channel-info em {
    font-style: normal;
}

.channel-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 18px 22px 22px;
    border-top: 1px solid rgba(30, 41, 59, 0.82);
}

.channel-links a {
    overflow: hidden;
    color: #cbd5e1;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.channel-links a:hover {
    color: #22d3ee;
}

.detail-wrap {
    margin-top: 32px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-bottom: 20px;
    color: #94a3b8;
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #22d3ee;
}

.player-card {
    overflow: hidden;
    border: 1px solid rgba(30, 41, 59, 0.9);
    border-radius: 24px;
    background: #000000;
    box-shadow: 0 26px 70px rgba(0, 0, 0, 0.42);
}

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

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

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.26), rgba(2, 6, 23, 0.66));
    cursor: pointer;
}

.player-overlay span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 86px;
    height: 86px;
    padding-left: 7px;
    border-radius: 999px;
    background: linear-gradient(135deg, #06b6d4, #2563eb);
    color: #ffffff;
    font-size: 38px;
    box-shadow: 0 18px 52px rgba(6, 182, 212, 0.3);
}

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

.detail-grid {
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 32px;
    margin-top: 34px;
}

.detail-poster img {
    width: 100%;
    aspect-ratio: 2 / 3;
    border: 1px solid rgba(51, 65, 85, 0.8);
    border-radius: 20px;
    object-fit: cover;
}

.detail-main h1 {
    margin: 0 0 18px;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.16;
}

.detail-meta {
    margin-bottom: 22px;
}

.lead-text {
    margin: 0 0 20px;
    color: #e2e8f0;
    font-size: 19px;
}

.tag-cloud {
    margin-bottom: 24px;
}

.text-panel {
    padding: 24px;
    margin-top: 18px;
    border: 1px solid rgba(30, 41, 59, 0.84);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.58);
}

.text-panel p {
    margin: 14px 0 0;
    color: #cbd5e1;
    font-size: 16px;
}

.related-section {
    padding-left: 0;
    padding-right: 0;
    margin-top: 64px;
}

.site-footer {
    border-top: 1px solid rgba(30, 41, 59, 0.92);
    background: #0f172a;
}

.footer-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) 1fr 1fr;
    gap: 34px;
    max-width: 1280px;
    padding: 44px 24px;
    margin: 0 auto;
}

.site-footer p {
    max-width: 520px;
    color: #94a3b8;
}

.footer-links {
    display: grid;
    gap: 10px;
    margin-top: 16px;
    color: #cbd5e1;
}

.footer-bottom {
    padding: 18px 24px;
    border-top: 1px solid rgba(30, 41, 59, 0.92);
    color: #64748b;
    text-align: center;
}

@media (max-width: 1180px) {
    .desktop-nav {
        gap: 14px;
        font-size: 13px;
    }

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

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

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

    .menu-toggle {
        display: flex;
    }

    .hero,
    .search-panel,
    .content-section,
    .page-hero,
    .detail-wrap {
        padding-left: 18px;
        padding-right: 18px;
    }

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

    .search-panel,
    .footer-inner,
    .detail-grid,
    .channel-card > a {
        grid-template-columns: 1fr;
    }

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

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

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

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

@media (max-width: 620px) {
    .header-inner {
        padding: 0 16px;
    }

    .logo-text {
        font-size: 18px;
    }

    .hero {
        padding: 18px 14px 0;
        margin-bottom: 42px;
    }

    .hero-carousel,
    .hero-image {
        min-height: 620px;
        border-radius: 22px;
    }

    .hero-shade {
        background: linear-gradient(0deg, rgba(2, 6, 23, 0.98) 0%, rgba(2, 6, 23, 0.78) 62%, rgba(2, 6, 23, 0.28) 100%);
    }

    .hero-content {
        left: 22px;
        right: 22px;
        bottom: 56px;
    }

    .hero-control {
        display: none;
    }

    .home-search {
        flex-direction: column;
    }

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

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

    .card-body h3 {
        font-size: 14px;
    }

    .card-desc {
        display: none;
    }

    .page-hero {
        margin-top: 20px;
        padding-top: 34px;
        padding-bottom: 34px;
        border-radius: 22px;
    }

    .rank-link {
        grid-template-columns: 42px 58px minmax(0, 1fr);
        gap: 10px;
    }

    .rank-number {
        font-size: 20px;
    }

    .rank-text small {
        display: none;
    }

    .player-overlay span {
        width: 68px;
        height: 68px;
        font-size: 30px;
    }
}
