* {
    box-sizing: border-box;
}

: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;
    --orange-50: #fff7ed;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-900: #111827;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.08);
    --shadow-md: 0 10px 28px rgba(120, 53, 15, 0.10);
    --shadow-xl: 0 24px 60px rgba(17, 24, 39, 0.22);
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--gray-900);
    background: linear-gradient(180deg, var(--amber-50) 0%, #ffffff 46%, var(--orange-50) 100%);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
select {
    font: inherit;
}

button {
    cursor: pointer;
}

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

.page-shell {
    min-height: 100vh;
}

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

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: min(1280px, calc(100% - 32px));
    height: 66px;
    margin: 0 auto;
    gap: 18px;
}

.logo,
.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--amber-900);
    font-size: 21px;
    font-weight: 800;
    white-space: nowrap;
}

.logo-mark {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    color: #ffffff;
    background: linear-gradient(135deg, var(--amber-600), var(--amber-800));
    border-radius: 999px;
    box-shadow: 0 10px 22px rgba(180, 83, 9, 0.28);
    font-size: 13px;
}

.desktop-nav {
    display: flex;
    align-items: center;
    gap: 24px;
    color: var(--amber-800);
    font-weight: 650;
}

.desktop-nav a,
.mobile-menu a {
    transition: color 0.2s ease, transform 0.2s ease;
}

.desktop-nav a:hover,
.desktop-nav a.is-active,
.mobile-menu a:hover,
.mobile-menu a.is-active {
    color: var(--amber-600);
}

.header-search,
.mobile-search {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-search input,
.mobile-search input,
.filter-panel input,
.filter-panel select {
    min-width: 220px;
    border: 1px solid var(--amber-200);
    outline: none;
    border-radius: 999px;
    background: #ffffff;
    color: var(--gray-700);
    padding: 10px 14px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.header-search input:focus,
.mobile-search input:focus,
.filter-panel input:focus,
.filter-panel select:focus {
    border-color: var(--amber-500);
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.18);
}

.header-search button,
.mobile-search button,
.filter-panel button {
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: var(--amber-600);
    padding: 10px 16px;
    font-weight: 700;
    transition: background 0.2s ease, transform 0.2s ease;
}

.header-search button:hover,
.mobile-search button:hover,
.filter-panel button:hover {
    background: var(--amber-700);
    transform: translateY(-1px);
}

.search-results {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    display: none;
    width: min(420px, 90vw);
    max-height: 460px;
    overflow: auto;
    border: 1px solid var(--amber-200);
    border-radius: 18px;
    background: #ffffff;
    box-shadow: var(--shadow-xl);
    padding: 10px;
}

.search-results.is-open {
    display: block;
}

.search-item {
    display: grid;
    grid-template-columns: 58px 1fr;
    gap: 12px;
    border-radius: 14px;
    padding: 8px;
    transition: background 0.2s ease;
}

.search-item:hover {
    background: var(--amber-50);
}

.search-item img {
    width: 58px;
    height: 76px;
    object-fit: cover;
    border-radius: 10px;
    background: var(--amber-100);
}

.search-item strong {
    display: block;
    color: var(--gray-900);
    font-size: 15px;
    margin-bottom: 4px;
}

.search-item span,
.search-empty {
    color: var(--gray-600);
    font-size: 13px;
}

.mobile-toggle {
    display: none;
    border: 0;
    border-radius: 12px;
    color: var(--amber-900);
    background: var(--amber-100);
    padding: 8px 12px;
    font-size: 22px;
}

.mobile-menu {
    display: none;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 0 0 16px;
}

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

.hero {
    position: relative;
    height: 70vh;
    min-height: 520px;
    overflow: hidden;
    background: var(--gray-900);
}

.hero-track,
.hero-slide,
.hero-slide img,
.hero-shade {
    position: absolute;
    inset: 0;
}

.hero-slide {
    opacity: 0;
    pointer-events: none;
    transition: opacity 1s ease;
}

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

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.03);
}

.hero-shade {
    background: linear-gradient(90deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.66) 45%, rgba(0, 0, 0, 0.12) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: min(1280px, calc(100% - 32px));
    height: 100%;
    margin: 0 auto;
    max-width: 760px;
    margin-left: max(16px, calc((100vw - 1280px) / 2));
    color: #ffffff;
}

.eyebrow {
    color: var(--amber-400);
    font-weight: 800;
    letter-spacing: 0.02em;
    margin: 0 0 14px;
}

.hero h1 {
    max-width: 780px;
    margin: 0 0 18px;
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: -0.04em;
}

