* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-orange: #f97316;
    --primary-orange-dark: #ea580c;
    --primary-orange-darker: #c2410c;
    --bg-light: #fff7ed;
    --bg-white: #ffffff;
    --bg-gray: #f3f4f6;
    --text-dark: #1f2937;
    --text-light: #6b7280;
    --text-white: #ffffff;
    --border-light: #fed7aa;
    --border-gray: #e5e7eb;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.dark {
    --bg-light: #111827;
    --bg-white: #1f2937;
    --bg-gray: #374151;
    --text-dark: #f9fafb;
    --text-light: #d1d5db;
    --border-light: #4b5563;
    --border-gray: #374151;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, var(--bg-light) 0%, var(--bg-white) 50%, var(--bg-light) 100%);
    min-height: 100vh;
    color: var(--text-dark);
    transition: all 0.3s ease;
}

body.dark {
    background: linear-gradient(135deg, #111827 0%, #1f2937 50%, #111827 100%);
}

/* 全局链接样式 */
a {
    color: inherit;
    text-decoration: none;
    outline: none;
    transition: all 0.2s ease;
}

/* 导航栏 */
nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-light);
    box-shadow: var(--shadow);
}

body.dark nav {
    background: rgba(31, 41, 55, 0.95);
    border-bottom-color: var(--border-gray);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo-icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon svg {
    width: 100%;
    height: 100%;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-size: 20px;
    font-weight: bold;
    color: var(--text-dark);
}

.logo-domain {
    font-size: 12px;
    color: var(--primary-orange);
    font-weight: 500;
    text-align: center;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-item {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
    position: relative;
    cursor: pointer;
    padding: 8px 0;
}

.nav-item:hover,
.nav-item.active {
    color: var(--primary-orange);
}

.nav-item.home {
    color: var(--primary-orange);
    font-weight: 600;
}

.nav-item .dropdown-arrow {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-left: 4px;
    transition: transform 0.2s;
}

.nav-item:hover .dropdown-arrow {
    transform: rotate(180deg);
}

/* 下拉菜单 */
.dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--bg-white);
    border-radius: 8px;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-light);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.2s;
    padding: 8px 0;
}

body.dark .dropdown {
    background: #1f2937;
    border-color: var(--border-gray);
}

.nav-item:hover .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 10px 16px;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
}

body.dark .dropdown-item {
    color: var(--text-light);
}

.dropdown-item:hover {
    background: var(--bg-light);
    color: var(--primary-orange);
}

body.dark .dropdown-item:hover {
    background: #374151;
    color: var(--primary-orange);
}

/* 主题切换按钮 */
.theme-toggle {
    padding: 8px;
    border-radius: 50%;
    background: var(--bg-gray);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    background: var(--bg-light);
}

body.dark .theme-toggle:hover {
    background: #374151;
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
    color: var(--text-dark);
}

/* 搜索标题区域 */
.search-header-section {
    text-align: center;
    padding: 40px 20px 20px;
    max-width: 900px;
    margin: 0 auto;
}

.search-title {
    font-size: 32px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 16px;
    letter-spacing: 1px;
}

body.dark .search-title {
    color: var(--text-dark);
}

.search-description {
    font-size: 16px;
    color: var(--text-light);
    line-height: 1.8;
    max-width: 700px;
    margin: 0 auto;
}

body.dark .search-description {
    color: var(--text-light);
}

.highlight-text {
    color: var(--primary-orange);
    font-weight: bold;
    font-size: 1.1em;
    display: inline-block;
    margin: 0 4px;
    position: relative;
}

.search-title .highlight-text {
    font-size: 1.2em;
}

/* 搜索框区域 */
.search-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 20px 16px;
}

.search-container {
    background: var(--bg-white);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    padding: 24px;
    border: 1px solid var(--border-light);
}

body.dark .search-container {
    background: #1f2937;
    border-color: var(--border-gray);
}

