:root {
    color-scheme: light;
    --brand: #1e3a8a;
    --brand-strong: #172554;
    --brand-soft: #eff6ff;
    --ink: #0f172a;
    --muted: #64748b;
    --line: #e2e8f0;
    --panel: #ffffff;
    --page: #f8fafc;
    --warm: #f59e0b;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background: var(--page);
    color: var(--ink);
}

img {
    background: linear-gradient(135deg, #dbeafe, #f8fafc);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
}

.header-inner {
    min-height: 4rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.7rem;
    color: var(--ink);
    font-weight: 800;
    font-size: 1.25rem;
}

.brand-mark {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.8rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: linear-gradient(135deg, var(--brand), #2563eb);
    box-shadow: 0 12px 28px rgba(30, 58, 138, 0.28);
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.main-nav a {
    color: #334155;
    font-weight: 600;
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--brand);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.search-form {
    position: relative;
}

.search-form input {
    width: 15rem;
    border: 1px solid #cbd5e1;
    border-radius: 9999px;
    padding: 0.62rem 1rem 0.62rem 2.4rem;
    background: #fff;
    outline: none;
}

.search-form input:focus,
.hero-search input:focus,
.page-filter:focus {
    border-color: transparent;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25);
}

.search-form::before {
    content: "⌕";
    position: absolute;
    left: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1.1rem;
}

.menu-toggle {
    display: none;
    border: 0;
    border-radius: 0.7rem;
    background: #eef2ff;
    color: var(--brand);
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.3rem;
}

.mobile-nav {
    display: none;
    border-top: 1px solid var(--line);
    padding: 0.8rem 0 1rem;
}

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

.mobile-nav a {
    display: block;
    padding: 0.8rem 1rem;
    border-radius: 0.8rem;
    color: #334155;
    font-weight: 700;
}

.mobile-nav a:hover {
    background: #f1f5f9;
    color: var(--brand);
}

.hero-carousel {
    position: relative;
    min-height: 620px;
    overflow: hidden;
    background: #0f172a;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.025);
    transition: opacity 0.7s ease, transform 1.1s ease;
    background-size: cover;
    background-position: center;
}

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

.hero-slide::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 72% 25%, rgba(59, 130, 246, 0.35), transparent 34%),
        linear-gradient(90deg, rgba(15, 23, 42, 0.94), rgba(15, 23, 42, 0.72) 48%, rgba(15, 23, 42, 0.2));
}

.hero-content {
    position: relative;
    z-index: 2;
    min-height: 620px;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.65fr);
    gap: 2.5rem;
    align-items: center;
    color: #fff;
}

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

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.35rem 0.8rem;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.12);
    color: #dbeafe;
    font-weight: 700;
}

.hero-title {
    margin: 0;
    font-size: clamp(2.4rem, 6vw, 5.25rem);
    line-height: 0.98;
    letter-spacing: -0.05em;
    color: #fff;
}

.hero-text {
    margin-top: 1.4rem;
    max-width: 660px;
    color: #dbeafe;
    font-size: 1.1rem;
    line-height: 1.85;
}

.hero-actions {
    margin-top: 2rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
}

.hero-search {
    margin-top: 1.5rem;
    max-width: 560px;
    display: flex;
    gap: 0.7rem;
    padding: 0.45rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.13);
    backdrop-filter: blur(12px);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    border-radius: 0.75rem;
    padding: 0.8rem 1rem;
    background: rgba(255, 255, 255, 0.95);
    color: var(--ink);
    outline: none;
}

.hero-search button,
.primary-link,
.secondary-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 0.75rem;
    padding: 0.8rem 1.1rem;
    font-weight: 800;
    line-height: 1;
}

.hero-search button,
.primary-link {
    background: #fff;
    color: var(--brand);
}

.primary-link:hover,
.hero-search button:hover {
    background: #dbeafe;
}

.secondary-link {
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.34);
    background: rgba(255, 255, 255, 0.12);
}

.secondary-link:hover {
    background: rgba(255, 255, 255, 0.22);
}

