:root {
    --primary-50: #f0f9ff;
    --primary-100: #e0f2fe;
    --primary-400: #38bdf8;
    --primary-500: #0ea5e9;
    --primary-600: #0284c7;
    --primary-700: #0369a1;
    --primary-800: #075985;
    --accent-600: #d97706;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.08);
    --shadow-md: 0 10px 24px rgba(15, 23, 42, 0.10);
    --shadow-lg: 0 24px 50px rgba(15, 23, 42, 0.16);
    --radius-lg: 18px;
    --radius-xl: 24px;
    --header-height: 64px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    color: var(--gray-900);
    background: linear-gradient(180deg, var(--gray-50), #ffffff);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Arial, sans-serif;
}

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

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

button,
input,
select {
    font: inherit;
}

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

.site-header {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(229, 231, 235, 0.85);
    box-shadow: var(--shadow-sm);
    backdrop-filter: blur(8px);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
}

.site-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    color: var(--gray-900);
    letter-spacing: 0.01em;
    transition: color 0.2s ease;
}

.site-logo:hover {
    color: var(--primary-700);
}

.logo-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: #ffffff;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-600), var(--primary-800));
    box-shadow: 0 12px 22px rgba(2, 132, 199, 0.24);
    font-size: 14px;
}

.logo-text {
    font-size: 20px;
}

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

.nav-link {
    color: var(--gray-700);
    font-weight: 600;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.is-active {
    color: var(--primary-600);
}

.nav-link-soft {
    color: var(--gray-500);
    font-size: 14px;
}

.mobile-menu-button {
    display: none;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 12px;
    background: var(--gray-100);
    cursor: pointer;
}

.mobile-menu-button span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 4px auto;
    background: var(--gray-700);
    border-radius: 999px;
}

.mobile-nav {
    display: none;
    padding: 10px 16px 18px;
    border-top: 1px solid var(--gray-200);
    background: #ffffff;
}

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

.mobile-link {
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--gray-700);
    font-weight: 700;
}

.mobile-link:hover,
.mobile-link.is-active {
    color: var(--primary-700);
    background: var(--primary-50);
}

.main-offset {
    padding-top: var(--header-height);
}

.page-bg,
.detail-bg {
    min-height: 100vh;
    background: var(--gray-50);
}

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

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

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

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.03);
    transition: transform 6s ease;
}

.hero-slide.is-active .hero-image {
    transform: scale(1.08);
}

.hero-shade {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        radial-gradient(circle at 20% 50%, rgba(14, 165, 233, 0.16), transparent 36%),
        linear-gradient(90deg, rgba(0, 0, 0, 0.78), rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.08));
}

.hero-content {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: flex;
    align-items: center;
}

.hero-copy {
    width: min(680px, 100%);
    color: #ffffff;
}

.hero-kicker {
    display: inline-flex;
    margin-bottom: 16px;
    padding: 7px 12px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(2, 132, 199, 0.92);
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.hero-copy h1,
.detail-title-block h1 {
    margin: 0 0 16px;
    font-size: clamp(42px, 7vw, 72px);
    line-height: 0.98;
    letter-spacing: -0.04em;
}

.hero-copy p,
.detail-title-block p {
    margin: 0 0 26px;
    max-width: 620px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 18px;
    line-height: 1.8;
}

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

.hero-meta {
    margin-bottom: 30px;
}

.hero-meta span {
    padding: 7px 12px;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(4px);
    font-weight: 700;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 24px;
    border-radius: 12px;
    border: 0;
    cursor: pointer;
    font-weight: 800;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    transform: translateY(-2px) scale(1.02);
}

.btn-primary {
    color: #ffffff;
    background: var(--primary-600);
    box-shadow: 0 16px 32px rgba(2, 132, 199, 0.26);
}

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

.btn-glass {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(6px);
}

.hero-arrow {
    position: absolute;
    z-index: 4;
    top: 50%;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 999px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.20);
    backdrop-filter: blur(6px);
    cursor: pointer;
    font-size: 36px;
    line-height: 1;
    transform: translateY(-50%);
    transition: background 0.2s ease;
}

.hero-arrow:hover {
    background: rgba(255, 255, 255, 0.32);
}

.hero-prev {
    left: 24px;
}

.hero-next {
    right: 24px;
}

