:root {
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-300: #fcd34d;
    --amber-400: #fbbf24;
    --amber-500: #f59e0b;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --amber-800: #92400e;
    --amber-900: #78350f;
    --text: #2d1d0d;
    --muted: #7c5d33;
    --line: rgba(146, 64, 14, 0.18);
    --white: rgba(255, 255, 255, 0.9);
    --shadow: 0 24px 70px rgba(120, 53, 15, 0.16);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--text);
    font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    background:
        radial-gradient(circle at top left, rgba(251, 191, 36, 0.24), transparent 32rem),
        linear-gradient(180deg, #fffbeb 0%, #fffaf0 45%, #ffffff 100%);
}

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

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

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

.header-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0.85rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1.1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex: 0 0 auto;
}

.logo-mark {
    width: 2.3rem;
    height: 2.3rem;
    border-radius: 999px;
    display: grid;
    place-items: center;
    color: white;
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber-500), var(--amber-800));
    box-shadow: 0 10px 26px rgba(217, 119, 6, 0.28);
}

.logo-text {
    color: var(--amber-900);
    font-size: 1.18rem;
    font-weight: 900;
    letter-spacing: 0.03em;
    white-space: nowrap;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    min-width: 0;
    flex: 1 1 auto;
    overflow: hidden;
}

.nav-link {
    padding: 0.55rem 0.78rem;
    border-radius: 999px;
    color: var(--amber-800);
    font-weight: 700;
    white-space: nowrap;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: white;
    background: var(--amber-600);
    transform: translateY(-1px);
}

.search-form,
.inline-filter,
.search-large {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-form input,
.inline-filter input,
.search-large input {
    border: 1px solid var(--amber-200);
    background: rgba(255, 255, 255, 0.88);
    border-radius: 999px;
    padding: 0.68rem 1rem;
    outline: none;
    color: var(--text);
    min-width: 13rem;
}

.search-form input:focus,
.inline-filter input:focus,
.search-large input:focus {
    border-color: var(--amber-500);
    box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.14);
}

.search-form button,
.inline-filter button,
.search-large button,
.btn {
    border: 0;
    border-radius: 999px;
    padding: 0.72rem 1.08rem;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.search-form button,
.inline-filter button,
.search-large button,
.btn.primary {
    color: white;
    background: linear-gradient(135deg, var(--amber-500), var(--amber-700));
    box-shadow: 0 14px 30px rgba(217, 119, 6, 0.24);
}

.btn.ghost {
    color: var(--amber-900);
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.62);
}

.btn.soft {
    color: var(--amber-800);
    background: var(--amber-100);
}

.btn:hover,
.search-form button:hover,
.inline-filter button:hover,
.search-large button:hover {
    transform: translateY(-2px);
}

.menu-toggle {
    display: none;
    width: 2.5rem;
    height: 2.5rem;
    border: 0;
    border-radius: 0.8rem;
    background: var(--amber-100);
    color: var(--amber-900);
    font-size: 1.2rem;
}

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

.mobile-panel a {
    display: block;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0.72rem 0;
    color: var(--amber-900);
    font-weight: 800;
}

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

.hero {
    position: relative;
    overflow: hidden;
    padding: 2rem 1.25rem 1.3rem;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 15%, rgba(251, 191, 36, 0.28), transparent 30rem),
        radial-gradient(circle at 80% 20%, rgba(180, 83, 9, 0.22), transparent 28rem),
        linear-gradient(135deg, #fff7d6, #fff, #fef3c7);
}

.hero-shell {
    position: relative;
    max-width: 1280px;
    margin: 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.66);
    border-radius: 2.2rem;
    background: rgba(255, 255, 255, 0.58);
    box-shadow: var(--shadow);
    overflow: hidden;
}

