* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
    color: #111827;
    background: linear-gradient(180deg, #fff7ed 0%, #ffffff 32%, #fffaf3 100%);
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid rgba(251, 146, 60, 0.16);
    backdrop-filter: blur(16px);
    box-shadow: 0 8px 30px rgba(124, 45, 18, 0.06);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.brand-mark {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    color: #fff7ed;
    font-weight: 900;
    background: linear-gradient(135deg, #f97316, #b45309);
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.28);
}

.brand-text {
    font-size: 22px;
    font-weight: 900;
    color: #9a3412;
    letter-spacing: 0.02em;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 22px;
    margin-left: 8px;
    color: #374151;
    font-weight: 700;
}

.desktop-nav a,
.nav-drop > button {
    border: 0;
    padding: 8px 0;
    color: #374151;
    background: transparent;
    transition: color 0.2s ease;
}

.desktop-nav a:hover,
.nav-drop:hover > button {
    color: #ea580c;
}

.nav-drop {
    position: relative;
}

.nav-drop-menu {
    position: absolute;
    left: 0;
    top: 38px;
    width: 180px;
    padding: 8px;
    display: grid;
    gap: 4px;
    opacity: 0;
    visibility: hidden;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: 0 24px 60px rgba(124, 45, 18, 0.18);
    transform: translateY(8px);
    transition: all 0.2s ease;
}

.nav-drop:hover .nav-drop-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-drop-menu a {
    padding: 10px 12px;
    border-radius: 12px;
}

.nav-drop-menu a:hover {
    background: #fff7ed;
}

.header-search {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.header-search input {
    width: 230px;
    height: 40px;
    padding: 0 14px;
    border: 1px solid #fed7aa;
    border-radius: 999px;
    outline: none;
    background: #ffffff;
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.header-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
    border-color: #f97316;
    box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.12);
}

.header-search button,
.primary-button,
.secondary-button,
.filter-panel button {
    border: 0;
    border-radius: 999px;
    font-weight: 800;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.header-search button,
.primary-button,
.filter-panel button {
    color: #ffffff;
    background: linear-gradient(135deg, #f97316, #b45309);
    box-shadow: 0 12px 26px rgba(249, 115, 22, 0.24);
}

.header-search button {
    height: 40px;
    padding: 0 18px;
}

.primary-button,
.secondary-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 0 22px;
}

.secondary-button {
    color: #9a3412;
    background: rgba(255, 247, 237, 0.9);
    border: 1px solid rgba(254, 215, 170, 0.9);
}

.header-search button:hover,
.primary-button:hover,
.secondary-button:hover,
.filter-panel button:hover {
    transform: translateY(-2px);
}

.menu-toggle {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    color: #9a3412;
    background: #fff7ed;
}

.mobile-nav {
    display: none;
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}

.mobile-nav a {
    padding: 12px;
    border-radius: 14px;
    color: #7c2d12;
    background: #fff7ed;
    font-weight: 700;
}

.hero {
    position: relative;
    overflow: hidden;
    min-height: 680px;
    background: radial-gradient(circle at 10% 10%, rgba(251, 191, 36, 0.38), transparent 28%), radial-gradient(circle at 88% 18%, rgba(249, 115, 22, 0.32), transparent 32%), linear-gradient(135deg, #451a03 0%, #9a3412 42%, #f97316 100%);
    color: #fff7ed;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.46), rgba(0, 0, 0, 0.08) 58%, rgba(0, 0, 0, 0.34));
    pointer-events: none;
}

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

.hero-slide {
    display: none;
    align-items: center;
    grid-template-columns: minmax(0, 1.03fr) minmax(300px, 0.72fr);
    gap: 54px;
}

.hero-slide.active {
    display: grid;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 8px 14px;
    border: 1px solid rgba(255, 237, 213, 0.42);
    border-radius: 999px;
    color: #fed7aa;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    font-weight: 800;
}

.hero h1 {
    margin: 0;
    font-size: clamp(42px, 7vw, 76px);
    line-height: 1.04;
    letter-spacing: -0.06em;
}

.hero p {
    max-width: 780px;
    margin: 20px 0 0;
    color: #ffedd5;
    font-size: 18px;
    line-height: 1.9;
}

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

.hero-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

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

.hero-tags span {
    padding: 7px 12px;
    color: #fff7ed;
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 237, 213, 0.28);
}

.hero-poster {
    position: relative;
    border-radius: 34px;
    overflow: hidden;
    min-height: 500px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.32);
    transform: rotate(1.2deg);
}

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

.hero-poster::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.48), transparent 60%);
}

.hero-card-mini {
    position: absolute;
    left: 22px;
    right: 22px;
    bottom: 22px;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    padding: 18px;
    border-radius: 24px;
    color: #fff7ed;
    background: rgba(67, 20, 7, 0.62);
    backdrop-filter: blur(14px);
}

