:root {
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-200: #fde68a;
    --amber-300: #fcd34d;
    --amber-500: #f59e0b;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --orange-50: #fff7ed;
    --orange-500: #f97316;
    --orange-600: #ea580c;
    --rose-50: #fff1f2;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --white: #ffffff;
    --shadow: 0 18px 45px rgba(120, 53, 15, 0.16);
    --shadow-strong: 0 24px 70px rgba(120, 53, 15, 0.28);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --max-width: 1220px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--gray-800);
    background:
        radial-gradient(circle at top left, rgba(245, 158, 11, 0.18), transparent 32rem),
        linear-gradient(135deg, var(--amber-50), var(--orange-50) 48%, var(--rose-50));
    min-height: 100vh;
}

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

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

button,
input,
select {
    font: inherit;
}

[hidden] {
    display: none !important;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 251, 235, 0.88);
    border-bottom: 1px solid rgba(245, 158, 11, 0.18);
    backdrop-filter: blur(18px);
    box-shadow: 0 10px 28px rgba(120, 53, 15, 0.08);
}

.top-nav {
    max-width: var(--max-width);
    margin: 0 auto;
    min-height: 72px;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand,
.footer-brand strong {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--amber-700);
}

.brand-mark {
    width: 38px;
    height: 38px;
    display: inline-grid;
    place-items: center;
    border-radius: 14px;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
    box-shadow: 0 12px 24px rgba(217, 119, 6, 0.28);
}

.brand-text {
    background: linear-gradient(135deg, var(--amber-700), var(--orange-600));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

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

.nav-link,
.mobile-nav-link {
    position: relative;
    color: var(--gray-700);
    font-weight: 700;
    transition: color 0.2s ease;
}

.nav-link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -10px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--amber-500), var(--orange-500));
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.2s ease;
}

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

.nav-link:hover::after,
.nav-link.active::after {
    transform: scaleX(1);
}

.mobile-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 14px;
    background: var(--white);
    box-shadow: 0 10px 24px rgba(120, 53, 15, 0.12);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.mobile-menu-toggle span {
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: var(--amber-700);
}

.mobile-nav {
    display: none;
    border-top: 1px solid rgba(245, 158, 11, 0.14);
    padding: 10px 22px 18px;
    background: rgba(255, 251, 235, 0.96);
}

.mobile-nav.is-open {
    display: grid;
    gap: 12px;
}

.main-wrap,
.page-shell {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 52px 22px;
}

.hero-slider {
    max-width: var(--max-width);
    margin: 28px auto 0;
    padding: 0 22px 28px;
}

.hero-shell {
    position: relative;
    min-height: 640px;
    overflow: hidden;
    border-radius: 32px;
    box-shadow: var(--shadow-strong);
    background: var(--gray-900);
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    display: grid;
    grid-template-columns: minmax(0, 1.12fr) minmax(280px, 0.72fr);
    align-items: center;
    gap: 42px;
    padding: 72px;
    background-image:
        linear-gradient(110deg, rgba(69, 26, 3, 0.92), rgba(146, 64, 14, 0.72) 45%, rgba(17, 24, 39, 0.48)),
        var(--hero-image);
    background-size: cover;
    background-position: center;
    transition: opacity 0.65s ease, transform 0.65s ease;
    transform: scale(1.02);
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
    position: relative;
}

.hero-content {
    color: var(--white);
    max-width: 720px;
}

.hero-kicker {
    margin: 0 0 16px;
    display: inline-flex;
    align-items: center;
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: var(--amber-100);
    font-weight: 800;
    letter-spacing: 0.08em;
    backdrop-filter: blur(10px);
}

.hero-content h1 {
    margin: 0;
    font-size: clamp(2.7rem, 7vw, 5.8rem);
    line-height: 0.96;
    letter-spacing: -0.05em;
    text-shadow: 0 18px 38px rgba(0, 0, 0, 0.28);
}

.hero-summary {
    margin: 24px 0 0;
    max-width: 660px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 1.15rem;
    line-height: 1.9;
}

.hero-tags,
.chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

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

.hero-tags span,
.chip-row span,
.detail-tags span {
    border-radius: 999px;
    padding: 6px 11px;
    font-size: 0.82rem;
    font-weight: 700;
}

.hero-tags span {
    color: var(--amber-100);
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.22);
}

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

.primary-button,
.ghost-button,
.filter-search button,
.player-action {
    border: 0;
    border-radius: 999px;
    padding: 13px 24px;
    font-weight: 800;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.primary-button {
    color: var(--amber-700);
    background: var(--white);
    box-shadow: 0 14px 30px rgba(255, 255, 255, 0.16);
}

.ghost-button {
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.38);
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

.primary-button:hover,
.ghost-button:hover,
.filter-search button:hover,
.player-action:hover {
    transform: translateY(-2px) scale(1.02);
}

.hero-poster {
    position: relative;
    justify-self: center;
    width: min(360px, 100%);
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 28px 70px rgba(0, 0, 0, 0.42);
    transform: rotate(2deg);
    transition: transform 0.25s ease;
}

.hero-poster:hover {
    transform: translateY(-5px) rotate(0deg);
}

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

.hero-poster span,
.score-badge,
.rank-badge {
    position: absolute;
    z-index: 2;
    top: 14px;
    right: 14px;
    min-width: 44px;
    height: 34px;
    display: grid;
    place-items: center;
    border-radius: 999px;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.2);
}

