/* 前台页面专用样式 - 修复模板混乱问题 */

/* 确保首页正常显示 */
body {
    background: #f5f7fa;
    min-height: 100vh;
    font-family: var(--font-family-primary);
    font-size: var(--font-size-base);
    color: #2d3748;
    line-height: var(--line-height-normal);
}

/* 隐藏导航栏（登录/注册页面） */
body.no-nav .navbar {
    display: none;
}

body.no-nav .main-content {
    padding: 0;
}

/* 登录页面 */
.login-page,
.register-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-container,
.register-container {
    width: 100%;
    max-width: 450px;
}

.login-box,
.register-box {
    background: white;
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.login-header,
.register-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h1,
.register-header h1 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #667eea;
    margin: 0 0 10px 0;
}

.login-header p,
.register-header p {
    font-size: 1.1rem;
    color: #666;
    margin: 0;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.form-control:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    outline: none;
}

.form-control::placeholder {
    color: #a0aec0;
}

.form-text {
    display: block;
    margin-top: 6px;
    font-size: 0.85rem;
    color: #718096;
}

.checkbox-group {
    display: flex;
    align-items: center;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin: 0;
    font-weight: 400;
}

.checkbox-group input[type="checkbox"] {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* 登录/注册按钮 */
.btn-block {
    width: 100%;
    padding: 14px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5a6fd6 0%, #6a4190 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

/* 登录/注册页脚 */
.login-footer {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e2e8f0;
    text-align: center;
}

.login-footer p {
    margin: 8px 0;
    font-size: 0.9rem;
    color: #718096;
}

.login-footer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.login-footer a:hover {
    color: #5a6fd6;
    text-decoration: underline;
}

/* 警告框 */
.alert {
    padding: 16px;
    margin-bottom: 24px;
    border-radius: 8px;
    border: none;
    font-size: 0.95rem;
}

.alert-success {
    background: rgba(76, 175, 80, 0.1);
    color: #2e7d32;
    border-left: 4px solid #4CAF50;
}

.alert-danger {
    background: rgba(244, 67, 54, 0.1);
    color: #c62828;
    border-left: 4px solid #f44336;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    color: #004085;
    border-left: 4px solid #2196F3;
}

.alert-warning {
    background: rgba(255, 193, 7, 0.1);
    color: #856404;
    border-left: 4px solid #ffc107;
}

/* 主容器 */
.container {
    max-width: 1200px;
    padding: 0 15px;
    margin: 0 auto;
}

/* 主内容区 */
.main-content {
    flex: 1;
    padding: 30px 0;
    background: #f5f7fa;
}

/* 导航栏 */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1) !important;
    padding: 0.8rem 0 !important;
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.4rem;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    color: rgba(255,255,255,0.9);
    margin: 0 0.2rem;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* 欢迎区域 */
.bg-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
}

.bg-gradient h2,
.bg-gradient h3,
.bg-gradient h4,
.bg-gradient h5,
.bg-gradient h6,
.bg-gradient p,
.bg-gradient .lead,
.bg-gradient small {
    color: white !important;
}

