* {
    box-sizing: border-box;
}

:root {
    --stone-950: #1c1917;
    --stone-900: #292524;
    --stone-800: #44403c;
    --stone-700: #57534e;
    --stone-600: #78716c;
    --stone-200: #e7e5e4;
    --stone-100: #f5f5f4;
    --amber-700: #b45309;
    --amber-600: #d97706;
    --amber-500: #f59e0b;
    --amber-300: #fcd34d;
    --white: #ffffff;
    --shadow-card: 0 18px 45px rgba(41, 37, 36, 0.14);
    --shadow-soft: 0 12px 30px rgba(41, 37, 36, 0.12);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--stone-800);
    background: #fafaf9;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    color: var(--white);
    background: linear-gradient(135deg, rgba(120, 53, 15, 0.96), rgba(41, 37, 36, 0.94));
    box-shadow: 0 8px 26px rgba(28, 25, 23, 0.18);
    backdrop-filter: blur(14px);
}

.nav-shell {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    max-width: 1220px;
    height: 70px;
    margin: 0 auto;
    padding: 0 24px;
}

.brand,
.footer-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    letter-spacing: 0.02em;
}

.brand {
    flex: 0 0 auto;
    font-size: 21px;
}

.brand-mark,
.footer-brand span {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    border-radius: 50%;
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.38);
}

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