.search-box {
    display: flex;
    gap: 12px;
    align-items: stretch;
}

.search-type-select {
    padding: 12px 16px;
    border: 2px solid var(--border-gray);
    border-radius: 12px;
    background: var(--bg-gray);
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    outline: none;
    transition: all 0.2s;
    min-width: 120px;
}

body.dark .search-type-select {
    background: #374151;
    border-color: #4b5563;
    color: var(--text-light);
}

.search-type-select:focus {
    border-color: var(--primary-orange);
}

.search-type-select option {
    background: var(--bg-white);
    color: var(--text-dark);
}

body.dark .search-type-select option {
    background: #1f2937;
    color: var(--text-light);
}

.search-input-wrapper {
    flex: 1;
    position: relative;
    min-width: 0; /* 防止flex子项溢出 */
}

.search-input {
    width: 100%;
    padding: 14px 60px 14px 20px;
    border: 2px solid var(--border-gray);
    border-radius: 12px;
    background: var(--bg-gray);
    color: var(--text-dark);
    font-size: 15px;
    outline: none;
    transition: all 0.2s;
    height: 48px;
    box-sizing: border-box;
}

body.dark .search-input {
    background: #374151;
    border-color: #4b5563;
    color: var(--text-light);
}

.search-input:focus {
    border-color: var(--primary-orange);
    background: var(--bg-white);
}

body.dark .search-input:focus {
    background: #1f2937;
}

.search-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    padding: 10px 12px;
    background: var(--primary-orange);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 36px;
}

.search-btn:hover {
    background: var(--primary-orange-dark);
    transform: translateY(-50%) scale(1.05);
}

.search-btn svg {
    width: 20px;
    height: 20px;
    color: white;
}

/* 热门搜索词区域 */
.hot-search-section {
    margin-top: 24px;
    text-align: center;
    padding: 0 20px;
}

.hot-search-tags {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    justify-content: center;
}

.hot-search-label {
    font-size: 14px;
    color: var(--text-light);
    font-weight: 500;
    margin-right: 8px;
    flex-shrink: 0;
}

body.dark .hot-search-label {
    color: var(--text-light);
}

.hot-search-tag {
    padding: 8px 16px;
    background: var(--bg-gray);
    color: var(--text-dark);
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s;
    border: 1px solid transparent;
    cursor: pointer;
    white-space: nowrap;
}

body.dark .hot-search-tag {
    background: #374151;
    color: var(--text-light);
    border-color: #4b5563;
}

.hot-search-tag:hover {
    background: var(--bg-light);
    color: var(--primary-orange);
    border-color: var(--primary-orange);
    transform: translateY(-2px);
}

body.dark .hot-search-tag:hover {
    background: #4b5563;
    border-color: var(--primary-orange);
}

/* 热门标签包装器 */
.hot-tags-wrapper {
    padding: 12px 0;
}

/* 热门标签区域 */
.hot-tags-section {
    padding: 20px;
    background: var(--bg-white);
    border-radius: 12px;
    border: 1px solid var(--border-light);
    margin: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

body.dark .hot-tags-section {
    background: #1f2937;
    border-color: #374151;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.hot-tags-header {
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-light);
}

body.dark .hot-tags-header {
    border-bottom-color: #374151;
}

.hot-tags-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0;
}

body.dark .hot-tags-title {
    color: var(--text-light);
}

.hot-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.hot-tag {
    padding: 8px 18px;
    background: linear-gradient(135deg, var(--primary-orange), #ff8c00);
    color: white;
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(255, 107, 0, 0.2);
    white-space: nowrap;
}

.hot-tag:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 0, 0.3);
}

/* 内容区域 */
.content-section {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 20px;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 24px;
}