.bg-gradient .display-5 {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.bg-gradient .lead {
    font-size: 1.1rem;
    opacity: 0.95;
}

/* 卡片 */
.card {
    border: none;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    background: white;
}

.card:not(.feature-card):hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.card-header {
    background: white;
    border-bottom: 2px solid #667eea;
    padding: 1rem 1.5rem;
    font-weight: 600;
    color: #2d3748;
}

.card-title {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d3748;
}

.card-body {
    padding: 1.5rem;
}

/* 统计卡片 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
    font-weight: 500;
}

/* 统计盒子 */
.stat-box {
    text-align: center;
    color: white;
}

.stat-box h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.stat-box small {
    font-size: 0.85rem;
    opacity: 0.75;
}

/* 视频卡片 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.video-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.video-link {
    display: block;
    color: inherit;
    text-decoration: none;
}

.video-thumbnail {
    position: relative;
    height: 180px;
    overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
    transform: scale(1.05);
}

.video-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.play-overlay {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(255,255,255,0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #667eea;
    opacity: 0;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.video-card:hover .play-overlay {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

.video-info {
    padding: 1.25rem;
}

.video-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.625rem 0;
    color: #2d3748;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-desc {
    font-size: 0.875rem;
    color: #666;
    margin: 0 0 0.75rem 0;
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.8125rem;
    color: #999;
}

.view-count {
    display: flex;
    align-items: center;
    gap: 4px;
}

/* 任务状态 */
.task-status {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.task-status.status-0 {
    background: #fff3cd;
    color: #856404;
}

.task-status.status-1 {
    background: #cce5ff;
    color: #004085;
}

.task-status.status-2 {
    background: #d4edda;
    color: #155724;
}

/* 按钮 */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    font-size: 0.875rem;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
    color: white;
}

.btn-success {
    background: #4CAF50;
    color: white;
}

.btn-success:hover {
    background: #45a049;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(76, 175, 80, 0.3);
}

.btn-danger {
    background: #f44336;
    color: white;
}

.btn-danger:hover {
    background: #d32f2f;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(244, 67, 54, 0.3);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
}

.btn-outline-primary {
    border: 2px solid #667eea;
    color: #667eea;
    background: transparent;
}

.btn-outline-primary:hover {
    background: #667eea;
    color: white;
    transform: translateY(-2px);
}

/* 警告框 */
.alert {
    padding: 1rem 1.5rem;
    margin: 1rem 0;
    border-radius: 8px;
    border: none;
}

.alert-success {
    background: rgba(76, 175, 80, 0.1);
    color: #2e7d32;
    border-left: 4px solid #4CAF50;
}

.alert-danger {
    background: rgba(244, 67, 54, 0.1);
    color: #c62828;
    border-left: 4px solid #f44336;
}

.alert-info {
    background: rgba(33, 150, 243, 0.1);
    color: #004085;
    border-left: 4px solid #2196F3;
}

/* 空状态 */
.empty-msg {
    text-align: center;
    padding: 4rem 1.25rem;
    color: #999;
    font-size: 1.1rem;
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* 标签页 */
.nav-tabs .nav-link {
    color: #2d3748;
    border: none;
    border-bottom: 2px solid transparent;
    padding: 0.75rem 1rem;
    cursor: pointer;
}

.nav-tabs .nav-link:hover {
    color: #667eea;
}

.nav-tabs .nav-link.active {
    color: #667eea;
    border-bottom: 2px solid #667eea;
    font-weight: 600;
}

/* 特征卡片 */
.feature-card {
    background: white !important;
    border-radius: 16px !important;
    padding: 2.5rem 2rem !important;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
    text-decoration: none !important;
    color: inherit;
    display: block;
    border: 2px solid transparent !important;
    position: relative;
    overflow: hidden;
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    transition: left 0.5s ease;
}

.feature-card:hover::before {
    left: 100%;
}

.feature-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.25);
    border-color: #667eea;
}

.feature-icon {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    width: 100px;
    height: 100px;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.4s ease;
    position: relative;
}

.feature-icon.text-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 4px 10px rgba(102, 126, 234, 0.3));
}

.feature-icon.text-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 4px 10px rgba(56, 239, 125, 0.3));
}