.desktop-nav a,
.mobile-panel a {
    padding: 9px 13px;
    border-radius: 999px;
    color: rgba(255, 255, 255, 0.88);
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.active,
.mobile-panel a:hover,
.mobile-panel a.active {
    color: var(--white);
    background: rgba(255, 255, 255, 0.12);
}

.nav-search,
.mobile-search,
.big-search {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-search input,
.mobile-search input,
.big-search input,
.filter-bar input,
.filter-bar select {
    min-width: 0;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    outline: none;
    transition: border 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.nav-search input,
.mobile-search input {
    width: 190px;
    padding: 9px 14px;
    color: var(--white);
    background: rgba(255, 255, 255, 0.1);
}

.nav-search input::placeholder,
.mobile-search input::placeholder {
    color: rgba(255, 255, 255, 0.68);
}

.nav-search input:focus,
.mobile-search input:focus {
    border-color: var(--amber-300);
    box-shadow: 0 0 0 3px rgba(252, 211, 77, 0.22);
    background: rgba(255, 255, 255, 0.16);
}

.nav-search button,
.mobile-search button,
.big-search button {
    border: 0;
    border-radius: 999px;
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    font-weight: 700;
    padding: 9px 16px;
    box-shadow: 0 10px 22px rgba(217, 119, 6, 0.26);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
}

.mobile-panel {
    display: none;
    max-width: 1220px;
    margin: 0 auto;
    padding: 0 24px 18px;
}

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

.mobile-panel nav,
.quick-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.hero {
    position: relative;
    overflow: hidden;
    color: var(--white);
    background: var(--stone-950);
}

.hero-slide {
    display: none;
    min-height: calc(100vh - 70px);
    background-image: linear-gradient(90deg, rgba(28, 25, 23, 0.92) 0%, rgba(28, 25, 23, 0.68) 42%, rgba(28, 25, 23, 0.28) 100%), var(--hero-image);
    background-position: center;
    background-size: cover;
}

.hero-slide.is-active {
    display: flex;
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(250px, 360px);
    align-items: center;
    gap: 56px;
    width: 100%;
    max-width: 1220px;
    margin: 0 auto;
    padding: 92px 24px 94px;
}

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

.eyebrow,
.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--amber-300);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero-copy h1,
.page-hero h1,
.detail-copy h1 {
    margin: 14px 0 18px;
    color: var(--white);
    font-size: clamp(36px, 6vw, 68px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero-copy p,
.page-hero p,
.detail-copy p {
    max-width: 680px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.84);
    font-size: 18px;
}

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

.hero-tags span,
.detail-meta span,
.tag-row span,
.footer-tags span {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.hero-tags span,
.detail-meta span {
    color: var(--white);
    background: rgba(255, 255, 255, 0.12);
    padding: 8px 13px;
    border: 1px solid rgba(255, 255, 255, 0.16);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 28px;
}

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

.primary-btn {
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    box-shadow: 0 14px 32px rgba(245, 158, 11, 0.34);
}

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

.primary-btn.small {
    min-height: 40px;
    padding: 0 18px;
    font-size: 14px;
}

.ghost-btn {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.24);
    background: rgba(255, 255, 255, 0.09);
}

.hero-poster {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
}

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

.hero-poster div {
    position: absolute;
    inset: auto 18px 18px 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hero-poster span {
    padding: 6px 9px;
    border-radius: 999px;
    color: var(--white);
    background: rgba(28, 25, 23, 0.62);
    backdrop-filter: blur(10px);
    font-size: 12px;
    font-weight: 700;
}

.hero-controls {
    position: absolute;
    right: 50%;
    bottom: 28px;
    display: flex;
    align-items: center;
    gap: 12px;
    transform: translateX(50%);
}

.hero-controls button {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    background: rgba(28, 25, 23, 0.42);
    backdrop-filter: blur(10px);
}

.hero-dots {
    display: flex;
    gap: 8px;
}

.hero-dots button {
    width: 10px;
    height: 10px;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.38);
}

.hero-dots button.is-active {
    width: 28px;
    border-radius: 999px;
    background: var(--amber-300);
}

.section-shell,
.page-main,
.detail-main {
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
}

.section-shell {
    padding: 56px 0;
}

.intro-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    gap: 36px;
    align-items: center;
    margin-top: -48px;
    padding: 34px;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-card);
    backdrop-filter: blur(18px);
}

.intro-panel h2,
.section-title h2,
.category-overview-head h2,
.detail-text h2 {
    margin: 8px 0 0;
    color: var(--stone-900);
    font-size: clamp(25px, 3vw, 36px);
    line-height: 1.15;
    font-weight: 900;
    letter-spacing: -0.03em;
}

.intro-panel p,
.category-overview-head p,
.detail-text p {
    color: var(--stone-600);
    font-size: 16px;
}

.big-search {
    padding: 7px;
    border-radius: 999px;
    background: var(--stone-100);
    box-shadow: inset 0 0 0 1px var(--stone-200);
}

.big-search input {
    flex: 1;
    min-width: 160px;
    padding: 14px 18px;
    color: var(--stone-800);
    background: transparent;
    border: 0;
}

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

.section-title.slim {
    margin-bottom: 18px;
}

.section-title a {
    color: var(--amber-700);
    font-weight: 800;
}

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

.category-tile {
    display: grid;
    gap: 12px;
    min-height: 162px;
    padding: 24px;
    color: var(--white);
    border-radius: 26px;
    background: radial-gradient(circle at top right, rgba(252, 211, 77, 0.44), transparent 42%), linear-gradient(135deg, var(--stone-900), #78350f);
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-tile span {
    font-size: 22px;
    font-weight: 900;
}

.category-tile strong {
    color: rgba(255, 255, 255, 0.74);
    font-size: 14px;
    font-weight: 600;
}

.movie-grid,
.mini-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(178px, 1fr));
    gap: 22px;
}

.mini-grid {
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 18px;
}

.movie-card {
    overflow: hidden;
    border-radius: 22px;
    background: var(--white);
    box-shadow: 0 10px 28px rgba(41, 37, 36, 0.1);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    box-shadow: var(--shadow-card);
}

.poster-link {
    position: relative;
    display: block;
    overflow: hidden;
    background: var(--stone-200);
}

.poster-link img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    transition: transform 0.35s ease;
}

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

.card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 9px;
    border-radius: 999px;
    color: var(--stone-950);
    background: var(--amber-300);
    font-size: 12px;
    font-weight: 800;
}

