/* 头部样式 */
.header {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    color: #333;
    padding: 10px 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 100;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
}

.header .header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header .user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header .user-info span {
    white-space: nowrap;
}

.header .theme-switcher select {
    padding: 4px 8px;
    border: 1px solid #667eea;
    border-radius: 4px;
    font-size: 12px;
    background-color: #fff;
    color: #333;
    cursor: pointer;
}

.header .user-info button {
    background: none;
    border: 1px solid #667eea;
    color: #667eea;
    padding: 4px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.3s ease;
}

.header .user-info button:hover {
    background: #667eea;
    color: white;
}

.header .user-info .welcome-text {
    white-space: nowrap;
}

.header .user-info .username {
    white-space: nowrap;
    font-weight: bold;
}

/* 移动端响应式设计 */
@media (max-width: 768px) {
    .header {
        padding: 8px 15px;
        border-radius: 0;
    }
    
    .header h2 {
        font-size: 14px;
    }
    
    .header .user-info .welcome-text {
        font-size: 11px;
    }
    
    .header .user-info .username {
        font-size: 11px;
    }
    
    .header .user-info button {
        padding: 3px 6px;
        font-size: 10px;
    }
    
    .header .theme-switcher select {
        padding: 2px 4px;
        font-size: 10px;
    }
}

/* 微信全屏遮罩 */
.header .wechat-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    padding: 20px;
    box-sizing: border-box;
}

.header .wechat-overlay.show {
    display: flex;
}

.header .wechat-overlay-content {
    background: linear-gradient(135deg, #fff 0%, #f8f9fa 100%);
    border-radius: 20px;
    padding: 40px 30px;
    max-width: 400px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.header .wechat-overlay-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.header .wechat-overlay-title {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 0 0 12px 0;
}

.header .wechat-overlay-desc {
    font-size: 14px;
    color: #666;
    margin: 0 0 25px 0;
    line-height: 1.6;
}

.header .wechat-overlay-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 30px;
    align-items: flex-start;
}

.header .wechat-overlay-steps .step {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    width: 100%;
}

.header .wechat-overlay-steps .step-num {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    flex-shrink: 0;
}

.header .wechat-overlay-steps .step-text {
    font-size: 15px;
    color: #333;
}

.header .wechat-overlay-steps .step-text .arrow {
    font-size: 18px;
    font-weight: bold;
    color: #667eea;
    margin: 0 4px;
}

.header .wechat-overlay-steps .step-text .action {
    color: #667eea;
    font-weight: 600;
}

.header .wechat-overlay-image {
    margin-top: 20px;
    margin-bottom: 30px;
    text-align: center;
}

.header .operation-image {
    max-width: 100%;
    height: auto;
    max-height: 200px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.header .wechat-overlay-close {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.header .wechat-overlay-close:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

/* 移动端响应式设计 - 全屏遮罩 */
@media (max-width: 768px) {
    .header .wechat-overlay-content {
        padding: 30px 20px;
        border-radius: 16px;
    }
    
    .header .wechat-overlay-icon {
        font-size: 50px;
        margin-bottom: 16px;
    }
    
    .header .wechat-overlay-title {
        font-size: 20px;
    }
    
    .header .wechat-overlay-desc {
        font-size: 13px;
    }
    
    .header .wechat-overlay-steps .step-text {
        font-size: 14px;
    }
    
    .header .wechat-overlay-close {
        padding: 12px;
        font-size: 15px;
    }
}

/* 深色模式支持 - 全屏遮罩 */
body.theme-dark .header .wechat-overlay-content {
    background: linear-gradient(135deg, #2c2c2c 0%, #1e1e1e 100%);
}

body.theme-dark .header .wechat-overlay-title {
    color: #fff;
}

body.theme-dark .header .wechat-overlay-desc {
    color: #999;
}

body.theme-dark .header .wechat-overlay-steps .step-text {
    color: #ccc;
}

body.theme-dark .header .wechat-overlay-steps .step-text .action {
    color: #3498db;
}