@media (min-width: 768px) {
    .grid-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* 卡片样式 */
.card {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid var(--border-light);
}

body.dark .card {
    background: #1f2937;
    border-color: var(--border-gray);
}

.card-header {
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.card-header h2 {
    font-size: 18px;
    font-weight: bold;
    color: white;
    margin: 0;
}

.card-header svg {
    width: 20px;
    height: 20px;
    fill: white;
}

.card-header.gradient-1 {
    background: linear-gradient(90deg, var(--primary-orange), var(--primary-orange-dark));
}

.card-header.gradient-2 {
    background: linear-gradient(90deg, var(--primary-orange-dark), var(--primary-orange-darker));
}

.card-header.gradient-3 {
    background: linear-gradient(90deg, var(--primary-orange-darker), #9a3412);
}

.card-header.music-gradient-1 {
    background: linear-gradient(90deg, #fb923c, var(--primary-orange));
}

.card-header.music-gradient-2 {
    background: linear-gradient(90deg, var(--primary-orange), var(--primary-orange-dark));
}

.card-header.music-gradient-3 {
    background: linear-gradient(90deg, var(--primary-orange-dark), var(--primary-orange-darker));
}

.card-content {
    padding: 16px;
}

.list-item {
    display: block;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
    margin-bottom: 8px;
}

.list-item:hover {
    background: var(--bg-light);
}

body.dark .list-item:hover {
    background: #374151;
}

.list-item:last-child {
    margin-bottom: 0;
}

.list-item-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.list-item-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.item-number {
    width: 24px;
    color: var(--primary-orange);
    font-weight: bold;
    font-size: 16px;
}

.item-name {
    color: var(--text-dark);
    font-weight: 500;
    transition: color 0.2s;
}

body.dark .item-name {
    color: var(--text-light);
}

.list-item:hover .item-name {
    color: var(--primary-orange);
}

.item-format {
    font-size: 12px;
    padding: 4px 8px;
    background: var(--bg-light);
    color: var(--primary-orange);
    border-radius: 9999px;
    font-family: monospace;
}

body.dark .item-format {
    background: #4b5563;
}

/* 页脚 */
footer {
    margin-top: 0;
    background: var(--bg-white);
    border-top: none;
    padding: 0 20px 32px;
}

body.dark footer {
    background: #1f2937;
    border-top-color: var(--border-gray);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

/* 友情链接区域 - 与页脚融为一体 */
.friend-links-section {
    margin-top: 48px;
    padding: 32px 20px 24px;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
}

body.dark .friend-links-section {
    background: #1f2937;
    border-top-color: var(--border-gray);
}

/* 友情链接区域 */
.friend-links-area {
    display: flex;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
}

.friend-links-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 0;
    white-space: nowrap;
}

body.dark .friend-links-title {
    color: var(--text-dark);
}

.friend-link-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    flex: 1;
}

/* 版权信息区域 */
.copyright-area {
    padding-top: 24px;
    border-top: 1px dashed var(--border-gray);
    text-align: center;
}

body.dark .copyright-area {
    border-top-color: #4b5563;
}

.copyright-area {
    display: flex;
    flex-direction: column;
    gap: 16px;
    justify-content: center;
    align-items: center;
}

.copyright-text {
    text-align: center;
    color: var(--text-light);
    font-size: 13px;
}

.copyright-text p {
    margin: 2px 0;
}

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

.friend-link {
    padding: 6px 14px;
    background: var(--bg-gray);
    color: var(--text-light);
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
}

body.dark .friend-link {
    background: #374151;
    color: var(--text-light);
}

.friend-link:hover {
    background: var(--bg-light);
    color: var(--primary-orange);
}

body.dark .friend-link:hover {
    background: #4b5563;
    color: var(--primary-orange);
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-content: center;
}

@media (min-width: 768px) {
    .footer-logo {
        justify-content: flex-end;
    }
}

.footer-logo .logo-icon {
    width: 32px;
    height: 32px;
}

.footer-logo .logo-name {
    font-size: 16px;
}

/* 移动端菜单按钮 - PC端隐藏 */
.mobile-menu-btn {
    display: none;
}

/* 响应式导航 */
@media (max-width: 1024px) {
    .nav-menu {
        display: none;
    }

    /* 移动端菜单按钮 */
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border: none;
        background: var(--bg-gray);
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.2s;
        color: var(--text-dark);
    }

    .mobile-menu-btn:hover {
        background: var(--primary-orange);
        color: white;
    }

    .mobile-menu-btn svg {
        width: 20px;
        height: 20px;
    }

    /* 移动端导航菜单 */
    .nav-menu {
        position: fixed;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--bg-white);
        border-bottom: 1px solid var(--border-gray);
        box-shadow: var(--shadow-lg);
        padding: 20px;
        display: flex;
        flex-direction: column;
        gap: 16px;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 49;
    }

    body.dark .nav-menu {
        background: #1f2937;
        border-bottom-color: #374151;
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-item {
        padding: 12px 16px;
        background: var(--bg-gray);
        border-radius: 8px;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
    }

    body.dark .nav-item {
        background: #374151;
    }

    .nav-item .dropdown-arrow {
        margin-left: auto;
    }

    /* 移动端下拉菜单 */
    .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: var(--shadow);
        border: 1px solid var(--border-gray);
        min-width: 100%;
        margin-top: 8px;
        padding: 12px 0;
        display: none;
        background: var(--bg-white);
        border-radius: 8px;
    }

    body.dark .dropdown {
        background: #2d3748;
        border-color: #4a5568;
    }

    .nav-item:hover .dropdown {
        display: none;
    }

    .nav-item.active .dropdown {
        display: block;
    }

    /* 移动端下拉菜单项 */
    .dropdown-item {
        padding: 14px 20px;
        font-size: 15px;
        border-bottom: 1px solid var(--border-light);
        transition: all 0.2s;
    }

    body.dark .dropdown-item {
        border-bottom-color: #4a5568;
    }

    .dropdown-item:last-child {
        border-bottom: none;
    }

    .dropdown-item:hover {
        background: var(--primary-orange);
        color: white;
        padding-left: 24px;
    }

    body.dark .dropdown-item:hover {
        background: var(--primary-orange);
        color: white;
    }
}

/* 月亮和太阳图标 */
.sun-icon {
    color: #fbbf24;
}

.moon-icon {
    color: #4b5563;
}

/* 隐藏的深色模式下显示的元素 */
.dark .moon-icon {
    display: none;
}

/* 隐藏的浅色模式下显示的元素 */
.sun-icon {
    display: none;
}

.dark .sun-icon {
    display: block;
}

/* 短剧列表页样式 */
.list-page-container {
    max-width: 1400px;
    margin: 16px auto 32px;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 24px;
    align-items: start;
}

@media (max-width: 1024px) {
    .list-page-container {
        grid-template-columns: 1fr;
    }
}

/* 左侧分类导航 */
.category-sidebar {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 0;
    border: 1px solid var(--border-light);
    position: relative;
}

body.dark .category-sidebar {
    background: #1f2937;
    border-color: var(--border-gray);
}

/* 分类容器 - 用于tags页面的独立sticky */
.category-container {
    padding: 20px;
    border-bottom: 1px solid var(--border-light);
}

body.dark .category-container {
    border-bottom-color: var(--border-gray);
}

.category-container:last-child {
    border-bottom: none;
}

/* 短剧分类容器 - 第一个sticky */
.drama-categories {
    position: sticky;
    top: 80px;
    z-index: 1;
    background: var(--bg-white);
}

body.dark .drama-categories {
    background: #1f2937;
}

/* 音乐格式容器 - 第二个sticky，z-index更高以覆盖短剧分类 */
.music-categories {
    position: sticky;
    top: 80px;
    z-index: 2;
    background: var(--bg-white);
}

body.dark .music-categories {
    background: #1f2937;
}

/* 移动端折叠按钮 */
.mobile-category-toggle {
    display: none;
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, var(--primary-orange), var(--primary-orange-dark));
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    margin-bottom: 16px;
    transition: all 0.3s;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.mobile-category-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 20px -3px rgba(249, 115, 22, 0.3);
}

