:root {
    --stone-50: #fafaf9;
    --stone-100: #f5f5f4;
    --stone-200: #e7e5e4;
    --stone-300: #d6d3d1;
    --stone-400: #a8a29e;
    --stone-500: #78716c;
    --stone-600: #57534e;
    --stone-700: #44403c;
    --stone-800: #292524;
    --stone-900: #1c1917;
    --amber-50: #fffbeb;
    --amber-100: #fef3c7;
    --amber-300: #fcd34d;
    --amber-400: #fbbf24;
    --amber-500: #f59e0b;
    --amber-600: #d97706;
    --amber-700: #b45309;
    --amber-800: #92400e;
    --shadow-soft: 0 18px 45px rgba(28, 25, 23, 0.12);
    --shadow-card: 0 10px 25px rgba(28, 25, 23, 0.10);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--stone-800);
    background: linear-gradient(135deg, var(--stone-100) 0%, var(--amber-50) 45%, var(--stone-200) 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
    line-height: 1.65;
}

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

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

button,
input {
    font: inherit;
}

button {
    cursor: pointer;
}

.container-custom {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
}

.navbar {
    position: sticky;
    top: 0;
    z-index: 100;
    color: #ffffff;
    background: rgba(41, 37, 36, 0.98);
    box-shadow: 0 10px 30px rgba(28, 25, 23, 0.22);
    backdrop-filter: blur(16px);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

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

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber-500), var(--amber-800));
    box-shadow: 0 10px 25px rgba(217, 119, 6, 0.35);
    font-size: 14px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
    font-size: 15px;
    font-weight: 700;
}

.nav-links a,
.mobile-menu a {
    color: rgba(255, 255, 255, 0.86);
    transition: color 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active,
.mobile-menu a:hover,
.mobile-menu a.active {
    color: var(--amber-400);
}

.mobile-toggle {
    display: none;
    border: 0;
    color: #ffffff;
    background: transparent;
    font-size: 28px;
    line-height: 1;
}

.mobile-menu {
    display: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--stone-900);
}

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

.mobile-menu .container-custom {
    display: grid;
    gap: 14px;
    padding: 18px 0 22px;
}

.hero {
    position: relative;
    height: 600px;
    overflow: hidden;
    color: #ffffff;
    background: var(--stone-900);
}

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

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

.hero-slide > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.58), rgba(0, 0, 0, 0.28));
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    height: 100%;
}

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

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

.hero h1 {
    margin: 0 0 18px;
    font-size: clamp(42px, 7vw, 72px);
    line-height: 1.04;
    font-weight: 900;
    text-shadow: 0 12px 40px rgba(0, 0, 0, 0.48);
}

.hero p {
    max-width: 670px;
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.86);
    font-size: clamp(17px, 2vw, 22px);
}

.hero-meta,
.detail-meta,
.movie-meta-line {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.hero-meta {
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.78);
}

.hero-meta span,
.detail-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 5px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 22px;
}

.btn-primary,
.btn-secondary,
.filter-grid button,
.btn-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    border: 0;
    border-radius: 12px;
    padding: 10px 22px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary,
.filter-grid button {
    color: #ffffff;
    background: var(--amber-600);
    box-shadow: 0 10px 25px rgba(217, 119, 6, 0.28);
}

.btn-primary:hover,
.filter-grid button:hover {
    transform: translateY(-2px);
    background: var(--amber-700);
    box-shadow: 0 16px 34px rgba(180, 83, 9, 0.32);
}

.btn-secondary {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.12);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.20);
}

.btn-text {
    min-height: 38px;
    padding: 8px 0;
    color: var(--amber-700);
    justify-content: flex-start;
}

.hero-search {
    display: flex;
    width: min(620px, 100%);
    padding: 8px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: var(--shadow-soft);
}

.hero-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    padding: 0 16px;
    color: var(--stone-800);
    background: transparent;
}

.hero-search button {
    border: 0;
    border-radius: 12px;
    padding: 10px 20px;
    color: #ffffff;
    background: var(--stone-800);
    font-weight: 800;
}

.hero-arrow {
    position: absolute;
    z-index: 4;
    top: 50%;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.46);
    font-size: 36px;
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.72);
}

.hero-prev {
    left: 18px;
}

.hero-next {
    right: 18px;
}

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

.hero-dot {
    width: 12px;
    height: 12px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.52);
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.active {
    width: 34px;
    background: var(--amber-500);
}

.section {
    padding: 70px 0;
}

.section-soft {
    background: rgba(255, 255, 255, 0.48);
}

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

.section-header.tight {
    margin-bottom: 18px;
}