.hero-panel {
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 1.5rem;
    background: rgba(255, 255, 255, 0.14);
    padding: 1rem;
    backdrop-filter: blur(18px);
    box-shadow: 0 25px 60px rgba(2, 6, 23, 0.45);
}

.hero-poster {
    aspect-ratio: 16 / 10;
    width: 100%;
    border-radius: 1rem;
    object-fit: cover;
}

.hero-meta {
    padding: 1rem 0.25rem 0;
}

.hero-meta h2,
.hero-meta h3 {
    color: #fff;
    margin: 0 0 0.35rem;
    font-size: 1.35rem;
}

.hero-meta p {
    margin: 0;
    color: #dbeafe;
}

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

.hero-dot {
    width: 0.7rem;
    height: 0.7rem;
    border: 0;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.45);
}

.hero-dot.active {
    width: 2rem;
    background: #fff;
}

.section-block {
    padding: 4rem 0;
}

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

.section-head p {
    max-width: 680px;
    color: var(--muted);
}

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

.movie-card {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: var(--panel);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-4px);
    border-color: #bfdbfe;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.12);
}

.movie-card a {
    display: block;
    color: inherit;
}

.poster-wrap {
    position: relative;
    overflow: hidden;
    background: #dbeafe;
}

.poster-wrap img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.card-rank,
.card-year {
    position: absolute;
    top: 0.7rem;
    border-radius: 9999px;
    padding: 0.25rem 0.62rem;
    font-size: 0.78rem;
    font-weight: 800;
}

.card-rank {
    left: 0.7rem;
    color: #fff;
    background: rgba(15, 23, 42, 0.78);
}

.card-year {
    right: 0.7rem;
    color: #92400e;
    background: rgba(254, 243, 199, 0.92);
}

.card-body {
    padding: 1rem;
}

.card-body h3 {
    margin: 0 0 0.45rem;
    color: var(--ink);
    font-size: 1.05rem;
    line-height: 1.35;
}

.card-body p {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.65;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: 0.8rem;
}

.pill {
    display: inline-flex;
    align-items: center;
    border-radius: 9999px;
    padding: 0.23rem 0.62rem;
    background: #f1f5f9;
    color: #475569;
    font-size: 0.78rem;
    font-weight: 700;
}

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

.category-card {
    position: relative;
    overflow: hidden;
    border: 1px solid #dbeafe;
    border-radius: 1.2rem;
    background: linear-gradient(135deg, #ffffff, #eff6ff);
    padding: 1.35rem;
    min-height: 168px;
    box-shadow: 0 12px 30px rgba(30, 58, 138, 0.07);
}

.category-card::after {
    content: "";
    position: absolute;
    right: -2rem;
    bottom: -2rem;
    width: 9rem;
    height: 9rem;
    border-radius: 50%;
    background: rgba(37, 99, 235, 0.12);
}

.category-card h2,
.category-card h3 {
    position: relative;
    z-index: 1;
    margin: 0 0 0.6rem;
    color: var(--brand-strong);
}

.category-card p {
    position: relative;
    z-index: 1;
    color: #475569;
}

.page-hero {
    background: linear-gradient(135deg, #eff6ff, #ffffff);
    border-bottom: 1px solid var(--line);
    padding: 3.2rem 0;
}

.page-hero h1 {
    max-width: 900px;
    color: var(--ink);
}

.page-hero p {
    max-width: 760px;
    color: var(--muted);
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    align-items: center;
    margin-bottom: 1.4rem;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: #fff;
}

.page-filter {
    flex: 1;
    min-width: 220px;
    border: 1px solid #cbd5e1;
    border-radius: 0.8rem;
    padding: 0.75rem 1rem;
    outline: none;
}

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

.player-card,
.info-card,
.side-card {
    border: 1px solid var(--line);
    border-radius: 1.1rem;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.player-card {
    overflow: hidden;
}

.player-shell {
    position: relative;
    background: #020617;
}

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

.play-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.18), rgba(2, 6, 23, 0.72));
    cursor: pointer;
}