.card-body {
    padding: 16px;
}

.card-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    color: var(--stone-600);
    font-size: 12px;
    font-weight: 700;
}

.card-body h3 {
    margin: 8px 0 8px;
    color: var(--stone-900);
    font-size: 17px;
    line-height: 1.32;
    font-weight: 900;
}

.card-body h3 a:hover {
    color: var(--amber-700);
}

.card-body p {
    display: -webkit-box;
    min-height: 44px;
    margin: 0 0 12px;
    overflow: hidden;
    color: var(--stone-600);
    font-size: 13px;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.tag-row span {
    color: #92400e;
    background: #fef3c7;
    padding: 5px 8px;
    font-size: 12px;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(320px, 0.8fr) minmax(0, 1.2fr);
    gap: 34px;
}

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

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

.rank-item {
    display: grid;
    grid-template-columns: 48px 58px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    padding: 12px;
    border: 1px solid var(--stone-200);
    border-radius: 18px;
    background: var(--white);
    box-shadow: 0 8px 22px rgba(41, 37, 36, 0.07);
}

.rank-item:hover strong {
    color: var(--amber-700);
}

.rank-number {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    border-radius: 14px;
    font-weight: 900;
}

.rank-item img {
    width: 58px;
    height: 78px;
    border-radius: 12px;
    object-fit: cover;
}

.rank-copy {
    min-width: 0;
}

.rank-copy strong,
.rank-copy em {
    display: block;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.rank-copy strong {
    color: var(--stone-900);
    font-weight: 900;
}

.rank-copy em {
    color: var(--stone-600);
    font-size: 13px;
    font-style: normal;
}

.page-main,
.detail-main {
    padding-bottom: 26px;
}

.page-hero,
.detail-hero {
    position: relative;
    overflow: hidden;
    width: min(1220px, calc(100% - 48px));
    margin: 34px auto 0;
    color: var(--white);
    border-radius: 34px;
    background-image: linear-gradient(90deg, rgba(28, 25, 23, 0.92), rgba(120, 53, 15, 0.54)), var(--hero-image);
    background-position: center;
    background-size: cover;
    box-shadow: var(--shadow-card);
}

.page-hero > div {
    max-width: 780px;
    padding: 72px 42px;
}

.compact-hero > div {
    padding: 58px 42px;
}

.stacked-list {
    display: grid;
    gap: 28px;
}

.category-overview-card {
    padding: 26px;
    border-radius: 28px;
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

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

.filter-panel {
    padding-top: 34px;
}

.filter-bar {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 180px 180px;
    gap: 12px;
    margin-bottom: 28px;
    padding: 16px;
    border-radius: 24px;
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

.filter-bar.wide {
    grid-template-columns: minmax(260px, 1fr) 160px 160px 160px;
}

.filter-bar input,
.filter-bar select {
    width: 100%;
    padding: 12px 15px;
    color: var(--stone-800);
    background: var(--stone-100);
    border-color: var(--stone-200);
}

.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--amber-500);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.16);
}

.filter-status {
    margin: 0 0 18px;
    color: var(--stone-600);
    font-weight: 800;
}

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

.detail-hero {
    width: 100%;
    margin-top: 0;
    border-radius: 0 0 38px 38px;
}

.detail-hero-inner {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 44px;
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
    padding: 76px 0;
}

.detail-poster {
    overflow: hidden;
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.1);
    box-shadow: 0 28px 74px rgba(0, 0, 0, 0.34);
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--amber-300);
}

.detail-tags {
    margin-top: 18px;
}

.detail-section {
    padding-top: 44px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 30px;
    background: #000;
    box-shadow: var(--shadow-card);
}

.movie-player {
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    gap: 12px;
    width: 100%;
    height: 100%;
    color: var(--white);
    border: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.16), rgba(0, 0, 0, 0.62));
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