.hero-card-mini strong {
    display: block;
    margin-bottom: 4px;
    font-size: 18px;
}

.hero-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 34px;
}

.hero-controls button {
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 237, 213, 0.4);
    border-radius: 999px;
    color: #fff7ed;
    background: rgba(255, 255, 255, 0.12);
}

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

.hero-dots button {
    width: 36px;
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 237, 213, 0.36);
}

.hero-dots button.active {
    background: #fed7aa;
}

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

.section {
    margin-top: 72px;
}

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

.section-title {
    margin: 0;
    color: #7c2d12;
    font-size: clamp(26px, 4vw, 40px);
    line-height: 1.2;
    letter-spacing: -0.04em;
}

.section-desc {
    margin: 8px 0 0;
    max-width: 680px;
    color: #6b7280;
    line-height: 1.8;
}

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

.movie-card {
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(254, 215, 170, 0.88);
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(124, 45, 18, 0.08);
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.movie-card:hover {
    transform: translateY(-7px);
    border-color: rgba(251, 146, 60, 0.78);
    box-shadow: 0 24px 62px rgba(124, 45, 18, 0.16);
}

.poster-wrap {
    position: relative;
    overflow: hidden;
    aspect-ratio: 2 / 3;
    background: linear-gradient(135deg, #fed7aa, #f97316);
}

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

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

.poster-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.56), transparent 58%);
    opacity: 0.72;
}

.poster-play {
    position: absolute;
    right: 14px;
    bottom: 14px;
    padding: 8px 12px;
    border-radius: 999px;
    color: #fff7ed;
    background: rgba(249, 115, 22, 0.92);
    font-size: 13px;
    font-weight: 900;
}

.rank-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    z-index: 2;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 14px;
    color: #ffffff;
    background: linear-gradient(135deg, #ef4444, #f97316);
    font-weight: 900;
    box-shadow: 0 10px 22px rgba(239, 68, 68, 0.3);
}

.movie-card-body {
    padding: 16px;
}

.movie-meta-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 10px;
    color: #ea580c;
    font-size: 13px;
    font-weight: 800;
}

.movie-card h3 {
    margin: 0;
    color: #111827;
    font-size: 18px;
    line-height: 1.35;
}

.movie-card h3 a:hover {
    color: #ea580c;
}

.movie-card p {
    min-height: 44px;
    margin: 10px 0 0;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    color: #6b7280;
    font-size: 14px;
    line-height: 1.6;
}

.tag-row,
.detail-tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-row {
    margin-top: 14px;
}

.tag-row span {
    padding: 5px 9px;
    color: #9a3412;
    background: #fff7ed;
}

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

.category-tile {
    overflow: hidden;
    display: grid;
    grid-template-columns: 188px minmax(0, 1fr);
    gap: 20px;
    min-height: 180px;
    padding: 18px;
    border-radius: 28px;
    border: 1px solid rgba(254, 215, 170, 0.9);
    background: linear-gradient(135deg, #ffffff, #fff7ed);
    box-shadow: 0 18px 42px rgba(124, 45, 18, 0.08);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

.category-tile:hover {
    transform: translateY(-5px);
    box-shadow: 0 24px 60px rgba(124, 45, 18, 0.14);
}

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

.category-images img {
    width: 100%;
    height: 78px;
    object-fit: cover;
    border-radius: 14px;
}

.category-tile h2 {
    margin: 6px 0 10px;
    color: #7c2d12;
    font-size: 24px;
}

.category-tile p {
    margin: 0;
    color: #6b7280;
    line-height: 1.8;
}

.page-hero {
    padding: 74px 0 48px;
    background: radial-gradient(circle at 20% 0%, rgba(253, 186, 116, 0.45), transparent 34%), linear-gradient(135deg, #fff7ed, #ffffff);
    border-bottom: 1px solid rgba(254, 215, 170, 0.72);
}

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

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: #ea580c;
    font-weight: 800;
    font-size: 14px;
}

.page-hero h1 {
    margin: 0;
    color: #7c2d12;
    font-size: clamp(36px, 5vw, 58px);
    letter-spacing: -0.05em;
    line-height: 1.12;
}

.page-hero p {
    max-width: 780px;
    margin: 16px 0 0;
    color: #6b7280;
    font-size: 17px;
    line-height: 1.9;
}

.filter-panel {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, minmax(140px, 0.7fr)) auto;
    gap: 12px;
    margin: 0 0 24px;
    padding: 18px;
    border: 1px solid rgba(254, 215, 170, 0.86);
    border-radius: 24px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(124, 45, 18, 0.08);
}

.filter-panel input,
.filter-panel select {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #fed7aa;
    border-radius: 14px;
    outline: none;
    background: #fffaf7;
}

.filter-panel button {
    min-width: 92px;
    padding: 0 18px;
}

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

.ranking-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border-radius: 22px;
    border: 1px solid rgba(254, 215, 170, 0.86);
    background: #ffffff;
    box-shadow: 0 14px 34px rgba(124, 45, 18, 0.08);
}

