:root {
    --primary-50: #f0f7ff;
    --primary-400: #36aaf7;
    --primary-600: #006fc6;
    --primary-700: #0158a0;
    --primary-900: #0b3f6e;
    --accent-300: #5feacf;
    --accent-500: #14b8a2;
    --accent-600: #0d9485;
    --neutral-50: #f8fafc;
    --neutral-100: #f1f5f9;
    --neutral-200: #e2e8f0;
    --neutral-400: #94a3b8;
    --neutral-600: #475569;
    --neutral-700: #334155;
    --neutral-800: #1e293b;
    --neutral-900: #0f172a;
    --shadow-md: 0 4px 16px rgba(15, 23, 42, 0.12);
    --shadow-xl: 0 24px 48px rgba(15, 23, 42, 0.18);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--neutral-50);
    color: var(--neutral-900);
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: linear-gradient(90deg, var(--primary-900), var(--primary-600), var(--accent-600));
    color: #ffffff;
    box-shadow: var(--shadow-md);
}

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

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand-mark {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
}

.brand-text {
    font-size: 20px;
}

.desktop-nav {
    display: flex;
    gap: 6px;
}

.nav-link,
.mobile-link {
    display: inline-flex;
    align-items: center;
    border-radius: 10px;
    padding: 10px 14px;
    color: rgba(255, 255, 255, 0.88);
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active,
.mobile-link:hover,
.mobile-link.is-active {
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
}

.menu-button {
    display: none;
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    border: 0;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.12);
    cursor: pointer;
}

.menu-button span {
    width: 20px;
    height: 2px;
    background: #ffffff;
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 14px;
}

.hero {
    position: relative;
    overflow: hidden;
    min-height: 640px;
    background: var(--neutral-900);
}

.hero-track {
    display: flex;
    width: 100%;
    min-height: 640px;
    transition: transform 0.5s ease-out;
}

.hero-slide {
    position: relative;
    flex: 0 0 100%;
    min-height: 640px;
    color: #ffffff;
}

.hero-slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 78% 20%, rgba(20, 184, 162, 0.28), transparent 30%),
        linear-gradient(90deg, rgba(11, 63, 110, 0.92), rgba(0, 0, 0, 0.56) 56%, rgba(0, 0, 0, 0.24)),
        linear-gradient(0deg, rgba(0, 0, 0, 0.88), transparent 52%);
}

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

.eyebrow {
    margin: 0 0 12px;
    color: var(--accent-300);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-copy h1 {
    margin: 0;
    max-width: 780px;
    font-size: clamp(34px, 6vw, 72px);
    line-height: 1.06;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero-meta {
    margin: 16px 0 0;
    max-width: 760px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
}

.hero-desc {
    max-width: 760px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.92);
    font-size: 18px;
}

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

.primary-button,
.ghost-button,
.section-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border-radius: 12px;
    padding: 11px 18px;
    font-weight: 700;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    background: var(--primary-600);
    color: #ffffff;
    box-shadow: 0 14px 32px rgba(0, 111, 198, 0.28);
}

.primary-button:hover {
    background: var(--primary-700);
    transform: translateY(-2px);
}

.ghost-button {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.24);
    backdrop-filter: blur(8px);
}

.ghost-button:hover {
    background: rgba(255, 255, 255, 0.24);
    transform: translateY(-2px);
}

.ghost-button.light {
    color: var(--primary-900);
    background: #ffffff;
}

.section-link {
    min-height: 40px;
    color: var(--primary-700);
    background: var(--primary-50);
}

.section-link:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

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

.hero-control:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.74);
}

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

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

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

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

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

.content-section {
    padding: 54px 0;
}

.quick-search-section {
    margin-top: -56px;
    position: relative;
    z-index: 5;
}

.search-banner,
.filter-panel,
.article-card,
.side-panel,
.category-overview-card {
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-xl);
    backdrop-filter: blur(12px);
}

.search-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 28px;
    background: linear-gradient(135deg, rgba(0, 111, 198, 0.95), rgba(13, 148, 133, 0.9));
    color: #ffffff;
}

.search-banner h2 {
    margin: 0;
    font-size: clamp(24px, 3vw, 36px);
}

.filter-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 16px;
    margin-top: 18px;
    padding: 18px;
}

.search-field,
.select-field {
    display: grid;
    gap: 8px;
    color: var(--neutral-700);
    font-weight: 700;
}

.search-field input,
.select-field select {
    width: 100%;
    height: 48px;
    border: 1px solid var(--neutral-200);
    border-radius: 14px;
    padding: 0 14px;
    outline: 0;
    background: #ffffff;
    color: var(--neutral-900);
}

.search-field input:focus,
.select-field select:focus {
    border-color: var(--primary-400);
    box-shadow: 0 0 0 4px rgba(54, 170, 247, 0.16);
}

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

.section-heading h2,
.side-panel h2,
.article-card h2 {
    margin: 0;
    color: var(--neutral-900);
    font-size: clamp(24px, 3vw, 36px);
    line-height: 1.18;
}

.section-heading p {
    margin: 8px 0 0;
    color: var(--neutral-600);
}

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

.movie-card {
    overflow: hidden;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow-md);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
}

.card-cover {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: var(--neutral-200);
}

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

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

.card-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.68), transparent 60%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

.movie-card:hover .card-gradient {
    opacity: 1;
}

.play-icon {
    position: absolute;
    left: 50%;
    top: 50%;
    display: inline-flex;
    width: 56px;
    height: 56px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.2);
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
    backdrop-filter: blur(6px);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.card-category,
