:root {
    --sunrise: #ff6916;
    --sunrise-dark: #e75100;
    --dawn: #fff9f0;
    --ink: #111827;
    --muted: #6b7280;
    --line: #eee3d6;
    --card: #ffffff;
    --soft: #fff3e8;
    --shadow: 0 18px 45px rgba(17, 24, 39, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: linear-gradient(180deg, var(--dawn), #ffffff 28%, #f9fafb 100%);
    color: var(--ink);
    font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
}

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

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

.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(238, 227, 214, 0.85);
}

.header-inner {
    width: min(1240px, calc(100% - 32px));
    min-height: 72px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 22px;
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 900;
    font-size: 22px;
    letter-spacing: -0.03em;
    white-space: nowrap;
}

.logo-mark {
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(135deg, var(--sunrise), #ff9a3d);
    box-shadow: 0 12px 28px rgba(255, 105, 22, 0.28);
    font-size: 16px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 18px;
    font-size: 15px;
    color: #374151;
    flex: 1;
}

.desktop-nav a {
    transition: color 0.2s ease;
}

.desktop-nav a:hover {
    color: var(--sunrise);
}

.header-search {
    position: relative;
    width: min(320px, 34vw);
}

.header-search input,
.catalog-search {
    width: 100%;
    border: 1px solid var(--line);
    background: #fff;
    color: var(--ink);
    border-radius: 999px;
    padding: 12px 18px;
    font-size: 14px;
    outline: none;
    box-shadow: 0 8px 24px rgba(17, 24, 39, 0.04);
}

.header-search input:focus,
.catalog-search:focus {
    border-color: rgba(255, 105, 22, 0.55);
    box-shadow: 0 0 0 4px rgba(255, 105, 22, 0.12);
}

.search-panel {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: min(460px, 90vw);
    max-height: 520px;
    overflow: auto;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
    padding: 12px;
}

.search-result {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    padding: 10px;
    border-radius: 18px;
    transition: background 0.2s ease;
}

.search-result:hover {
    background: var(--soft);
}

.search-result img {
    width: 72px;
    height: 96px;
    border-radius: 12px;
    object-fit: cover;
    background: #f3f4f6;
}

.search-result strong {
    display: block;
    font-size: 15px;
    margin-bottom: 4px;
}

.search-result span {
    display: block;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.menu-button {
    display: none;
    border: 0;
    background: #fff4eb;
    color: var(--sunrise-dark);
    width: 42px;
    height: 42px;
    border-radius: 14px;
    font-size: 22px;
}

.mobile-nav {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 18px;
    display: grid;
    gap: 10px;
}

.mobile-nav[hidden] {
    display: none;
}

.mobile-nav a {
    padding: 12px 14px;
    border-radius: 14px;
    background: #fff6ef;
    color: #374151;
}

.hero {
    position: relative;
    min-height: 70vh;
    overflow: hidden;
    background: #111827;
}

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

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

.hero-slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(1.05);
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.42) 48%, rgba(0, 0, 0, 0.08)), linear-gradient(0deg, rgba(0, 0, 0, 0.72), transparent 42%);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    min-height: 70vh;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    align-items: center;
    gap: 42px;
    color: #fff;
}

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

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--sunrise);
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.38);
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 800;
    font-size: 13px;
}

.hero h1 {
    margin: 22px 0 18px;
    font-family: "Noto Serif SC", Georgia, serif;
    font-size: clamp(42px, 7vw, 78px);
    line-height: 1.02;
    letter-spacing: -0.06em;
    text-shadow: 0 18px 42px rgba(0, 0, 0, 0.35);
}

.hero p {
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.86);
    font-size: 18px;
    line-height: 1.85;
}

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

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

.primary-btn {
    background: linear-gradient(135deg, var(--sunrise), #ff9a3d);
    color: #fff;
    box-shadow: 0 16px 34px rgba(255, 105, 22, 0.32);
}

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

.ghost-btn {
    background: #fff;
    color: var(--sunrise-dark);
    border: 1px solid var(--line);
}

.primary-btn:hover,
.secondary-btn:hover,
.ghost-btn:hover {
    transform: translateY(-2px);
}

.hero-side {
    display: grid;
    gap: 12px;
    padding: 18px;
    border-radius: 28px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.26);
    backdrop-filter: blur(14px);
}

.hero-side-title {
    color: #fff;
    font-weight: 900;
    margin-bottom: 4px;
}

.hero-mini {
    display: grid;
    grid-template-columns: 74px 1fr;
    gap: 12px;
    align-items: center;
    padding: 9px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.hero-mini img {
    width: 74px;
    height: 98px;
    object-fit: cover;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.1);
}

.hero-mini strong {
    display: block;
    font-size: 15px;
    margin-bottom: 6px;
}

