:root {
    --site-primary: #2563eb;
    --site-primary-dark: #1d4ed8;
    --site-accent: #7c3aed;
    --site-accent-soft: #eef2ff;
    --site-ink: #111827;
    --site-muted: #6b7280;
    --site-border: #e5e7eb;
    --site-card: #ffffff;
    --site-bg: #f8fafc;
    --site-shadow: 0 18px 50px rgba(15, 23, 42, 0.12);
    --site-radius: 18px;
}

body {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 42%, #f8fafc 100%);
    color: var(--site-ink);
}

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

.site-nav {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    min-height: 72px;
    display: flex;
    align-items: center;
    gap: 28px;
}

.logo-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 900;
    color: var(--site-ink);
    white-space: nowrap;
}

.logo-mark {
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    box-shadow: 0 10px 24px rgba(37, 99, 235, 0.32);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.nav-links a {
    padding: 10px 14px;
    border-radius: 999px;
    color: #374151;
    font-weight: 700;
    transition: color 0.2s ease, background 0.2s ease;
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--site-primary);
    background: #eff6ff;
}

.nav-search {
    width: min(300px, 30vw);
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px 8px 16px;
    border: 1px solid #dbe4f0;
    border-radius: 999px;
    background: #ffffff;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.nav-search input {
    width: 100%;
    outline: none;
    color: #111827;
    background: transparent;
}

.nav-search button {
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    color: #ffffff;
    background: var(--site-primary);
    transition: transform 0.2s ease, background 0.2s ease;
}

.nav-search button:hover {
    transform: translateY(-1px);
    background: var(--site-primary-dark);
}

.mobile-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    color: var(--site-ink);
    background: #f1f5f9;
}

.mobile-menu {
    display: none;
    border-top: 1px solid var(--site-border);
    padding: 14px 24px 22px;
    background: #ffffff;
}

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

.mobile-menu a {
    display: block;
    padding: 12px 4px;
    font-weight: 700;
    color: #374151;
}

.page-shell {
    max-width: 1280px;
    margin: 0 auto;
    padding: 48px 24px 72px;
}

.hero-slider {
    position: relative;
    min-height: 70vh;
    overflow: hidden;
    background: #020617;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

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

.hero-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: radial-gradient(circle at 30% 20%, rgba(59, 130, 246, 0.58), transparent 28%), linear-gradient(135deg, #111827, #312e81);
    transform: scale(1.03);
    transition: transform 5s ease, opacity 0.3s ease;
}

.hero-slide.is-active .hero-image {
    transform: scale(1);
}

.hero-image.is-missing,
.poster-image.is-missing {
    opacity: 0;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.76), rgba(0, 0, 0, 0.48), rgba(0, 0, 0, 0.12));
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    width: 100%;
    margin: 0 auto;
    padding: 92px 24px 72px;
}

.hero-copy {
    max-width: 680px;
    color: #ffffff;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border-radius: 999px;
    color: #dbeafe;
    background: rgba(37, 99, 235, 0.25);
    border: 1px solid rgba(147, 197, 253, 0.35);
    backdrop-filter: blur(10px);
    font-weight: 800;
}

.hero-copy h1,
.hero-copy h2 {
    margin: 0;
    font-size: clamp(42px, 7vw, 76px);
    line-height: 0.98;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.hero-copy p {
    margin: 22px 0 0;
    max-width: 620px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
    line-height: 1.8;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.hero-meta span,
.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 800;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(10px);
}

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

.primary-button,
.secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 0 22px;
    border-radius: 12px;
    font-weight: 900;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: #ffffff;
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    box-shadow: 0 16px 36px rgba(37, 99, 235, 0.35);
}

.secondary-button {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.32);
    backdrop-filter: blur(12px);
}

.primary-button:hover,
.secondary-button:hover {
    transform: translateY(-2px);
}

.hero-controls {
    position: absolute;
    z-index: 4;
    right: 42px;
    bottom: 38px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.hero-control {
    width: 44px;
    height: 44px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    transition: background 0.2s ease, transform 0.2s ease;
}

.hero-control:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: translateY(-1px);
}

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

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

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

.section-block {
    margin-top: 72px;
}

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

.section-title {
    font-size: clamp(28px, 3vw, 38px);
    font-weight: 950;
    letter-spacing: -0.03em;
    color: #111827;
}

.section-desc {
    margin-top: 8px;
    color: var(--site-muted);
    line-height: 1.7;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 900;
    color: var(--site-primary);
}

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

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

