/* 订阅管理系统 - 优化后的前端样式 */

/* 全局字体和基础样式 */
.sm-verification-container,
.sm-user-center {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

/* 登录提示样式 */
.sm-login-prompt {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    margin: 20px 0;
    color: white;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.sm-login-prompt h3 {
    margin-top: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.sm-login-button {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: white !important;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    margin-top: 15px;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

.sm-login-button:hover {
    background: rgba(255, 255, 255, 0.3);
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* 错误提示样式 */
.sm-error {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    border: none;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

/* 邮件验证容器 */
.sm-verification-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 0 20px;
}

/* 用户欢迎头部 */
.sm-user-welcome {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(255, 152, 0, 0.3);
}

.sm-user-welcome h2 {
    margin: 0 0 10px 0;
    font-size: 1.8rem;
    font-weight: 600;
}

.sm-user-welcome p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
}

/* 验证警告框 */
.sm-verification-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.2);
    position: relative;
    overflow: hidden;
}

.sm-verification-warning::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #ffc107, #ff8c00, #ffc107);
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.sm-verify-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.sm-verify-header h3 {
    margin: 0;
    color: #856404;
    margin-left: 15px;
    font-size: 1.4rem;
    font-weight: 600;
}

.sm-verify-icon {
    font-size: 2rem;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.1));
}

.sm-verification-warning p {
    color: #856404;
    margin-bottom: 15px;
    font-size: 1.05rem;
    line-height: 1.6;
}

/* 🔥 优化后的验证按钮样式 */
.sm-verify-button {
    background: linear-gradient(135deg, #007cba 0%, #0056b3 100%);
    color: white;
    border: none;
    padding: 15px 35px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    min-width: 220px;
    min-height: 50px;
    box-shadow: 0 4px 15px rgba(0, 124, 186, 0.4);
    overflow: hidden;
    text-transform: uppercase;
}

.sm-verify-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.sm-verify-button:hover::before {
    left: 100%;
}

.sm-verify-button:hover:not(:disabled) {
    background: linear-gradient(135deg, #0056b3 0%, #004085 100%);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 124, 186, 0.5);
}

.sm-verify-button:active:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0, 124, 186, 0.4);
}

.sm-verify-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 124, 186, 0.2);
}

.sm-verify-button .sm-button-text {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.sm-verify-button .sm-button-text::before {
    content: '✉️';
    font-size: 16px;
}

.sm-verify-button .sm-loading-spinner {
    display: none;
    align-items: center;
    gap: 10px;
}

.sm-verify-button.loading .sm-button-text {
    display: none;
}

.sm-verify-button.loading .sm-loading-spinner {
    display: inline-flex;
}

/* 操作区域 */
.sm-verify-actions {
    text-align: center;
    margin: 30px 0;
}

/* 消息显示优化 */
.sm-verify-message {
    margin-top: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    text-align: center;
    min-height: 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.sm-verify-message.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border: 2px solid #28a745;
    color: #155724;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.2);
}

.sm-verify-message.success::before {
    content: '✅ ';
    font-size: 1.2rem;
}

.sm-verify-message.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border: 2px solid #dc3545;
    color: #721c24;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.2);
}

.sm-verify-message.error::before {
    content: '❌ ';
    font-size: 1.2rem;
}

/* 功能预览区域 */
.sm-feature-preview {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #dee2e6;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.sm-feature-preview h4 {
    margin-top: 0;
    color: #495057;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sm-feature-preview ul {
    margin: 15px 0 0 0;
    padding-left: 0;
    list-style: none;
}

.sm-feature-preview li {
    padding: 8px 0;
    color: #6c757d;
    position: relative;
    padding-left: 25px;
    font-weight: 500;
}

.sm-feature-preview li::before {
    content: '🔒';
    position: absolute;
    left: 0;
    top: 8px;
}

/* 帮助提示优化 */
.sm-verify-tips {
    background: linear-gradient(135deg, #e7f3ff 0%, #cce7ff 100%);
    border-left: 4px solid #2196f3;
    border-radius: 0 12px 12px 0;
    padding: 25px;
    margin-top: 25px;
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.1);
}

.sm-verify-tips h4 {
    margin-top: 0;
    color: #1976d2;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.sm-verify-tips ul {
    margin: 15px 0 0 0;
    padding-left: 20px;
}

.sm-verify-tips li {
    margin-bottom: 8px;
    color: #555;
    font-size: 14px;
    line-height: 1.5;
}

/* 成功状态 */
.sm-verification-success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border: 2px solid #28a745;
    border-radius: 12px;
    padding: 20px;
    color: #155724;
    text-align: center;
    font-weight: 600;
    font-size: 1.1rem;
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.2);
}

.sm-verification-success .sm-verify-icon {
    font-size: 2rem;
    margin-right: 10px;
    vertical-align: middle;
}