.hero-slides {
    position: relative;
    min-height: 560px;
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(18rem, 32rem);
    align-items: center;
    gap: 2.5rem;
    padding: 4rem;
    opacity: 0;
    transform: translateX(2rem);
    pointer-events: none;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.hero-slide.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.eyebrow,
.section-kicker {
    margin: 0 0 0.7rem;
    color: var(--amber-600);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.detail-info h1 {
    margin: 0;
    color: var(--amber-900);
    line-height: 1.08;
    font-weight: 950;
}

.hero h1 {
    font-size: clamp(2.4rem, 5vw, 5.5rem);
    max-width: 12ch;
}

.hero-desc {
    max-width: 44rem;
    margin: 1.25rem 0 1.1rem;
    color: #5f3f17;
    font-size: 1.15rem;
    line-height: 1.85;
}

.hero-tags,
.detail-tags,
.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.hero-tags span,
.detail-tags span,
.card-tags span {
    border-radius: 999px;
    color: var(--amber-800);
    background: rgba(254, 243, 199, 0.88);
    border: 1px solid rgba(217, 119, 6, 0.14);
    padding: 0.3rem 0.62rem;
    font-size: 0.82rem;
    font-weight: 800;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.8rem;
    margin-top: 1.6rem;
}

.hero-poster {
    position: relative;
    display: block;
    border-radius: 1.8rem;
    padding: 0.72rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.84), rgba(253, 230, 138, 0.7));
    box-shadow: 0 30px 70px rgba(120, 53, 15, 0.22);
}

.hero-poster img {
    aspect-ratio: 3 / 4;
    object-fit: cover;
    border-radius: 1.35rem;
    background: linear-gradient(135deg, var(--amber-100), var(--amber-300));
}

.hero-thumbs {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.75rem;
    padding: 0 1.1rem 1.1rem;
}

.hero-dot {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    border: 1px solid rgba(217, 119, 6, 0.16);
    border-radius: 1rem;
    padding: 0.5rem;
    color: var(--amber-900);
    background: rgba(255, 255, 255, 0.64);
    cursor: pointer;
    min-width: 0;
}

.hero-dot.active {
    background: var(--amber-100);
    box-shadow: 0 12px 30px rgba(180, 83, 9, 0.12);
}

.hero-dot img {
    width: 3rem;
    height: 3rem;
    border-radius: 0.7rem;
    object-fit: cover;
    flex: 0 0 auto;
}

.hero-dot span {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 0.86rem;
    font-weight: 800;
}

.section,
.page-shell,
.detail-shell {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2.4rem 1.25rem;
}

.section-lift {
    margin-top: 0.5rem;
}

.section.plain {
    padding-left: 0;
    padding-right: 0;
}

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

.section-head h2 {
    margin: 0;
    color: var(--amber-900);
    font-size: clamp(1.55rem, 3vw, 2.3rem);
}

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

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

.movie-card {
    border: 1px solid rgba(217, 119, 6, 0.12);
    border-radius: 1.45rem;
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 16px 40px rgba(120, 53, 15, 0.08);
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 54px rgba(120, 53, 15, 0.16);
}

.poster {
    position: relative;
    display: block;
    overflow: hidden;
}

.poster img {
    aspect-ratio: 3 / 4;
    object-fit: cover;
    background: linear-gradient(135deg, var(--amber-100), var(--amber-300));
    transition: transform 0.32s ease;
}

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

.poster-badge {
    position: absolute;
    top: 0.65rem;
    left: 0.65rem;
    border-radius: 999px;
    padding: 0.28rem 0.62rem;
    color: white;
    background: rgba(120, 53, 15, 0.86);
    font-size: 0.78rem;
    font-weight: 900;
}

.card-body {
    padding: 1rem;
}

