
:root {
    --primary-50: #f0f9ff;
    --primary-100: #e0f2fe;
    --primary-600: #0284c7;
    --primary-700: #0369a1;
    --accent-50: #ecfdf5;
    --accent-600: #059669;
    --orange-500: #f97316;
    --yellow-400: #facc15;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-900: #111827;
    --slate-900: #0f172a;
    --white: #ffffff;
    --shadow-sm: 0 1px 2px rgb(0 0 0 / 0.05);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.10), 0 4px 6px -4px rgb(0 0 0 / 0.10);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.10), 0 8px 10px -6px rgb(0 0 0 / 0.10);
    --radius: 18px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--gray-50);
    color: var(--gray-900);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
}

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

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

button,
input,
select {
    font: inherit;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgb(255 255 255 / 0.94);
    border-bottom: 1px solid rgb(229 231 235 / 0.9);
    backdrop-filter: blur(16px);
}

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

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: max-content;
}

.brand-mark {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    color: var(--white);
    font-weight: 800;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--primary-600), var(--accent-600));
    box-shadow: var(--shadow-lg);
}

.brand-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.brand-text strong {
    font-size: 20px;
    letter-spacing: -0.02em;
}

.brand-text small {
    color: var(--gray-500);
    font-size: 12px;
}

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

.nav-link,
.nav-dropdown > button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    padding: 0 16px;
    color: var(--gray-700);
    border-radius: 10px;
    border: 0;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-link:hover,
.nav-dropdown > button:hover,
.nav-link.active {
    color: var(--primary-700);
    background: var(--primary-50);
}

.nav-dropdown {
    position: relative;
}

.dropdown-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    display: grid;
    min-width: 220px;
    padding: 10px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    box-shadow: var(--shadow-xl);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: 0.2s ease;
}

.nav-dropdown:hover .dropdown-panel,
.nav-dropdown:focus-within .dropdown-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-panel a {
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--gray-700);
}

.dropdown-panel a:hover {
    background: var(--primary-50);
    color: var(--primary-700);
}

.header-search {
    display: flex;
    align-items: center;
    width: min(280px, 24vw);
    background: var(--gray-100);
    border-radius: 999px;
    padding: 4px;
    border: 1px solid transparent;
}

.header-search:focus-within {
    border-color: var(--primary-600);
    background: var(--white);
}

.header-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    background: transparent;
    padding: 8px 12px;
}

.header-search button {
    border: 0;
    border-radius: 999px;
    background: var(--primary-600);
    color: var(--white);
    padding: 8px 14px;
    cursor: pointer;
}

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

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

.mobile-nav {
    display: none;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto 14px;
    padding: 10px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
}

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

.mobile-nav a {
    padding: 12px;
    text-align: center;
    border-radius: 12px;
    background: var(--gray-50);
}

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

.section {
    padding: 56px 0;
}

.section-white {
    background: var(--white);
}

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

.section-title {
    margin: 0;
    font-size: clamp(24px, 4vw, 34px);
    line-height: 1.2;
    letter-spacing: -0.03em;
}

.section-subtitle {
    max-width: 680px;
    margin: 8px 0 0;
    color: var(--gray-600);
}

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

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

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1s ease;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgb(0 0 0 / 0.82), rgb(0 0 0 / 0.52), rgb(0 0 0 / 0.08));
}

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

.hero-content .container {
    display: grid;
    gap: 26px;
}

.hero-copy {
    max-width: 680px;
    animation: fadeIn 0.6s ease both;
}

.kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--white);
    background: rgb(2 132 199 / 0.9);
    border-radius: 999px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 700;
    backdrop-filter: blur(4px);
}

.hero h1 {
    max-width: 900px;
    margin: 18px 0 16px;
    color: var(--white);
    font-size: clamp(38px, 6vw, 72px);
    line-height: 1.06;
    letter-spacing: -0.05em;
}

.hero p {
    max-width: 660px;
    margin: 0 0 24px;
    color: rgb(229 231 235 / 0.96);
    font-size: clamp(17px, 2vw, 22px);
}

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

.hero-meta span,
.hero-meta a {
    color: var(--white);
    background: rgb(255 255 255 / 0.18);
    border: 1px solid rgb(255 255 255 / 0.18);
    border-radius: 12px;
    padding: 9px 14px;
    backdrop-filter: blur(6px);
}

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

.button-primary {
    color: var(--white);
    background: var(--primary-600);
    box-shadow: var(--shadow-lg);
}

.button-primary:hover {
    transform: translateY(-2px) scale(1.02);
    background: var(--primary-700);
    box-shadow: var(--shadow-xl);
}

.button-secondary {
    color: var(--gray-900);
    background: var(--white);
    border: 1px solid var(--gray-200);
}

.button-secondary:hover {
    color: var(--primary-700);
    border-color: var(--primary-100);
    background: var(--primary-50);
}