.mobile-category-toggle .toggle-arrow {
    width: 20px;
    height: 20px;
    transition: transform 0.3s;
}

.mobile-category-toggle.active .toggle-arrow {
    transform: rotate(180deg);
}

/* 移动端侧边栏覆盖层 */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

/* 移动端分类导航 */
@media (max-width: 1024px) {
    .mobile-category-toggle {
        display: flex;
    }

    .category-sidebar {
        position: fixed;
        top: 64px;
        left: 0;
        width: 280px;
        height: calc(100vh - 64px);
        z-index: 1000;
        border-radius: 0 12px 12px 0;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        overflow-y: auto;
    }

    .category-sidebar::-webkit-scrollbar {
        width: 6px;
    }

    .category-sidebar::-webkit-scrollbar-track {
        background: transparent;
    }

    .category-sidebar::-webkit-scrollbar-thumb {
        background: #d1d5db;
        border-radius: 3px;
    }

    body.dark .category-sidebar::-webkit-scrollbar-thumb {
        background: #4b5563;
    }

    .category-sidebar::-webkit-scrollbar-thumb:hover {
        background: #9ca3af;
    }

    .category-sidebar.open {
        transform: translateX(0);
    }

    .sidebar-overlay.show {
        display: block;
    }
}

.sidebar-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-orange);
}