/* 🔥 优化验证提示横幅 - 修复置顶显示问题 */
.sm-verification-success-banner,
.sm-verification-error-banner {
    padding: 15px 50px 15px 20px; /* 右侧留出关闭按钮空间 */
    margin: 0 0 20px 0; /* 移除顶部边距，防止偏移 */
    border-radius: 8px;
    position: relative;
    display: flex;
    align-items: center;
    font-weight: 500;
    font-size: 1rem;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.15);
    animation: slideInDown 0.4s ease-out;
    z-index: 1000; /* 确保在其他元素之上 */
    opacity: 1;
    transition: all 0.3s ease;
}

/* 🔥 改进动画效果 */
@keyframes slideInDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 淡出动画 */
@keyframes fadeOutUp {
    from {
        transform: translateY(0);
        opacity: 1;
    }
    to {
        transform: translateY(-100%);
        opacity: 0;
    }
}

.sm-banner-fade-out {
    animation: fadeOutUp 0.4s ease-in forwards;
}

/* 成功横幅样式 */
.sm-verification-success-banner {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-left: 4px solid #28a745;
    color: #155724;
    border: 1px solid rgba(40, 167, 69, 0.3);
}

/* 错误横幅样式 */
.sm-verification-error-banner {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border-left: 4px solid #dc3545;
    color: #721c24;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

/* 🔥 优化关闭按钮 */
.sm-close-banner {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.1);
    border: none;
    border-radius: 50%;
    font-size: 16px;
    cursor: pointer;
    opacity: 0.6;
    padding: 6px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    font-weight: bold;
    line-height: 1;
}

.sm-close-banner:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.2);
    transform: translateY(-50%) scale(1.1);
}

.sm-close-banner:active {
    transform: translateY(-50%) scale(0.95);
}

/* 横幅图标优化 */
.sm-verification-success-banner .sm-verify-icon,
.sm-verification-error-banner .sm-verify-icon {
    font-size: 1.4rem;
    margin-right: 12px;
    flex-shrink: 0;
}

/* 登录提示样式 */
.sm-login-prompt {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    margin: 20px 0;
    color: white;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.sm-login-prompt h3 {
    margin-top: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.sm-login-button {
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    color: white !important;
    padding: 12px 30px;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    margin-top: 15px;
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

.sm-login-button:hover {
    background: rgba(255, 255, 255, 0.3);
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* 错误提示样式 */
.sm-error {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    border: none;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    color: white;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
}

/* 邮件验证容器 */
.sm-verification-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 0 20px;
}

/* 用户欢迎头部 */
.sm-user-welcome {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(255, 152, 0, 0.3);
}

.sm-user-welcome h2 {
    margin: 0 0 10px 0;
    font-size: 1.8rem;
    font-weight: 600;
}

.sm-user-welcome p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
}

/* 验证警告框 */
.sm-verification-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.2);
    position: relative;
    overflow: hidden;
}

/* 临时通知优化 */
.sm-temp-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #333 0%, #444 100%);
    color: white;
    padding: 20px 25px;
    border-radius: 12px;
    z-index: 10000;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    max-width: 350px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}

.sm-temp-notification.show {
    transform: translateX(0);
}

.sm-temp-notification::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #00d4aa, #00a085);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .sm-verification-container {
        margin: 10px;
        max-width: none;
        padding: 0 15px;
    }
    
    .sm-user-welcome {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .sm-user-welcome h2 {
        font-size: 1.5rem;
    }
    
    .sm-verification-warning {
        padding: 20px;
    }
    
    .sm-verify-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .sm-verify-header h3 {
        margin-left: 0;
        font-size: 1.2rem;
    }
    
    .sm-verify-button {
        width: 100%;
        padding: 18px;
        font-size: 14px;
        min-width: auto;
    }
    
    .sm-user-center {
        margin: 10px !important;
        max-width: none !important;
    }
    
    .sm-temp-notification {
        right: 10px;
        left: 10px;
        transform: translateY(-100%);
        max-width: none;
    }
    
    .sm-temp-notification.show {
        transform: translateY(0);
    }
}

/* 加载动画优化 */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.sm-loading-spinner::after {
    content: "";
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s linear infinite;
    margin-left: 10px;
    vertical-align: middle;
}