.hero-control {
    position: absolute;
    top: 50%;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 999px;
    color: var(--white);
    background: rgb(255 255 255 / 0.22);
    cursor: pointer;
    transform: translateY(-50%);
    backdrop-filter: blur(6px);
    transition: background 0.2s ease;
}

.hero-control:hover {
    background: rgb(255 255 255 / 0.34);
}

.hero-prev {
    left: max(18px, calc((100vw - 1180px) / 2 - 68px));
}

.hero-next {
    right: max(18px, calc((100vw - 1180px) / 2 - 68px));
}

.hero-dots {
    position: absolute;
    left: 50%;
    bottom: 28px;
    display: flex;
    align-items: center;
    gap: 8px;
    transform: translateX(-50%);
}

.hero-dot {
    width: 10px;
    height: 10px;
    border: 0;
    border-radius: 99px;
    background: rgb(255 255 255 / 0.55);
    cursor: pointer;
    transition: 0.2s ease;
}

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

.grid {
    display: grid;
    gap: 24px;
}

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

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

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

.movie-card {
    min-width: 0;
}

.movie-card-large {
    padding: 0;
}

.poster-wrap {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--gray-200);
    border-radius: 18px;
    box-shadow: var(--shadow-sm);
}

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

.poster-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgb(0 0 0 / 0.52), transparent 55%);
    opacity: 0;
    transition: opacity 0.25s ease;
}

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

.movie-card:hover .poster-wrap::after,
.movie-card-large:hover .poster-wrap::after {
    opacity: 1;
}

.play-round {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    color: var(--primary-600);
    background: rgb(255 255 255 / 0.92);
    border-radius: 999px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.9);
    transition: 0.25s ease;
}

.movie-card:hover .play-round,
.movie-card-large:hover .play-round {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.year-chip {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 3;
    color: var(--white);
    background: rgb(0 0 0 / 0.76);
    border-radius: 9px;
    padding: 3px 9px;
    font-size: 12px;
}

.rank-badge {
    position: absolute;
    left: 10px;
    top: 10px;
    z-index: 4;
    display: grid;
    place-items: center;
    min-width: 34px;
    height: 34px;
    padding: 0 9px;
    color: var(--gray-900);
    background: var(--yellow-400);
    border-radius: 999px;
    font-weight: 900;
    box-shadow: var(--shadow-lg);
}

.card-body {
    padding: 14px 2px 0;
}

.card-title {
    display: -webkit-box;
    overflow: hidden;
    margin-bottom: 6px;
    color: var(--gray-900);
    font-weight: 800;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.movie-card-large .card-title {
    font-size: 20px;
}

.movie-card:hover .card-title,
.movie-card-large:hover .card-title,
.movie-row:hover .row-title {
    color: var(--primary-600);
}

.card-body p,
.row-info p {
    display: -webkit-box;
    overflow: hidden;
    margin: 0 0 10px;
    color: var(--gray-600);
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.card-meta,
.row-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--gray-500);
    font-size: 13px;
}

.card-meta a {
    color: var(--primary-700);
    background: var(--primary-50);
    border-radius: 999px;
    padding: 4px 10px;
    font-weight: 700;
}

.scroll-row {
    display: flex;
    gap: 18px;
    overflow-x: auto;
    padding: 2px 0 16px;
    scroll-snap-type: x proximity;
}

.scroll-row .movie-card {
    flex: 0 0 320px;
    scroll-snap-align: start;
}

.movie-list {
    display: grid;
    gap: 18px;
}

.movie-row {
    display: grid;
    grid-template-columns: 240px minmax(0, 1fr);
    gap: 18px;
    align-items: center;
    padding: 16px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 18px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

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

.row-cover {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--gray-200);
    border-radius: 14px;
}

.row-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.row-title {
    display: inline-block;
    margin-bottom: 8px;
    font-size: 20px;
    font-weight: 850;
    line-height: 1.3;
}

.inline-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 10px 0;
}

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

.category-band {
    padding: 56px 0;
    background: linear-gradient(135deg, var(--primary-50), var(--accent-50));
}

.category-card {
    display: grid;
    gap: 10px;
    min-height: 160px;
    padding: 24px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    transition: 0.2s ease;
}

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

.category-card strong {
    font-size: 20px;
}

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

.category-card span {
    color: var(--primary-700);
    font-weight: 800;
}

.page-hero {
    padding: 70px 0 42px;
    background: linear-gradient(135deg, var(--slate-900), var(--primary-700));
    color: var(--white);
}

.page-hero h1 {
    margin: 0 0 10px;
    font-size: clamp(34px, 5vw, 56px);
    line-height: 1.1;
    letter-spacing: -0.04em;
}

.page-hero p {
    max-width: 760px;
    margin: 0;
    color: rgb(255 255 255 / 0.82);
    font-size: 18px;
}

.filter-bar {
    display: grid;
    grid-template-columns: 1.5fr repeat(3, minmax(140px, 0.5fr));
    gap: 12px;
    padding: 16px;
    margin: -28px auto 30px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
}