.hero-dots {
    position: absolute;
    z-index: 4;
    right: 32px;
    bottom: 32px;
    display: flex;
    gap: 9px;
}

.hero-dot {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.42);
    cursor: pointer;
    transition: width 0.2s ease, background 0.2s ease;
}

.hero-dot.is-active {
    width: 30px;
    background: #ffffff;
}

.home-search-wrap {
    margin-top: -34px;
    position: relative;
    z-index: 5;
}

.home-search {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    padding: 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(8px);
}

.home-search input,
.search-field input,
.filter-grid select {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    color: var(--gray-800);
    background: #ffffff;
    outline: none;
}

.home-search input,
.search-field input {
    padding: 0 16px;
}

.home-search input:focus,
.search-field input:focus,
.filter-grid select:focus {
    border-color: var(--primary-500);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.12);
}

.home-search button,
.filter-reset {
    min-height: 48px;
    padding: 0 22px;
    border: 0;
    border-radius: 12px;
    color: #ffffff;
    background: var(--primary-600);
    cursor: pointer;
    font-weight: 800;
}

.content-section {
    padding: 60px 0 0;
}

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

.section-heading h2 {
    margin: 0 0 8px;
    color: var(--gray-900);
    font-size: clamp(26px, 4vw, 38px);
    line-height: 1.1;
}

.section-heading p {
    margin: 0;
    color: var(--gray-600);
    line-height: 1.7;
}

.section-link {
    color: var(--primary-600);
    font-weight: 800;
    white-space: nowrap;
}

.section-link:hover {
    color: var(--primary-700);
}

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

.mixed-grid .movie-card-wide {
    grid-column: span 2;
}

.movie-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: var(--radius-lg);
    color: inherit;
    background: #ffffff;
    box-shadow: var(--shadow-md);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

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

.poster-cover {
    position: relative;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    background: var(--gray-200);
}

.poster-cover img,
.wide-cover img,
.category-preview img,
.rank-card img,
.detail-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.cover-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 2;
    padding: 5px 8px;
    border-radius: 8px;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.72);
    font-size: 12px;
    font-weight: 700;
    backdrop-filter: blur(4px);
}

.play-float {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    color: #ffffff;
    background: rgba(0, 0, 0, 0);
    font-size: 38px;
    opacity: 0;
    transition: background 0.25s ease, opacity 0.25s ease;
}

.movie-card:hover .play-float {
    background: rgba(0, 0, 0, 0.42);
    opacity: 1;
}

.card-body,
.wide-body,
.category-card-body,
.rank-card-body {
    padding: 18px;
}

.card-body h3,
.wide-body h3,
.rank-card-body h3 {
    display: -webkit-box;
    min-height: 2.7em;
    margin: 0 0 10px;
    overflow: hidden;
    color: var(--gray-900);
    font-size: 18px;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color 0.2s ease;
}

.movie-card:hover h3,
.rank-card:hover h3 {
    color: var(--primary-600);
}

.card-body p,
.wide-body p,
.rank-card-body p {
    display: -webkit-box;
    margin: 0 0 14px;
    overflow: hidden;
    color: var(--gray-600);
    font-size: 14px;
    line-height: 1.65;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-meta {
    color: var(--gray-500);
    font-size: 13px;
}

.card-meta span {
    display: inline-flex;
    align-items: center;
    min-height: 25px;
    padding: 3px 8px;
    border-radius: 999px;
    background: var(--gray-100);
}

.movie-card-wide {
    display: grid;
    grid-template-columns: 42% 1fr;
    min-height: 240px;
}

.wide-cover {
    position: relative;
    min-height: 100%;
    overflow: hidden;
    background: var(--gray-200);
}

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

.small-tag,
.detail-tag,
.tag {
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: var(--primary-50);
    color: var(--primary-700);
    font-size: 12px;
    font-weight: 700;
}

.small-tag {
    padding: 4px 8px;
}

.detail-tag,
.tag {
    padding: 7px 11px;
}

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

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

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.category-preview {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    height: 170px;
    overflow: hidden;
}

.category-card-body span,
.page-count {
    display: inline-flex;
    margin-bottom: 8px;
    padding: 5px 9px;
    border-radius: 999px;
    color: #ffffff;
    background: var(--primary-600);
    font-size: 12px;
    font-weight: 800;
}

.category-card-body h3 {
    margin: 0 0 8px;
    font-size: 22px;
}

.category-card-body p {
    margin: 0;
    color: var(--gray-600);
    line-height: 1.6;
}

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

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

.rank-item {
    display: grid;
    grid-template-columns: 44px 88px 1fr;
    align-items: center;
    gap: 14px;
    padding: 12px;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-md);
}

