:root {
    --bg: #f8fafc;
    --text: #111827;
    --muted: #6b7280;
    --line: #e5e7eb;
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --dark: #0f172a;
    --card: #ffffff;
    --soft: #eff6ff;
    --radius: 18px;
    --shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

body {
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

img {
    background: linear-gradient(135deg, #0f172a, #2563eb);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #0f172a;
    font-weight: 900;
    letter-spacing: -0.02em;
    white-space: nowrap;
}

.brand__icon {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #0f172a);
    box-shadow: 0 12px 28px rgba(37, 99, 235, 0.32);
}

.brand__name {
    font-size: 21px;
}

.nav {
    display: flex;
    align-items: center;
    gap: 26px;
    margin-left: auto;
}

.nav-link {
    color: #374151;
    font-weight: 700;
    transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--primary);
}

.header-search {
    display: flex;
    align-items: center;
    gap: 0;
    width: 300px;
    border: 1px solid var(--line);
    border-radius: 999px;
    overflow: hidden;
    background: #fff;
}

.header-search input {
    width: 100%;
    height: 40px;
    padding: 0 14px;
    outline: none;
    color: #111827;
}

.header-search button {
    height: 40px;
    padding: 0 18px;
    color: #fff;
    background: var(--primary);
    font-weight: 700;
}

.mobile-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: #f1f5f9;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.mobile-toggle span {
    width: 20px;
    height: 2px;
    background: #0f172a;
    border-radius: 2px;
}

.mobile-panel {
    display: none;
    padding: 0 24px 18px;
    border-top: 1px solid #e5e7eb;
}

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

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

.hero-slider {
    position: relative;
    height: 520px;
    overflow: hidden;
    background: linear-gradient(135deg, #1e3a8a, #0f172a);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 900ms ease;
}

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

.hero-slide__image {
    position: absolute;
    inset: 0;
}

.hero-slide__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.03);
}

.hero-slide__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.90), rgba(0, 0, 0, 0.45) 42%, rgba(15, 23, 42, 0.18));
}

.hero-slide__content {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    height: 100%;
    margin: 0 auto;
    padding: 0 24px 72px;
    display: flex;
    align-items: flex-end;
}

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

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 16px;
}

.hero-badges span,
.rank-badge,
.meta-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 7px 12px;
    background: rgba(37, 99, 235, 0.9);
    color: #fff;
    font-size: 13px;
    font-weight: 800;
}

.hero-badges span:first-child {
    background: #dc2626;
}

.hero-copy h1,
.hero-copy h2 {
    margin: 0 0 16px;
    font-size: clamp(34px, 6vw, 58px);
    line-height: 1.05;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.hero-copy p {
    max-width: 680px;
    margin-bottom: 24px;
    color: #e5e7eb;
    font-size: 18px;
    line-height: 1.8;
}

.hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin-bottom: 26px;
    color: #d1d5db;
    font-weight: 700;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0 22px;
    border-radius: 999px;
    font-weight: 850;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn-primary {
    color: #fff;
    background: var(--primary);
    box-shadow: 0 14px 30px rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-ghost {
    color: #fff;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
}

.hero-search {
    display: flex;
    align-items: center;
    width: min(440px, 100%);
    min-height: 48px;
    overflow: hidden;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(12px);
}

.hero-search input {
    width: 100%;
    height: 48px;
    padding: 0 18px;
    color: #fff;
    outline: none;
}

.hero-search input::placeholder {
    color: rgba(255, 255, 255, 0.74);
}

.hero-search button {
    height: 48px;
    padding: 0 20px;
    background: #fff;
    color: var(--primary);
    font-weight: 900;
}

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 4;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: rgba(0, 0, 0, 0.48);
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.72);
}

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

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

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

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

.hero-dots button.is-active {
    width: 34px;
    background: #fff;
}

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

.page-main.is-wide {
    max-width: 1400px;
}

.content-section {
    margin-bottom: 64px;
}

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