.ranking-item img {
    width: 72px;
    height: 98px;
    flex-shrink: 0;
    object-fit: cover;
    border-radius: 16px;
}

.ranking-item strong {
    display: block;
    color: #111827;
    line-height: 1.35;
}

.ranking-item span {
    display: block;
    margin-top: 8px;
    color: #ea580c;
    font-weight: 900;
    font-size: 13px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 28px;
    align-items: start;
    margin-top: 42px;
}

.player-card,
.detail-panel,
.side-panel {
    border: 1px solid rgba(254, 215, 170, 0.86);
    border-radius: 28px;
    background: #ffffff;
    box-shadow: 0 18px 45px rgba(124, 45, 18, 0.08);
}

.player-card {
    overflow: hidden;
}

.video-frame {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: #111827;
}

.video-frame video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #111827;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: #ffffff;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.18));
    z-index: 2;
}

.player-overlay span {
    display: inline-grid;
    place-items: center;
    width: 86px;
    height: 86px;
    border-radius: 999px;
    background: linear-gradient(135deg, #f97316, #ef4444);
    font-size: 28px;
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

.player-wrap.is-playing .player-overlay {
    display: none;
}

.player-info,
.detail-panel,
.side-panel {
    padding: 24px;
}

.player-info h2,
.detail-panel h2,
.side-panel h2 {
    margin: 0 0 14px;
    color: #7c2d12;
    font-size: 24px;
}

.player-info p,
.detail-panel p {
    margin: 0 0 18px;
    color: #4b5563;
    line-height: 1.9;
}

.detail-meta-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin: 20px 0 0;
}

.detail-meta-grid div {
    padding: 14px;
    border-radius: 18px;
    background: #fff7ed;
}

.detail-meta-grid span {
    display: block;
    color: #9a3412;
    font-size: 13px;
    font-weight: 800;
}

.detail-meta-grid strong {
    display: block;
    margin-top: 6px;
    color: #111827;
}

.detail-tag-row {
    margin-top: 14px;
}

.detail-tag-row span {
    padding: 7px 11px;
    color: #9a3412;
    background: #ffedd5;
}

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

.side-list a {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    padding: 10px;
    border-radius: 18px;
    background: #fff7ed;
    transition: transform 0.2s ease, background 0.2s ease;
}

.side-list a:hover {
    transform: translateX(4px);
    background: #ffedd5;
}

.side-list img {
    width: 70px;
    height: 92px;
    object-fit: cover;
    border-radius: 14px;
}

.side-list strong {
    display: block;
    color: #111827;
    line-height: 1.35;
}

.side-list span {
    display: block;
    margin-top: 6px;
    color: #ea580c;
    font-size: 13px;
    font-weight: 800;
}

.search-results-note {
    margin: 0 0 18px;
    color: #6b7280;
}

.site-footer {
    margin-top: 86px;
    color: #ffedd5;
    background: linear-gradient(180deg, #78350f, #431407);
}

.footer-grid {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 50px 0 36px;
    display: grid;
    grid-template-columns: 1.6fr repeat(3, 1fr);
    gap: 32px;
}

.footer-grid h2,
.footer-grid h3 {
    margin: 0 0 14px;
    color: #fff7ed;
}

.footer-grid p {
    margin: 0;
    max-width: 420px;
    color: #fed7aa;
    line-height: 1.8;
}

.footer-grid a,
.footer-grid span {
    display: block;
    margin-top: 9px;
    color: #fed7aa;
}

.footer-bottom {
    width: min(1240px, calc(100% - 32px));
    margin: 0 auto;
    padding: 22px 0;
    border-top: 1px solid rgba(254, 215, 170, 0.22);
    color: #fed7aa;
    text-align: center;
}

.hidden-card {
    display: none !important;
}

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

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

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

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

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

    .mobile-nav.open {
        display: grid;
    }

    .hero {
        min-height: auto;
    }

    .hero-slide.active {
        grid-template-columns: 1fr;
    }

    .hero-poster,
    .hero-poster img {
        min-height: 360px;
    }

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

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

    .filter-panel {
        grid-template-columns: 1fr 1fr;
    }

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

@media (max-width: 640px) {
    .header-inner,
    .main-wrap,
    .page-hero-inner,
    .hero-inner,
    .footer-grid,
    .footer-bottom {
        width: min(100% - 24px, 1240px);
    }

    .brand-text {
        font-size: 19px;
    }

    .hero-inner {
        padding: 58px 0 48px;
    }

    .hero h1 {
        font-size: 38px;
    }

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

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

    .movie-card-body {
        padding: 13px;
    }

    .movie-card h3 {
        font-size: 16px;
    }

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

    .ranking-strip {
        grid-template-columns: 1fr;
    }

    .filter-panel {
        grid-template-columns: 1fr;
    }

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

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