.sm-verify-button.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* 表单增强 */
.sm-form-field.invalid {
    border-color: #dc3545 !important;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* 平滑过渡 */
* {
    box-sizing: border-box;
}

.sm-verification-container *,
.sm-user-center * {
    transition: all 0.3s ease;
}

/* 深色模式适配 */
@media (prefers-color-scheme: dark) {
    .sm-verification-container,
    .sm-user-center {
        color: #e9ecef;
    }
    
    .sm-verification-warning {
        background: linear-gradient(135deg, #2d2000 0%, #3d3000 100%);
        border-color: #ffc107;
    }
    
    .sm-verification-warning h3,
    .sm-verification-warning p {
        color: #ffd43b;
    }
    
    .sm-verify-tips {
        background: linear-gradient(135deg, #001a2e 0%, #002a4e 100%);
        border-color: #1976d2;
    }
    
    .sm-verify-tips h4,
    .sm-verify-tips li {
        color: #64b5f6;
    }
    
    .sm-feature-preview {
        background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
        border-color: #444;
    }
    
    .sm-feature-preview h4,
    .sm-feature-preview li {
        color: #adb5bd;
    }
    
    .sm-verification-success {
        background: linear-gradient(135deg, #003d00 0%, #005d00 100%);
        border-color: #28a745;
        color: #4caf50;
    }
}

/* 特殊效果 */
.sm-verify-button:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 124, 186, 0.3);
}

/* 自定义滚动条 */
.sm-verify-tips::-webkit-scrollbar,
.sm-feature-preview::-webkit-scrollbar {
    width: 6px;
}

.sm-verify-tips::-webkit-scrollbar-track,
.sm-feature-preview::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 3px;
}

.sm-verify-tips::-webkit-scrollbar-thumb,
.sm-feature-preview::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.sm-verify-tips::-webkit-scrollbar-thumb:hover,
.sm-feature-preview::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

/* ==================== 用户组状态警告卡片 ==================== */

/* 警告卡片容器 */
.sm-group-status-warning {
    background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
    color: white;
    padding: 20px;
    margin: 20px 0;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
    animation: sm-warning-pulse 2s ease-in-out infinite alternate;
    position: relative;
    overflow: hidden;
}

/* 警告卡片内容布局 */
.sm-warning-content {
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
    z-index: 2;
}

/* 警告图标 */
.sm-warning-icon {
    font-size: 32px;
    line-height: 1;
    animation: sm-warning-shake 1s ease-in-out infinite;
}

/* 警告文字区域 */
.sm-warning-text h4 {
    margin: 0 0 5px 0;
    font-size: 18px;
    font-weight: bold;
    color: white;
}

.sm-warning-text p {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.4;
}

/* 背景动态效果 */
.sm-group-status-warning::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: sm-warning-shine 3s linear infinite;
    pointer-events: none;
}

/* 警告卡片动画效果 */
@keyframes sm-warning-pulse {
    0% {
        box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
        transform: translateY(0);
    }
    100% {
        box-shadow: 0 6px 20px rgba(255, 107, 107, 0.5);
        transform: translateY(-2px);
    }
}

@keyframes sm-warning-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    75% { transform: translateX(2px); }
}

@keyframes sm-warning-shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

/* ==================== 用户组状态徽章 ==================== */

/* 状态徽章基础样式 */
.sm-group-status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    line-height: 1;
    margin-left: 8px;
    vertical-align: middle;
}

/* 正常状态徽章 */
.sm-group-status-badge.sm-status-normal {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

/* 失效状态徽章 */
.sm-group-status-badge.sm-status-invalid {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    animation: sm-badge-blink 2s ease-in-out infinite;
}

@keyframes sm-badge-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ==================== 响应式设计 ==================== */

@media (max-width: 768px) {
    .sm-group-status-warning {
        padding: 15px;
        margin: 15px 0;
    }
    
    .sm-warning-content {
        gap: 12px;
    }
    
    .sm-warning-icon {
        font-size: 28px;
    }
    
    .sm-warning-text h4 {
        font-size: 16px;
    }
    
    .sm-warning-text p {
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .sm-group-status-warning {
        padding: 12px;
    }
    
    .sm-warning-content {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    
    .sm-warning-icon {
        font-size: 24px;
    }
    
    .sm-warning-text h4 {
        font-size: 15px;
    }
}

/* ==================== 无障碍访问支持 ==================== */

/* 为使用屏幕阅读器的用户提供支持 */
.sm-group-status-warning {
    role: alert;
    aria-live: polite;
}

/* 高对比度模式适配 */
@media (prefers-contrast: high) {
    .sm-group-status-warning {
        background: #c41e3a;
        border: 2px solid #ffffff;
    }
    
    .sm-group-status-badge.sm-status-invalid {
        background: #ffffff;
        color: #000000;
        border: 2px solid #c41e3a;
    }
}

/* 减少动画模式适配 */
@media (prefers-reduced-motion: reduce) {
    .sm-group-status-warning,
    .sm-warning-icon,
    .sm-group-status-badge.sm-status-invalid {
        animation: none;
    }
    
    .sm-group-status-warning::before {
        display: none;
    }
}

/* ==================== 打印样式 ==================== */

@media print {
    .sm-group-status-warning {
        background: #fff !important;
        color: #000 !important;
        border: 2px solid #000 !important;
        box-shadow: none !important;
        animation: none !important;
    }
    
    .sm-group-status-warning::before {
        display: none !important;
    }
    
    .sm-warning-text h4::after {
        content: " (重要提醒)";
    }
}

/* ==================== 与现有样式的兼容性 ==================== */

/* 确保在用户中心容器内正确显示 */
.sm-user-center .sm-group-status-warning {
    max-width: 100%;
    box-sizing: border-box;
}

/* 与状态卡片的间距协调 */
.sm-group-status-warning + .sm-status-card {
    margin-top: 15px;
}

.sm-status-card + .sm-group-status-warning {
    margin-top: 15px;
}

/* ==================== 验证按钮样式 ==================== */

.sm-verify-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--sm-primary-color) 0%, var(--sm-primary-dark) 100%);
    color: white !important;
    padding: 16px 32px;
    border: none;
    border-radius: var(--sm-border-radius);
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: var(--sm-transition);
    box-shadow: var(--sm-box-shadow);
    min-height: 56px;
    min-width: 200px;
    position: relative;
    overflow: hidden;
}