.section-title,
.section-header h2,
.cta-card h2 {
    margin: 0;
    color: var(--stone-800);
    font-size: clamp(28px, 4vw, 40px);
    line-height: 1.16;
    font-weight: 900;
}

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

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

.page-grid {
    margin-top: 28px;
}

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

.movie-card {
    overflow: hidden;
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow-card);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.movie-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 45px rgba(28, 25, 23, 0.16);
}

.poster {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: linear-gradient(135deg, var(--stone-300), var(--amber-100));
}

.poster img,
.category-preview img,
.category-mosaic img,
.rank-cover img,
.detail-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.poster::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 46%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.72), transparent);
}

.poster-type,
.rank-badge,
.poster-play {
    position: absolute;
    z-index: 2;
}

.poster-type {
    top: 10px;
    right: 10px;
    padding: 4px 9px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.55);
    font-size: 12px;
    font-weight: 800;
}

.rank-badge {
    top: 10px;
    left: 10px;
    width: 34px;
    height: 34px;
    border-radius: 12px;
    color: #ffffff;
    background: var(--amber-600);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
}

.poster-play {
    right: 12px;
    bottom: 12px;
    width: 42px;
    height: 42px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    background: rgba(217, 119, 6, 0.92);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28);
}

.card-body {
    padding: 16px;
}

.movie-meta-line {
    color: var(--stone-500);
    font-size: 13px;
    font-weight: 700;
}

.movie-meta-line span + span::before {
    content: "·";
    margin-right: 10px;
    color: var(--stone-300);
}

.movie-card h3 {
    margin: 8px 0 8px;
    font-size: 18px;
    line-height: 1.3;
    font-weight: 900;
}

.movie-card h3 a:hover,
.rank-item h3 a:hover,
.category-card-large h2 a:hover {
    color: var(--amber-700);
}

.movie-card p,
.rank-item p,
.category-tile p,
.category-card-large p,
.cta-card p,
.detail-title-box p,
.content-card p {
    color: var(--stone-600);
}

.movie-card p {
    display: -webkit-box;
    min-height: 52px;
    margin: 0 0 12px;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 14px;
}

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

.tag {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 9px;
    border-radius: 999px;
    color: var(--amber-800);
    background: var(--amber-100);
    font-size: 12px;
    font-weight: 800;
}

.tag.large {
    min-height: 30px;
    padding: 5px 12px;
    font-size: 13px;
}

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

.category-tile,
.category-card-large,
.filter-card,
.content-card,
.side-card,
.player-card,
.cta-card,
.rank-panel {
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow-card);
}

.category-tile {
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-tile:hover,
.category-card-large:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 50px rgba(28, 25, 23, 0.16);
}

.category-mosaic {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    height: 118px;
    background: var(--stone-200);
}

.category-tile > div:last-child {
    padding: 18px;
}

.category-tile h3,
.category-card-large h2,
.side-card h2,
.content-card h2 {
    margin: 0 0 8px;
    color: var(--stone-800);
    font-size: 22px;
    font-weight: 900;
}

.split-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 390px;
    gap: 32px;
    align-items: start;
}

.rank-panel {
    position: sticky;
    top: 84px;
    padding: 22px;
}

.rank-list,
.side-related {
    display: grid;
    gap: 14px;
}

.rank-item {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 13px;
    align-items: center;
}

.rank-cover {
    position: relative;
    display: block;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 12px;
    background: var(--stone-200);
}

.rank-cover span {
    position: absolute;
    top: 6px;
    left: 6px;
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9px;
    color: #ffffff;
    background: var(--amber-600);
    font-size: 13px;
    font-weight: 900;
}

.rank-item h3 {
    margin: 0 0 6px;
    font-size: 16px;
    line-height: 1.3;
}

.rank-item p {
    display: -webkit-box;
    margin: 0 0 6px;
    overflow: hidden;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    font-size: 13px;
}

.section-cta {
    padding-top: 30px;
}

.cta-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 34px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--stone-900), var(--amber-800));
}

.cta-card h2,
.cta-card p {
    color: #ffffff;
}

.cta-card p {
    max-width: 760px;
    margin: 12px 0 0;
}

.page-hero,
.detail-header {
    color: #ffffff;
    background: radial-gradient(circle at top left, rgba(245, 158, 11, 0.55), transparent 34%), linear-gradient(135deg, var(--stone-900), var(--stone-800));
}

.page-hero {
    padding: 60px 0 70px;
}

.page-hero h1,
.detail-title-box h1 {
    margin: 12px 0 14px;
    font-size: clamp(36px, 6vw, 58px);
    line-height: 1.08;
    font-weight: 900;
}