.hero-mini span {
    display: block;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.72);
}

.hero-controls {
    position: absolute;
    z-index: 5;
    left: 50%;
    bottom: 32px;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
}

.hero-controls button {
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.32);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    color: #fff;
    font-size: 24px;
    backdrop-filter: blur(12px);
}

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

.hero-dot {
    width: 32px;
    height: 4px;
    border: 0;
    border-radius: 99px;
    background: rgba(255, 255, 255, 0.36);
}

.hero-dot.is-active {
    background: var(--sunrise);
}

.section {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 64px 0;
}

.section.alt {
    width: 100%;
    background: linear-gradient(180deg, #fff7ef, #fff);
}

.section.alt > .section-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
}

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

.section-title h2 {
    margin: 0;
    font-family: "Noto Serif SC", Georgia, serif;
    font-size: clamp(28px, 3.8vw, 42px);
    line-height: 1.1;
}

.section-title p {
    margin: 8px 0 0;
    color: var(--muted);
    line-height: 1.8;
}

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

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

.movie-card {
    background: var(--card);
    border: 1px solid rgba(238, 227, 214, 0.9);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 12px 32px rgba(17, 24, 39, 0.06);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.movie-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow);
}

.card-poster {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, #fff1e6, #fde6d6);
}

.card-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
}

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

.type-badge,
.rank-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    color: #fff;
    background: var(--sunrise);
    font-size: 12px;
    font-weight: 800;
    box-shadow: 0 10px 24px rgba(255, 105, 22, 0.3);
}

.rank-badge {
    left: 12px;
    right: auto;
    background: rgba(17, 24, 39, 0.88);
}

.card-body {
    padding: 16px;
}

.card-body h3 {
    margin: 0 0 10px;
    font-size: 17px;
    line-height: 1.35;
}

.card-body h3 a:hover {
    color: var(--sunrise-dark);
}

.meta-line {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--muted);
    font-size: 13px;
    margin: 0 0 10px;
}