.sm-verify-button:hover {
    background: linear-gradient(135deg, var(--sm-primary-dark) 0%, #003d5c 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 115, 170, 0.3);
}

.sm-verify-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(0, 115, 170, 0.2);
}

.sm-verify-button:disabled {
    background: linear-gradient(135deg, #8c8f94 0%, #787c82 100%);
    cursor: not-allowed;
    transform: none;
    box-shadow: var(--sm-box-shadow);
}

.sm-verify-button .sm-loading-spinner {
    display: none;
}

.sm-verify-button:disabled .sm-loading-spinner {
    display: inline-block;
    animation: sm-spin 1s linear infinite;
}

@keyframes sm-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==================== 消息提示样式 ==================== */

.sm-verify-message {
    margin: 20px 0;
    padding: 15px;
    border-radius: var(--sm-border-radius);
    border-left: 4px solid transparent;
    font-size: 14px;
    line-height: 1.5;
    transition: var(--sm-transition);
}

.sm-message-success {
    background: linear-gradient(135deg, #d1f2d1 0%, #e8f5e8 100%);
    border-left-color: var(--sm-success-color);
    color: #155724;
}

.sm-message-error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border-left-color: var(--sm-error-color);
    color: #721c24;
}

.sm-message-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border-left-color: var(--sm-warning-color);
    color: #856404;
}

.sm-message-info {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    border-left-color: #17a2b8;
    color: #0c5460;
}

/* ==================== 用户欢迎头部 ==================== */

.sm-user-welcome {
    background: linear-gradient(135deg, #ff9800 0%, #f57c00 100%);
    color: white;
    padding: 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    text-align: center;
    box-shadow: 0 8px 25px rgba(255, 152, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.sm-user-welcome::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: sm-welcome-shimmer 3s ease-in-out infinite;
}

@keyframes sm-welcome-shimmer {
    0%, 100% { transform: scale(1) rotate(0deg); opacity: 0.5; }
    50% { transform: scale(1.1) rotate(180deg); opacity: 0.8; }
}

.sm-user-welcome h2 {
    margin: 0 0 10px 0;
    font-size: 1.8rem;
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.sm-user-welcome p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
    position: relative;
    z-index: 1;
}

/* ==================== 验证警告框 ==================== */

.sm-verification-warning {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.2);
    position: relative;
    overflow: hidden;
}

.sm-verification-warning::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    animation: sm-warning-sweep 2s ease-in-out infinite;
}

@keyframes sm-warning-sweep {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

.sm-verify-header {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.sm-verify-icon {
    font-size: 2rem;
    animation: sm-pulse 2s ease-in-out infinite;
}

@keyframes sm-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.sm-verify-header h3 {
    margin: 0;
    color: #856404;
    font-size: 1.4rem;
    font-weight: 600;
}

.sm-verification-warning p {
    margin: 10px 0;
    color: #856404;
    line-height: 1.6;
    position: relative;
    z-index: 1;
}

.sm-verify-actions {
    margin: 25px 0;
    text-align: center;
    position: relative;
    z-index: 1;
}

/* ==================== 功能预览和帮助 ==================== */

.sm-feature-preview,
.sm-verify-tips {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 1px solid var(--sm-border-color);
    border-radius: var(--sm-border-radius);
    padding: 25px;
    margin: 20px 0;
    box-shadow: var(--sm-box-shadow);
}

.sm-feature-preview h4,
.sm-verify-tips h4 {
    margin: 0 0 15px 0;
    color: var(--sm-text-color);
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sm-feature-preview ul,
.sm-verify-tips ul {
    margin: 0;
    padding-left: 20px;
    list-style: none;
}

.sm-feature-preview li,
.sm-verify-tips li {
    margin: 8px 0;
    color: var(--sm-text-light);
    line-height: 1.5;
    position: relative;
}

.sm-feature-preview li::before,
.sm-verify-tips li::before {
    content: '✓';
    position: absolute;
    left: -20px;
    color: var(--sm-success-color);
    font-weight: bold;
}

/* ==================== 临时通知 ==================== */

.sm-temp-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #333 0%, #444 100%);
    color: white;
    padding: 20px 25px;
    border-radius: 12px;
    z-index: 10000;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    max-width: 350px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    gap: 12px;
}

.sm-temp-notification.show {
    transform: translateX(0);
}

.sm-temp-notification::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(180deg, #00d4aa, #00a085);
    border-radius: 4px 0 0 4px;
}

.sm-temp-notification.sm-temp-success::before {
    background: linear-gradient(180deg, var(--sm-success-color), #007a1f);
}

.sm-temp-notification.sm-temp-error::before {
    background: linear-gradient(180deg, var(--sm-error-color), #a72b2d);
}

.sm-temp-notification.sm-temp-warning::before {
    background: linear-gradient(180deg, var(--sm-warning-color), #b8940e);
}

.sm-notification-icon {
    font-size: 1.2rem;
    animation: sm-icon-bounce 0.6s ease-out;
}

@keyframes sm-icon-bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-8px); }
    60% { transform: translateY(-4px); }
}

.sm-notification-message {
    flex: 1;
    font-weight: 500;
    line-height: 1.4;
}

/* ==================== 验证容器 ==================== */

.sm-verification-container {
    max-width: 600px;
    margin: 20px auto;
    padding: 0 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ==================== 进度条 ==================== */

.sm-progress-container {
    width: 100%;
    height: 4px;
    background-color: #f0f0f1;
    border-radius: 2px;
    overflow: hidden;
    margin: 15px 0;
}

.sm-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--sm-primary-color), var(--sm-primary-dark));
    border-radius: 2px;
    transition: width 0.3s ease;
    width: 0%;
}