.card-title {
    display: -webkit-box;
    min-height: 2.8em;
    overflow: hidden;
    color: var(--amber-900);
    font-size: 1.05rem;
    font-weight: 950;
    line-height: 1.4;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-meta {
    margin: 0.55rem 0;
    color: var(--amber-700);
    font-size: 0.86rem;
    font-weight: 800;
}

.card-line {
    display: -webkit-box;
    margin: 0 0 0.8rem;
    min-height: 4.5em;
    color: #6a4a20;
    font-size: 0.92rem;
    line-height: 1.5;
    overflow: hidden;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.card-category {
    display: inline-flex;
    margin-top: 0.8rem;
    color: var(--amber-700);
    font-size: 0.86rem;
    font-weight: 900;
}

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

.category-tile,
.category-overview {
    border: 1px solid rgba(217, 119, 6, 0.13);
    border-radius: 1.5rem;
    padding: 1.15rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(254, 243, 199, 0.78));
    box-shadow: 0 16px 42px rgba(120, 53, 15, 0.08);
}

.category-tile a:first-child {
    display: block;
}

.category-tile span,
.category-overview h2 {
    color: var(--amber-900);
    font-weight: 950;
    font-size: 1.25rem;
}

.category-tile strong,
.category-overview p {
    display: block;
    margin-top: 0.45rem;
    color: #6a4a20;
    line-height: 1.65;
    font-weight: 500;
}

.category-tile div {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.95rem;
}

.category-tile div a {
    border-radius: 999px;
    padding: 0.4rem 0.68rem;
    background: rgba(255, 255, 255, 0.72);
    color: var(--amber-800);
    font-size: 0.85rem;
    font-weight: 800;
}

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

.ranking-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
}

.rank-item {
    display: grid;
    grid-template-columns: 3.2rem 4.2rem minmax(0, 1fr);
    gap: 0.75rem;
    align-items: center;
    border: 1px solid rgba(217, 119, 6, 0.12);
    border-radius: 1.1rem;
    padding: 0.7rem;
    background: rgba(255, 255, 255, 0.82);
}

.rank-num {
    color: var(--amber-600);
    font-size: 1.4rem;
    font-weight: 950;
    text-align: center;
}

.rank-item img {
    width: 4.2rem;
    height: 5.6rem;
    border-radius: 0.75rem;
    object-fit: cover;
    background: var(--amber-100);
}

.rank-item a {
    color: var(--amber-900);
    font-weight: 950;
}

.rank-item p {
    margin: 0.35rem 0 0;
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.5;
}

.page-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(16rem, 24rem);
    align-items: center;
    gap: 2rem;
    border: 1px solid rgba(217, 119, 6, 0.13);
    border-radius: 2rem;
    padding: 2.2rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(254, 243, 199, 0.78));
    box-shadow: var(--shadow);
}

.page-hero.slim {
    display: block;
    max-width: 900px;
}

.page-hero h1 {
    font-size: clamp(2rem, 4vw, 4rem);
}

.page-hero p {
    max-width: 720px;
    color: #6a4a20;
    font-size: 1.08rem;
    line-height: 1.8;
}

.category-cover img {
    aspect-ratio: 3 / 4;
    border-radius: 1.5rem;
    object-fit: cover;
    background: var(--amber-100);
    box-shadow: 0 24px 60px rgba(120, 53, 15, 0.18);
}

.overview-link {
    display: grid;
    grid-template-columns: 12rem minmax(0, 1fr);
    gap: 1rem;
    align-items: center;
}

.overview-posters {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.35rem;
}

.overview-posters img {
    aspect-ratio: 3 / 4;
    border-radius: 0.8rem;
    object-fit: cover;
    background: var(--amber-100);
}

.crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 1rem;
    color: var(--amber-800);
    font-weight: 800;
}

.detail-hero {
    display: grid;
    grid-template-columns: minmax(16rem, 24rem) minmax(0, 1fr);
    gap: 2rem;
    align-items: end;
    border: 1px solid rgba(217, 119, 6, 0.13);
    border-radius: 2rem;
    padding: 1.4rem;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.84), rgba(254, 243, 199, 0.72));
    box-shadow: var(--shadow);
}

.detail-poster img {
    aspect-ratio: 3 / 4;
    border-radius: 1.4rem;
    object-fit: cover;
    background: var(--amber-100);
}

.detail-info h1 {
    font-size: clamp(2.1rem, 4vw, 4.8rem);
}