.section-heading h1,
.section-heading h2 {
    font-size: clamp(26px, 4vw, 36px);
    line-height: 1.18;
    font-weight: 950;
    color: #111827;
    letter-spacing: -0.04em;
}

.section-heading p,
.page-lead {
    margin-top: 8px;
    color: var(--muted);
    line-height: 1.75;
}

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

.movie-card {
    min-width: 0;
    overflow: hidden;
    border: 1px solid rgba(226, 232, 240, 0.95);
    border-radius: var(--radius);
    background: var(--card);
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    border-color: rgba(37, 99, 235, 0.32);
    box-shadow: var(--shadow);
}

.movie-card__poster {
    position: relative;
    display: block;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    background: #0f172a;
}

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

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

.movie-card__poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.58));
    opacity: 0;
    transition: opacity 0.25s ease;
}

.movie-card:hover .movie-card__poster::after {
    opacity: 1;
}

.movie-card__duration {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    padding: 4px 9px;
    color: #fff;
    background: rgba(0, 0, 0, 0.72);
    border-radius: 8px;
    font-size: 12px;
    font-weight: 800;
}

.movie-card__play {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 3;
    width: 50px;
    height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    background: rgba(37, 99, 235, 0.92);
    border-radius: 999px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.86);
    transition: opacity 0.25s ease, transform 0.25s ease;
}

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

.movie-card__body {
    padding: 18px;
}

.movie-card__meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 10px;
    color: #64748b;
    font-size: 13px;
    font-weight: 750;
}

.movie-card h3 {
    margin-bottom: 10px;
    color: #111827;
    font-size: 18px;
    line-height: 1.32;
    font-weight: 900;
}

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

.movie-card p {
    color: #64748b;
    font-size: 14px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

.tag-list span {
    display: inline-flex;
    padding: 5px 9px;
    border-radius: 999px;
    background: #eff6ff;
    color: #1d4ed8;
    font-size: 12px;
    font-weight: 800;
}

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

.category-card {
    min-height: 150px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px;
    border-radius: 22px;
    background: linear-gradient(135deg, #ffffff, #eff6ff);
    border: 1px solid rgba(226, 232, 240, 0.95);
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.05);
    transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.category-card:hover {
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #0f172a);
    transform: translateY(-5px);
}

.category-card strong {
    display: block;
    margin-bottom: 10px;
    font-size: 20px;
    font-weight: 950;
}

.category-card span {
    color: #64748b;
    line-height: 1.7;
}

.category-card:hover span {
    color: rgba(255, 255, 255, 0.82);
}

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin: 26px 0 30px;
    padding: 18px;
    border: 1px solid #e5e7eb;
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.filter-bar input,
.filter-bar select {
    min-height: 44px;
    padding: 0 14px;
    border: 1px solid #dbe3ef;
    border-radius: 14px;
    outline: none;
    background: #fff;
}

.filter-bar input {
    flex: 1 1 260px;
}

.rank-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.8fr);
    gap: 26px;
    align-items: start;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 60px 150px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    padding: 14px;
    border-radius: 18px;
    background: #fff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.04);
}

.rank-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, #dc2626, #f59e0b);
    font-size: 18px;
    font-weight: 950;
}

.rank-item img {
    width: 150px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 14px;
}

.rank-info h2,
.rank-info h3 {
    margin-bottom: 8px;
    font-size: 20px;
    line-height: 1.28;
    font-weight: 950;
}

.rank-info p {
    color: #64748b;
    line-height: 1.68;
}

.movie-row {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 14px;
    padding: 12px;
    border-radius: 16px;
    background: #fff;
    border: 1px solid #e5e7eb;
}

.movie-row__cover img {
    width: 150px;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 12px;
}

.movie-row__body {
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}

.movie-row__body strong {
    color: #111827;
    font-weight: 950;
}

.movie-row__body em {
    color: var(--primary);
    font-size: 13px;
    font-style: normal;
    font-weight: 800;
}