/* ==================== 重发计数器 ==================== */

.sm-resend-counter {
    margin-top: 15px;
    padding: 10px;
    background: rgba(0, 115, 170, 0.1);
    border-radius: var(--sm-border-radius);
    text-align: center;
    font-size: 14px;
    color: var(--sm-primary-color);
    border: 1px solid rgba(0, 115, 170, 0.2);
}

.sm-resend-counter.sm-limit-reached {
    background: rgba(214, 54, 56, 0.1);
    color: var(--sm-error-color);
    border-color: rgba(214, 54, 56, 0.2);
}

/* ==================== 用户中心内容 ==================== */

.user-center-content {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: var(--sm-box-shadow);
    margin: 20px 0;
}

.subscription-info {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 1px solid var(--sm-border-color);
    border-radius: var(--sm-border-radius);
    padding: 25px;
    margin: 20px 0;
}

.subscription-info h3 {
    margin: 0 0 20px 0;
    color: var(--sm-text-color);
    font-size: 1.4rem;
    font-weight: 600;
    border-bottom: 2px solid var(--sm-primary-color);
    padding-bottom: 10px;
}

.subscription-info p {
    margin: 12px 0;
    color: var(--sm-text-light);
    line-height: 1.6;
}

.subscription-info strong {
    color: var(--sm-text-color);
    font-weight: 600;
}

/* ==================== 表单增强 ==================== */

.sm-form {
    background: white;
    border-radius: var(--sm-border-radius);
    padding: 30px;
    box-shadow: var(--sm-box-shadow);
}

.sm-form input,
.sm-form textarea,
.sm-form select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--sm-border-color);
    border-radius: var(--sm-border-radius);
    font-size: 16px;
    transition: var(--sm-transition);
    background: white;
}

.sm-form input:focus,
.sm-form textarea:focus,
.sm-form select:focus {
    outline: none;
    border-color: var(--sm-primary-color);
    box-shadow: 0 0 0 3px rgba(0, 115, 170, 0.1);
}

.sm-form input.sm-invalid,
.sm-form textarea.sm-invalid,
.sm-form select.sm-invalid {
    border-color: var(--sm-error-color);
    box-shadow: 0 0 0 3px rgba(214, 54, 56, 0.1);
}

.sm-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--sm-text-color);
}

/* ==================== 功能切换按钮 ==================== */

.sm-feature-toggle {
    display: inline-flex;
    align-items: center;
    padding: 8px 16px;
    border: 2px solid var(--sm-border-color);
    border-radius: 20px;
    background: white;
    cursor: pointer;
    transition: var(--sm-transition);
    font-size: 14px;
    font-weight: 500;
}

.sm-feature-toggle.enabled {
    background: var(--sm-success-color);
    border-color: var(--sm-success-color);
    color: white;
}

.sm-feature-toggle:hover {
    border-color: var(--sm-primary-color);
    transform: translateY(-1px);
}

/* ==================== 刷新按钮 ==================== */

.sm-refresh-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    color: white;
    border: none;
    border-radius: var(--sm-border-radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--sm-transition);
    text-decoration: none;
}

.sm-refresh-btn:hover {
    background: linear-gradient(135deg, #5a6268 0%, #4e555b 100%);
    transform: translateY(-1px);
}

.sm-refresh-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* ==================== 关闭按钮 ==================== */

.sm-close-banner {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(0, 0, 0, 0.1);
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--sm-transition);
    font-size: 18px;
    line-height: 1;
}

.sm-close-banner:hover {
    background: rgba(0, 0, 0, 0.2);
    transform: scale(1.1);
}

/* ==================== 组状态徽章 ==================== */

.sm-group-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sm-status-normal {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border: 1px solid #c3e6cb;
}

