
:root {
    --bg: #020617;
    --panel: #0f172a;
    --panel-soft: #1e293b;
    --text: #f8fafc;
    --muted: #94a3b8;
    --line: rgba(148, 163, 184, 0.2);
    --amber: #f59e0b;
    --amber-dark: #d97706;
    --radius: 20px;
    --shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background: radial-gradient(circle at top left, rgba(245, 158, 11, 0.16), transparent 30%), var(--bg);
    color: var(--text);
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

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

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

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: linear-gradient(90deg, rgba(2, 6, 23, 0.96), rgba(15, 23, 42, 0.96), rgba(2, 6, 23, 0.96));
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
}

.site-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 72px;
    gap: 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--amber), #f97316);
    color: white;
    font-weight: 900;
    box-shadow: 0 14px 34px rgba(245, 158, 11, 0.35);
}

.brand-text {
    display: grid;
    line-height: 1.1;
}

.brand-text strong {
    font-size: 20px;
    letter-spacing: 0.02em;
}

.brand-text small {
    margin-top: 4px;
    color: var(--muted);
    font-size: 12px;
}

.nav-panel {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 1;
    gap: 28px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 18px;
    white-space: nowrap;
}

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

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

.nav-search {
    display: flex;
    align-items: center;
    background: rgba(30, 41, 59, 0.92);
    border: 1px solid var(--line);
    border-radius: 999px;
    overflow: hidden;
}

.nav-search input,
.search-page-form input,
.filter-row input {
    min-width: 220px;
    color: var(--text);
    background: transparent;
    outline: none;
    padding: 11px 16px;
}

.nav-search button,
.search-page-form button,
.filter-row button {
    color: white;
    background: var(--amber);
    font-weight: 700;
    padding: 11px 18px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.nav-search button:hover,
.search-page-form button:hover,
.filter-row button:hover,
.filter-row button.is-active {
    background: var(--amber-dark);
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(30, 41, 59, 0.85);
}

.menu-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 4px auto;
    background: white;
    border-radius: 2px;
}

.hero-carousel {
    position: relative;
    overflow: hidden;
    background: #020617;
}

.hero-stage {
    position: relative;
    min-height: 680px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: center;
    gap: 56px;
    padding: 76px max(32px, calc((100vw - 1200px) / 2)) 96px;
    background-size: cover;
    background-position: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.55s ease;
}

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

.hero-content {
    max-width: 720px;
}

.hero-kicker,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    padding: 8px 14px;
    border: 1px solid rgba(245, 158, 11, 0.35);
    border-radius: 999px;
    background: rgba(245, 158, 11, 0.12);
    color: #fbbf24;
    font-size: 14px;
    font-weight: 800;
}

.hero-content h1,
.hero-content h2,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    color: white;
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.hero-content h1,
.hero-content h2 {
    font-size: clamp(40px, 7vw, 76px);
}

.hero-movie-name {
    margin: 18px 0 0;
    color: #fde68a;
    font-size: clamp(24px, 4vw, 44px);
    font-weight: 800;
}

.hero-content p {
    max-width: 680px;
    margin: 24px 0 0;
    color: #dbeafe;
    font-size: 19px;
    line-height: 1.75;
}

.hero-tags,
.detail-meta,
.detail-tags,
.tag-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-tags {
    margin-top: 24px;
}

.hero-tags span,
.detail-meta span,
.detail-tags a,
.tag-row span {
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.14);
    color: #e2e8f0;
    font-size: 13px;
    font-weight: 700;
    padding: 7px 12px;
}

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

.btn-primary,
.btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    font-weight: 900;
    padding: 13px 24px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
    background: linear-gradient(135deg, var(--amber), #f97316);
    color: white;
    box-shadow: 0 18px 40px rgba(245, 158, 11, 0.35);
}

.btn-ghost {
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(15, 23, 42, 0.42);
    color: white;
}

.btn-primary:hover,
.btn-ghost:hover,
.movie-card:hover,
.mini-card:hover,
.category-tile:hover,
.category-card-large:hover,
.rank-card:hover {
    transform: translateY(-3px);
}

.hero-poster {
    width: 100%;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 28px;
    box-shadow: var(--shadow);
}

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

.hero-arrow {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.62);
    color: white;
    font-size: 34px;
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(245, 158, 11, 0.9);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.4);
}

.hero-dot.is-active {
    width: 34px;
    background: var(--amber);
}