body.dark .sidebar-title {
    color: var(--text-dark);
}

.category-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.category-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-dark);
    transition: all 0.2s;
}

body.dark .category-item {
    color: var(--text-light);
}

.category-item:hover {
    background: var(--bg-light);
    color: var(--primary-orange);
}

body.dark .category-item:hover {
    background: #374151;
}

.category-item.active {
    background: linear-gradient(135deg, var(--primary-orange), var(--primary-orange-dark));
    color: white;
}

.category-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.category-name {
    font-size: 15px;
    font-weight: 500;
}

/* 右侧主内容区 */
.list-main-content {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 24px;
    border: 1px solid var(--border-light);
}

body.dark .list-main-content {
    background: #1f2937;
    border-color: var(--border-gray);
}

/* 排序按钮 */
.sort-buttons {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.sort-btn {
    padding: 10px 24px;
    border: 2px solid var(--border-gray);
    background: var(--bg-gray);
    color: var(--text-dark);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

body.dark .sort-btn {
    background: #374151;
    border-color: #4b5563;
    color: var(--text-light);
}

.sort-btn:hover {
    border-color: var(--primary-orange);
    color: var(--primary-orange);
}

body.dark .sort-btn:hover {
    border-color: var(--primary-orange);
    color: var(--primary-orange);
}

.sort-btn.active {
    background: var(--primary-orange);
    border-color: var(--primary-orange);
    color: white;
}

/* 短剧列表 */
.drama-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.drama-list-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--bg-gray);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
    border: 1px solid transparent;
}

body.dark .drama-list-item {
    background: #374151;
}

.drama-list-item:hover {
    background: var(--bg-light);
    border-color: var(--primary-orange);
    transform: translateX(8px);
}

body.dark .drama-list-item:hover {
    background: #4b5563;
}

.drama-name {
    color: var(--text-dark);
    font-size: 16px;
    font-weight: 500;
    flex: 1;
}

body.dark .drama-name {
    color: var(--text-light);
}

.drama-list-item:hover .drama-name {
    color: var(--primary-orange);
}

.drama-date {
    color: var(--text-light);
    font-size: 14px;
    margin-left: 16px;
}

body.dark .drama-date {
    color: var(--text-light);
}
/* 短剧详情页样式 */
.detail-page-container {
    max-width: 1400px;
    margin: 32px auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 24px;
    align-items: start;
}

@media (max-width: 1024px) {
    .detail-page-container {
        grid-template-columns: 1fr;
    }
}