.play-overlay.hidden {
    display: none;
}

.play-button {
    width: 5rem;
    height: 5rem;
    border: 0;
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.95);
    color: var(--brand);
    font-size: 2.1rem;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.35);
    cursor: pointer;
}

.player-caption,
.info-card,
.side-card {
    padding: 1.4rem;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    color: #64748b;
    margin-bottom: 1rem;
    font-size: 0.92rem;
}

.breadcrumb a {
    color: var(--brand);
    font-weight: 700;
}

.detail-title {
    margin: 0 0 0.75rem;
    color: var(--ink);
}

.detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0 0;
}

.article-section {
    margin-top: 1rem;
}

.article-section h2 {
    color: var(--ink);
}

.article-section p {
    color: #334155;
    line-height: 1.9;
}

.side-card {
    position: sticky;
    top: 5.4rem;
}

.side-poster {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 0.8rem;
    margin-bottom: 1rem;
}

.info-list {
    display: grid;
    gap: 0.7rem;
    margin: 0;
}

.info-row {
    display: grid;
    grid-template-columns: 5rem 1fr;
    gap: 0.8rem;
    font-size: 0.95rem;
}

.info-row dt {
    color: #64748b;
}

.info-row dd {
    margin: 0;
    color: #0f172a;
    font-weight: 700;
}

.related-list {
    display: grid;
    gap: 0.75rem;
}

.related-item {
    display: grid;
    grid-template-columns: 6.2rem 1fr;
    gap: 0.75rem;
    align-items: center;
    color: inherit;
}

.related-item img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 0.6rem;
}

.related-item strong {
    display: block;
    color: var(--ink);
    line-height: 1.35;
}

.related-item span {
    display: block;
    margin-top: 0.25rem;
    color: #64748b;
    font-size: 0.86rem;
}

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

.rank-row {
    display: grid;
    grid-template-columns: 4rem 8rem minmax(0, 1fr) auto;
    gap: 1rem;
    align-items: center;
    padding: 0.8rem;
    border: 1px solid var(--line);
    border-radius: 0.9rem;
    background: #fff;
}

.rank-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.8rem;
    color: #fff;
    background: var(--brand);
    font-weight: 900;
}

.rank-row img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 0.65rem;
}

.search-results {
    display: grid;
    gap: 0.9rem;
}

.search-result-card {
    display: grid;
    grid-template-columns: 11rem minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: #fff;
}

.search-result-card img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 0.75rem;
}

.site-footer {
    margin-top: 4rem;
    background: #0f172a;
    color: #cbd5e1;
}

.footer-inner {
    padding: 3rem 0;
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 1.5rem;
}

.footer-inner h2,
.footer-inner h3 {
    color: #fff;
    margin-top: 0;
}

.footer-inner a {
    display: block;
    color: #cbd5e1;
    margin: 0.45rem 0;
}

.footer-inner a:hover {
    color: #fff;
}

.footer-bottom {
    border-top: 1px solid #1e293b;
    padding: 1rem 0;
    color: #94a3b8;
}

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

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

    .side-card {
        position: static;
    }
}

@media (max-width: 820px) {
    .main-nav,
    .header-actions .search-form {
        display: none;
    }

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

    .hero-carousel,
    .hero-content {
        min-height: 720px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        align-content: center;
        gap: 1.2rem;
    }

    .hero-panel {
        max-width: 460px;
    }

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

    .rank-row {
        grid-template-columns: 3rem 7rem minmax(0, 1fr);
    }

    .rank-row .rank-action {
        grid-column: 2 / -1;
    }

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

@media (max-width: 560px) {
    .hero-search {
        display: block;
    }

    .hero-search button {
        width: 100%;
        margin-top: 0.55rem;
    }

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

    .search-result-card,
    .related-item {
        grid-template-columns: 1fr;
    }

    .rank-row {
        grid-template-columns: 3rem minmax(0, 1fr);
    }

    .rank-row img {
        display: none;
    }

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