.hero-controls {
    position: absolute;
    left: 34px;
    right: 34px;
    bottom: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
}

.hero-controls button {
    border: 0;
}

.hero-controls > button {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    font-size: 2rem;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
}

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

.hero-dot {
    width: 10px;
    height: 10px;
    padding: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.48);
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 28px;
    border-radius: 999px;
    background: var(--white);
}

.hero-category-strip {
    margin: -18px auto 0;
    position: relative;
    z-index: 3;
    width: min(1060px, calc(100% - 30px));
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 999px;
    padding: 15px 18px;
    color: var(--gray-700);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.hero-category-strip span {
    font-weight: 900;
    color: var(--amber-700);
}

.hero-category-strip a {
    padding: 8px 13px;
    border-radius: 999px;
    background: var(--amber-50);
    color: var(--gray-700);
    font-weight: 700;
}

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

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

.section-kicker,
.breadcrumbs {
    color: var(--amber-700);
    font-weight: 900;
    letter-spacing: 0.08em;
}

.section-head h1,
.section-head h2,
.page-title h1,
.detail-title h1 {
    margin: 8px 0 0;
    color: var(--gray-900);
    font-size: clamp(2rem, 4.6vw, 3.6rem);
    line-height: 1.08;
    letter-spacing: -0.04em;
}

.section-head p,
.page-title p {
    max-width: 760px;
    color: var(--gray-600);
    font-size: 1.04rem;
    line-height: 1.8;
}

.link-more {
    color: var(--amber-700);
    font-weight: 900;
}

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

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

.movie-card {
    min-width: 0;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 10px 30px rgba(120, 53, 15, 0.1);
    transition: transform 0.24s ease, box-shadow 0.24s ease;
}

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

.movie-poster {
    position: relative;
    overflow: hidden;
    background: var(--amber-100);
}

.movie-poster img {
    width: 100%;
    aspect-ratio: 3 / 4.1;
    object-fit: cover;
    transition: transform 0.28s ease;
}

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

.rank-badge {
    left: 12px;
    right: auto;
    padding: 0 12px;
}

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

.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    color: var(--amber-700);
    font-size: 0.78rem;
    font-weight: 900;
}

.movie-card h2 {
    margin: 9px 0 7px;
    min-height: 2.8em;
    color: var(--gray-900);
    font-size: 1.08rem;
    line-height: 1.35;
}

.movie-card p {
    margin: 0;
    min-height: 4.8em;
    color: var(--gray-600);
    font-size: 0.92rem;
    line-height: 1.6;
}

.chip-row {
    margin-top: 13px;
}

.chip-row span,
.detail-tags span {
    color: var(--amber-700);
    background: var(--amber-50);
}

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

.category-tile {
    position: relative;
    min-height: 210px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    overflow: hidden;
    border-radius: 28px;
    padding: 24px;
    color: var(--white);
    background:
        radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.26), transparent 34%),
        linear-gradient(135deg, var(--amber-600), var(--orange-600));
    box-shadow: var(--shadow);
}

.category-tile:nth-child(2n) {
    background:
        radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.24), transparent 34%),
        linear-gradient(135deg, #92400e, #fb923c);
}

.category-tile:nth-child(3n) {
    background:
        radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.22), transparent 34%),
        linear-gradient(135deg, #7c2d12, #f59e0b);
}

.category-tile span {
    position: absolute;
    top: 16px;
    right: 22px;
    font-size: 3.4rem;
    line-height: 1;
    font-weight: 900;
    opacity: 0.17;
}

.category-tile h2 {
    margin: 0 0 9px;
    font-size: 1.35rem;
}

.category-tile p {
    margin: 0;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
}

.rank-layout,
.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.62fr);
    gap: 28px;
    align-items: start;
}

.rank-list,
.sidebar-card,
.content-card,
.filter-panel,
.player-card,
.detail-meta,
.related-block {
    border-radius: var(--radius-xl);
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 12px 34px rgba(120, 53, 15, 0.1);
}

.rank-list {
    padding: 14px;
    display: grid;
    gap: 10px;
}

.mini-card {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    padding: 10px;
    border-radius: 18px;
    transition: background 0.2s ease, transform 0.2s ease;
}

.mini-card:hover {
    background: var(--amber-50);
    transform: translateX(3px);
}

.mini-card img {
    width: 78px;
    height: 104px;
    border-radius: 14px;
    object-fit: cover;
}

.mini-card h3 {
    margin: 0 0 8px;
    color: var(--gray-900);
    font-size: 1rem;
}

.mini-card p {
    margin: 0;
    color: var(--gray-600);
    font-size: 0.88rem;
    line-height: 1.55;
}

.mini-card > span {
    min-width: 48px;
    text-align: center;
    border-radius: 999px;
    padding: 7px 10px;
    color: var(--white);
    font-weight: 900;
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
}