.section-block {
    width: min(1200px, calc(100% - 32px));
    margin: 72px auto 0;
}

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

.section-head h2,
.site-footer h2,
.detail-content h2 {
    margin: 0;
    color: white;
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 900;
    letter-spacing: -0.03em;
}

.section-head a {
    color: #fbbf24;
    font-weight: 800;
}

.section-desc {
    max-width: 860px;
    color: var(--muted);
    line-height: 1.8;
    margin: -8px 0 24px;
}

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

.category-tile,
.category-card-large,
.movie-card,
.rank-card,
.filter-panel,
.detail-content,
.video-shell {
    border: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.9));
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.18);
}

.category-tile {
    min-height: 160px;
    padding: 22px;
    border-radius: var(--radius);
}

.category-tile strong {
    display: block;
    margin-bottom: 12px;
    color: white;
    font-size: 22px;
}

.category-tile span {
    color: #cbd5e1;
    line-height: 1.7;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.movie-card:hover {
    border-color: rgba(245, 158, 11, 0.5);
}

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

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

.movie-card:hover .movie-cover img,
.mini-card:hover img,
.rank-card:hover img {
    transform: scale(1.07);
}

.movie-badge {
    position: absolute;
    right: 12px;
    bottom: 12px;
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.78);
    color: white;
    font-size: 12px;
    font-weight: 900;
    padding: 6px 10px;
}

.movie-info {
    padding: 18px;
}

.movie-info h2 {
    margin: 0 0 8px;
    color: white;
    font-size: 19px;
    font-weight: 900;
}

.movie-meta,
.movie-line {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.65;
}

.movie-line {
    margin: 10px 0 14px;
    color: #cbd5e1;
}

.dark-strip {
    width: min(1240px, calc(100% - 32px));
    padding: 32px;
    border-radius: 28px;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.96));
    border: 1px solid var(--line);
}

.horizontal-list {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding-bottom: 14px;
    scrollbar-width: thin;
}

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

.mini-card {
    display: block;
    overflow: hidden;
    min-width: 178px;
    border-radius: 18px;
    background: rgba(15, 23, 42, 0.86);
    border: 1px solid var(--line);
    transition: transform 0.2s ease;
}

.mini-card img {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    transition: transform 0.32s ease;
}

.mini-card span,
.mini-card small {
    display: block;
    padding: 0 12px;
}

.mini-card span {
    margin-top: 12px;
    color: white;
    font-weight: 900;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mini-card small {
    padding-bottom: 12px;
    color: var(--muted);
}

.ranking-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px 28px;
    padding: 0;
    list-style: none;
}

.ranking-list li {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) auto;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.72);
    border: 1px solid var(--line);
}

.ranking-list span,
.rank-num {
    color: #fbbf24;
    font-size: 20px;
    font-weight: 900;
}

.ranking-list a {
    overflow: hidden;
    color: white;
    font-weight: 800;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ranking-list em {
    color: var(--muted);
    font-size: 13px;
    font-style: normal;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at top right, rgba(245, 158, 11, 0.18), transparent 34%), #020617;
}

.page-hero {
    padding: 82px max(32px, calc((100vw - 1200px) / 2));
}

.slim-hero {
    min-height: 300px;
    display: flex;
    align-items: center;
}

.page-hero h1,
.detail-info h1 {
    font-size: clamp(38px, 6vw, 62px);
}

.page-hero p {
    max-width: 820px;
    color: #cbd5e1;
    font-size: 18px;
    line-height: 1.8;
}

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

.category-card-large {
    border-radius: 24px;
    padding: 28px;
    transition: transform 0.2s ease;
}

.category-card-large p {
    color: #cbd5e1;
    line-height: 1.8;
}

.category-preview-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 18px 0 24px;
}

.category-preview-links a {
    border-radius: 999px;
    background: rgba(148, 163, 184, 0.14);
    color: #e2e8f0;
    padding: 7px 11px;
}

.filter-panel {
    border-radius: 22px;
    padding: 18px;
}

.filter-row,
.search-page-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.filter-row input,
.search-page-form input {
    flex: 1 1 300px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: rgba(2, 6, 23, 0.42);
}

.filter-row button {
    border-radius: 999px;
    background: rgba(30, 41, 59, 0.9);
}

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

.searchable-card.is-hidden {
    display: none;
}

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