.rank-number,
.rank-large-number {
    display: grid;
    place-items: center;
    color: #ffffff;
    background: linear-gradient(135deg, var(--primary-600), var(--accent-600));
    font-weight: 900;
}

.rank-number {
    width: 36px;
    height: 36px;
    border-radius: 999px;
}

.rank-item img {
    width: 88px;
    height: 58px;
    border-radius: 10px;
    object-fit: cover;
}

.rank-info strong,
.rank-info em {
    display: block;
}

.rank-info strong {
    overflow: hidden;
    color: var(--gray-900);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rank-info em {
    margin-top: 5px;
    color: var(--gray-500);
    font-style: normal;
    font-size: 13px;
}

.highlight-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 380px;
    padding: 34px;
    border-radius: var(--radius-xl);
    color: #ffffff;
    background:
        radial-gradient(circle at 18% 20%, rgba(255, 255, 255, 0.2), transparent 32%),
        linear-gradient(135deg, var(--primary-600), var(--primary-800));
    box-shadow: var(--shadow-lg);
}

.highlight-panel span {
    font-weight: 800;
    opacity: 0.86;
}

.highlight-panel h2 {
    margin: 12px 0;
    font-size: 36px;
    line-height: 1.12;
}

.highlight-panel p {
    margin: 0 0 24px;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.8;
}

.page-hero {
    padding: 70px 0;
    color: #ffffff;
    background:
        radial-gradient(circle at 16% 30%, rgba(255, 255, 255, 0.18), transparent 28%),
        linear-gradient(135deg, var(--primary-600), var(--primary-800));
}

.back-link {
    display: inline-flex;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.78);
    font-weight: 800;
}

.back-link:hover {
    color: #ffffff;
}

.page-hero h1 {
    margin: 0 0 12px;
    font-size: clamp(36px, 6vw, 58px);
    line-height: 1.05;
}

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

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

.category-row {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr) 100px;
    gap: 18px;
    align-items: center;
    padding: 18px 20px;
    border-radius: 16px;
    background: #ffffff;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.category-row:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.category-row span {
    color: var(--gray-600);
}

.category-row em {
    color: var(--primary-700);
    font-style: normal;
    font-weight: 800;
    text-align: right;
}

.filter-panel {
    margin-bottom: 28px;
    padding: 18px;
    border-radius: var(--radius-xl);
    background: #ffffff;
    box-shadow: var(--shadow-md);
}

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

.filter-grid select {
    padding: 0 12px;
}

.filter-count {
    margin: 12px 0 0;
    color: var(--gray-500);
    font-weight: 700;
}

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

.rank-card-list {
    display: grid;
    gap: 16px;
}

.rank-card {
    display: grid;
    grid-template-columns: 64px 160px minmax(0, 1fr);
    gap: 18px;
    align-items: stretch;
    overflow: hidden;
    padding: 14px;
    border-radius: var(--radius-lg);
    background: #ffffff;
    box-shadow: var(--shadow-md);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.rank-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.rank-large-number {
    border-radius: 16px;
    font-size: 24px;
}

.rank-card img {
    width: 160px;
    height: 108px;
    border-radius: 14px;
    object-fit: cover;
}

.detail-hero {
    position: relative;
    overflow: hidden;
    color: #ffffff;
    background-image: var(--detail-cover);
    background-size: cover;
    background-position: center;
}

.detail-hero-shade {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.84), rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.38)),
        rgba(3, 105, 161, 0.24);
    backdrop-filter: blur(3px);
}

.detail-hero-inner {
    position: relative;
    z-index: 2;
    padding: 48px 0 58px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 28px;
    color: rgba(255, 255, 255, 0.76);
    font-size: 14px;
}

.breadcrumb a:hover {
    color: #ffffff;
}

.detail-hero-grid {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 34px;
    align-items: center;
}