.feature-icon.text-info {
    background: linear-gradient(135deg, #2193b0 0%, #6dd5ed 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 4px 10px rgba(33, 147, 176, 0.3));
}

.feature-card:hover .feature-icon {
    transform: scale(1.15) rotate(5deg);
}

.feature-card:hover .feature-icon.text-primary {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-card:hover .feature-icon.text-success {
    background: linear-gradient(135deg, #38ef7d 0%, #11998e 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-card:hover .feature-icon.text-info {
    background: linear-gradient(135deg, #6dd5ed 0%, #2193b0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-card .card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #2d3748;
    transition: color 0.3s ease;
}

.feature-card:hover .card-title {
    color: #667eea;
}

.feature-card .card-text {
    font-size: 0.95rem;
    color: #718096;
    margin-bottom: 1.25rem;
    line-height: 1.6;
}

.feature-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    border-radius: 20px;
    background: rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
}

.feature-link:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateX(5px);
}

.feature-card .feature-link i {
    transition: transform 0.3s ease;
}

.feature-card:hover .feature-link i {
    transform: translateX(5px);
}

/* 页脚 */
.footer {
    background: #2d3748;
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: auto;
}

.footer p {
    margin: 0;
    opacity: 0.8;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .video-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 1.25rem;
    }
    
    .welcome-section {
        text-align: center;
    }
}

@media (max-width: 768px) {
    .video-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .main-content {
        padding: 20px 0;
    }
    
    .stat-card {
        padding: 1rem;
    }
    
    .card {
        margin-bottom: 1rem;
    }
    
    .bg-gradient .display-5 {
        font-size: 1.8rem;
    }
    
    .bg-gradient .lead {
        font-size: 1rem;
    }
    
    /* 导航栏优化 */
    .navbar-nav .nav-link {
        padding: 0.5rem 0.75rem;
        font-size: 0.9rem;
    }
    
    .navbar-collapse {
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        border-radius: 12px;
        margin-top: 10px;
        padding: 10px;
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    }
    
    .dropdown-menu {
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
    }
    
    /* 筛选表单在手机上改为垂直堆叠 */
    .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 {
        flex-wrap: wrap !important;
        overflow-x: visible !important;
    }
    
    .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 > .col-auto.flex-shrink-0 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
        margin-bottom: 10px;
    }
    
    .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 > .col-auto.flex-shrink-0:last-child {
        margin-bottom: 0;
    }
    
    /* 快速导航卡片在手机上改为单列 */
    .quick-actions-section .row.g-4 {
        flex-direction: column;
    }
    
    .quick-actions-section .col-lg-3.col-md-6 {
        width: 100%;
        margin-bottom: 15px;
    }
    
    .quick-actions-section .col-lg-3.col-md-6:last-child {
        margin-bottom: 0;
    }
    
    /* 视频卡片在手机上调整 */
    .video-thumbnail {
        height: 160px;
    }
    
    .video-title {
        font-size: 0.9rem;
    }
    
    .video-desc {
        font-size: 0.8rem;
    }
}