.hero p:not(.eyebrow) {
    max-width: 680px;
    margin: 0 0 22px;
    color: #e5e7eb;
    font-size: clamp(16px, 2vw, 20px);
}

.hero-meta,
.detail-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
}

.hero-meta span,
.detail-meta span,
.detail-meta strong {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    padding: 7px 12px;
    font-weight: 700;
}

.hero-meta strong,
.detail-meta strong {
    background: var(--amber-600);
}

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

.primary-link,
.ghost-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    padding: 14px 22px;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.primary-link {
    color: #ffffff;
    background: var(--amber-600);
    box-shadow: 0 14px 30px rgba(217, 119, 6, 0.32);
}

.primary-link:hover,
.ghost-link:hover {
    transform: translateY(-2px) scale(1.02);
}

.primary-link:hover {
    background: var(--amber-700);
}

.ghost-link {
    border: 1px solid rgba(255, 255, 255, 0.42);
    color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
}

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

.hero-arrow:hover {
    background: rgba(0, 0, 0, 0.72);
    transform: translateY(-50%) scale(1.08);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

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

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

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

.quick-entry {
    position: relative;
    z-index: 5;
    margin-top: -38px;
}

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

.quick-grid a {
    min-height: 92px;
    border: 1px solid var(--amber-200);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow-md);
    padding: 18px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.quick-grid a:hover {
    border-color: var(--amber-400);
    box-shadow: var(--shadow-xl);
    transform: translateY(-4px);
}

.quick-grid strong {
    display: block;
    color: var(--amber-900);
    font-size: 18px;
    margin-bottom: 6px;
}

.quick-grid span {
    color: var(--gray-600);
    font-size: 14px;
}

.section {
    padding: 52px 0;
}

.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
}

.section-heading h2 {
    margin: 0;
    color: var(--gray-900);
    font-size: clamp(24px, 3vw, 34px);
    font-weight: 900;
}

.section-heading a {
    color: var(--amber-600);
    font-weight: 800;
}

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

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

.movie-card {
    overflow: hidden;
    border: 1px solid rgba(251, 191, 36, 0.28);
    border-radius: 20px;
    background: #ffffff;
    box-shadow: var(--shadow-md);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.movie-card:hover {
    border-color: var(--amber-400);
    box-shadow: var(--shadow-xl);
    transform: translateY(-5px);
}

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

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

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

.poster-gradient {
    position: absolute;
    inset: auto 0 0;
    height: 44%;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, 0.72));
}

.score,
.rank-badge {
    position: absolute;
    z-index: 2;
    display: inline-grid;
    place-items: center;
    border-radius: 999px;
    font-weight: 900;
}

.score {
    right: 10px;
    bottom: 10px;
    min-width: 48px;
    height: 30px;
    color: #ffffff;
    background: var(--amber-600);
}

.rank-badge {
    left: 10px;
    top: 10px;
    min-width: 36px;
    height: 36px;
    color: var(--amber-900);
    background: var(--amber-200);
}

.movie-info {
    padding: 16px;
}

.movie-info h3 {
    margin: 0 0 8px;
    color: var(--gray-900);
    font-size: 18px;
    font-weight: 850;
    line-height: 1.3;
}

.movie-info h3 a:hover {
    color: var(--amber-700);
}

.movie-meta {
    margin: 0 0 10px;
    color: var(--amber-700);
    font-size: 13px;
    font-weight: 750;
}

.movie-desc {
    display: -webkit-box;
    min-height: 44px;
    margin: 0 0 12px;
    overflow: hidden;
    color: var(--gray-600);
    font-size: 14px;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

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

.tag-row span {
    border-radius: 999px;
    color: var(--amber-800);
    background: var(--amber-100);
    padding: 5px 9px;
    font-size: 12px;
    font-weight: 750;
}

.page-title,
.detail-hero {
    padding: 58px 0;
    background: radial-gradient(circle at 18% 0%, rgba(252, 211, 77, 0.34), transparent 36%), linear-gradient(135deg, var(--amber-50), #ffffff 58%, var(--orange-50));
}

.page-title h1,
.detail-copy h1 {
    margin: 0 0 14px;
    color: var(--gray-900);
    font-size: clamp(34px, 5vw, 58px);
    line-height: 1.08;
    font-weight: 950;
    letter-spacing: -0.035em;
}

.page-title p:not(.eyebrow) {
    max-width: 780px;
    margin: 0;
    color: var(--gray-600);
    font-size: 18px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
    color: var(--amber-700);
    font-weight: 750;
}

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

.category-card a {
    position: relative;
    display: block;
    min-height: 270px;
    overflow: hidden;
    border-radius: 22px;
    color: #ffffff;
    box-shadow: var(--shadow-xl);
}

.category-card img,
.category-card span {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.category-card img {
    object-fit: cover;
    transition: transform 0.35s ease;
}

.category-card span {
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.78));
}

.category-card div {
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: 20px;
}

.category-card p {
    margin: 0 0 8px;
    color: var(--amber-300);
    font-weight: 800;
}

.category-card h2 {
    margin: 0 0 10px;
    font-size: 28px;
    font-weight: 950;
}

.category-card em {
    display: block;
    color: #f3f4f6;
    font-style: normal;
}

.category-card a:hover img {
    transform: scale(1.1);
}

.filter-panel {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-bottom: 26px;
    border: 1px solid var(--amber-200);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.88);
    padding: 16px;
    box-shadow: var(--shadow-md);
}