.detail-poster {
    overflow: hidden;
    aspect-ratio: 2 / 3;
    border: 4px solid rgba(255, 255, 255, 0.18);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
}

.detail-title-block h1 {
    font-size: clamp(38px, 6vw, 64px);
}

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

.detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 30px;
    align-items: start;
    padding-top: 42px;
    padding-bottom: 72px;
}

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

.player-section,
.detail-card,
.side-panel {
    overflow: hidden;
    border-radius: var(--radius-xl);
    background: #ffffff;
    box-shadow: var(--shadow-md);
}

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

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

.player-overlay {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: grid;
    place-items: center;
    gap: 10px;
    border: 0;
    color: #ffffff;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.58));
    cursor: pointer;
    transition: opacity 0.2s ease, visibility 0.2s ease;
}

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

.player-play-icon {
    display: grid;
    place-items: center;
    width: 78px;
    height: 78px;
    border-radius: 50%;
    color: var(--primary-700);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 20px 42px rgba(0, 0, 0, 0.28);
    font-size: 32px;
}

.player-overlay strong {
    padding: 8px 14px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.42);
}

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

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

.detail-card p {
    margin: 0 0 14px;
    color: var(--gray-700);
    line-height: 1.9;
}

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

.info-list div {
    padding: 14px;
    border-radius: 14px;
    background: var(--gray-50);
}

.info-list dt {
    margin-bottom: 5px;
    color: var(--gray-500);
    font-size: 13px;
}

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

.detail-side {
    position: sticky;
    top: 88px;
}

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

.related-list .movie-card-wide {
    grid-template-columns: 122px 1fr;
    min-height: 116px;
    box-shadow: var(--shadow-sm);
}

.related-list .wide-body {
    padding: 12px;
}

.related-list .wide-body h3 {
    font-size: 15px;
}

.related-list .wide-body p,
.related-list .tag-row {
    display: none;
}

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

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 2fr) 1fr 1fr;
    gap: 30px;
    padding: 46px 0 32px;
}

.footer-logo {
    color: #ffffff;
}

.footer-brand p {
    max-width: 520px;
    color: var(--gray-400);
    line-height: 1.8;
}

.site-footer h3 {
    margin: 0 0 14px;
    color: #ffffff;
}

.site-footer ul {
    display: grid;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-footer a {
    color: var(--gray-400);
    transition: color 0.2s ease;
}

.site-footer a:hover {
    color: var(--primary-400);
}

.footer-bottom {
    padding: 18px 0 26px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--gray-500);
    text-align: center;
}

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

    .nav-link-soft {
        display: none;
    }

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

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

    .detail-side {
        position: static;
    }
}

@media (max-width: 760px) {
    :root {
        --header-height: 60px;
    }

    .desktop-nav {
        display: none;
    }

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

    .hero-carousel {
        min-height: 620px;
        height: calc(100vh - var(--header-height));
    }

    .hero-copy h1,
    .detail-title-block h1 {
        font-size: 42px;
    }

    .hero-arrow {
        display: none;
    }

    .hero-dots {
        right: auto;
        left: 24px;
    }

    .home-search,
    .filter-grid,
    .footer-grid,
    .detail-hero-grid,
    .info-list,
    .category-row,
    .rank-card {
        grid-template-columns: 1fr;
    }

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

    .mixed-grid .movie-card-wide {
        grid-column: span 2;
    }

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

    .wide-cover {
        aspect-ratio: 16 / 10;
    }

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

    .rank-card img {
        width: 100%;
        height: auto;
        aspect-ratio: 16 / 9;
    }

    .rank-large-number {
        width: 54px;
        height: 54px;
    }

    .detail-poster {
        width: 210px;
    }

    .detail-hero-inner {
        padding: 32px 0 44px;
    }

    .detail-layout {
        padding-top: 28px;
    }
}

@media (max-width: 520px) {
    .site-container {
        width: min(100% - 24px, 1180px);
    }

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

    .mixed-grid .movie-card-wide {
        grid-column: span 1;
    }

    .hero-copy p,
    .detail-title-block p {
        font-size: 16px;
    }

    .hero-meta span {
        font-size: 13px;
    }

    .home-search-wrap {
        margin-top: 18px;
    }

    .content-section {
        padding-top: 42px;
    }
}
