:root {
    --site-blue: #0284c7;
    --site-blue-dark: #0369a1;
    --site-surface: #ffffff;
    --site-text: #111827;
    --site-muted: #6b7280;
    --site-line: #e5e7eb;
    --site-shadow: 0 20px 40px rgba(15, 23, 42, 0.12);
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    color: var(--site-text);
    background: #f8fafc;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 40;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.site-logo-mark {
    display: inline-flex;
    width: 2.25rem;
    height: 2.25rem;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #0ea5e9, #2563eb);
    color: #ffffff;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(14, 165, 233, 0.28);
}

.nav-link {
    display: inline-flex;
    align-items: center;
    color: #374151;
    font-weight: 600;
    transition: color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover {
    color: var(--site-blue);
    transform: translateY(-1px);
}

.mobile-panel {
    display: none;
}

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

.hero-carousel {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    color: #ffffff;
    background: #082f49;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    background-size: cover;
    background-position: center;
    transition: opacity 0.8s ease;
}

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

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 70% 30%, rgba(125, 211, 252, 0.36), transparent 34%),
        linear-gradient(115deg, rgba(7, 89, 133, 0.95), rgba(29, 78, 216, 0.78) 48%, rgba(2, 6, 23, 0.84));
}

.hero-inner {
    position: relative;
    z-index: 1;
    width: 100%;
}

.hero-glass {
    max-width: 760px;
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 1.5rem;
    background: rgba(15, 23, 42, 0.34);
    box-shadow: 0 30px 70px rgba(2, 6, 23, 0.3);
    backdrop-filter: blur(10px);
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #bae6fd;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.hero-title {
    margin-top: 1rem;
    font-size: clamp(2.4rem, 6vw, 4.9rem);
    line-height: 1.03;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.hero-copy {
    margin-top: 1.25rem;
    max-width: 680px;
    color: #dbeafe;
    font-size: clamp(1.05rem, 2vw, 1.35rem);
    line-height: 1.85;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.hero-search {
    display: flex;
    max-width: 620px;
    margin-top: 1.5rem;
    overflow: hidden;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 18px 45px rgba(2, 6, 23, 0.25);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    padding: 0.95rem 1.1rem;
    color: #111827;
    outline: none;
}

.hero-search button {
    padding: 0.95rem 1.35rem;
    background: #0284c7;
    color: #ffffff;
    font-weight: 800;
}

.hero-dots {
    position: absolute;
    z-index: 2;
    left: 50%;
    bottom: 2rem;
    display: flex;
    gap: 0.5rem;
    transform: translateX(-50%);
}

.hero-dot {
    width: 2rem;
    height: 0.35rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.36);
    transition: background 0.2s ease, width 0.2s ease;
}

.hero-dot.is-active {
    width: 3.4rem;
    background: #ffffff;
}

.btn-primary,
.btn-secondary,
.btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    border-radius: 0.8rem;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
    padding: 0.8rem 1.15rem;
    background: #ffffff;
    color: #0369a1;
    box-shadow: 0 14px 28px rgba(255, 255, 255, 0.24);
}

.btn-secondary {
    padding: 0.8rem 1.15rem;
    background: #0284c7;
    color: #ffffff;
    box-shadow: 0 14px 28px rgba(2, 132, 199, 0.28);
}

.btn-ghost {
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.24);
}

.btn-primary:hover,
.btn-secondary:hover,
.btn-ghost:hover {
    transform: translateY(-2px) scale(1.02);
}

.section-wrap {
    max-width: 80rem;
    margin: 0 auto;
    padding: 4rem 1rem;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.75rem;
}

.section-heading h2,
.section-heading h1 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    line-height: 1.12;
    font-weight: 900;
    letter-spacing: -0.035em;
    color: #111827;
}

.section-heading p {
    max-width: 48rem;
    margin-top: 0.55rem;
    color: #6b7280;
    line-height: 1.8;
}

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

.movie-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 1rem;
    background: #ffffff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.08);
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-0.35rem);
    box-shadow: var(--site-shadow);
}

.poster-frame {
    position: relative;
    display: block;
    min-height: 16rem;
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

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

.card-badge {
    position: absolute;
    z-index: 1;
    left: 0.85rem;
    top: 0.85rem;
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.25rem 0.65rem;
    background: rgba(2, 132, 199, 0.9);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
}

.card-year {
    position: absolute;
    z-index: 1;
    right: 0.85rem;
    top: 0.85rem;
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    padding: 0.25rem 0.65rem;
    background: rgba(15, 23, 42, 0.76);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 800;
}

.card-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 1rem;
}

