:root {
    color-scheme: dark;
    --bg: #020617;
    --panel: rgba(15, 23, 42, 0.92);
    --panel-soft: rgba(30, 41, 59, 0.72);
    --line: rgba(51, 65, 85, 0.78);
    --line-bright: rgba(6, 182, 212, 0.48);
    --text: #f8fafc;
    --muted: #94a3b8;
    --soft: #cbd5e1;
    --cyan: #22d3ee;
    --cyan-strong: #06b6d4;
    --blue: #3b82f6;
    --orange: #f59e0b;
    --shadow: 0 24px 70px rgba(6, 182, 212, 0.15);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at top left, rgba(6, 182, 212, 0.16), transparent 32rem),
        radial-gradient(circle at 70% 5%, rgba(59, 130, 246, 0.12), transparent 30rem),
        linear-gradient(180deg, #020617 0%, #0f172a 38%, #020617 100%);
    color: var(--text);
}

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

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

button,
input,
select,
textarea {
    font: inherit;
}

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

.nav-shell {
    width: min(1180px, calc(100% - 32px));
    height: 68px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 18px;
}

.site-logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    background: linear-gradient(90deg, #67e8f9, #60a5fa);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    white-space: nowrap;
}

.logo-mark {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 999px;
    background: rgba(6, 182, 212, 0.16);
    color: var(--cyan);
    box-shadow: 0 0 30px rgba(34, 211, 238, 0.22);
}

.desktop-nav {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 4px;
    min-width: 0;
    overflow: hidden;
}

.desktop-nav a,
.mobile-nav a {
    padding: 10px 12px;
    border-radius: 11px;
    color: #cbd5e1;
    font-size: 0.92rem;
    font-weight: 650;
    transition: color 0.22s ease, background 0.22s ease, transform 0.22s ease;
    white-space: nowrap;
}

.desktop-nav a:hover,
.mobile-nav a:hover {
    color: var(--cyan);
    background: rgba(30, 41, 59, 0.76);
    transform: translateY(-1px);
}

.nav-search,
.mobile-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select {
    border: 1px solid rgba(51, 65, 85, 0.86);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.8);
    color: var(--text);
    outline: none;
    transition: border 0.22s ease, box-shadow 0.22s ease;
}

.nav-search input {
    width: 210px;
    padding: 10px 12px;
}

.nav-search input:focus,
.mobile-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--cyan-strong);
    box-shadow: 0 0 0 4px rgba(6, 182, 212, 0.12);
}

.nav-search button,
.mobile-search button,
.primary-btn,
.secondary-btn,
.text-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    cursor: pointer;
    color: #fff;
    font-weight: 750;
    border-radius: 12px;
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.nav-search button,
.mobile-search button,
.primary-btn {
    background: linear-gradient(90deg, var(--cyan-strong), var(--blue));
    box-shadow: 0 15px 34px rgba(6, 182, 212, 0.28);
}

.nav-search button,
.mobile-search button {
    padding: 10px 14px;
}

.primary-btn {
    padding: 14px 24px;
}

.secondary-btn {
    padding: 13px 22px;
    color: #dbeafe;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid rgba(148, 163, 184, 0.24);
}

.primary-btn:hover,
.secondary-btn:hover,
.nav-search button:hover,
.mobile-search button:hover,
.text-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 46px rgba(6, 182, 212, 0.32);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(51, 65, 85, 0.86);
    border-radius: 12px;
    color: var(--cyan);
    background: rgba(15, 23, 42, 0.78);
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 14px 0 18px;
    border-top: 1px solid rgba(51, 65, 85, 0.55);
}

.mobile-nav.is-open {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.mobile-search {
    margin-bottom: 6px;
}

.mobile-search input {
    flex: 1;
    padding: 11px 12px;
}

.hero {
    position: relative;
    min-height: 72vh;
    max-height: 820px;
    overflow: hidden;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(51, 65, 85, 0.45);
}

.hero-bg,
.hero-bg img,
.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.08) contrast(1.04);
}