.rank-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    border-radius: 999px;
    padding: 5px 10px;
    color: #ffffff;
    background: var(--accent-500);
    font-size: 12px;
    font-weight: 800;
}

.rank-badge {
    left: auto;
    right: 12px;
    background: rgba(0, 0, 0, 0.72);
}

.card-body {
    padding: 16px;
}

.card-body h2 {
    margin: 0 0 6px;
    font-size: 18px;
    line-height: 1.35;
}

.card-body h2 a:hover {
    color: var(--primary-600);
}

.card-meta,
.card-desc {
    margin: 0;
    color: var(--neutral-600);
    font-size: 14px;
}

.card-desc {
    margin-top: 10px;
    min-height: 44px;
}

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

.tag-row span {
    border-radius: 999px;
    padding: 4px 9px;
    background: var(--primary-50);
    color: var(--primary-700);
    font-size: 12px;
    font-weight: 700;
}

.card-stats {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 12px;
    color: var(--neutral-700);
    font-size: 13px;
    font-weight: 700;
}

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

.category-tile {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    overflow: hidden;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: var(--shadow-md);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-xl);
}

.category-thumbs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    min-height: 160px;
    background: var(--neutral-200);
}

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

.category-copy {
    display: grid;
    align-content: center;
    gap: 10px;
    padding: 22px;
}

.category-copy strong {
    font-size: 24px;
}

.category-copy em {
    color: var(--neutral-600);
    font-style: normal;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 28px;
}

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

.compact-card {
    display: grid;
    grid-template-columns: 160px minmax(0, 1fr);
}

.compact-card .card-cover {
    height: 100%;
    min-height: 130px;
    aspect-ratio: auto;
}

.compact-card .card-desc {
    min-height: auto;
}

.side-panel {
    align-self: start;
    padding: 22px;
}

.side-panel h2 {
    margin-bottom: 18px;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background:
        radial-gradient(circle at 15% 0, rgba(20, 184, 162, 0.34), transparent 28%),
        linear-gradient(135deg, var(--primary-900), var(--neutral-900));
}

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

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

.page-hero p {
    max-width: 760px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
}

.small-actions {
    margin-top: 22px;
}

.category-overview-card {
    padding: 24px;
}

.category-overview-card h2 {
    margin: 0;
    font-size: 26px;
}

.category-overview-card p {
    margin: 8px 0 18px;
    color: var(--neutral-600);
}

.category-overview-card ul {
    display: grid;
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}

.category-overview-card li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-radius: 12px;
    padding: 10px 12px;
    background: var(--neutral-50);
    color: var(--neutral-900);
    font-weight: 700;
}

.category-overview-card li a:hover {
    color: var(--primary-700);
    background: var(--primary-50);
}

.category-overview-card li span {
    color: var(--neutral-600);
    font-size: 13px;
    font-weight: 600;
}

.detail-hero {
    min-height: 560px;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
}

.detail-backdrop img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(8px) saturate(1.1);
    transform: scale(1.04);
}

.detail-backdrop span {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(11, 63, 110, 0.94), rgba(15, 23, 42, 0.78)),
        linear-gradient(0deg, rgba(15, 23, 42, 0.98), transparent 56%);
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    padding: 48px 0 64px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 28px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #ffffff;
}

.detail-grid {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
}

.poster-card {
    overflow: hidden;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-xl);
}

.poster-card img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.detail-line {
    max-width: 820px;
    margin: 18px 0 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.detail-meta span {
    border-radius: 999px;
    padding: 7px 12px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    font-weight: 700;
}

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

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #000000;
    box-shadow: var(--shadow-xl);
}

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

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.48), rgba(0, 0, 0, 0.12));
    cursor: pointer;
}

.player-overlay span {
    display: inline-flex;
    width: 88px;
    height: 88px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.2);
    font-size: 38px;
    backdrop-filter: blur(8px);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.28);
}

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

.detail-content {
    display: grid;
    gap: 24px;
}

.article-card {
    padding: 28px;
}

.article-card p {
    margin: 14px 0 0;
    color: var(--neutral-700);
    font-size: 17px;
}

.related-section {
    padding-top: 14px;
}

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

.site-footer {
    margin-top: 40px;
    background: var(--neutral-900);
    color: var(--neutral-300);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 34px;
    padding: 46px 0;
}

.footer-grid p {
    max-width: 520px;
    color: var(--neutral-400);
}

.footer-grid h2 {
    margin: 0 0 14px;
    color: #ffffff;
    font-size: 18px;
}

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

.footer-grid a:hover {
    color: var(--accent-300);
}

.footer-bottom {
    border-top: 1px solid var(--neutral-800);
    padding: 18px 16px;
    color: var(--neutral-400);
    text-align: center;
}

@media (max-width: 1100px) {
    .movie-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .split-layout {
        grid-template-columns: 1fr;
    }

    .side-panel {
        width: 100%;
    }
}

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

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

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

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

    .hero-content {
        padding-top: 96px;
    }

    .filter-panel,
    .category-grid,
    .category-overview-grid,
    .footer-grid,
    .detail-grid {
        grid-template-columns: 1fr;
    }

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

    .category-thumbs {
        min-height: 220px;
    }

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

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

    .poster-card {
        max-width: 280px;
    }
}

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

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

    .hero,
    .hero-track,
    .hero-slide {
        min-height: 600px;
    }

    .hero-content {
        padding: 88px 0 78px;
    }

    .hero-control {
        display: none;
    }

    .search-banner {
        align-items: flex-start;
        flex-direction: column;
    }

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

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

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

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

    .card-desc,
    .compact-card .tag-row {
        display: none;
    }

    .detail-hero-inner {
        padding-top: 32px;
    }

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