/* 左侧内容区 */
.detail-left {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* 短剧基本信息卡片 */
.drama-info-card {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 32px;
    border: 1px solid var(--border-light);
}

body.dark .drama-info-card {
    background: #1f2937;
    border-color: var(--border-gray);
}

.drama-title {
    font-size: 28px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 20px;
    line-height: 1.4;
}

body.dark .drama-title {
    color: var(--text-dark);
}

/* 元信息 */
.drama-meta {
    display: flex;
    gap: 32px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.meta-label {
    color: var(--text-light);
    font-size: 14px;
}

.meta-value {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 15px;
}

body.dark .meta-value {
    color: var(--text-light);
}

/* 标签 */
.drama-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
}

.tag {
    display: inline-block;
    padding: 6px 16px;
    background: var(--bg-light);
    color: var(--primary-orange);
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

body.dark .tag {
    background: #374151;
}

.tag:hover {
    background: var(--primary-orange);
    color: white;
    transform: translateY(-2px);
}

/* 剧情简介 */
.drama-description {
    margin-bottom: 28px;
}

.drama-description h3 {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 12px;
}

body.dark .drama-description h3 {
    color: var(--text-dark);
}

.drama-description p {
    color: var(--text-light);
    line-height: 1.8;
    font-size: 15px;
}

body.dark .drama-description p {
    color: var(--text-light);
}

/* 下载区域 */
.download-section {
    margin-bottom: 24px;
}

.download-section h3 {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 16px;
}

body.dark .download-section h3 {
    color: var(--text-dark);
}

.download-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.download-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    color: white;
}

.download-btn svg {
    width: 20px;
    height: 20px;
}

.quark-btn {
    background: linear-gradient(135deg, #ffb020, #f59e0b);
}

.quark-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -3px rgba(251, 176, 32, 0.4);
}

.baidu-btn {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

.baidu-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px -3px rgba(59, 130, 246, 0.4);
}

/* 注意事项提示框 */
.notice-box {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-radius: 8px;
    padding: 20px;
    border-left: 4px solid #f59e0b;
}

body.dark .notice-box {
    background: linear-gradient(135deg, #4b5563, #374151);
}

.notice-box h4 {
    font-size: 16px;
    font-weight: bold;
    color: #92400e;
    margin-bottom: 12px;
}

body.dark .notice-box h4 {
    color: #fbbf24;
}

.notice-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.notice-box li {
    color: #78350f;
    font-size: 14px;
    line-height: 2;
    padding-left: 0;
}

body.dark .notice-box li {
    color: #d1d5db;
}

/* 相关短剧区域 */
.related-dramas-section {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 24px;
    border: 1px solid var(--border-light);
}

body.dark .related-dramas-section {
    background: #1f2937;
    border-color: var(--border-gray);
}

.section-title {
    font-size: 20px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 20px;
}

body.dark .section-title {
    color: var(--text-dark);
}

.related-dramas-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.related-drama-item {
    display: block;
    padding: 12px 16px;
    background: var(--bg-gray);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    line-height: 1.5;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.dark .related-drama-item {
    background: #374151;
    color: var(--text-light);
}

.related-drama-item:hover {
    background: var(--primary-orange);
    color: white;
    transform: translateX(4px);
}

/* 右侧侧边栏 */
.detail-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sidebar-section {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    padding: 24px;
    border: 1px solid var(--border-light);
}

body.dark .sidebar-section {
    background: #1f2937;
    border-color: var(--border-gray);
}

.sidebar-title {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-dark);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-orange);
    display: flex;
    align-items: center;
    gap: 8px;
}

body.dark .sidebar-title {
    color: var(--text-dark);
}

.title-icon {
    font-size: 20px;
}

.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-item {
    margin-bottom: 12px;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
}

.sidebar-link:hover {
    background: var(--bg-light);
}

body.dark .sidebar-link:hover {
    background: #374151;
}

.item-rank {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-gray);
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    color: var(--text-light);
    flex-shrink: 0;
}