.hero-overlay {
    background:
        linear-gradient(90deg, rgba(2, 6, 23, 0.94), rgba(2, 6, 23, 0.7) 48%, rgba(2, 6, 23, 0.38)),
        linear-gradient(0deg, #020617 0%, rgba(2, 6, 23, 0.5) 45%, rgba(2, 6, 23, 0.3) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 80px 0;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
    color: var(--cyan);
    font-weight: 800;
    letter-spacing: 0.04em;
}

.hero h1,
.page-hero h1,
.detail-title h1 {
    margin: 0;
    color: #fff;
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero h1 {
    max-width: 900px;
    font-size: clamp(2.6rem, 7vw, 5.8rem);
}

.hero p {
    max-width: 760px;
    margin: 24px 0 0;
    color: #d1d5db;
    font-size: clamp(1.05rem, 2vw, 1.36rem);
    line-height: 1.8;
}

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

.hero-meta {
    margin: 28px 0;
}

.hero-meta span,
.detail-meta span,
.rank-meta span,
.card-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 6px 10px;
    border-radius: 9px;
    background: rgba(15, 23, 42, 0.78);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #e2e8f0;
    font-size: 0.88rem;
}

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

.hero-strip {
    position: relative;
    z-index: 2;
    width: min(1180px, calc(100% - 32px));
    margin: -104px auto 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.focus-card {
    min-height: 138px;
    display: flex;
    align-items: flex-end;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(51, 65, 85, 0.7);
    border-radius: 18px;
    background: var(--panel);
    box-shadow: var(--shadow);
    transform: translateZ(0);
}

.focus-card img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.72;
    transition: transform 0.5s ease, opacity 0.5s ease;
}

.focus-card span {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(2, 6, 23, 0.96), rgba(2, 6, 23, 0.16));
}

.focus-card strong {
    position: relative;
    z-index: 2;
    padding: 18px;
    color: #fff;
    line-height: 1.35;
}

.focus-card:hover img {
    transform: scale(1.08);
    opacity: 0.95;
}

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

.section-block {
    padding: 72px 0 0;
}

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

.section-head h2,
.page-hero h1 {
    margin: 0;
    color: #f8fafc;
    font-size: clamp(1.7rem, 3vw, 2.45rem);
    font-weight: 900;
    letter-spacing: -0.03em;
}

.section-head p,
.page-hero p,
.detail-title p,
.channel-card p,
.site-footer p {
    color: var(--muted);
    line-height: 1.75;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(30, 41, 59, 0.92);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.9);
    transition: border-color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease;
}

.movie-card:hover {
    border-color: var(--line-bright);
    box-shadow: 0 22px 52px rgba(6, 182, 212, 0.16);
    transform: translateY(-4px);
}

.movie-poster {
    position: relative;
    display: block;
    height: 270px;
    overflow: hidden;
    background: rgba(30, 41, 59, 0.6);
}

.compact-grid .movie-poster,
.movie-card-small .movie-poster {
    height: 185px;
}

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

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

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

.play-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    display: grid;
    width: 58px;
    height: 58px;
    place-items: center;
    border-radius: 999px;
    background: rgba(6, 182, 212, 0.86);
    color: white;
    box-shadow: 0 18px 44px rgba(6, 182, 212, 0.34);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.86);
    transition: opacity 0.28s ease, transform 0.28s ease;
}

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

.category-badge,
.meta-badges {
    position: absolute;
    z-index: 2;
}

.category-badge {
    top: 12px;
    left: 12px;
    padding: 6px 9px;
    border: 1px solid rgba(6, 182, 212, 0.32);
    border-radius: 9px;
    color: var(--cyan);
    background: rgba(2, 6, 23, 0.72);
    font-size: 0.76rem;
    font-weight: 800;
    backdrop-filter: blur(12px);
}

.meta-badges {
    right: 12px;
    bottom: 12px;
    display: flex;
    gap: 6px;
}