.rank-card {
    display: grid;
    grid-template-columns: 60px 160px minmax(0, 1fr);
    gap: 20px;
    align-items: center;
    border-radius: 22px;
    padding: 16px;
    transition: transform 0.2s ease;
}

.rank-cover {
    overflow: hidden;
    border-radius: 16px;
}

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

.rank-card h2 {
    margin: 0 0 8px;
    color: white;
    font-size: 22px;
    font-weight: 900;
}

.rank-card p {
    margin: 6px 0;
    color: #cbd5e1;
    line-height: 1.7;
}

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

.detail-backdrop {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    filter: saturate(1.05);
}

.detail-wrap {
    position: relative;
    width: min(1200px, calc(100% - 32px));
    margin: 0 auto;
    padding: 54px 0 72px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    color: #cbd5e1;
    margin-bottom: 34px;
}

.breadcrumb a {
    color: #fbbf24;
}

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

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.18);
}

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

.detail-one-line {
    max-width: 760px;
    color: #dbeafe;
    font-size: 19px;
    line-height: 1.8;
}

.detail-meta,
.detail-tags {
    margin: 20px 0;
}

.player-block {
    margin-top: -90px;
    position: relative;
    z-index: 3;
}

.video-shell {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: black;
}

.video-shell video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: black;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    align-content: center;
    gap: 18px;
    color: white;
    background: linear-gradient(180deg, rgba(2, 6, 23, 0.1), rgba(2, 6, 23, 0.64));
    cursor: pointer;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

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

.play-circle {
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--amber), #f97316);
    box-shadow: 0 18px 44px rgba(245, 158, 11, 0.35);
    font-size: 34px;
    text-indent: 5px;
}

.play-overlay strong {
    font-size: 20px;
}

.detail-content {
    border-radius: 24px;
    padding: 32px;
}

.detail-content p {
    color: #dbeafe;
    font-size: 17px;
    line-height: 1.9;
}

.site-footer {
    margin-top: 86px;
    padding: 56px max(32px, calc((100vw - 1200px) / 2)) 26px;
    color: #cbd5e1;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.95), #020617);
    border-top: 1px solid var(--line);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
    gap: 32px;
}

.site-footer p,
.site-footer li {
    color: #94a3b8;
    line-height: 1.8;
}

.site-footer ul {
    padding: 0;
    list-style: none;
}

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

.footer-bottom {
    margin-top: 34px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
    color: #64748b;
}

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

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

    .hero-slide {
        grid-template-columns: minmax(0, 1fr) 280px;
    }
}

@media (max-width: 860px) {
    .menu-toggle {
        display: block;
    }

    .nav-panel {
        position: absolute;
        left: 16px;
        right: 16px;
        top: 76px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 18px;
        border: 1px solid var(--line);
        border-radius: 22px;
        background: rgba(15, 23, 42, 0.98);
        box-shadow: var(--shadow);
    }

    .nav-panel.is-open {
        display: flex;
    }

    .nav-links {
        flex-wrap: wrap;
    }

    .nav-search input {
        min-width: 0;
        width: 100%;
    }

    .hero-stage {
        min-height: 760px;
    }

    .hero-slide {
        grid-template-columns: 1fr;
        align-content: center;
        gap: 28px;
        padding: 60px 24px 92px;
    }

    .hero-poster {
        max-width: 220px;
    }

    .hero-content h1,
    .hero-content h2 {
        font-size: clamp(34px, 12vw, 54px);
    }

    .tile-grid,
    .movie-grid,
    .all-movie-grid,
    .category-large-grid,
    .ranking-list,
    .footer-grid,
    .detail-grid {
        grid-template-columns: 1fr;
    }

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

    .rank-card {
        grid-template-columns: 42px 104px minmax(0, 1fr);
        gap: 14px;
    }

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

    .player-block {
        margin-top: 32px;
    }
}

@media (max-width: 520px) {
    .site-nav,
    .section-block,
    .detail-wrap {
        width: min(100% - 24px, 1200px);
    }

    .brand-text strong {
        font-size: 17px;
    }

    .brand-mark {
        width: 38px;
        height: 38px;
        border-radius: 14px;
    }

    .hero-arrow {
        display: none;
    }

    .hero-stage {
        min-height: 700px;
    }

    .dark-strip,
    .detail-content {
        padding: 22px;
    }

    .mini-grid {
        grid-template-columns: 1fr 1fr;
    }

    .rank-card {
        grid-template-columns: 1fr;
    }

    .rank-cover {
        width: 100%;
    }
}