.sidebar-card,
.content-card,
.detail-meta,
.related-block {
    padding: 24px;
}

.sidebar-card h2,
.content-card h2,
.related-block h2 {
    margin: 0 0 16px;
    color: var(--gray-900);
    font-size: 1.35rem;
}

.sidebar-card p,
.content-card p,
.detail-meta p {
    color: var(--gray-600);
    line-height: 1.8;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 20px;
}

.filter-search {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
}

.filter-search input,
.filter-controls select {
    width: 100%;
    border: 1px solid rgba(245, 158, 11, 0.22);
    outline: none;
    border-radius: 999px;
    padding: 13px 16px;
    color: var(--gray-800);
    background: var(--white);
}

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

.filter-search button {
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
}

.filter-controls {
    margin-top: 15px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.filter-controls label span {
    display: block;
    margin: 0 0 7px 4px;
    color: var(--amber-700);
    font-size: 0.86rem;
    font-weight: 900;
}

.filter-tags {
    margin-top: 16px;
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.filter-tags button {
    border: 0;
    border-radius: 999px;
    padding: 8px 13px;
    color: var(--gray-700);
    font-weight: 800;
    background: var(--amber-50);
}

.filter-tags button.active,
.filter-tags button:hover {
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
}

.empty-state {
    display: none;
    padding: 32px;
    text-align: center;
    color: var(--gray-600);
}

.empty-state.is-visible {
    display: block;
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
    font-size: 0.92rem;
}

.breadcrumbs a:hover {
    color: var(--orange-600);
}

.player-card {
    overflow: hidden;
    padding: 0;
}

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

.player-shell video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #000000;
}

.player-overlay {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    border: 0;
    color: var(--white);
    background: linear-gradient(180deg, rgba(17, 24, 39, 0.12), rgba(17, 24, 39, 0.58));
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-action {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--amber-700);
    background: var(--white);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.28);
}

.player-action span:first-child {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--white);
    background: linear-gradient(135deg, var(--amber-500), var(--orange-600));
}

.detail-title {
    margin-top: 24px;
}

.detail-title h1 {
    margin-bottom: 14px;
}

.detail-title p {
    color: var(--gray-600);
    font-size: 1.08rem;
    line-height: 1.9;
}

.detail-meta {
    display: grid;
    gap: 14px;
}

.detail-meta dl {
    margin: 0;
    display: grid;
    grid-template-columns: 86px 1fr;
    gap: 10px 14px;
}

.detail-meta dt {
    color: var(--amber-700);
    font-weight: 900;
}

.detail-meta dd {
    margin: 0;
    color: var(--gray-700);
}

.detail-cover {
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow);
}

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

.content-card {
    margin-top: 28px;
}

.content-card p {
    margin: 0;
    white-space: pre-line;
}

.detail-tags {
    margin-top: 18px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.related-block {
    margin-top: 28px;
}

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

.site-footer {
    margin-top: 44px;
    color: var(--amber-100);
    background: linear-gradient(135deg, #78350f, #9a3412);
}

.footer-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 42px 22px;
    display: grid;
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 34px;
}

.footer-brand strong {
    color: var(--white);
}

.footer-brand p {
    margin: 16px 0 0;
    max-width: 420px;
    line-height: 1.8;
}

.footer-links h2 {
    margin: 0 0 14px;
    color: var(--white);
    font-size: 1.08rem;
}

.footer-links div {
    display: grid;
    gap: 8px;
}

.footer-links a {
    color: var(--amber-100);
}

.footer-links a:hover {
    color: var(--white);
}

.footer-bottom {
    border-top: 1px solid rgba(254, 243, 199, 0.18);
    padding: 18px 22px;
    text-align: center;
    color: var(--amber-200);
    font-size: 0.92rem;
}

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

    .hero-slide {
        grid-template-columns: 1fr;
        padding: 56px;
    }

    .hero-poster {
        display: none;
    }
}

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

    .mobile-menu-toggle {
        display: inline-flex;
    }

    .hero-shell {
        min-height: 560px;
        border-radius: 24px;
    }

    .hero-slide {
        padding: 42px 26px 86px;
    }

    .hero-category-strip {
        border-radius: 22px;
    }

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

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

    .rank-layout,
    .detail-layout,
    .footer-inner {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 560px) {
    .top-nav {
        min-height: 66px;
        padding-inline: 16px;
    }

    .brand-text {
        font-size: 1.08rem;
    }

    .main-wrap,
    .page-shell {
        padding: 36px 16px;
    }

    .hero-slider {
        padding: 0 14px 24px;
    }

    .hero-shell {
        min-height: 520px;
    }

    .hero-content h1 {
        font-size: 2.65rem;
    }

    .hero-summary {
        font-size: 1rem;
    }

    .movie-grid,
    .movie-grid-wide,
    .category-grid,
    .related-grid {
        grid-template-columns: 1fr;
    }

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

    .mini-card {
        grid-template-columns: 64px minmax(0, 1fr);
    }

    .mini-card > span {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .mini-card img {
        width: 64px;
        height: 86px;
    }
}