body.dark .item-rank {
    background: #374151;
    color: var(--text-light);
}

.item-rank.rank-1 {
    background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
    color: white;
}

.item-rank.rank-2 {
    background: linear-gradient(135deg, #ffa94d, #ff922b);
    color: white;
}

.item-rank.rank-3 {
    background: linear-gradient(135deg, #ffd43b, #fab005);
    color: white;
}

.item-name {
    flex: 1;
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

body.dark .item-name {
    color: var(--text-light);
}

.sidebar-link:hover .item-name {
    color: var(--primary-orange);
}

/* 二维码弹窗 */
.qrcode-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.qrcode-modal.show {
    display: flex;
}

.qrcode-content {
    background: var(--bg-white);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    max-width: 400px;
    width: 100%;
    overflow: hidden;
}

body.dark .qrcode-content {
    background: #1f2937;
}

.qrcode-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-gray);
}

body.dark .qrcode-header {
    border-bottom-color: #374151;
}

.qrcode-header h3 {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-dark);
    margin: 0;
}

body.dark .qrcode-header h3 {
    color: var(--text-dark);
}

.close-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--bg-gray);
    border-radius: 6px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    color: var(--text-light);
}

body.dark .close-btn {
    background: #374151;
    color: var(--text-light);
}

.close-btn:hover {
    background: var(--primary-orange);
    color: white;
}

.qrcode-body {
    padding: 32px 24px;
    text-align: center;
}

.qrcode-image {
    width: 200px;
    height: 200px;
    margin: 0 auto 16px;
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--text-light);
}

.qrcode-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.qrcode-tip {
    color: var(--text-light);
    font-size: 14px;
    margin: 0;
}

body.dark .qrcode-tip {
    color: var(--text-light);
}

.qrcode-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-gray);
}

body.dark .qrcode-footer {
    border-top-color: #374151;
}

.qrcode-link {
    display: block;
    text-align: center;
    padding: 10px 16px;
    background: var(--primary-orange);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.qrcode-link:hover {
    background: var(--primary-orange-dark);
}

@media (max-width: 768px) {
    .drama-title {
        font-size: 22px;
    }

    .drama-info-card {
        padding: 20px;
    }

    .download-buttons {
        grid-template-columns: 1fr;
    }

    .related-dramas-grid {
        grid-template-columns: 1fr;
    }
}

/* 分页样式 */
.pagination-section {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border-light);
}

body.dark .pagination-section {
    border-top-color: var(--border-gray);
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.page-item {
    display: inline-block;
}

.page-link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 16px;
    background: var(--bg-white);
    border: 1px solid var(--border-gray);
    border-radius: 8px;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    white-space: nowrap;
}

body.dark .page-link {
    background: #1f2937;
    border-color: #374151;
    color: var(--text-light);
}

.page-link:hover {
    background: var(--primary-orange);
    border-color: var(--primary-orange);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px -3px rgba(249, 115, 22, 0.3);
}

.page-link.active {
    background: var(--primary-orange);
    border-color: var(--primary-orange);
    color: white;
    cursor: default;
}

.page-ellipsis {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 8px;
    color: var(--text-light);
    font-size: 14px;
    user-select: none;
}

body.dark .page-ellipsis {
    color: var(--text-light);
}

@media (max-width: 768px) {
    .pagination {
        gap: 6px;
    }

    .page-link {
        min-width: 36px;
        height: 36px;
        padding: 0 12px;
        font-size: 13px;
    }

    .page-ellipsis {
        min-width: 36px;
        height: 36px;
        font-size: 13px;
    }

    /* 移动端隐藏数字页码和省略号，只保留首页、上一页、当前页、下一页、尾页 */
    .page-item:not(:first-child):not(:nth-child(2)):not(.active):not(:nth-last-child(2)):not(:last-child):not(.page-ellipsis) {
        display: none;
    }

    .page-ellipsis {
        display: none;
    }
}
