/* 认证页面样式 */
.auth-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.auth-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1000px;
    width: 100%;
    align-items: center;
}

.auth-card {
    background: white;
    border-radius: 15px;
    padding: 3rem;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: #666;
    font-size: 1.1rem;
}

.auth-form {
    margin-bottom: 2rem;
}

.auth-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
}

.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.auth-footer {
    text-align: center;
    color: #666;
    font-size: 0.9rem;
}

.auth-footer .link {
    color: #667eea;
    text-decoration: none;
}

.auth-footer .link:hover {
    text-decoration: underline;
}

.auth-features {
    color: white;
}

.auth-features h3 {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    text-align: center;
}

.feature-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.feature-item i {
    font-size: 2rem;
    color: rgba(255,255,255,0.8);
}

.feature-item h4 {
    margin-bottom: 0.25rem;
    font-size: 1.1rem;
}

.feature-item p {
    opacity: 0.8;
    font-size: 0.9rem;
}

/* 个人中心页面样式 */
.profile-main {
    padding: 2rem 0;
    min-height: calc(100vh - 200px);
}

/* 导航栏用户菜单通用修复：确保可点击与层级正确 */
.navbar .nav-right,
.navbar .nav-user { position: relative; z-index: 10; }
.navbar .user-btn { position: relative; z-index: 11; pointer-events: auto; }
.navbar .user-dropdown { position: absolute; right: 0; top: 100%; z-index: 9999; }

/* 自动封面生成提示样式 */
.auto-cover-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
}

.auto-cover-info i {
    font-size: 18px;
    color: #ffd700;
}

/* 封面上传进度样式 */
#coverUploadProgress {
    margin-top: 10px;
}

#coverUploadProgress .progress-bar {
    background: #f0f0f0;
    border-radius: 10px;
    height: 8px;
    overflow: hidden;
    margin-bottom: 5px;
}

#coverUploadProgress .progress-fill {
    background: linear-gradient(90deg, #007bff, #0056b3);
    height: 100%;
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 10px;
}

#coverUploadProgress .progress-text {
    font-size: 12px;
    color: #666;
    text-align: center;
    display: block;
}

.profile-card {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.profile-avatar {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid #667eea;
}

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

.avatar-edit {
    position: absolute;
    bottom: 0;
    right: 0;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s;
}

.avatar-edit:hover {
    background: #5a6fd8;
}

.profile-info {
    flex: 1;
}

.profile-info h1 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 0.5rem;
}

.profile-info p {
    color: #666;
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.vip-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    color: #333;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
}

.edit-profile-btn {
    background: #667eea;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: background-color 0.3s;
}

.edit-profile-btn:hover {
    background: #5a6fd8;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 2rem;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 10px;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2rem;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 0.5rem;
}

.stat-label {
    color: #666;
    font-size: 0.9rem;
}

.profile-nav {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #dee2e6;
    overflow-x: auto;
}

.nav-tab {
    background: none;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    color: #666;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-tab:hover {
    color: #333;
    background: #f8f9fa;
}

.nav-tab.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.content-header h2 {
    color: #333;
    font-size: 1.5rem;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.filter-group select {
    padding: 0.5rem;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    background: white;
}

.clear-history-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background-color 0.3s;
}

.clear-history-btn:hover {
    background: #c82333;
}

/* 上传视频样式 */
.upload-section {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
}

.upload-tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid #dee2e6;
    overflow-x: auto;
}

.upload-tab {
    background: none;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    color: #666;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.upload-tab:hover {
    color: #333;
    background: #f8f9fa;
}

.upload-tab.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.upload-form {
    max-width: 800px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.upload-progress {
    margin-top: 1rem;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: #667eea;
    transition: width 0.3s;
}

.upload-btn {
    width: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.upload-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

/* 视频分类页面样式 */
.category-main {
    padding: 2rem 0;
    min-height: calc(100vh - 200px);
}

.page-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 小视频特殊网格 */
.short-video-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.short-video-grid .video-card {
    aspect-ratio: 9/16;
}

.short-video-grid .video-thumbnail {
    height: 100%;
}

/* 视频详情模态框样式 */
.video-modal-content {
    max-width: 1200px;
    width: 95%;
}

/* 视频播放布局 */
.video-layout {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.video-main {
    flex: 1;
    min-width: 0;
}

.video-sidebar {
    width: 300px;
    flex-shrink: 0;
}

/* 侧边栏广告容器 */
.sidebar-ad-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.ad-slot {
    width: 100%;
    min-height: 200px;
    border: 2px dashed #ddd;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f9f9f9;
    transition: all 0.3s ease;
}

.ad-slot:hover {
    border-color: #007bff;
    background: #f0f8ff;
}

.ad-placeholder {
    text-align: center;
    color: #999;
    font-size: 14px;
}

.ad-placeholder i {
    font-size: 24px;
    margin-bottom: 8px;
    display: block;
}

.ad-slot img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    cursor: pointer;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .video-layout {
        flex-direction: column;
    }
    
    .video-sidebar {
        width: 100%;
    }
    
    .sidebar-ad-container {
        flex-direction: row;
        gap: 10px;
    }
    
    .ad-slot {
        min-height: 150px;
    }
}

/* 视频广告样式 */
.video-ad-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.video-ad-container {
    position: relative;
    max-width: 80%;
    max-height: 80%;
}

.video-ad-content {
    position: relative;
    background: #000;
    border-radius: 8px;
    overflow: hidden;
}

.video-ad-content video {
    width: 100%;
    height: auto;
    max-height: 400px;
}

.video-ad-controls {
    position: absolute;
    bottom: 10px;
    right: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.ad-countdown {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
}

.skip-ad-btn {
    background: #ff4444;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: background 0.3s ease;
}

.skip-ad-btn:hover {
    background: #ff6666;
}

.skip-ad-btn:disabled {
    background: #666;
    cursor: not-allowed;
}

.video-player {
    position: relative;
    width: 100%;
    margin-bottom: 1rem;
}

.video-player video {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

.video-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.video-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.video-meta span {
    background: #f8f9fa;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.875rem;
    color: #666;
}

.video-actions {
    display: flex;
    gap: 1rem;
}

.action-btn {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    color: #666;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.action-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.action-btn.liked {
    background: #ff6b6b;
    color: white;
    border-color: #ff6b6b;
}

.video-description,
.video-rating {
    margin-bottom: 1.5rem;
}

.video-description h3,
.video-rating h3 {
    margin-bottom: 0.5rem;
    color: #333;
}

.episode-list {
    margin-top: 2rem;
}

.episode-list h3 {
    margin-bottom: 1rem;
    color: #333;
}

.episodes {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.episode-item {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 5px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    text-align: center;
}

.episode-item:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.episode-item.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* 评论列表样式 */
.comments-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.comment-item {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 1rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #667eea;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.comment-user {
    flex: 1;
}

.comment-username {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.25rem;
}

.comment-time {
    font-size: 0.875rem;
    color: #666;
}

.comment-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: #ffc107;
}

.comment-content {
    color: #333;
    line-height: 1.6;
    margin-top: 0.5rem;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .auth-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    
    .profile-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .upload-tabs {
        flex-wrap: wrap;
    }
    
    .video-info {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .episodes {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 2rem;
    }
    
    .profile-card {
        padding: 1.5rem;
    }
    
    .upload-section {
        padding: 1.5rem;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .profile-stats {
        grid-template-columns: 1fr;
    }
    
    .nav-tab,
    .upload-tab {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
}
