/* 002模板 - 现代移动端UI样式 */

/* 重置样式和基础设置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
    padding-top: 120px; /* 为固定header预留空间 */
    padding-bottom: 70px; /* 为底部导航预留空间 */
}

.mobile-layout {
    max-width: 100vw;
    overflow-x: hidden;
}

/* 顶部导航栏 */
.mobile-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #ff6b6b, #4ecdc4);
    z-index: 1000;
    padding: env(safe-area-inset-top) 0 0 0;
}

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

.header-left .logo {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 18px;
}

.logo-text {
    background: linear-gradient(45deg, #fff, #f0f0f0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-center {
    flex: 1;
}

.search-container {
    position: relative;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 20px;
    padding: 8px 16px;
    backdrop-filter: blur(10px);
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
}

.search-input {
    width: 100%;
    background: none;
    border: none;
    outline: none;
    color: white;
    font-size: 14px;
    padding-left: 24px;
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.header-right .user-icon {
    color: white;
    font-size: 18px;
    padding: 8px;
    text-decoration: none;
}

/* 分类导航 */
.category-nav {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background: white;
    border-bottom: 1px solid #e9ecef;
    z-index: 999;
    padding: env(safe-area-inset-top) 0 0 0;
}

.category-scroll {
    display: flex;
    overflow-x: auto;
    padding: 12px 16px;
    gap: 20px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.category-scroll::-webkit-scrollbar {
    display: none;
}

.category-item {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(0, 0, 0, 0.1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.category-item.active {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
    border: 1px solid rgba(255, 107, 107, 0.2);
    transform: translateY(-1px);
}

.category-item:hover {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #ff6b6b;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.category-item.active:hover {
    background: linear-gradient(135deg, #e55555 0%, #d63031 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 107, 0.4);
}

/* 主要内容区域 */
.main-container {
    padding: 0 8px;
    min-height: calc(100vh - 190px);
}

/* 热门推荐Banner */
.hero-banner {
    margin: 12px 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(255, 107, 107, 0.3);
}

.banner-content {
    padding: 40px 20px;
    text-align: center;
    position: relative;
    min-height: 180px;
    max-height: 220px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
    border-radius: 12px;
}

.banner-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    z-index: 1;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
}

.banner-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(255,107,107,0.4), rgba(78,84,200,0.3));
}

.banner-info {
    position: relative;
    z-index: 3;
}

.banner-title {
    color: white;
    font-size: 24px;
    font-weight: bold;
    margin-bottom: 8px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 16px;
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.banner-subtitle {
    color: rgba(255, 255, 255, 0.95);
    font-size: 14px;
    margin-bottom: 20px;
    text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
    background: rgba(0, 0, 0, 0.2);
    padding: 4px 12px;
    border-radius: 8px;
    backdrop-filter: blur(5px);
    display: inline-block;
}

.banner-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.25);
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    transition: all 0.3s ease;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.banner-btn:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

/* 视频区域 */
.video-section {
    margin: 16px 0;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.section-title {
    font-size: 18px;
    font-weight: bold;
    color: #333;
}

.more-link {
    color: #ff6b6b;
    text-decoration: none;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.more-link:hover {
    color: #e55555;
}

/* 视频网格 - 统一2列布局 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px;
}

/* 分类页面网格 - 强制2列 */
.category-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px;
}

/* 搜索结果网格 - 2列 */
.search-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px;
}

/* 全局强制所有视频网格为2列 */
.video-grid,
.video-grid.category-grid,
.video-grid.search-grid {
    grid-template-columns: repeat(2, 1fr) !important;
}

.video-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.video-thumbnail {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.video-thumbnail img,
.lazy-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
    transform: scale(1.05);
}

.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(0, 0, 0, 0.7);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-card:hover .play-overlay {
    opacity: 1;
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.video-info {
    padding: 8px;
}

.video-title {
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-title a {
    color: #333;
    text-decoration: none;
}

.video-title a:hover {
    color: #ff6b6b;
}

.video-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 12px;
    color: #666;
}

.video-views,
.video-time {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 分页 */
.pagination-wrapper {
    margin: 20px 0;
    display: flex;
    justify-content: center;
    padding: 0 10px;
}

.pagination {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 5px;
    border-radius: 25px;
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.3);
    overflow: hidden;
}

.pagination a,
.pagination span {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 12px;
    color: white;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    border-radius: 20px;
    position: relative;
    background: transparent;
}

.pagination a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

/* 当前页样式 */
.pagination .current,
.pagination span.current {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
    transform: scale(1.1);
}

/* 首页和尾页样式 */
.pagination a:first-child,
.pagination a:last-child {
    font-size: 12px;
    padding: 0 10px;
}

/* 省略号样式 */
.pagination .dots {
    color: rgba(255, 255, 255, 0.7);
    cursor: default;
}

.pagination .dots:hover {
    background: transparent;
    transform: none;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .pagination {
        gap: 1px;
        padding: 3px;
    }
    
    .pagination a,
    .pagination span {
        min-width: 35px;
        height: 35px;
        font-size: 13px;
        padding: 0 8px;
    }
    
    .pagination .current {
        transform: scale(1.05);
    }
}

/* 底部导航栏 */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid #e9ecef;
    padding: 8px 0 calc(8px + env(safe-area-inset-bottom));
    display: flex;
    justify-content: space-around;
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #666;
    font-size: 12px;
    padding: 4px 8px;
    transition: color 0.3s ease;
}

.nav-item.active {
    color: #ff6b6b;
}

.nav-item i {
    font-size: 18px;
    margin-bottom: 4px;
}

.nav-item span {
    font-size: 10px;
}

/* 分类弹出菜单 */
.category-popup {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.category-popup.show {
    opacity: 1;
    visibility: visible;
}

.popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.popup-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-radius: 16px 16px 0 0;
    padding: 20px 16px calc(20px + env(safe-area-inset-bottom));
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.category-popup.show .popup-content {
    transform: translateY(0);
}

.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.popup-header h3 {
    font-size: 18px;
    font-weight: bold;
}

.close-btn {
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.category-grid-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    padding: 16px;
    border-radius: 12px;
    background: #f8f9fa;
    transition: all 0.3s ease;
}

.category-grid-item:hover {
    background: #ff6b6b;
    color: white;
}

.category-icon {
    font-size: 24px;
    margin-bottom: 8px;
    color: #ff6b6b;
}

.category-grid-item:hover .category-icon {
    color: white;
}

/* 分类页面样式 */
.category-header {
    background: white;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 120px;
    z-index: 998;
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
}

.back-btn,
.more-btn {
    background: none;
    border: none;
    font-size: 18px;
    color: #666;
    cursor: pointer;
    padding: 8px;
}

.page-title {
    font-size: 18px;
    font-weight: bold;
}

/* 筛选栏 */
.filter-bar {
    background: white;
    padding: 16px;
    border-bottom: 1px solid #e9ecef;
}

.filter-group {
    margin-bottom: 16px;
}

.filter-group:last-child {
    margin-bottom: 0;
}

.filter-label {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
}

.filter-options {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.filter-options::-webkit-scrollbar {
    display: none;
}

.filter-btn {
    background: #f8f9fa;
    border: none;
    padding: 8px 16px;
    border-radius: 16px;
    font-size: 12px;
    color: #666;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn.active {
    background: #ff6b6b;
    color: white;
}

.filter-btn:hover {
    background: #e9ecef;
}

.filter-btn.active:hover {
    background: #e55555;
}

/* 加载更多 */
.load-more-container {
    text-align: center;
    margin: 30px 0;
}

.load-more-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.load-more-btn:hover {
    background: #e55555;
    transform: translateY(-2px);
}

.load-more-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.no-more {
    color: #666;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* 播放页面样式 */
.play-page .main-container {
    padding: 0;
}

.play-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: white;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 120px;
    z-index: 998;
}

.play-title {
    font-size: 18px;
    font-weight: bold;
}

.share-btn {
    background: none;
    border: none;
    font-size: 18px;
    color: #666;
    cursor: pointer;
    padding: 8px;
}

/* 视频播放器 */
.video-player-container {
    background: #000;
    position: relative;
}

.video-player {
    width: 100%;
    aspect-ratio: 16/9;
    position: relative;
}

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

.video-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.8));
    padding: 20px 16px 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.video-player:hover .video-controls {
    opacity: 1;
}

.progress-container {
    margin-bottom: 12px;
}

.progress-bar {
    height: 4px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: #ff6b6b;
    width: 0%;
    transition: width 0.1s ease;
}

.control-buttons {
    display: flex;
    align-items: center;
    gap: 16px;
}

.control-buttons button {
    background: none;
    border: none;
    color: white;
    font-size: 16px;
    cursor: pointer;
}

.time-display {
    color: white;
    font-size: 12px;
    margin-left: auto;
}

/* 视频详情 */
.video-details {
    padding: 20px 16px;
    background: white;
    border-bottom: 1px solid #e9ecef;
}

.video-details .video-title {
    font-size: 18px;
    font-weight: bold;
    line-height: 1.4;
    margin-bottom: 12px;
    color: #333;
}

.video-stats {
    display: flex;
    gap: 16px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #666;
}

/* 互动按钮 */
.action-buttons {
    display: flex;
    justify-content: space-around;
    gap: 8px;
}

.action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: none;
    border: none;
    color: #666;
    font-size: 12px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    min-width: 60px;
}

.action-btn:hover {
    background: #f8f9fa;
    color: #ff6b6b;
}

.action-btn.active {
    color: #ff6b6b;
}

.action-btn i {
    font-size: 18px;
    margin-bottom: 4px;
}

.action-btn .count {
    font-size: 10px;
}

/* 作者信息 */
.author-info {
    display: flex;
    align-items: center;
    padding: 16px;
    background: white;
    border-bottom: 1px solid #e9ecef;
}

.author-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.author-details {
    flex: 1;
    margin-left: 12px;
}

.author-name {
    font-size: 16px;
    font-weight: 500;
    margin-bottom: 4px;
}

.author-followers {
    font-size: 12px;
    color: #666;
}

.follow-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.3s ease;
}

.follow-btn:hover {
    background: #e55555;
}

.follow-btn.following {
    background: #28a745;
}

/* 视频描述 */
.video-description {
    padding: 16px;
    background: white;
    border-bottom: 1px solid #e9ecef;
}

.description-text {
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 12px;
    max-height: 3em;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.expand-btn {
    background: none;
    border: none;
    color: #ff6b6b;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 评论区 */
.comments-section {
    background: white;
    margin-top: 8px;
    padding: 16px;
}

.comments-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.comments-header h3 {
    font-size: 16px;
    font-weight: bold;
}

.sort-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

.comment-input-area {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
}

.user-avatar img,
.comment-avatar img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
}

.input-wrapper {
    flex: 1;
    display: flex;
    gap: 8px;
}

.comment-input {
    flex: 1;
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 20px;
    padding: 8px 16px;
    font-size: 14px;
    outline: none;
}

.comment-input:focus {
    border-color: #ff6b6b;
}

.submit-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
}

.comment-item {
    display: flex;
    gap: 12px;
    margin-bottom: 16px;
}

.comment-content {
    flex: 1;
}

.comment-header {
    display: flex;
    gap: 12px;
    margin-bottom: 8px;
    font-size: 12px;
}

.username {
    font-weight: 500;
    color: #333;
}

.comment-time {
    color: #666;
}

.comment-text {
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 8px;
}

.comment-actions {
    display: flex;
    gap: 16px;
}

.comment-like,
.comment-reply {
    background: none;
    border: none;
    color: #666;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

.comment-like:hover,
.comment-reply:hover {
    color: #ff6b6b;
}

/* 相关视频推荐 */
.related-videos {
    background: white;
    margin-top: 8px;
    padding: 16px;
}

.related-videos .section-header {
    margin-bottom: 16px;
}

.related-videos .section-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.related-videos .video-grid {
    gap: 8px !important;
}

.related-videos .video-card {
    background: #f8f9fa;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.related-videos .video-card:hover {
    background: #e9ecef;
    transform: translateY(-2px);
}

.related-videos .video-thumbnail {
    height: 120px;
}

.related-videos .video-info {
    padding: 8px;
}

.related-videos .video-title {
    font-size: 13px;
    line-height: 1.3;
    margin-bottom: 6px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.related-videos .video-title a {
    color: #333;
    text-decoration: none;
}

.related-videos .video-title a:hover {
    color: #ff6b6b;
}

.related-videos .video-meta {
    font-size: 11px;
    color: #666;
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

/* 相关标签 */
.related-tags {
    background: white;
    margin-top: 8px;
    padding: 16px;
}

.related-tags .section-header {
    margin-bottom: 12px;
}

.related-tags .section-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-item {
    display: inline-block;
    padding: 6px 12px;
    background: #f8f9fa;
    color: #666;
    text-decoration: none;
    border-radius: 16px;
    font-size: 12px;
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
}

.tag-item:hover {
    background: #ff6b6b;
    color: white;
    transform: translateY(-1px);
    border-color: #ff6b6b;
}

/* 搜索页面样式 */
.search-header {
    background: white;
    border-bottom: 1px solid #e9ecef;
    position: sticky;
    top: 120px;
    z-index: 998;
}

.search-bar-container {
    padding: 16px;
}

.search-bar {
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-input-wrapper {
    flex: 1;
    position: relative;
    background: #f8f9fa;
    border-radius: 20px;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-input-wrapper i {
    color: #666;
    font-size: 14px;
}

.search-input-wrapper .search-input {
    flex: 1;
    background: none;
    border: none;
    outline: none;
    font-size: 14px;
    color: #333;
}

.clear-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 12px;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
}

.search-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
}

/* 搜索结果 */
.search-results {
    padding: 0;
}

.results-header {
    margin-bottom: 20px;
    padding: 0 8px;
}

.results-title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 4px;
}

.results-info {
    font-size: 12px;
    color: #666;
}

.no-results {
    text-align: center;
    padding: 60px 20px;
}

.no-results-icon {
    font-size: 48px;
    color: #ccc;
    margin-bottom: 16px;
}

.no-results h3 {
    font-size: 18px;
    margin-bottom: 8px;
}

.no-results p {
    color: #666;
    margin-bottom: 20px;
}

.retry-btn {
    background: #ff6b6b;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
}

/* 搜索建议 */
.search-suggestions {
    padding: 16px;
}

.suggestion-section {
    margin-bottom: 30px;
}

.suggestion-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.clear-history-btn {
    background: none;
    border: none;
    color: #666;
    font-size: 14px;
    cursor: pointer;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-item,
.recent-item {
    background: #f8f9fa;
    color: #666;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tag-item:hover,
.recent-item:hover {
    background: #ff6b6b;
    color: white;
}

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

.category-suggestion {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    text-decoration: none;
    color: #333;
    transition: all 0.3s ease;
}

.category-suggestion:hover {
    background: #ff6b6b;
    color: white;
}

.category-suggestion .category-icon {
    font-size: 20px;
    color: #ff6b6b;
}

.category-suggestion:hover .category-icon {
    color: white;
}

/* 无限内页样式 */
.featured-content {
    margin: 20px 0;
}

.featured-video {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.featured-video .video-thumbnail {
    aspect-ratio: 16/9;
}

.featured-video .video-info {
    padding: 16px;
}

.featured-video .video-title {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 8px;
}

.content-description,
.related-content,
.category-recommendations,
.hot-keywords,
.content-notice {
    margin: 30px 0;
    background: white;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.content-description h3,
.related-content h3,
.category-recommendations h3,
.hot-keywords h3,
.content-notice h3 {
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 12px;
}

.tag-cloud {
    margin-top: 20px;
}

.tag-cloud h4 {
    font-size: 14px;
    margin-bottom: 8px;
    color: #666;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    background: #f8f9fa;
    color: #666;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.tag:hover {
    background: #ff6b6b;
    color: white;
}

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

.category-recommendations .category-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #333;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.category-recommendations .category-item:hover {
    background: #ff6b6b;
    color: white;
}

.category-name {
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 4px;
}

.category-count {
    font-size: 11px;
    color: #666;
}

.category-recommendations .category-item:hover .category-count {
    color: rgba(255, 255, 255, 0.8);
}

.keyword-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.keyword-item {
    background: #f8f9fa;
    color: #666;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.keyword-item:hover {
    background: #ff6b6b;
    color: white;
}

.notice-features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-top: 16px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #666;
}

.feature-item i {
    color: #ff6b6b;
    font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 375px) {
    .video-grid,
    .video-grid.category-grid,
    .video-grid.search-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 4px; /* 小屏幕最小间距 */
    }
    
    .main-container {
        padding: 0 4px; /* 小屏幕减少左右边距 */
    }
    
    .category-suggestions {
        grid-template-columns: 1fr;
    }
    
    .notice-features {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 376px) and (max-width: 767px) {
    .video-grid,
    .video-grid.category-grid,
    .video-grid.search-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 6px;
    }
}

@media (min-width: 768px) {
    .video-grid,
    .video-grid.category-grid,
    .video-grid.search-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px; /* 大屏幕适中间距 */
    }
    
    .main-container {
        padding: 0 12px; /* 大屏幕适中边距 */
    }
}

@media (min-width: 1024px) {
    .video-grid,
    .video-grid.category-grid,
    .video-grid.search-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px; /* 桌面端适中间距 */
    }
    
    .main-container {
        max-width: 1200px;
        margin: 0 auto;
        padding: 0 16px; /* 桌面端标准边距 */
    }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #1a1a1a;
        color: #e1e1e1;
    }
    
    .video-card,
    .content-description,
    .related-content,
    .category-recommendations,
    .hot-keywords,
    .content-notice {
        background: #2d2d2d;
        color: #e1e1e1;
    }
    
    .category-nav,
    .category-header,
    .play-header,
    .search-header,
    .author-info,
    .video-description,
    .comments-section {
        background: #2d2d2d;
        border-color: #404040;
    }
    
    .video-title a {
        color: #e1e1e1;
    }
    
    .search-input-wrapper,
    .filter-btn,
    .tag-item,
    .category-suggestion {
        background: #404040;
        color: #e1e1e1;
    }
}

/* 悬浮反馈按钮 */
.feedback-float-btn {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    width: 60px;
    height: 100px;
    border-radius: 30px 0 0 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: -2px 0 10px rgba(255, 107, 107, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
    writing-mode: vertical-lr;
    text-orientation: mixed;
}

.feedback-float-btn:hover {
    background: linear-gradient(135deg, #e55555, #d63031);
    transform: translateY(-50%) translateX(-5px);
    box-shadow: -4px 0 15px rgba(255, 107, 107, 0.4);
}

.feedback-float-btn i {
    font-size: 18px;
    margin-bottom: 8px;
}

.feedback-float-btn span {
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 2px;
}

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

.feedback-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.feedback-content {
    background: white;
    border-radius: 12px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    z-index: 1;
    animation: feedbackSlideIn 0.3s ease;
}

@keyframes feedbackSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.feedback-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 0;
    margin-bottom: 20px;
}

.feedback-header h3 {
    margin: 0;
    color: #333;
    font-size: 18px;
    font-weight: 600;
}

.feedback-header .close-btn {
    background: none;
    border: none;
    color: #999;
    font-size: 18px;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.feedback-header .close-btn:hover {
    background: #f8f9fa;
    color: #333;
}

.feedback-form {
    padding: 0 20px 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 14px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff6b6b;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 24px;
}

.btn-cancel,
.btn-submit {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-cancel {
    background: #f8f9fa;
    color: #666;
}

.btn-cancel:hover {
    background: #e9ecef;
    color: #333;
}

.btn-submit {
    background: #ff6b6b;
    color: white;
}

.btn-submit:hover {
    background: #e55555;
}

.btn-submit:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* 移动端适配 */
@media (max-width: 768px) {
    .feedback-float-btn {
        width: 50px;
        height: 80px;
        right: 0;
    }
    
    .feedback-float-btn i {
        font-size: 16px;
        margin-bottom: 6px;
    }
    
    .feedback-float-btn span {
        font-size: 11px;
        letter-spacing: 1px;
    }
    
    .feedback-modal {
        padding: 15px;
    }
    
    .feedback-content {
        max-height: 85vh;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .btn-cancel,
    .btn-submit {
        width: 100%;
    }
} 