.sm-status-invalid {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ==================== 响应式设计 ==================== */

@media (max-width: 768px) {
    .sm-verification-container {
        margin: 10px;
        max-width: none;
        padding: 0 15px;
    }
    
    .sm-user-welcome {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .sm-user-welcome h2 {
        font-size: 1.5rem;
    }
    
    .sm-verification-warning {
        padding: 20px;
    }
    
    .sm-verify-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .sm-verify-header h3 {
        margin-left: 0;
        font-size: 1.2rem;
    }
    
    .sm-verify-button {
        width: 100%;
        padding: 18px;
        font-size: 14px;
        min-height: 52px;
    }
    
    .sm-temp-notification {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        transform: translateY(-100%);
    }
    
    .sm-temp-notification.show {
        transform: translateY(0);
    }
    
    .sm-feature-preview,
    .sm-verify-tips {
        padding: 20px;
    }
    
    .user-center-content,
    .subscription-info {
        padding: 20px;
        margin: 15px 0;
    }
}

@media (max-width: 480px) {
    .sm-verification-container {
        padding: 0 10px;
    }
    
    .sm-user-welcome,
    .sm-verification-warning,
    .sm-feature-preview,
    .sm-verify-tips {
        padding: 15px;
    }
    
    .sm-verify-button {
        padding: 16px;
        font-size: 14px;
    }
    
    .sm-verify-header h3 {
        font-size: 1.1rem;
    }
}

/* ==================== 触摸设备优化 ==================== */

@media (hover: none) and (pointer: coarse) {
    .sm-verify-button,
    .sm-feature-toggle,
    .sm-refresh-btn {
        min-height: 44px;
        padding: 12px 20px;
    }
    
    .sm-touched {
        opacity: 0.8;
        transform: scale(0.98);
    }
    
    .sm-close-banner {
        min-width: 44px;
        min-height: 44px;
    }
}

/* ==================== 打印样式 ==================== */

@media print {
    .sm-temp-notification,
    .sm-verify-button,
    .sm-refresh-btn {
        display: none !important;
    }
    
    .sm-verification-container {
        box-shadow: none;
        border: 1px solid #ddd;
    }
    
    .sm-user-welcome,
    .sm-verification-warning {
        background: white !important;
        border: 1px solid #ddd;
        color: #333 !important;
    }
}

/* ==================== 动画性能优化 ==================== */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ==================== 高对比度模式 ==================== */

@media (prefers-contrast: high) {
    :root {
        --sm-primary-color: #0066cc;
        --sm-primary-dark: #004499;
        --sm-success-color: #008800;
        --sm-error-color: #cc0000;
        --sm-warning-color: #cc8800;
        --sm-text-color: #000000;
        --sm-border-color: #666666;
    }
    
    .sm-verify-button,
    .sm-refresh-btn {
        border: 2px solid currentColor;
    }
    
    .sm-temp-notification {
        border: 2px solid white;
    }
}

/* ==================== 暗色模式 ==================== */

@media (prefers-color-scheme: dark) {
    :root {
        --sm-text-color: #ffffff;
        --sm-text-light: #cccccc;
        --sm-border-color: #444444;
        --sm-box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    }
    
    .sm-verification-container {
        background: #1a1a1a;
        color: var(--sm-text-color);
    }
    
    .user-center-content,
    .subscription-info,
    .sm-form {
        background: #2d2d2d;
        border-color: var(--sm-border-color);
    }
    
    .sm-form input,
    .sm-form textarea,
    .sm-form select {
        background: #3d3d3d;
        border-color: var(--sm-border-color);
        color: var(--sm-text-color);
    }
    
    .sm-feature-preview,
    .sm-verify-tips {
        background: linear-gradient(135deg, #2d2d2d 0%, #3d3d3d 100%);
        border-color: var(--sm-border-color);
    }
}

/* ==================== 无障碍访问 ==================== */

.sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* 焦点指示器 */
.sm-verify-button:focus,
.sm-feature-toggle:focus,
.sm-refresh-btn:focus,
.sm-close-banner:focus {
    outline: 3px solid var(--sm-primary-color);
    outline-offset: 2px;
}

/* 确保充足的颜色对比度 */
.sm-message-success,
.sm-message-error,
.sm-message-warning,
.sm-message-info {
    font-weight: 500;
}

/* ==================== 兼容性修复 ==================== */

/* IE11 支持 */
@media screen and (-ms-high-contrast: active), screen and (-ms-high-contrast: none) {
    .sm-verify-button {
        display: block;
        text-align: center;
    }
    
    .sm-temp-notification {
        position: fixed;
        top: 20px;
        right: 20px;
    }
}

/* Safari 修复 */
@supports (-webkit-appearance: none) {
    .sm-verify-button {
        -webkit-appearance: none;
    }
    
    .sm-form input,
    .sm-form textarea,
    .sm-form select {
        -webkit-appearance: none;
    }
}

/* Firefox 修复 */
@-moz-document url-prefix() {
    .sm-verify-button {
        -moz-appearance: none;
    }
}

/* ==================== 加载状态 ==================== */

.sm-loading {
    opacity: 0.7;
    pointer-events: none;
    position: relative;
}

.sm-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid var(--sm-primary-color);
    border-radius: 50%;
    animation: sm-spin 1s linear infinite;
}

/* ==================== 工具提示 ==================== */

[data-tooltip] {
    position: relative;
    cursor: help;
}

[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #333;
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 1000;
    margin-bottom: 5px;
}

[data-tooltip]:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
    z-index: 1000;
}

/* === 基础样式重置 === */
.sm-balance-widget *,
.sm-leader-panel *,
.sm-balance-logs * {
    box-sizing: border-box;
}

/* === 余额小部件样式 === */
.sm-balance-widget {
    background: #ffffff;
    border: 1px solid #e1e5e9;
    border-radius: 12px;
    padding: 24px;
    margin: 20px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    transition: box-shadow 0.3s ease;
}

.sm-balance-widget:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.sm-balance-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f8f9fa;
}