.card-title {
    color: #111827;
    font-weight: 900;
    line-height: 1.35;
    transition: color 0.2s ease;
}

.movie-card:hover .card-title {
    color: #0284c7;
}

.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.55rem;
    color: #6b7280;
    font-size: 0.82rem;
}

.card-desc {
    margin-top: 0.7rem;
    color: #4b5563;
    font-size: 0.92rem;
    line-height: 1.72;
}

.line-clamp-2 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.line-clamp-3 {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

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

.category-card {
    display: block;
    padding: 1.25rem;
    border: 1px solid var(--site-line);
    border-radius: 1.1rem;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.category-card:hover {
    transform: translateY(-0.25rem);
    border-color: rgba(14, 165, 233, 0.45);
    box-shadow: var(--site-shadow);
}

.category-card strong {
    display: block;
    color: #111827;
    font-size: 1.15rem;
    font-weight: 900;
}

.category-card span {
    display: block;
    margin-top: 0.45rem;
    color: #6b7280;
    line-height: 1.7;
}

.rank-list {
    display: grid;
    gap: 0.85rem;
}

.rank-row {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.8rem;
    align-items: center;
    padding: 0.95rem;
    border-radius: 0.95rem;
    background: #ffffff;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.06);
}

.rank-num {
    display: inline-flex;
    width: 2rem;
    height: 2rem;
    align-items: center;
    justify-content: center;
    border-radius: 0.65rem;
    background: #e0f2fe;
    color: #0369a1;
    font-weight: 900;
}

.filter-panel {
    display: grid;
    gap: 0.9rem;
    margin-bottom: 2rem;
    padding: 1rem;
    border: 1px solid var(--site-line);
    border-radius: 1.1rem;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 0.8rem;
    padding: 0.75rem 0.9rem;
    outline: none;
    background: #ffffff;
}

.filter-panel input:focus,
.filter-panel select:focus {
    border-color: #0284c7;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.18);
}

.detail-hero {
    color: #ffffff;
    background-size: cover;
    background-position: center;
}

.detail-overlay {
    background:
        linear-gradient(115deg, rgba(2, 6, 23, 0.92), rgba(3, 105, 161, 0.78)),
        radial-gradient(circle at 70% 30%, rgba(125, 211, 252, 0.25), transparent 30%);
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 1.1rem;
    background: #000000;
    box-shadow: 0 24px 55px rgba(15, 23, 42, 0.24);
}

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

.player-cover {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(2, 6, 23, 0.74), rgba(2, 132, 199, 0.42));
    color: #ffffff;
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.player-cover.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.player-button {
    display: inline-flex;
    width: 5.25rem;
    height: 5.25rem;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.94);
    color: #0369a1;
    font-size: 2.2rem;
    box-shadow: 0 16px 40px rgba(255, 255, 255, 0.22);
}

.info-card {
    border-radius: 1.1rem;
    background: #ffffff;
    padding: 1.25rem;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.07);
}

.info-card h2 {
    margin-bottom: 0.75rem;
    color: #111827;
    font-size: 1.35rem;
    font-weight: 900;
}

.info-card p {
    color: #374151;
    line-height: 1.9;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tag-list span,
.tag-list a {
    display: inline-flex;
    border-radius: 999px;
    padding: 0.35rem 0.72rem;
    background: #e0f2fe;
    color: #0369a1;
    font-size: 0.82rem;
    font-weight: 800;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    color: #bae6fd;
    font-weight: 700;
}

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

.site-footer {
    margin-top: 4rem;
    background: #111827;
    color: #d1d5db;
}

.site-footer a:hover {
    color: #38bdf8;
}

.hidden-by-filter {
    display: none !important;
}

@media (min-width: 640px) {
    .movie-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

@media (min-width: 768px) {
    .filter-panel {
        grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 0.8fr));
        align-items: center;
    }
}

@media (min-width: 1024px) {
    .movie-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

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

    .detail-layout {
        grid-template-columns: minmax(0, 1.7fr) 23rem;
    }
}

@media (min-width: 1280px) {
    .movie-grid {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .hero-carousel {
        min-height: 680px;
    }

    .hero-glass {
        padding: 1.25rem;
        border-radius: 1.1rem;
    }

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

    .section-heading {
        display: block;
    }
}