.movie-link {
    display: block;
    height: 100%;
}

.poster-wrap {
    position: relative;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 16px;
    background: radial-gradient(circle at 25% 18%, rgba(59, 130, 246, 0.35), transparent 28%), linear-gradient(135deg, #111827, #312e81 56%, #7c3aed);
    box-shadow: 0 15px 35px rgba(15, 23, 42, 0.16);
}

.poster-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease, opacity 0.25s ease;
}

.movie-link:hover .poster-image {
    transform: scale(1.06);
}

.card-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 6px 9px;
    border-radius: 8px;
    color: #ffffff;
    background: rgba(37, 99, 235, 0.92);
    font-size: 12px;
    font-weight: 900;
    box-shadow: 0 8px 18px rgba(37, 99, 235, 0.28);
}

.card-shade {
    position: absolute;
    inset: auto 0 0;
    padding: 36px 12px 12px;
    color: #ffffff;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.movie-link:hover .card-shade {
    opacity: 1;
}

.movie-title {
    margin-top: 12px;
    color: #111827;
    font-size: 16px;
    line-height: 1.35;
    font-weight: 900;
    transition: color 0.2s ease;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.movie-link:hover .movie-title {
    color: var(--site-primary);
}

.movie-meta {
    margin-top: 6px;
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
}

.movie-one-line {
    margin-top: 7px;
    color: #6b7280;
    font-size: 13px;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.category-hero,
.ranking-hero,
.search-hero {
    margin: 0 0 36px;
    padding: clamp(36px, 6vw, 70px);
    border-radius: 26px;
    color: #ffffff;
    background: radial-gradient(circle at 85% 10%, rgba(124, 58, 237, 0.65), transparent 28%), linear-gradient(135deg, #1e3a8a, #312e81 54%, #111827);
    box-shadow: var(--site-shadow);
}

.category-hero h1,
.ranking-hero h1,
.search-hero h1 {
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.05;
    font-weight: 950;
    letter-spacing: -0.04em;
}

.category-hero p,
.ranking-hero p,
.search-hero p {
    max-width: 780px;
    margin-top: 16px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
    line-height: 1.8;
}

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

.category-tile {
    position: relative;
    overflow: hidden;
    min-height: 170px;
    padding: 26px;
    border-radius: 22px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    box-shadow: 0 16px 38px rgba(37, 99, 235, 0.22);
}

.category-tile:nth-child(2n) {
    background: linear-gradient(135deg, #0f172a, #2563eb);
}

.category-tile:nth-child(3n) {
    background: linear-gradient(135deg, #7c3aed, #db2777);
}

.category-tile h2 {
    position: relative;
    z-index: 2;
    font-size: 26px;
    font-weight: 950;
}

.category-tile p {
    position: relative;
    z-index: 2;
    margin-top: 12px;
    color: rgba(255, 255, 255, 0.86);
    line-height: 1.7;
}

.category-tile span {
    position: relative;
    z-index: 2;
    display: inline-flex;
    margin-top: 18px;
    font-weight: 900;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 18px;
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px;
    gap: 14px;
    border: 1px solid var(--site-border);
    border-radius: 20px;
    background: #ffffff;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
}

.filter-panel input,
.filter-panel select,
.search-main-form input,
.search-main-form select {
    width: 100%;
    height: 46px;
    padding: 0 14px;
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    color: #111827;
    background: #ffffff;
    outline: none;
}

.filter-panel input:focus,
.filter-panel select:focus,
.search-main-form input:focus,
.search-main-form select:focus {
    border-color: var(--site-primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.empty-message {
    display: none;
    padding: 46px 24px;
    text-align: center;
    color: #64748b;
    font-weight: 800;
    border: 1px dashed #cbd5e1;
    border-radius: 18px;
    background: #ffffff;
}

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

.ranking-list {
    display: grid;
    gap: 16px;
}

.ranking-item {
    display: grid;
    grid-template-columns: 64px 92px minmax(0, 1fr) auto;
    align-items: center;
    gap: 18px;
    padding: 16px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.rank-number {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    font-weight: 950;
}

.rank-poster {
    width: 92px;
    aspect-ratio: 2 / 3;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #111827, #312e81);
}

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

.rank-title {
    font-size: 20px;
    font-weight: 950;
    color: #111827;
}

.rank-summary {
    margin-top: 6px;
    color: #64748b;
    line-height: 1.65;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.search-main-form {
    display: grid;
    grid-template-columns: minmax(240px, 1fr) 180px 120px;
    gap: 12px;
    margin-top: 26px;
    max-width: 820px;
}

.search-main-form button {
    border-radius: 12px;
    color: #ffffff;
    background: var(--site-primary);
    font-weight: 900;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 380px;
    gap: 28px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 22px;
    color: #475569;
    font-weight: 900;
}

.back-link:hover {
    color: var(--site-primary);
}

.player-card,
.detail-content,
.related-panel {
    overflow: hidden;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.1);
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.video-shell {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #020617;
}

.video-shell video {
    width: 100%;
    height: 100%;
    display: block;
    background: #020617;
}

.video-start {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: #ffffff;
    background: radial-gradient(circle at 50% 35%, rgba(37, 99, 235, 0.2), rgba(0, 0, 0, 0.42));
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.video-start.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.play-symbol {
    width: 76px;
    height: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--site-primary), var(--site-accent));
    font-size: 28px;
    box-shadow: 0 20px 48px rgba(37, 99, 235, 0.38);
}

.video-start span:last-child {
    font-size: 18px;
    font-weight: 950;
}

.detail-content {
    margin-top: 22px;
    padding: clamp(24px, 4vw, 38px);
}

.detail-content h1 {
    font-size: clamp(32px, 5vw, 50px);
    line-height: 1.1;
    font-weight: 950;
    letter-spacing: -0.04em;
}

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

.detail-meta span,
.tag-list span {
    display: inline-flex;
    padding: 7px 12px;
    border-radius: 999px;
    color: #1d4ed8;
    background: #dbeafe;
    font-size: 14px;
    font-weight: 900;
}

.detail-section {
    margin-top: 28px;
}

.detail-section h2 {
    margin-bottom: 12px;
    font-size: 22px;
    font-weight: 950;
}

.detail-section p {
    color: #374151;
    line-height: 1.9;
    font-size: 16px;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.related-panel {
    padding: 22px;
    align-self: start;
    position: sticky;
    top: 96px;
}

.related-panel h2 {
    margin-bottom: 18px;
    font-size: 22px;
    font-weight: 950;
}

.related-item {
    display: grid;
    grid-template-columns: 76px minmax(0, 1fr);
    gap: 13px;
    padding: 12px 0;
    border-bottom: 1px solid #eef2f7;
}

.related-item:last-child {
    border-bottom: 0;
}

.related-thumb {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 10px;
    background: linear-gradient(135deg, #111827, #312e81);
}

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

.related-title {
    font-weight: 950;
    color: #111827;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-meta {
    margin-top: 6px;
    color: #64748b;
    font-size: 13px;
    font-weight: 700;
}

.site-footer {
    background: #0f172a;
    color: #cbd5e1;
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 46px 24px;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 32px;
}

.footer-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #ffffff;
    font-size: 22px;
    font-weight: 950;
}

.footer-inner p {
    margin-top: 14px;
    max-width: 560px;
    color: #94a3b8;
    line-height: 1.75;
}

.footer-col h3 {
    margin-bottom: 14px;
    color: #ffffff;
    font-weight: 900;
}

.footer-col a {
    display: block;
    margin: 9px 0;
    color: #94a3b8;
}

.footer-col a:hover {
    color: #ffffff;
}

.footer-bottom {
    border-top: 1px solid rgba(148, 163, 184, 0.16);
    padding: 18px 24px;
    text-align: center;
    color: #64748b;
    font-size: 14px;
}

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

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

    .related-panel {
        position: static;
    }
}

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

    .site-nav {
        justify-content: space-between;
    }

    .mobile-menu-button {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .hero-controls {
        right: 24px;
        bottom: 24px;
    }

    .hero-dots {
        display: none;
    }

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

    .filter-panel,
    .search-main-form {
        grid-template-columns: 1fr;
    }

    .footer-inner {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .site-nav {
        min-height: 64px;
        padding: 0 16px;
    }

    .logo-link {
        font-size: 20px;
    }

    .hero-slider {
        min-height: 78vh;
    }

    .hero-content {
        padding: 82px 18px 86px;
    }

    .hero-copy p {
        font-size: 16px;
    }

    .page-shell {
        padding: 32px 16px 56px;
    }

    .section-head {
        display: block;
    }

    .section-head .text-link {
        margin-top: 12px;
    }

    .movie-grid,
    .category-cloud {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

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

    .ranking-item .primary-button {
        grid-column: 2 / -1;
        width: 100%;
    }

    .category-hero,
    .ranking-hero,
    .search-hero {
        border-radius: 22px;
        padding: 30px 22px;
    }
}