.sm-balance-header h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 20px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sm-balance-amount {
    font-size: 28px;
    font-weight: 700;
    color: #27ae60;
    font-family: 'Courier New', Monaco, monospace;
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 2px 4px rgba(39, 174, 96, 0.2);
}

.sm-balance-actions {
    margin: 20px 0;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.sm-leader-section {
    border-top: 1px solid #eee;
    padding-top: 20px;
    margin-top: 20px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 8px;
    padding: 16px;
}

.sm-leader-section h4 {
    margin: 0 0 12px 0;
    color: #8e44ad;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* === 按钮样式 === */
.sm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    background: none;
    position: relative;
    overflow: hidden;
}

.sm-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.sm-btn:hover::before {
    left: 100%;
}

.sm-btn-primary {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.3);
}

.sm-btn-primary:hover {
    background: linear-gradient(135deg, #2980b9, #21618c);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
}

.sm-btn-outline {
    background: transparent;
    border: 2px solid #3498db;
    color: #3498db;
}

.sm-btn-outline:hover {
    background: #3498db;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

.sm-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* === 余额日志样式 === */
.sm-balance-logs {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 2px solid #eee;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sm-balance-logs h4 {
    margin: 0 0 16px 0;
    color: #2c3e50;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sm-logs-list {
    max-height: 500px;
    overflow-y: auto;
    padding-right: 8px;
}

.sm-logs-list::-webkit-scrollbar {
    width: 6px;
}

.sm-logs-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.sm-logs-list::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.sm-logs-list::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.sm-log-item {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
    position: relative;
}

.sm-log-item:hover {
    background: #ffffff;
    border-color: #3498db;
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.1);
    transform: translateX(4px);
}

.sm-log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.sm-log-date {
    color: #6c757d;
    font-size: 12px;
    font-weight: 500;
    background: #e9ecef;
    padding: 2px 8px;
    border-radius: 4px;
}

.sm-log-amount {
    font-weight: 700;
    font-family: 'Courier New', Monaco, monospace;
    font-size: 16px;
    padding: 4px 8px;
    border-radius: 4px;
}

.sm-amount-add {
    color: #27ae60;
    background: rgba(39, 174, 96, 0.1);
}

.sm-amount-subtract {
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
}

.sm-amount-set {
    color: #3498db;
    background: rgba(52, 152, 219, 0.1);
}

.sm-log-content {
    border-top: 1px solid #eee;
    padding-top: 10px;
}

.sm-log-action {
    font-weight: 600;
    color: #495057;
    margin-bottom: 6px;
}

.sm-log-note {
    color: #6c757d;
    font-size: 13px;
    margin: 6px 0;
    font-style: italic;
    line-height: 1.4;
}

.sm-log-balance {
    color: #27ae60;
    font-size: 12px;
    font-weight: 600;
    background: rgba(39, 174, 96, 0.1);
    padding: 2px 6px;
    border-radius: 3px;
    display: inline-block;
}

.sm-logs-pagination {
    text-align: center;
    margin-top: 20px;
}

/* === 组长面板样式 === */
.sm-leader-panel {
    background: #ffffff;
    border: 1px solid #e1e5e9;
    border-radius: 12px;
    padding: 24px;
    margin: 20px 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.sm-leader-panel h3 {
    margin: 0 0 20px 0;
    color: #8e44ad;
    font-size: 22px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    border-bottom: 2px solid #f8f9fa;
    padding-bottom: 12px;
}

.sm-group-tabs {
    display: flex;
    margin-bottom: 24px;
    border-bottom: 2px solid #dee2e6;
    overflow-x: auto;
    gap: 4px;
}

.sm-group-tab {
    padding: 12px 20px;
    border: none;
    background: none;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    color: #6c757d;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.3s ease;
    border-radius: 6px 6px 0 0;
}

.sm-group-tab.active,
.sm-group-tab:hover {
    color: #495057;
    border-bottom-color: #8e44ad;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
}

.sm-group-content {
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.sm-group-members-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.sm-member-card {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.sm-member-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #3498db, #8e44ad);
    transition: width 0.3s ease;
}

.sm-member-card:hover {
    background: #ffffff;
    border-color: #3498db;
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.15);
    transform: translateY(-2px);
}

.sm-member-card:hover::before {
    width: 8px;
}

.sm-member-info {
    margin-bottom: 8px;
}

.sm-member-info strong {
    display: block;
    color: #2c3e50;
    font-size: 16px;
    margin-bottom: 4px;
}

.sm-member-info span {
    color: #6c757d;
    font-size: 13px;
}

.sm-leader-badge {
    background: linear-gradient(135deg, #ffc107, #fd7e14);
    color: #212529;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: bold;
    margin-left: 8px;
    display: inline-block;
    box-shadow: 0 2px 4px rgba(255, 193, 7, 0.3);
}

.sm-member-balance {
    color: #27ae60;
    font-weight: 600;
    font-family: 'Courier New', Monaco, monospace;
    background: rgba(39, 174, 96, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
    display: inline-block;
}

/* === 表单样式 === */
.sm-balance-form {
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.sm-balance-form h4 {
    margin: 0 0 16px 0;
    color: #495057;
    font-size: 16px;
    font-weight: 600;
    border-bottom: 1px solid #dee2e6;
    padding-bottom: 8px;
}

.sm-form-row {
    margin-bottom: 16px;
}

.sm-form-row label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    color: #495057;
    font-size: 14px;
}

.sm-form-row input,
.sm-form-row select,
.sm-form-row textarea {
    width: 100%;
    padding: 10px 12px;
    border: 2px solid #ced4da;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #ffffff;
}

.sm-form-row input:focus,
.sm-form-row select:focus,
.sm-form-row textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
    background: #ffffff;
}

.sm-form-row textarea {
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
}

.sm-form-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

/* === 状态样式 === */
.sm-loading {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
    font-style: italic;
}

.sm-loading::before {
    content: '⏳';
    display: block;
    font-size: 24px;
    margin-bottom: 8px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.sm-no-logs {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.sm-no-logs::before {
    content: '📄';
    display: block;
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.sm-balance-error {
    color: #721c24;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 12px 16px;
    border-radius: 6px;
    margin: 12px 0;
    font-weight: 500;
}

.sm-balance-error::before {
    content: '⚠️';
    margin-right: 8px;
}

/* === 响应式设计 === */
@media (max-width: 768px) {
    .sm-balance-widget,
    .sm-leader-panel {
        padding: 16px;
        margin: 16px 0;
    }
    
    .sm-balance-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        text-align: left;
    }
    
    .sm-balance-amount {
        font-size: 24px;
    }
    
    .sm-group-tabs {
        flex-direction: column;
        border-bottom: none;
        border-right: 2px solid #dee2e6;
    }
    
    .sm-group-tab {
        border-bottom: none;
        border-right: 3px solid transparent;
        text-align: left;
        border-radius: 0 6px 6px 0;
    }
    
    .sm-group-tab.active,
    .sm-group-tab:hover {
        border-right-color: #8e44ad;
        border-bottom-color: transparent;
    }
    
    .sm-group-members-list {
        grid-template-columns: 1fr;
    }
    
    .sm-form-actions {
        flex-direction: column;
    }
    
    .sm-btn {
        justify-content: center;
    }
    
    .sm-balance-actions {
        flex-direction: column;
    }
    
    .sm-log-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
}

@media (max-width: 480px) {
    .sm-balance-widget,
    .sm-leader-panel {
        padding: 12px;
        margin: 12px 0;
        border-radius: 8px;
    }
    
    .sm-balance-header h3 {
        font-size: 18px;
    }
    
    .sm-balance-amount {
        font-size: 20px;
    }
    
    .sm-log-item {
        padding: 12px;
    }
    
    .sm-member-card {
        padding: 12px;
    }
    
    .sm-balance-form {
        padding: 16px;
    }
}

/* === 动画增强 === */
.sm-balance-widget,
.sm-leader-panel,
.sm-log-item,
.sm-member-card {
    animation: slideInUp 0.6s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === 辅助工具类 === */
.sm-text-center { text-align: center; }
.sm-text-left { text-align: left; }
.sm-text-right { text-align: right; }

.sm-mt-1 { margin-top: 8px; }
.sm-mt-2 { margin-top: 16px; }
.sm-mt-3 { margin-top: 24px; }

.sm-mb-1 { margin-bottom: 8px; }
.sm-mb-2 { margin-bottom: 16px; }
.sm-mb-3 { margin-bottom: 24px; }

.sm-p-1 { padding: 8px; }
.sm-p-2 { padding: 16px; }
.sm-p-3 { padding: 24px; }

.sm-hidden { display: none !important; }
.sm-visible { display: block !important; }

/* === 打印样式 === */
@media print {
    .sm-balance-widget,
    .sm-leader-panel {
        box-shadow: none;
        border: 1px solid #000;
        background: #fff !important;
    }
    
    .sm-btn {
        display: none;
    }
    
    .sm-balance-actions,
    .sm-form-actions {
        display: none;
    }
    
    .sm-log-item {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}