.page-hero p {
    max-width: 780px;
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 18px;
}

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

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

.category-large-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 26px;
}

.category-card-large {
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.category-preview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    height: 170px;
    background: var(--stone-200);
}

.category-card-body {
    padding: 22px;
}

.category-sample-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 16px 0 8px;
}

.category-sample-links a {
    padding: 5px 10px;
    border-radius: 999px;
    color: var(--stone-700);
    background: var(--stone-100);
    font-size: 13px;
    font-weight: 800;
}

.filter-card {
    padding: 20px;
}

.filter-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr auto;
    gap: 14px;
    align-items: end;
}

.filter-grid label {
    display: grid;
    gap: 7px;
    color: var(--stone-600);
    font-size: 13px;
    font-weight: 900;
}

.filter-grid input {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--stone-200);
    border-radius: 12px;
    outline: 0;
    padding: 0 13px;
    color: var(--stone-800);
    background: var(--stone-50);
}

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

.empty-state {
    margin: 18px 0 0;
    color: var(--stone-500);
    font-weight: 800;
}

.detail-header {
    padding: 36px 0 46px;
}

.detail-head-grid {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
    margin-top: 26px;
}

.detail-poster {
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border-radius: 20px;
    background: var(--stone-300);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.35);
}

.detail-title-box p {
    max-width: 820px;
    margin: 0 0 18px;
    color: rgba(255, 255, 255, 0.82);
    font-size: 18px;
}

.detail-tags {
    margin: 18px 0 24px;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 32px;
    align-items: start;
}

.detail-main {
    display: grid;
    gap: 24px;
}

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

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

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

.player-layer {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.72), rgba(0, 0, 0, 0.25));
    font-size: 18px;
    font-weight: 900;
}

.player-layer.is-hidden {
    display: none;
}

.play-circle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 74px;
    height: 74px;
    border-radius: 999px;
    color: #ffffff;
    background: var(--amber-600);
    box-shadow: 0 18px 40px rgba(217, 119, 6, 0.42);
    font-size: 30px;
}

.content-card,
.side-card {
    padding: 26px;
}

.content-card p {
    margin: 0 0 22px;
    font-size: 17px;
}

.content-card p:last-child {
    margin-bottom: 0;
}

.detail-side {
    position: sticky;
    top: 84px;
    display: grid;
    gap: 22px;
}

.info-list {
    display: grid;
    gap: 12px;
    margin: 0;
}

.info-list div {
    display: grid;
    grid-template-columns: 70px minmax(0, 1fr);
    gap: 12px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--stone-100);
}

.info-list dt {
    color: var(--stone-500);
    font-weight: 900;
}

.info-list dd {
    margin: 0;
    color: var(--stone-800);
    font-weight: 700;
}

.info-list a {
    color: var(--amber-700);
}

.site-footer {
    margin-top: 30px;
    color: var(--stone-300);
    background: var(--stone-900);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1.2fr;
    gap: 36px;
    padding: 48px 0 32px;
}

.footer-brand {
    color: #ffffff;
    margin-bottom: 14px;
}

.site-footer p {
    max-width: 460px;
    margin: 0;
    color: var(--stone-400);
}

.site-footer h2 {
    margin: 0 0 15px;
    color: #ffffff;
    font-size: 17px;
}

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

.footer-links a {
    color: var(--stone-400);
}

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

.footer-tags {
    display: flex;
    flex-wrap: wrap;
}

.footer-tags a {
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
}

.footer-bottom {
    padding: 20px 0 28px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--stone-500);
    font-size: 14px;
}

@media (max-width: 1080px) {
    .split-layout,
    .detail-layout {
        grid-template-columns: 1fr;
    }

    .rank-panel,
    .detail-side {
        position: static;
    }
}

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

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

    .hero {
        height: 680px;
    }

    .hero-arrow {
        display: none;
    }

    .hero-search {
        flex-direction: column;
        gap: 8px;
    }

    .hero-search input {
        min-height: 44px;
    }

    .section-header,
    .cta-card {
        align-items: flex-start;
        flex-direction: column;
    }

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

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

    .detail-poster {
        width: min(240px, 70vw);
    }
}

@media (max-width: 560px) {
    .container-custom {
        width: min(100% - 22px, 1280px);
    }

    .hero {
        height: 720px;
    }

    .hero-copy {
        padding-top: 0;
    }

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

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

    .card-body {
        padding: 12px;
    }

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

    .movie-card p,
    .tag-row {
        display: none;
    }

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

    .category-preview {
        height: 130px;
    }

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