.meta-badges b {
    padding: 5px 8px;
    border-radius: 8px;
    background: rgba(2, 6, 23, 0.78);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 800;
}

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

.movie-card-body h3 {
    min-height: 2.8em;
    margin: 0;
    color: #e2e8f0;
    font-size: 1.02rem;
    line-height: 1.38;
    font-weight: 800;
    transition: color 0.2s ease;
}

.movie-card:hover h3 {
    color: var(--cyan);
}

.movie-card-body p {
    min-height: 3.2em;
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.65;
}

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

.tag-row span {
    padding: 5px 8px;
    border-radius: 8px;
    background: rgba(30, 41, 59, 0.9);
    color: #94a3b8;
    font-size: 0.75rem;
}

.page-hero {
    padding: 70px 0 36px;
    background:
        radial-gradient(circle at 16% 12%, rgba(6, 182, 212, 0.18), transparent 25rem),
        linear-gradient(180deg, rgba(15, 23, 42, 0.55), rgba(2, 6, 23, 0));
}

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

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

.channel-card {
    min-height: 210px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px;
    border: 1px solid rgba(30, 41, 59, 0.96);
    border-radius: 20px;
    background:
        radial-gradient(circle at top right, rgba(6, 182, 212, 0.16), transparent 14rem),
        rgba(15, 23, 42, 0.78);
    transition: border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.channel-card:hover {
    border-color: var(--line-bright);
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.channel-card h2 {
    margin: 0 0 12px;
    color: #f8fafc;
    font-size: 1.34rem;
}

.filter-panel {
    display: grid;
    grid-template-columns: 2fr repeat(3, 1fr);
    gap: 14px;
    padding: 18px;
    margin-bottom: 28px;
    border: 1px solid rgba(30, 41, 59, 0.9);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.72);
}

.filter-panel label {
    display: grid;
    gap: 8px;
    color: #cbd5e1;
    font-size: 0.88rem;
    font-weight: 750;
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
}

.hidden-card {
    display: none;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 56px 86px 1fr auto;
    align-items: center;
    gap: 18px;
    padding: 14px;
    border: 1px solid rgba(30, 41, 59, 0.9);
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.84);
    transition: border-color 0.22s ease, transform 0.22s ease, box-shadow 0.22s ease;
}

.rank-row:hover {
    border-color: var(--line-bright);
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(6, 182, 212, 0.12);
}

.rank-num {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    background: rgba(6, 182, 212, 0.14);
    color: var(--cyan);
    font-weight: 900;
}

.rank-thumb {
    display: block;
    width: 86px;
    height: 116px;
    overflow: hidden;
    border-radius: 12px;
    background: rgba(30, 41, 59, 0.75);
}

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

.rank-main h3 {
    margin: 0 0 8px;
    color: #f8fafc;
    font-size: 1.08rem;
}

.rank-main p {
    margin: 0 0 10px;
    color: var(--muted);
    line-height: 1.65;
}

.text-link {
    padding: 10px 14px;
    color: var(--cyan);
    background: rgba(6, 182, 212, 0.1);
    border: 1px solid rgba(6, 182, 212, 0.25);
    white-space: nowrap;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 34px 0 18px;
    color: var(--muted);
    font-size: 0.92rem;
}

.breadcrumb a {
    color: var(--cyan);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(300px, 0.78fr);
    gap: 30px;
    align-items: start;
}

.player-box,
.detail-side,
.content-panel {
    border: 1px solid rgba(30, 41, 59, 0.95);
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.88);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
}

.player-box {
    overflow: hidden;
}

.player-stage {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #020617;
    cursor: pointer;
}

.player-stage video,
.player-poster {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.player-stage video {
    z-index: 1;
    object-fit: contain;
    background: #020617;
}

.player-poster {
    z-index: 2;
    pointer-events: none;
}

.player-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.76;
    filter: blur(1px) saturate(1.05);
}

