/**
 * 用户端自定义样式
 * 移动端优先设计
 */

/* 全局样式 */
* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background-color: #f5f5f5;
}

/* 移动端适配 */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
}

/* 按钮样式 */
.btn-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
}

.btn-gradient:hover {
    background: linear-gradient(135deg, #5568d3 0%, #63408b 100%);
    color: white;
}

/* 卡片样式 */
.card-custom {
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    border: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}

/* 视频封面 */
.video-cover {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
}

@media (max-width: 768px) {
    .video-cover {
        height: 150px;
    }
}

/* 加载动画 */
.loading-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

/* 触摸优化 */
.touch-target {
    min-height: 44px;
    min-width: 44px;
}

/* 安全区域适配（iPhone X等） */
@supports (padding: max(0px)) {
    body {
        padding-left: max(0px, env(safe-area-inset-left));
        padding-right: max(0px, env(safe-area-inset-right));
        padding-bottom: max(0px, env(safe-area-inset-bottom));
    }
}