.filter-bar input,
.filter-bar select,
.search-box input {
    width: 100%;
    min-height: 44px;
    border: 1px solid var(--gray-200);
    border-radius: 12px;
    outline: 0;
    padding: 0 14px;
    background: var(--gray-50);
}

.filter-bar input:focus,
.filter-bar select:focus,
.search-box input:focus {
    border-color: var(--primary-600);
    background: var(--white);
}

.no-results {
    display: none;
    padding: 28px;
    text-align: center;
    color: var(--gray-600);
    background: var(--white);
    border: 1px dashed var(--gray-200);
    border-radius: 18px;
}

.no-results.show {
    display: block;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    color: rgb(255 255 255 / 0.78);
    font-size: 14px;
}

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

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

.player-card,
.detail-card,
.sidebar-card {
    background: var(--white);
    border: 1px solid var(--gray-200);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
}

.player-card {
    overflow: hidden;
}

.player-box {
    position: relative;
    aspect-ratio: 16 / 9;
    background: var(--gray-900);
}

.player-box video,
.player-poster {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.player-box video {
    object-fit: contain;
    background: #000000;
}

.player-poster {
    z-index: 3;
    border: 0;
    padding: 0;
    cursor: pointer;
    background: transparent;
}

.player-poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.56);
}

.player-poster span {
    position: absolute;
    left: 50%;
    top: 50%;
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    color: var(--primary-600);
    background: rgb(255 255 255 / 0.94);
    border-radius: 999px;
    transform: translate(-50%, -50%);
    font-size: 26px;
    box-shadow: var(--shadow-xl);
}

.player-poster.hidden {
    display: none;
}

.player-info {
    padding: 22px;
}

.player-info h2 {
    margin: 0 0 8px;
    font-size: 24px;
}

.player-info p {
    margin: 0;
    color: var(--gray-600);
}

.detail-card {
    padding: 26px;
    margin-top: 24px;
}

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

.detail-card p {
    margin: 0 0 18px;
    color: var(--gray-700);
    font-size: 17px;
}

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

.meta-table div {
    padding: 12px 14px;
    background: var(--gray-50);
    border-radius: 12px;
}

.meta-table span {
    display: block;
    color: var(--gray-500);
    font-size: 12px;
}

.meta-table strong {
    display: block;
    margin-top: 2px;
}

.sidebar-card {
    padding: 18px;
}

.sidebar-card .movie-row {
    grid-template-columns: 112px minmax(0, 1fr);
    gap: 12px;
    padding: 0;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    background: transparent;
}

.sidebar-card .movie-row + .movie-row {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--gray-200);
}

.sidebar-card .row-title {
    margin-bottom: 4px;
    font-size: 15px;
}

.sidebar-card .row-info p,
.sidebar-card .inline-tags {
    display: none;
}

.search-box {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
    max-width: 740px;
    margin-top: 24px;
}

.search-box button {
    min-height: 48px;
    border: 0;
    border-radius: 12px;
    padding: 0 24px;
    color: var(--white);
    background: var(--primary-600);
    font-weight: 800;
    cursor: pointer;
}

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

.site-footer {
    margin-top: 44px;
    color: rgb(255 255 255 / 0.82);
    background: var(--slate-900);
}

.footer-inner {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 28px;
    width: min(1180px, calc(100% - 32px));
    margin: 0 auto;
    padding: 42px 0;
}

.footer-inner strong {
    display: block;
    margin-bottom: 8px;
    color: var(--white);
    font-size: 20px;
}

.footer-inner p {
    margin: 0;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: end;
    gap: 10px;
}

.footer-links a {
    padding: 8px 12px;
    border-radius: 999px;
    background: rgb(255 255 255 / 0.08);
}

.footer-links a:hover {
    background: rgb(255 255 255 / 0.15);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (min-width: 1200px) {
    .hero {
        height: 70vh;
    }
}

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

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

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

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

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

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

@media (max-width: 720px) {
    .header-inner {
        min-height: 66px;
    }

    .brand-text small {
        display: none;
    }

    .brand-text strong {
        font-size: 17px;
    }

    .hero {
        min-height: 520px;
        height: 68vh;
    }

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

    .hero-control {
        display: none;
    }

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

    .grid-4,
    .grid-3,
    .grid-2,
    .search-results {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }

    .scroll-row .movie-card {
        flex-basis: 260px;
    }

    .movie-row {
        grid-template-columns: 132px minmax(0, 1fr);
        gap: 12px;
        padding: 12px;
    }

    .row-title {
        font-size: 16px;
    }

    .row-info p {
        -webkit-line-clamp: 1;
    }

    .filter-bar {
        grid-template-columns: 1fr;
        margin-top: -22px;
    }

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

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

    .footer-links {
        justify-content: start;
    }
}

@media (max-width: 480px) {
    .grid-4,
    .grid-3,
    .grid-2,
    .search-results {
        grid-template-columns: 1fr;
    }

    .movie-row,
    .sidebar-card .movie-row {
        grid-template-columns: 116px minmax(0, 1fr);
    }

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