.player-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.1), rgba(2, 6, 23, 0.78));
}

.player-start {
    position: absolute;
    z-index: 3;
    top: 50%;
    left: 50%;
    display: grid;
    width: 82px;
    height: 82px;
    place-items: center;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--cyan-strong), var(--blue));
    color: white;
    cursor: pointer;
    font-size: 2rem;
    box-shadow: 0 22px 60px rgba(6, 182, 212, 0.32);
    transform: translate(-50%, -50%);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.player-start:hover {
    transform: translate(-50%, -50%) scale(1.06);
    box-shadow: 0 28px 76px rgba(6, 182, 212, 0.42);
}

.player-stage.is-playing .player-poster,
.player-stage.is-playing .player-start {
    display: none;
}

.player-caption {
    padding: 18px 20px;
    color: #cbd5e1;
    border-top: 1px solid rgba(30, 41, 59, 0.88);
}

.detail-side {
    padding: 22px;
}

.detail-cover {
    overflow: hidden;
    border-radius: 18px;
    aspect-ratio: 3 / 4;
    margin-bottom: 20px;
    background: rgba(30, 41, 59, 0.76);
}

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

.detail-title h1 {
    font-size: clamp(2rem, 3.4vw, 3.5rem);
    margin-bottom: 16px;
}

.detail-title p {
    margin: 0 0 20px;
}

.detail-meta {
    margin: 18px 0;
}

.content-panel {
    padding: 28px;
    margin-top: 28px;
}

.content-panel h2 {
    margin: 0 0 16px;
    color: #f8fafc;
    font-size: 1.55rem;
}

.content-panel p {
    margin: 0 0 18px;
    color: #cbd5e1;
    line-height: 1.9;
    font-size: 1rem;
}

.site-footer {
    margin-top: 86px;
    padding: 48px 0 28px;
    border-top: 1px solid rgba(30, 41, 59, 0.78);
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.62), #020617);
}

.footer-grid {
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.5fr 0.7fr 1fr;
    gap: 34px;
}

.site-footer h2 {
    margin: 0 0 16px;
    color: #e2e8f0;
    font-size: 1.02rem;
}

.site-footer ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 10px;
}

.site-footer a:not(.footer-logo) {
    color: var(--muted);
    transition: color 0.2s ease;
}

.site-footer a:hover {
    color: var(--cyan);
}

.footer-bottom {
    width: min(1180px, calc(100% - 32px));
    margin: 34px auto 0;
    padding-top: 22px;
    border-top: 1px solid rgba(30, 41, 59, 0.75);
    display: flex;
    justify-content: space-between;
    gap: 14px;
    color: #64748b;
    font-size: 0.9rem;
}

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

    .menu-toggle {
        display: inline-grid;
        place-items: center;
        margin-left: auto;
    }

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

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

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

@media (max-width: 760px) {
    .nav-shell {
        height: 62px;
    }

    .hero {
        min-height: 660px;
        align-items: flex-start;
    }

    .hero-content {
        padding: 64px 0 150px;
    }

    .hero-strip {
        margin-top: -132px;
        grid-template-columns: 1fr;
    }

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

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

    .movie-poster,
    .compact-grid .movie-poster,
    .movie-card-small .movie-poster {
        height: 210px;
    }

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

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

    .rank-row {
        grid-template-columns: 42px 70px 1fr;
        gap: 12px;
    }

    .rank-row .text-link {
        grid-column: 2 / 4;
        width: max-content;
    }

    .rank-thumb {
        width: 70px;
        height: 96px;
    }

    .footer-bottom {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .card-grid,
    .card-grid.compact-grid {
        grid-template-columns: 1fr;
    }

    .movie-poster,
    .compact-grid .movie-poster,
    .movie-card-small .movie-poster {
        height: 300px;
    }

    .hero h1 {
        font-size: 2.4rem;
    }

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

    .primary-btn,
    .secondary-btn {
        width: 100%;
    }
}