@media (max-width: 576px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .video-thumbnail {
        height: 140px;
    }
    
    .container {
        padding: 0 10px;
    }
    
    .card-body,
    .card-header {
        padding: 0.8rem;
    }
    
    .video-title {
        font-size: 0.85rem;
    }
    
    .video-desc {
        font-size: 0.75rem;
    }
    
    /* 导航栏进一步优化 */
    .navbar-brand {
        font-size: 1.2rem;
    }
    
    .navbar-toggler {
        padding: 0.25rem 0.5rem;
        font-size: 0.9rem;
    }
    
    /* 筛选表单元素缩小 */
    .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 > .col-auto.flex-shrink-0 {
        margin-bottom: 8px;
    }
    
    .form-control, .form-select, .btn {
        font-size: 0.85rem;
        padding: 0.5rem 0.75rem;
    }
    
    /* 快速导航卡片调整 */
    .quick-action-card {
        padding: 1.2rem 1rem;
    }
    
    .card-icon {
        font-size: 2.2rem;
    }
    
    .card-title {
        font-size: 1.1rem;
    }
    
    .card-description {
        font-size: 0.8rem;
    }
    
    /* 统计面板调整 */
    .stats-panel .stat-item {
        padding: 0.5rem;
    }
    
    .stat-icon {
        font-size: 1.5rem;
    }
    
    .stat-value {
        font-size: 1.3rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
    
    /* 按钮大小优化 */
    .btn {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
    
    /* 欢迎区域调整 */
    .bg-gradient .display-5 {
        font-size: 1.5rem;
    }
    
    .bg-gradient .lead {
        font-size: 0.9rem;
    }
}

/* 超小屏幕优化（375px以下） */
@media (max-width: 375px) {
    .video-thumbnail {
        height: 120px;
    }
    
    .video-title {
        font-size: 0.8rem;
    }
    
    .video-desc {
        font-size: 0.7rem;
    }
    
    .navbar-brand {
        font-size: 1rem;
    }
    
    .navbar-toggler-icon {
        width: 1em;
        height: 1em;
    }
    
    .quick-action-card {
        padding: 1rem 0.8rem;
    }
    
    .card-icon {
        font-size: 1.8rem;
    }
    
    .card-title {
        font-size: 1rem;
    }
    
    .card-description {
        font-size: 0.75rem;
    }
    
    .form-control, .form-select, .btn {
        font-size: 0.8rem;
        padding: 0.4rem 0.6rem;
    }
    
    .btn {
        padding: 0.4rem 0.8rem;
    }
    
    .stat-icon {
        font-size: 1.2rem;
    }
    
    .stat-value {
        font-size: 1.1rem;
    }
}

/* 移动设备专用优化 */
.mobile-device {
    --mobile-font-size: 14px;
    --mobile-spacing: 8px;
    --mobile-button-height: 44px;
}

.mobile-device .navbar {
    padding: 0.5rem 0 !important;
}

.mobile-device .navbar-brand {
    font-size: 1.1rem !important;
}

.mobile-device .navbar-toggler {
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
}

.mobile-device .navbar-nav .nav-link {
    padding: 0.6rem 0.8rem !important;
    font-size: 0.9rem;
    min-height: var(--mobile-button-height);
    display: flex;
    align-items: center;
}

.mobile-device .dropdown-menu {
    min-width: 200px;
    border-radius: 12px;
    margin-top: 5px;
}

.mobile-device .dropdown-item {
    padding: 0.75rem 1rem;
    min-height: 44px;
    display: flex;
    align-items: center;
}

.mobile-device .container {
    padding: 0 10px;
    max-width: 100%;
}

.mobile-device .main-content {
    padding: 15px 0;
}

.mobile-device .card {
    margin-bottom: 1rem;
    border-radius: 12px;
}

.mobile-device .card-body {
    padding: 1rem;
}

.mobile-device .card-header {
    padding: 0.75rem 1rem;
}

.mobile-device .video-card {
    border-radius: 12px;
    overflow: hidden;
}

.mobile-device .video-thumbnail {
    height: 150px;
}

.mobile-device .video-title {
    font-size: 0.9rem;
    line-height: 1.3;
}

.mobile-device .video-desc {
    font-size: 0.8rem;
    line-height: 1.4;
}

.mobile-device .btn, 
.mobile-device .form-control,
.mobile-device .form-select {
    min-height: var(--mobile-button-height);
    font-size: var(--mobile-font-size);
    padding: 0.5rem 0.75rem;
}

.mobile-device .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.mobile-device .input-group .input-group-text {
    min-height: var(--mobile-button-height);
    font-size: var(--mobile-font-size);
}

/* 快速导航卡片在移动设备上的优化 */
.mobile-device .quick-action-card {
    padding: 1.5rem 1rem;
    margin-bottom: 15px;
}

.mobile-device .card-icon {
    font-size: 2.5rem;
    margin-bottom: 0.75rem;
}

.mobile-device .card-title {
    font-size: 1.1rem;
}

.mobile-device .card-description {
    font-size: 0.85rem;
    line-height: 1.4;
}

.mobile-device .action-btn {
    padding: 0.6rem 1.25rem;
    min-height: 40px;
}

/* 筛选表单在移动设备上的优化 */
.mobile-device .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 {
    flex-direction: column;
    gap: 10px;
}

.mobile-device .row.g-2.align-items-center.flex-nowrap.overflow-x-auto.pb-2 > .col-auto.flex-shrink-0 {
    flex: 0 0 100% !important;
    max-width: 100% !important;
    width: 100%;
    margin-bottom: 0;
}

.mobile-device .input-group {
    width: 100%;
}

.mobile-device .form-select,
.mobile-device .form-control {
    width: 100%;
}

/* 视频网格在移动设备上的优化 */
.mobile-device .video-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
}

.mobile-device .row.g-4 {
    gap: 1rem;
}

.mobile-device .col-xl-3.col-lg-4.col-md-6 {
    width: 100%;
    margin-bottom: 1rem;
}

/* 统计信息面板优化 */
.mobile-device .stats-panel {
    padding: 1rem;
    border-radius: 12px;
}

.mobile-device .stat-item {
    padding: 0.75rem;
    flex-direction: column;
    text-align: center;
    margin-bottom: 1rem;
}

.mobile-device .stat-icon {
    font-size: 1.5rem;
    margin-right: 0;
    margin-bottom: 0.5rem;
}

.mobile-device .stat-value {
    font-size: 1.3rem;
    margin-bottom: 0.25rem;
}

.mobile-device .stat-label {
    font-size: 0.85rem;
}

/* 分页优化 */
.mobile-device .pagination {
    flex-wrap: wrap;
    justify-content: center;
    gap: 5px;
}

.mobile-device .page-item {
    margin-bottom: 5px;
}

.mobile-device .page-link {
    min-height: 36px;
    min-width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem;
}

/* 模态框优化 */
.mobile-device .modal-dialog {
    margin: 10px;
    max-width: calc(100% - 20px);
}

.mobile-device .modal-content {
    border-radius: 16px;
}

.mobile-device .modal-header,
.mobile-device .modal-body,
.mobile-device .modal-footer {
    padding: 1rem;
}

/* 触控优化 */
.mobile-device a,
.mobile-device button,
.mobile-device .btn,
.mobile-device .nav-link,
.mobile-device .dropdown-item {
    cursor: pointer;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
}

.mobile-device a:active,
.mobile-device button:active,
.mobile-device .btn:active,
.mobile-device .nav-link:active {
    opacity: 0.7;
    transform: scale(0.98);
    transition: all 0.1s ease;
}

/* 滚动优化 */
.mobile-device .container,
.mobile-device .main-content {
    overflow-x: hidden;
}

/* 欢迎区域优化 */
.mobile-device .bg-gradient .display-5 {
    font-size: 1.5rem;
    line-height: 1.3;
}

.mobile-device .bg-gradient .lead {
    font-size: 0.9rem;
    line-height: 1.4;
}

.mobile-device .stat-box {
    padding: 0.5rem;
}

.mobile-device .stat-box h3 {
    font-size: 1.2rem;
}

/* 部门标签页优化 */
.mobile-device .nav-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 5px;
}

.mobile-device .nav-tabs .nav-item {
    flex-shrink: 0;
}

.mobile-device .nav-tabs .nav-link {
    white-space: nowrap;
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
}

/* 超小屏幕额外优化 */
@media (max-width: 375px) {
    .mobile-device .video-thumbnail {
        height: 130px;
    }
    
    .mobile-device .video-title {
        font-size: 0.85rem;
    }
    
    .mobile-device .video-desc {
        font-size: 0.75rem;
    }
    
    .mobile-device .navbar-brand {
        font-size: 1rem !important;
    }
    
    .mobile-device .quick-action-card {
        padding: 1.25rem 0.8rem;
    }
    
    .mobile-device .card-icon {
        font-size: 2rem;
    }
    
    .mobile-device .card-title {
        font-size: 1rem;
    }
    
    .mobile-device .card-description {
        font-size: 0.8rem;
    }
}