.card-desc {
    color: #4b5563;
    font-size: 13px;
    line-height: 1.7;
    min-height: 44px;
    margin: 0 0 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.tag-row span {
    font-size: 12px;
    color: var(--sunrise-dark);
    background: #fff1e6;
    border-radius: 999px;
    padding: 5px 8px;
}

.category-strip {
    display: grid;
    gap: 18px;
}

.category-row {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 30px;
    padding: 22px;
    box-shadow: 0 12px 32px rgba(17, 24, 39, 0.05);
}

.category-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.category-head h3 {
    margin: 0;
    font-size: 22px;
}

.category-head p {
    margin: 6px 0 0;
    color: var(--muted);
}

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

.compact-card .card-body {
    padding: 12px;
}

.compact-card .card-body h3 {
    font-size: 15px;
}

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

.rank-item {
    display: grid;
    grid-template-columns: 88px 54px 1fr;
    gap: 14px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(17, 24, 39, 0.04);
}

.rank-cover img {
    width: 88px;
    height: 118px;
    object-fit: cover;
    border-radius: 16px;
    background: #f3f4f6;
}

.rank-number {
    color: var(--sunrise);
    font-size: 30px;
    font-weight: 900;
    text-align: center;
}

.rank-text h3 {
    margin: 0 0 8px;
    font-size: 18px;
}

.rank-text p,
.rank-text span {
    display: block;
    color: var(--muted);
    font-size: 13px;
    line-height: 1.65;
}

.page-hero {
    background: radial-gradient(circle at 22% 18%, #ffe1c7, transparent 28%), linear-gradient(135deg, #fff9f0, #fff, #fff2e8);
    border-bottom: 1px solid var(--line);
}

.page-hero-inner {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 72px 0 54px;
}

.page-hero h1 {
    margin: 20px 0 12px;
    font-family: "Noto Serif SC", Georgia, serif;
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.08;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: var(--muted);
    font-size: 17px;
    line-height: 1.8;
}

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

.category-card {
    min-height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 26px;
    border-radius: 28px;
    border: 1px solid var(--line);
    background: linear-gradient(135deg, #fff, #fff4ea);
    box-shadow: 0 12px 32px rgba(17, 24, 39, 0.05);
}

.category-card h2 {
    margin: 0 0 12px;
    font-size: 24px;
}

.category-card p {
    color: var(--muted);
    line-height: 1.75;
}

.category-card span {
    color: var(--sunrise-dark);
    font-weight: 800;
}

.catalog-tools {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) auto;
    gap: 18px;
    align-items: center;
    margin-bottom: 28px;
}

.filter-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.filter-chip {
    border: 1px solid var(--line);
    background: #fff;
    color: #374151;
    border-radius: 999px;
    padding: 10px 14px;
    font-weight: 700;
}

.filter-chip.is-active {
    color: #fff;
    border-color: var(--sunrise);
    background: var(--sunrise);
}

.breadcrumb {
    width: min(1240px, calc(100% - 32px));
    margin: 26px auto 0;
    color: var(--muted);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: var(--sunrise-dark);
}

.detail-layout {
    width: min(1240px, calc(100% - 32px));
    margin: 28px auto 64px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
}

.player-card,
.detail-card,
.side-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 30px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.player-wrap {
    position: relative;
    background: #000;
    aspect-ratio: 16 / 9;
}

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

.play-cover {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.48), rgba(0, 0, 0, 0.72));
    cursor: pointer;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

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

.play-button {
    width: 94px;
    height: 94px;
    border-radius: 50%;
    border: 0;
    background: linear-gradient(135deg, var(--sunrise), #ff9a3d);
    color: #fff;
    font-size: 38px;
    box-shadow: 0 18px 42px rgba(255, 105, 22, 0.36);
}

.player-caption {
    padding: 20px 24px 24px;
}

.player-caption h1 {
    margin: 0 0 12px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.18;
    font-family: "Noto Serif SC", Georgia, serif;
}

.player-caption p {
    color: var(--muted);
    line-height: 1.85;
    margin: 0;
}

.detail-card {
    padding: 26px;
}

.detail-card h2,
.side-card h2 {
    margin: 0 0 16px;
    font-size: 24px;
}

.detail-card p {
    color: #374151;
    line-height: 1.9;
    margin: 0 0 18px;
}

.movie-facts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.fact {
    padding: 12px 14px;
    border-radius: 16px;
    background: #fff7ef;
    color: #374151;
    font-size: 14px;
}

.fact strong {
    color: var(--sunrise-dark);
}

.side-card {
    padding: 18px;
}

.side-cover {
    border-radius: 24px;
    overflow: hidden;
    margin-bottom: 18px;
    background: #fff1e6;
}

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

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

.related-item {
    display: grid;
    grid-template-columns: 70px 1fr;
    gap: 12px;
    align-items: center;
    padding: 8px;
    border-radius: 16px;
    transition: background 0.2s ease;
}

.related-item:hover {
    background: #fff7ef;
}

.related-item img {
    width: 70px;
    height: 94px;
    object-fit: cover;
    border-radius: 12px;
    background: #f3f4f6;
}

.related-item strong {
    display: block;
    font-size: 15px;
    margin-bottom: 4px;
}

.related-item span {
    color: var(--muted);
    font-size: 12px;
}

.site-footer {
    background: linear-gradient(135deg, #111827, #1f2937);
    color: #d1d5db;
    padding: 52px 0 28px;
}

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

.site-footer h2,
.site-footer h3 {
    color: #fff;
    margin: 0 0 16px;
}

.site-footer p {
    color: #9ca3af;
    line-height: 1.8;
    margin: 0;
}

.site-footer a {
    display: block;
    color: #d1d5db;
    margin: 0 0 10px;
}

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

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

.copyright {
    width: min(1240px, calc(100% - 32px));
    margin: 28px auto 0 !important;
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 13px;
}

.empty-state {
    display: none;
    padding: 32px;
    text-align: center;
    color: var(--muted);
    border: 1px dashed var(--line);
    border-radius: 24px;
    background: #fff;
}

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

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

    .header-search {
        margin-left: auto;
        width: min(360px, 48vw);
    }

    .hero-content {
        grid-template-columns: 1fr;
        padding: 96px 0 120px;
    }

    .hero-side {
        display: none;
    }

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

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

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

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

@media (max-width: 760px) {
    .header-inner {
        width: min(100% - 24px, 1240px);
        gap: 12px;
    }

    .site-logo span:last-child {
        display: none;
    }

    .header-search {
        width: 100%;
    }

    .hero,
    .hero-content {
        min-height: 78vh;
    }

    .hero-content {
        padding: 60px 0 128px;
    }

    .hero p {
        font-size: 15px;
    }

    .section,
    .section.alt > .section-inner,
    .page-hero-inner,
    .breadcrumb,
    .detail-layout {
        width: min(100% - 24px, 1240px);
    }

    .section {
        padding: 46px 0;
    }

    .section-title {
        display: block;
    }

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

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

    .rank-list,
    .category-cards {
        grid-template-columns: 1fr;
    }

    .rank-item {
        grid-template-columns: 74px 44px 1fr;
    }

    .rank-cover img {
        width: 74px;
        height: 100px;
    }

    .catalog-tools {
        grid-template-columns: 1fr;
    }

    .filter-chips {
        justify-content: flex-start;
    }

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

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

@media (max-width: 430px) {
    .movie-grid.large,
    .movie-grid,
    .category-preview {
        grid-template-columns: 1fr;
    }
}