.play-overlay span {
    display: grid;
    place-items: center;
    width: 86px;
    height: 86px;
    color: var(--stone-950);
    background: linear-gradient(135deg, var(--amber-300), var(--amber-600));
    border-radius: 50%;
    box-shadow: 0 16px 46px rgba(245, 158, 11, 0.38);
    font-size: 34px;
}

.play-overlay strong {
    padding: 8px 16px;
    border-radius: 999px;
    background: rgba(28, 25, 23, 0.62);
    backdrop-filter: blur(10px);
}

.play-overlay.is-hidden,
.player-shell.video-ready .play-overlay {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.detail-text {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.detail-text article {
    padding: 26px;
    border-radius: 26px;
    background: var(--white);
    box-shadow: var(--shadow-soft);
}

.detail-text h2 {
    margin-bottom: 12px;
    font-size: 26px;
}

.site-footer {
    margin-top: 40px;
    color: rgba(255, 255, 255, 0.72);
    background: var(--stone-950);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr;
    gap: 34px;
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
    padding: 48px 0;
}

.footer-brand {
    color: var(--white);
    font-size: 20px;
}

.site-footer p {
    margin: 16px 0 0;
}

.site-footer h2 {
    margin: 0 0 14px;
    color: var(--white);
    font-size: 16px;
}

.site-footer ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer a:hover {
    color: var(--amber-300);
}

.footer-tags span {
    color: var(--amber-300);
    background: rgba(252, 211, 77, 0.1);
    padding: 7px 10px;
}

.footer-bottom {
    width: min(1220px, calc(100% - 48px));
    margin: 0 auto;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 14px;
}

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

    .menu-toggle {
        display: inline-grid;
        place-items: center;
    }

    .hero-inner,
    .intro-panel,
    .split-layout,
    .detail-text,
    .footer-grid {
        grid-template-columns: 1fr;
    }

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

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

    .detail-hero-inner {
        grid-template-columns: 210px minmax(0, 1fr);
    }
}

@media (max-width: 760px) {
    .nav-shell {
        height: 64px;
        padding: 0 16px;
    }

    .brand {
        font-size: 18px;
    }

    .mobile-panel {
        padding: 0 16px 16px;
    }

    .mobile-search {
        display: grid;
        grid-template-columns: 1fr auto;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 28px;
        padding: 56px 18px 82px;
    }

    .hero-slide {
        min-height: auto;
    }

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

    .section-shell,
    .page-main,
    .detail-main,
    .detail-hero-inner {
        width: min(100% - 28px, 1220px);
    }

    .section-shell {
        padding: 38px 0;
    }

    .intro-panel {
        margin-top: 18px;
        padding: 22px;
        border-radius: 24px;
    }

    .big-search,
    .filter-bar,
    .filter-bar.wide {
        display: grid;
        grid-template-columns: 1fr;
        border-radius: 22px;
    }

    .section-title,
    .category-overview-head {
        align-items: flex-start;
        flex-direction: column;
    }

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

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

    .card-body {
        padding: 13px;
    }

    .page-hero {
        width: min(100% - 28px, 1220px);
        border-radius: 26px;
    }

    .page-hero > div,
    .compact-hero > div {
        padding: 46px 22px;
    }

    .detail-hero {
        width: 100%;
        border-radius: 0 0 28px 28px;
    }

    .detail-hero-inner {
        grid-template-columns: 1fr;
        padding: 42px 0;
    }

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

    .player-shell {
        border-radius: 20px;
    }

    .play-overlay span {
        width: 68px;
        height: 68px;
        font-size: 26px;
    }

    .rank-item {
        grid-template-columns: 42px 52px minmax(0, 1fr);
    }

    .footer-grid {
        width: min(100% - 28px, 1220px);
    }
}

@media (max-width: 420px) {
    .movie-grid,
    .mini-grid {
        grid-template-columns: 1fr;
    }
}