.movie-row__body span {
    color: #64748b;
    line-height: 1.55;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.detail-hero {
    background: radial-gradient(circle at 20% 0%, rgba(37, 99, 235, 0.42), transparent 32%), linear-gradient(135deg, #0f172a, #111827 58%, #1e3a8a);
    color: #fff;
}

.detail-hero__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 52px 24px;
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 34px;
    align-items: end;
}

.detail-cover {
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35);
}

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

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 700;
}

.breadcrumbs a:hover {
    color: #fff;
}

.detail-copy h1 {
    margin-bottom: 16px;
    font-size: clamp(32px, 5vw, 56px);
    line-height: 1.08;
    font-weight: 950;
    letter-spacing: -0.05em;
}

.detail-copy p {
    max-width: 850px;
    color: #e5e7eb;
    font-size: 18px;
    line-height: 1.85;
}

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

.detail-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 30px;
    align-items: start;
}

.player-card,
.article-card,
.side-card {
    padding: 24px;
    border-radius: 24px;
    background: #fff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.player-card h2,
.article-card h2,
.side-card h2 {
    margin-bottom: 16px;
    color: #111827;
    font-size: 24px;
    font-weight: 950;
    letter-spacing: -0.03em;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 22px;
    background: #020617;
    aspect-ratio: 16 / 9;
}

.player-shell video {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #020617;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.22), rgba(15, 23, 42, 0.64));
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-overlay span {
    width: 82px;
    height: 82px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    color: #fff;
    background: rgba(37, 99, 235, 0.95);
    box-shadow: 0 18px 44px rgba(37, 99, 235, 0.45);
    font-size: 32px;
    transform: translateX(3px);
}

.article-card {
    margin-top: 28px;
}

.article-card p {
    margin-bottom: 18px;
    color: #334155;
    font-size: 17px;
    line-height: 1.9;
}

.side-card {
    margin-bottom: 24px;
}

.side-card .movie-row {
    grid-template-columns: 110px minmax(0, 1fr);
    box-shadow: none;
}

.side-card .movie-row__cover img {
    width: 110px;
}

.no-result {
    display: none;
    padding: 24px;
    border-radius: 18px;
    background: #fff;
    border: 1px solid #e5e7eb;
    color: #64748b;
    font-weight: 800;
}

.no-result.is-visible {
    display: block;
}

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

.footer-grid {
    max-width: 1280px;
    margin: 0 auto;
    padding: 48px 24px;
    display: grid;
    grid-template-columns: 1.2fr 0.7fr 0.9fr 1fr;
    gap: 30px;
}

.site-footer h2 {
    margin-bottom: 16px;
    color: #fff;
    font-size: 18px;
    font-weight: 950;
}

.site-footer p,
.site-footer a {
    display: block;
    margin-bottom: 9px;
    color: #cbd5e1;
    line-height: 1.7;
}

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

.footer-bottom {
    padding: 18px 24px;
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    text-align: center;
    color: #94a3b8;
}

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

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

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

@media (max-width: 860px) {
    .site-header__inner {
        gap: 14px;
    }

    .nav,
    .header-search {
        display: none;
    }

    .mobile-toggle {
        display: flex;
        margin-left: auto;
    }

    .hero-slider {
        height: 620px;
    }

    .hero-slide__content {
        padding-bottom: 84px;
    }

    .hero-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .hero-search {
        width: 100%;
    }

    .hero-arrow {
        display: none;
    }

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

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

    .detail-cover {
        max-width: 260px;
    }
}

@media (max-width: 560px) {
    .site-header__inner,
    .page-main,
    .detail-hero__inner {
        padding-left: 16px;
        padding-right: 16px;
    }

    .brand__name {
        font-size: 18px;
    }

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

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

    .rank-item,
    .movie-row {
        grid-template-columns: 1fr;
    }

    .rank-item img,
    .movie-row__cover img,
    .side-card .movie-row__cover img {
        width: 100%;
    }
}