.filter-panel input {
    flex: 1 1 260px;
}

.filter-panel select {
    min-width: 150px;
}

.movie-card.is-hidden {
    display: none;
}

.detail-layout {
    display: grid;
    grid-template-columns: minmax(220px, 330px) 1fr;
    gap: 36px;
    align-items: center;
}

.detail-cover {
    overflow: hidden;
    border-radius: 26px;
    box-shadow: var(--shadow-xl);
    background: var(--amber-100);
}

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

.detail-copy {
    max-width: 820px;
}

.detail-summary {
    margin: 0 0 22px;
    color: var(--gray-600);
    font-size: 19px;
}

.detail-meta span,
.detail-meta strong {
    color: var(--amber-900);
    background: var(--amber-100);
}

.detail-tags {
    margin-bottom: 28px;
}

.player-shell {
    position: relative;
    overflow: hidden;
    border-radius: 24px;
    background: #050505;
    box-shadow: var(--shadow-xl);
    aspect-ratio: 16 / 9;
}

.movie-video {
    width: 100%;
    height: 100%;
    background: #000000;
}

.play-overlay {
    position: absolute;
    inset: 0;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    border: 0;
    color: #ffffff;
    background: radial-gradient(circle, rgba(0, 0, 0, 0.24), rgba(0, 0, 0, 0.68));
    font-size: 20px;
    font-weight: 900;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.play-circle {
    display: grid;
    place-items: center;
    width: 78px;
    height: 78px;
    border-radius: 999px;
    color: #ffffff;
    background: var(--amber-600);
    box-shadow: 0 18px 38px rgba(217, 119, 6, 0.42);
    padding-left: 5px;
    font-size: 31px;
}

.detail-text {
    max-width: 980px;
}

.detail-text h2 {
    margin: 0 0 16px;
    color: var(--gray-900);
    font-size: 28px;
    font-weight: 900;
}

.detail-text p {
    margin: 0 0 28px;
    color: var(--gray-700);
    font-size: 18px;
    line-height: 1.9;
}

.site-footer {
    margin-top: 40px;
    color: var(--amber-100);
    background: linear-gradient(135deg, var(--amber-900), #451a03);
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    gap: 28px;
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
    padding: 36px 0;
}

.footer-logo {
    color: #ffffff;
}

.site-footer p {
    margin: 10px 0 0;
    color: var(--amber-200);
}

.site-footer nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 12px 18px;
    max-width: 720px;
}

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

@media (max-width: 1120px) {
    .desktop-nav {
        gap: 14px;
        font-size: 14px;
    }

    .header-search input {
        min-width: 180px;
    }

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

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

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

    .mobile-search {
        align-items: stretch;
    }

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

    .hero {
        min-height: 560px;
    }

    .hero-content {
        max-width: none;
        margin-left: 16px;
        margin-right: 16px;
    }

    .hero-arrow {
        display: none;
    }

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

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

    .detail-cover {
        max-width: 320px;
    }

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

    .site-footer nav {
        justify-content: flex-start;
    }
}

@media (max-width: 560px) {
    .container,
    .header-inner,
    .mobile-menu,
    .footer-inner {
        width: min(100% - 24px, 1280px);
    }

    .logo {
        font-size: 18px;
    }

    .hero {
        min-height: 620px;
    }

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

    .quick-grid,
    .movie-grid,
    .compact-grid,
    .category-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 36px 0;
    }

    .movie-card {
        border-radius: 18px;
    }

    .filter-panel {
        display: grid;
    }

    .filter-panel input,
    .filter-panel select,
    .filter-panel button {
        width: 100%;
    }
}