.detail-line {
    color: #5f3f17;
    font-size: 1.12rem;
    line-height: 1.8;
}

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

.detail-meta span {
    border-radius: 999px;
    padding: 0.45rem 0.75rem;
    color: white;
    background: var(--amber-700);
    font-weight: 800;
}

.player-section {
    margin: 1.5rem 0;
}

.player-box {
    position: relative;
    overflow: hidden;
    border-radius: 1.6rem;
    background: #1c1004;
    box-shadow: 0 28px 70px rgba(37, 22, 6, 0.28);
}

.movie-video {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #140b02;
    cursor: pointer;
}

.play-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: white;
    background: linear-gradient(135deg, rgba(28, 16, 4, 0.38), rgba(120, 53, 15, 0.25));
    cursor: pointer;
}

.play-cover span {
    width: 5.6rem;
    height: 5.6rem;
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-size: 2rem;
    background: linear-gradient(135deg, var(--amber-500), var(--amber-700));
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
}

.player-box.playing .play-cover {
    display: none;
}

.detail-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(18rem, 28rem);
    gap: 1rem;
}

.detail-content article {
    border: 1px solid rgba(217, 119, 6, 0.12);
    border-radius: 1.4rem;
    padding: 1.25rem;
    background: rgba(255, 255, 255, 0.84);
}

.detail-content h2 {
    margin: 0 0 0.8rem;
    color: var(--amber-900);
}

.detail-content p {
    color: #5f3f17;
    line-height: 1.9;
}

.movie-card.compact .card-line {
    min-height: 3em;
    -webkit-line-clamp: 2;
}

.site-footer {
    margin-top: 2rem;
    border-top: 1px solid var(--line);
    background: linear-gradient(180deg, rgba(254, 243, 199, 0.5), rgba(255, 251, 235, 0.94));
}

.footer-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 2rem 1.25rem;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.5rem;
}

.footer-inner strong {
    color: var(--amber-900);
    font-size: 1.15rem;
}

.footer-inner p {
    max-width: 42rem;
    color: var(--muted);
    line-height: 1.7;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    color: var(--amber-800);
    font-weight: 900;
}

.copyright {
    margin: 0;
    padding: 0 1.25rem 1.6rem;
    color: var(--muted);
    text-align: center;
}

@media (max-width: 1100px) {
    .main-nav {
        display: none;
    }

    .search-form {
        margin-left: auto;
    }

    .menu-toggle {
        display: block;
    }

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

    .hero-slide {
        grid-template-columns: minmax(0, 1fr) minmax(14rem, 24rem);
        padding: 3rem 2rem;
    }

    .hero-thumbs {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 820px) {
    .header-inner {
        flex-wrap: wrap;
    }

    .search-form {
        order: 3;
        width: 100%;
    }

    .search-form input {
        flex: 1;
        min-width: 0;
    }

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

    .hero-slide,
    .page-hero,
    .detail-hero,
    .detail-content,
    .overview-link {
        grid-template-columns: 1fr;
    }

    .hero-slide {
        align-items: start;
        gap: 1.5rem;
        padding: 2rem 1rem;
    }

    .hero h1 {
        font-size: 2.4rem;
    }

    .hero-thumbs {
        grid-template-columns: repeat(2, 1fr);
    }

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

    .footer-inner {
        flex-direction: column;
    }
}

@media (max-width: 560px) {
    .movie-grid,
    .rank-grid,
    .ranking-list,
    .category-grid,
    .overview-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        padding-left: 0.7rem;
        padding-right: 0.7rem;
    }

    .hero-shell,
    .page-hero,
    .detail-hero {
        border-radius: 1.25rem;
    }

    .hero-slides {
        min-height: 720px;
    }

    .hero-dot span {
        display: none;
    }

    .hero-dot {
        justify-content: center;
    }

    .section,
    .page-shell,
    .detail-shell {
        padding-left: 0.85rem;
        padding-right: 0.85rem;
    }

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

    .rank-item {
        grid-template-columns: 2.8rem 4rem minmax(0, 1fr);
    }
}
