/* 管理系统 - 主样式 */
/* ===== 全局强制不透明背景（任何浏览器/设备都生效） ===== */
html {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    margin: 0;
    padding: 0;
}

body {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    background-image: none !important;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    opacity: 1 !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    -moz-backdrop-filter: none !important;
    -ms-backdrop-filter: none !important;
}

.layout, .main-content, .content {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    background-image: none !important;
}

.sidebar {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

.header {
    background-color: #1a1a2e !important;
    background: #1a1a2e !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.card, .card-body {
    background-color: #1e1e3a !important;
    background: #1e1e3a !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    opacity: 1 !important;
}

/* 深色模式兜底：在JS执行前防止闪白 - 所有设备默认深色 */
html {
    background: #0f0f1a;
}
.login-page {
    background: linear-gradient(135deg, #0f0f1a 0%, #1a1a3e 100%);
}

:root {
    color-scheme: dark;
    --primary-color: #818cf8;
    --primary-dark: #6366f1;
    --secondary-color: #764ba2;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #3b82f6;
    --text-primary: #f3f4f6;
    --text-secondary: #9ca3af;
    --text-light: #6b7280;
    --text-tertiary: #6b7280;
    --bg-primary: #0f0f1a;
    --bg-white: #1a1a2e;
    --bg-card: #1e1e3a;
    --bg-input: #15152b;
    --bg-active: #2a1a3e;
    --bg-sidebar: #0f0f1a;
    --bg-sidebar-hover: #1e1e3a;
    --border-color: #2d2d4a;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.5), 0 4px 6px -2px rgba(0, 0, 0, 0.4);
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;
    --sidebar-width: 220px;
    --header-height: 54px;
}

/* 浅色模式变量定义（用户主动选择时才生效） */
html body.theme-light {
    color-scheme: light;
    --primary-color: #667eea;
    --primary-dark: #5568d3;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --text-light: #9ca3af;
    --text-tertiary: #9ca3af;
    --bg-primary: #f5f7fa;
    --bg-white: #ffffff;
    --bg-card: #ffffff;
    --bg-input: #f5f5f5;
    --bg-active: #e8e0ff;
    --bg-sidebar: #1f2937;
    --bg-sidebar-hover: #374151;
    --border-color: #e5e7eb;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* 深色模式（保持兼容） */
html body.theme-dark {
    color-scheme: dark;
}

/* ===== 主题选择页面 ===== */
.theme-select-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.theme-select-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 16px 12px;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid transparent;
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.theme-select-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}

.theme-select-card.active {
    border-color: var(--primary-color);
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.25);
}

.theme-select-card.active .theme-select-check {
    opacity: 1;
    transform: scale(1);
}

.theme-select-check {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--primary-color);
    color: #fff;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.3s;
    font-weight: bold;
}

.theme-select-preview {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 8px 0;
}

.theme-select-device {
    width: 70px;
    height: 100px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
}

.theme-device-light {
    background: #f0f2f5;
}

.theme-device-dark {
    background: #0f0f1a;
    border-color: rgba(255, 255, 255, 0.1);
}

.theme-device-white {
    background: #ffffff;
    border-color: #e5e7eb;
}

.theme-select-statusbar {
    height: 8px;
    background: rgba(0, 0, 0, 0.08);
}

.theme-device-dark .theme-select-statusbar {
    background: rgba(255, 255, 255, 0.1);
}

.theme-select-nav {
    height: 14px;
    background: #667eea;
    flex-shrink: 0;
}

.theme-nav-dark { background: #1e1e3a; }
.theme-nav-white { background: #f8fafc; }

.theme-select-body {
    flex: 1;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.theme-body-dark {
    background: #0f0f1a;
}
.theme-body-dark::before {
    display: none;
}
.theme-body-white {
    background: #f5f7fa;
}
.theme-body-white::before {
    display: none;
}

.theme-select-card-light {
    height: 12px;
    background: #fff;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.theme-select-card-dark {
    height: 12px;
    background: #1e1e3a;
    border-radius: 4px;
}

.theme-select-card-white {
    height: 12px;
    background: #f8fafc;
    border-radius: 4px;
    border: 1px solid #e5e7eb;
}

.theme-select-info {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
}

.theme-select-icon {
    font-size: 20px;
    margin-bottom: 2px;
}

.theme-select-name {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
}

.theme-select-desc {
    font-size: 11px;
    color: var(--text-secondary);
    line-height: 1.3;
}

/* 使用说明 */
.theme-tips {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.theme-tip-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.theme-tip-icon {
    font-size: 22px;
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1), rgba(118, 75, 162, 0.1));
    border-radius: 10px;
}

.theme-tip-item strong {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 3px;
}

.theme-tip-item p {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 0;
}

/* 深色模式下的主题卡片适配 */
body.theme-dark .theme-select-card {
    background: #1e1e3a;
    border-color: transparent;
}

body.theme-dark .theme-select-card.active {
    border-color: #818cf8;
}

body.theme-dark .theme-tip-icon {
    background: rgba(129, 140, 248, 0.15);
}

@media (max-width: 480px) {
    .theme-select-grid {
        gap: 8px;
    }
    .theme-select-card {
        padding: 12px 8px;
        border-radius: 14px;
    }
    .theme-select-device {
        width: 56px;
        height: 80px;
    }
    .theme-select-name {
        font-size: 12px;
    }
    .theme-select-desc {
        font-size: 10px;
    }
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Noto Sans CJK SC", "WenQuanYi Micro Hei", sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    font-size: 13px;
    line-height: 1.5;
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--primary-dark);
}

/* 登录页面 */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.login-container {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    width: 100%;
    max-width: 380px;
    padding: 32px;
}

.login-header {
    text-align: center;
    margin-bottom: 24px;
}

.login-header .logo {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 14px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    font-weight: bold;
}

.login-header h1 {
    font-size: 20px;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 13px;
}

.login-form .form-group {
    margin-bottom: 16px;
}

.login-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 13px;
}

.login-form input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 13px;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.login-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.login-btn {
    width: 100%;
    padding: 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.login-btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

/* 主布局 */
.layout {
    display: flex;
    min-height: 100vh;
    position: relative;
    z-index: 1;
}

/* 侧边栏 */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    color: white;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 100;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    will-change: width;
}

.sidebar::-webkit-scrollbar {
    width: 5px;
}

.sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 3px;
}

.sidebar-logo {
    padding: 16px 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.sidebar-logo .logo-icon {
    width: 34px;
    height: 34px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: bold;
}

.sidebar-logo .logo-text {
    font-size: 16px;
    font-weight: 600;
}

.sidebar-menu {
    padding: 8px 0 4px 0;
    flex: 1;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
    font-size: 13px;
    text-decoration: none;
}

.menu-item:hover {
    background: var(--bg-sidebar-hover);
    color: white;
}

.menu-item.active {
    background: var(--bg-sidebar-hover);
    color: white;
    border-left-color: var(--primary-color);
}

.menu-parent {
    user-select: none;
}

.menu-item .menu-icon {
    font-size: 16px;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
}

.menu-item .menu-text {
    flex: 1;
}

.menu-item .menu-arrow {
    font-size: 10px;
    transition: transform 0.2s;
    opacity: 0.6;
    flex-shrink: 0;
}

.menu-item .menu-arrow.rotate {
    transform: rotate(180deg);
}

.submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: rgba(0, 0, 0, 0.25);
}

.submenu.open {
    max-height: 500px;
}

.submenu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 18px 8px 48px;
    color: rgba(255, 255, 255, 0.55);
    font-size: 12.5px;
    transition: all 0.2s;
    text-decoration: none;
}

.submenu-item:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.submenu-item.active {
    color: var(--primary-color);
    background: rgba(102, 126, 234, 0.12);
}

.submenu-item .submenu-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    flex-shrink: 0;
}

.submenu-item.active .submenu-dot {
    background: var(--primary-color);
}

.sidebar-footer {
    padding: 10px 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
    flex-shrink: 0;
}

.sidebar-toggle-btn {
    width: 100%;
    padding: 8px 6px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.sidebar-toggle-btn:hover,
.sidebar-toggle-btn:active {
    background: rgba(255, 255, 255, 0.15);
    color: white;
}

.sidebar-toggle-btn .toggle-icon {
    transition: transform 0.3s;
    display: inline-block;
    font-weight: bold;
}

.sidebar-version {
    font-size: 10.5px;
    color: rgba(255, 255, 255, 0.4);
    line-height: 1.4;
}

/* 侧边栏收缩状态 */
.sidebar.collapsed {
    width: 70px;
}

.sidebar.collapsed .sidebar-logo {
    padding: 14px 10px;
    justify-content: center;
}

.sidebar.collapsed .sidebar-logo .logo-icon {
    width: 36px;
    height: 36px;
    font-size: 16px;
}

.sidebar.collapsed .sidebar-logo .logo-text {
    display: none;
}

.sidebar.collapsed .menu-item {
    padding: 12px 10px;
    justify-content: center;
}

.sidebar.collapsed .menu-item .menu-icon {
    font-size: 18px;
    width: auto;
}

.sidebar.collapsed .menu-item .menu-text {
    display: none;
}

.sidebar.collapsed .menu-item .menu-arrow {
    display: none;
}

.sidebar.collapsed .submenu {
    display: none;
}

.sidebar.collapsed .sidebar-toggle-btn .toggle-icon {
    transform: rotate(180deg);
}

.sidebar.collapsed .sidebar-version {
    display: none;
}

.sidebar.collapsed .sidebar-toggle-btn {
    margin-bottom: 0;
}

/* 主内容区 */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left 0.3s ease;
}

/* 无侧边栏全屏模式 */
.main-content.full-width {
    margin-left: 0;
    width: 100%;
}

/* 侧边栏收缩状态 - 主内容区跟随调整 */
.main-content.sidebar-collapsed {
    margin-left: 70px;
}

/* 顶部导航 */
.header {
    height: var(--header-height);
    background: var(--bg-white);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    position: sticky;
    top: 0;
    z-index: 50;
    flex-shrink: 0;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* 顶部侧边栏切换按钮 */
.sidebar-toggle-header-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.sidebar-toggle-header-btn:hover {
    background: #e5e7eb;
    border-color: #d1d5db;
}

.sidebar-toggle-header-btn:active {
    transform: scale(0.95);
}

.sidebar-toggle-header-btn .toggle-lines {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
}

.sidebar-toggle-header-btn .toggle-lines span {
    display: block;
    width: 22px;
    height: 2.5px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* 收缩状态下按钮变成X */
.sidebar.collapsed ~ .main-content .sidebar-toggle-header-btn .toggle-lines span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.sidebar.collapsed ~ .main-content .sidebar-toggle-header-btn .toggle-lines span:nth-child(2) {
    opacity: 0;
}

.sidebar.collapsed ~ .main-content .sidebar-toggle-header-btn .toggle-lines span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: var(--text-primary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
}

.mobile-menu-btn:hover {
    background: var(--bg-primary);
}

/* 返回按钮 */
.back-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    text-decoration: none;
    color: var(--text-primary);
    font-size: 18px;
    font-weight: bold;
    transition: all 0.2s;
    flex-shrink: 0;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.back-btn:hover {
    background: #e5e7eb;
    transform: translateX(-2px);
}

.back-btn:active {
    transform: scale(0.95);
}

/* 首页logo */
.home-logo {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    font-weight: bold;
    flex-shrink: 0;
}

.header-title {
    font-size: 16px;
    font-weight: 600;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-link {
    color: var(--text-secondary);
    font-size: 12px;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    transition: all 0.2s;
}

.header-link:hover {
    background: var(--bg-primary);
    color: var(--text-primary);
}

.admin-info {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    transition: background 0.2s;
}

.admin-info:hover {
    background: var(--bg-primary);
}

.admin-avatar {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
    font-weight: 600;
}

.admin-name {
    font-size: 13px;
    font-weight: 500;
}

/* 内容区 */
.content {
    flex: 1;
    padding: 20px;
}

.page-header {
    margin-bottom: 18px;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 3px;
}

.page-desc {
    color: var(--text-secondary);
    font-size: 12.5px;
}

/* 卡片 */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: 16px;
}

.card-header {
    padding: 12px 16px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.card-title {
    font-size: 14px;
    font-weight: 600;
}

.card-body {
    padding: 16px;
}

.card-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-color);
    background: #f9fafb;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

/* 统计卡片 */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    padding: 16px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.stat-icon.primary {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
}

.stat-icon.success {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.stat-icon.warning {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.stat-icon.danger {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger-color);
}

.stat-info .stat-value {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 2px;
}

.stat-info .stat-label {
    color: var(--text-secondary);
    font-size: 12px;
}

/* 按钮 */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 10px 18px;
    border: none;
    border-radius: 14px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    line-height: 1.4;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    color: white;
}

.btn-success {
    background: var(--success-color);
    color: white;
}

.btn-success:hover {
    background: #059669;
    color: white;
}

.btn-warning {
    background: var(--warning-color);
    color: white;
}

.btn-warning:hover {
    background: #d97706;
    color: white;
}

.btn-danger {
    background: var(--danger-color);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    color: white;
}

.btn-secondary {
    background: var(--text-secondary);
    color: white;
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover {
    background: var(--bg-primary);
    border-color: var(--text-light);
}

.btn-sm {
    padding: 3px 8px;
    font-size: 11.5px;
}

.btn-lg {
    padding: 10px 20px;
    font-size: 14px;
}

/* 表单 */
.form-group {
    margin-bottom: 16px;
}

.form-label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 12.5px;
}

.form-label .required {
    color: var(--danger-color);
    margin-left: 3px;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 14px;
    font-size: 14px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: inherit;
    box-sizing: border-box;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-textarea {
    min-height: 80px;
    resize: vertical;
}

.form-row {
    display: flex;
    gap: 14px;
}

.form-row .form-group {
    flex: 1;
}

.form-hint {
    font-size: 11.5px;
    color: var(--text-light);
    margin-top: 5px;
    line-height: 1.5;
}

/* 开关 */
.switch {
    position: relative;
    display: inline-block;
    width: 42px;
    height: 22px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 22px;
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.switch input:checked + .switch-slider {
    background-color: var(--primary-color);
}

.switch input:checked + .switch-slider:before {
    transform: translateX(20px);
}

/* 表格 */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-md);
}

.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.data-table th,
.data-table td {
    padding: 10px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
    font-size: 12.5px;
}

.data-table th {
    background: #f9fafb;
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 12px;
    white-space: nowrap;
    border-bottom: 2px solid var(--border-color);
}

.data-table tbody tr {
    transition: background 0.15s;
}

.data-table tbody tr:hover {
    background: #f9fafb;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.data-table td img {
    max-width: 42px;
    max-height: 42px;
    border-radius: var(--radius-sm);
    object-fit: cover;
}

.table-actions {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

/* 状态标签 */
.status-badge {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
    line-height: 1.6;
}

.status-active {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success-color);
}

.status-pending {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning-color);
}

.status-disabled {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger-color);
}

.status-used {
    background: rgba(107, 114, 128, 0.1);
    color: var(--text-secondary);
}

/* 分页 */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 16px;
}

.page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 30px;
    padding: 0 10px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    text-decoration: none;
    font-size: 12px;
    transition: all 0.2s;
}

.page-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.page-btn.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.page-ellipsis {
    padding: 0 6px;
    color: var(--text-light);
    font-size: 12px;
}

/* 提示消息 */
.alert {
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    color: #065f46;
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    color: #991b1b;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #92400e;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.alert-info {
    background: rgba(59, 130, 246, 0.1);
    color: #1e40af;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

/* 模态框 */
.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay.show {
    display: flex;
}

.modal {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 460px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 15px;
    font-weight: 600;
}

.modal-close {
    background: none;
    border: none;
    font-size: 22px;
    color: var(--text-light);
    cursor: pointer;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 12px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* 搜索栏 */
.search-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.search-bar .form-group {
    margin-bottom: 0;
    flex: 1;
    min-width: 160px;
}

/* 工具栏 */
.toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 10px;
}

/* 文件上传区域 */
.upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 28px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
}

.upload-area:hover {
    border-color: var(--primary-color);
    background: rgba(102, 126, 234, 0.02);
}

.upload-area .upload-icon {
    font-size: 36px;
    color: var(--text-light);
    margin-bottom: 8px;
}

.upload-area .upload-text {
    color: var(--text-secondary);
    margin-bottom: 4px;
    font-size: 13px;
}

.upload-area .upload-hint {
    color: var(--text-light);
    font-size: 11.5px;
}

.upload-preview {
    margin-top: 10px;
    display: inline-block;
}

.upload-preview img {
    max-width: 100%;
    border-radius: var(--radius-sm);
    max-height: 100px;
}

/* 网格布局 */
.grid {
    display: grid;
    gap: 16px;
}

.grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

/* ========================================
   控制台首页 - 图标网格导航
   ======================================== */

.dashboard-home {
    padding: 2px 0 16px;
}

/* ===== 顶部信息卡片：时钟/天气/节日（紫蓝渐变 + 波浪装饰）===== */
.info-strip-card {
    background: linear-gradient(135deg, #8B5CF6 0%, #3B82F6 100%);
    border-radius: 28px;
    padding: 28px 26px;
    margin-bottom: 14px;
    box-shadow: 0 10px 36px rgba(139,92,246,0.38);
    color: #fff;
    display: flex;
    flex-direction: column;
    gap: 16px;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: default;
}
/* 光晕装饰 - 右上角柔光 */
.info-strip-card::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -20%;
    width: 50%;
    height: 180%;
    background: radial-gradient(ellipse at center, rgba(255,255,255,0.12), transparent 70%);
    pointer-events: none;
}
/* 波浪曲线装饰 - 右下角弧线纹理 */
.info-strip-card::after {
    content: '';
    position: absolute;
    bottom: -30px;
    right: -30px;
    width: 220px;
    height: 220px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 220 220'%3E%3Cpath d='M0,110 C40,70 80,70 110,110 C140,150 180,150 220,110' fill='none' stroke='rgba(255,255,255,0.10)' stroke-width='3'/%3E%3Cpath d='M0,140 C40,100 80,100 110,140 C140,180 180,180 220,140' fill='none' stroke='rgba(255,255,255,0.07)' stroke-width='3'/%3E%3Cpath d='M0,170 C40,130 80,130 110,170 C140,210 180,210 220,170' fill='none' stroke='rgba(255,255,255,0.04)' stroke-width='3'/%3E%3C/svg%3E") no-repeat;
    pointer-events: none;
}
.info-strip-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    line-height: 1.5;
    text-align: center;
    position: relative;
    z-index: 1;
}
/* 第一行：时钟 */
.info-strip-clock {
    flex-direction: column;
    gap: 6px;
}
.info-strip-time {
    font-size: 48px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    letter-spacing: 2px;
    text-shadow: 0 2px 12px rgba(0,0,0,0.18);
}
.info-strip-date-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0 4px;
}
.info-strip-solar {
    font-size: 15px;
    opacity: 0.9;
    letter-spacing: 0.5px;
}
.info-strip-lunar-date {
    font-size: 15px;
    opacity: 0.85;
    letter-spacing: 0.5px;
}
.info-strip-date {
    font-size: 16px;
    opacity: 0.85;
    letter-spacing: 0.5px;
}
/* 第二行：天气 */
.info-strip-weather {
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 12px;
    flex-wrap: wrap;
}
.info-strip-wicon {
    font-size: 28px;
}
.info-strip-wtemp {
    font-size: 28px;
    font-weight: 800;
    text-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.info-strip-wdesc {
    font-size: 15px;
    opacity: 0.9;
}
.info-strip-wloc {
    font-size: 13px;
    opacity: 0.7;
}
/* 天气行内预警播报徽章 */
.w-alert-badge {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    margin-left: auto;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    animation: alertPulse 2s ease-in-out infinite;
}
@keyframes alertPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}
.w-alert-badge-icon {
    font-size: 16px;
    line-height: 1;
}
.w-alert-badge-text {
    font-size: 12px;
    white-space: nowrap;
}
.w-alert-blue {
    background: rgba(59,130,246,0.85);
    border: 1px solid rgba(147,197,253,0.5);
}
.w-alert-yellow {
    background: rgba(245,158,11,0.85);
    border: 1px solid rgba(253,230,138,0.5);
}
.w-alert-orange {
    background: rgba(249,115,22,0.85);
    border: 1px solid rgba(254,215,170,0.5);
}
.w-alert-red {
    background: rgba(239,68,68,0.85);
    border: 1px solid rgba(252,165,165,0.5);
}
/* 天气详情行：最高温/最低温/湿度/风速 */
.info-strip-wdetail {
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 10px;
    justify-content: space-around;
    gap: 6px;
}
.wdetail-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    flex: 1;
}
.wdetail-icon {
    font-size: 14px;
    opacity: 0.8;
}
.wdetail-label {
    font-size: 11px;
    opacity: 0.75;
    color: #fff;
}
.wdetail-value {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
}
/* 预警信息行 */
.info-strip-alert {
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 12px;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}
/* 标准气象预警信号图标 - 左图右文 + 底部级别条（与卡片同色渐变） */
.alert-signal-icon {
    display: flex;
    align-items: stretch;
    width: auto;
    min-width: 190px;
    height: 58px;
    border-radius: 10px;
    border: 2px solid rgba(255,255,255,0.25);
    overflow: hidden;
    font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    box-shadow: 0 4px 14px rgba(0,0,0,0.2);
    position: relative;
    background: linear-gradient(135deg, rgba(139,92,246,0.6) 0%, rgba(59,130,246,0.6) 100%);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}
.alert-signal-graphic {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    flex-shrink: 0;
    font-size: 32px;
    background: rgba(255,255,255,0.12);
    border-right: 2px solid rgba(255,255,255,0.2);
}
.alert-signal-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    flex: 1;
    padding: 4px 10px 16px;
    gap: 2px;
    min-width: 0;
}
.alert-signal-name {
    font-size: 20px;
    font-weight: 900;
    color: #fff;
    line-height: 1.1;
    letter-spacing: 2px;
    text-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.alert-signal-en {
    font-size: 8px;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    line-height: 1;
}
.alert-signal-level {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 4px;
}
/* 预警等级配色（级别色条，图标主体与卡片同色） */
.alert-signal-blue .alert-signal-level {
    background: rgba(59,130,246,0.8);
}
.alert-signal-yellow .alert-signal-level {
    background: rgba(245,158,11,0.85);
}
.alert-signal-orange .alert-signal-level {
    background: rgba(249,115,22,0.85);
}
.alert-signal-red .alert-signal-level {
    background: rgba(239,68,68,0.85);
}
.info-strip-alert-text {
    font-size: 12px;
    opacity: 0.85;
    text-align: center;
    line-height: 1.4;
    color: #fff;
}
/* 第三行：节日 */
.info-strip-fest {
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 12px;
}
.info-strip-ficon {
    font-size: 22px;
}
.info-strip-fname {
    font-size: 16px;
    font-weight: 600;
}
.info-strip-fdays {
    font-size: 28px;
    font-weight: 800;
    color: #FBBF24;
    text-shadow: 0 2px 8px rgba(0,0,0,0.2);
}
.info-strip-funit {
    font-size: 14px;
    opacity: 0.85;
}
/* 星座运势（节日行右侧） */
.info-strip-zodiac {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: rgba(255,255,255,0.12);
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.15);
    flex-shrink: 0;
}
.zodiac-icon {
    font-size: 18px;
    line-height: 1;
}
.zodiac-text {
    font-size: 13px;
    font-weight: 600;
    color: #fff;
}
.zodiac-luck {
    font-size: 11px;
    color: #FBBF24;
    letter-spacing: 1px;
}
/* 第四行：农历干支（年/月/日） */
.info-strip-lunar {
    border-top: 1px solid rgba(255,255,255,0.18);
    padding-top: 10px;
    justify-content: space-around;
    gap: 8px;
}
.lunar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    flex: 1;
}
.lunar-label {
    font-size: 11px;
    opacity: 0.6;
    color: #fff;
}
.lunar-value {
    font-size: 16px;
    font-weight: 600;
    color: #fff;
    letter-spacing: 2px;
}

/* 暗色主题适配 */
html body.theme-dark .info-strip-card {
    background: linear-gradient(135deg, #6D28D9 0%, #1D4ED8 100%);
}

/* 移动端适配 */
@media (max-width: 600px) {
    .info-strip-card {
        padding: 22px 20px;
        gap: 14px;
        border-radius: 24px;
        margin-bottom: 12px;
    }
    .info-strip-row {
        gap: 8px;
        line-height: 1.4;
    }
    .info-strip-time {
        font-size: 38px;
        letter-spacing: 1.5px;
    }
    .info-strip-date-row {
        padding: 0 2px;
    }
    .info-strip-solar {
        font-size: 13px;
    }
    .info-strip-lunar-date {
        font-size: 13px;
    }
    .info-strip-date {
        font-size: 14px;
    }
    .info-strip-wicon {
        font-size: 22px;
    }
    .info-strip-wtemp {
        font-size: 22px;
    }
    .info-strip-wdesc {
        font-size: 13px;
    }
    .info-strip-wloc {
        font-size: 12px;
    }
    .w-alert-badge {
        padding: 4px 8px;
        gap: 4px;
    }
    .w-alert-badge-icon {
        font-size: 14px;
    }
    .w-alert-badge-text {
        font-size: 11px;
    }
    .info-strip-wdetail {
        padding-top: 8px;
    }
    .wdetail-icon {
        font-size: 12px;
    }
    .wdetail-label {
        font-size: 10px;
    }
    .wdetail-value {
        font-size: 12px;
    }
    .info-strip-weather,
    .info-strip-fest,
    .info-strip-alert,
    .info-strip-wdetail,
    .info-strip-lunar {
        padding-top: 10px;
    }
    .info-strip-zodiac {
        padding: 3px 10px;
        gap: 4px;
    }
    .zodiac-icon {
        font-size: 16px;
    }
    .zodiac-text {
        font-size: 12px;
    }
    .zodiac-luck {
        font-size: 10px;
    }
    .lunar-text,
    .lunar-solar {
        font-size: 12px;
    }
    .lunar-label {
        font-size: 10px;
    }
    .lunar-value {
        font-size: 14px;
    }
    .alert-signal-icon {
        min-width: 170px;
        height: 52px;
    }
    .alert-signal-graphic {
        width: 50px;
        font-size: 26px;
    }
    .alert-signal-name {
        font-size: 18px;
    }
    .alert-signal-en {
        font-size: 7px;
    }
    .alert-signal-level {
        height: 12px;
        font-size: 9px;
        letter-spacing: 3px;
    }
    .info-strip-alert-text {
        font-size: 11px;
    }
    .info-strip-ficon {
        font-size: 18px;
    }
    .info-strip-fname {
        font-size: 14px;
    }
    .info-strip-fdays {
        font-size: 22px;
    }
    .info-strip-funit {
        font-size: 12px;
    }
}

/* ===== 天气 + 节日二合一卡片 ===== */
.weather-festival-card {
    display: flex;
    align-items: stretch;
    margin-bottom: 12px;
    border-radius: 20px;
    overflow: hidden;
    background: linear-gradient(135deg, #5b6ee8 0%, #7b4bb8 100%);
    box-shadow: 0 6px 24px rgba(91,110,232,0.35);
    color: #fff;
    position: relative;
    min-height: 220px;
}
.weather-festival-card::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -8%;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(255,255,255,0.06) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 0;
}

/* ===== 左侧：天气 ===== */
.wf-left {
    flex: 1;
    min-width: 0;
    padding: 20px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
    z-index: 1;
}
.wf-weather-top {
    display: flex;
    align-items: center;
    gap: 12px;
}
.wf-weather-icon {
    font-size: 56px;
    line-height: 1;
    filter: drop-shadow(0 3px 10px rgba(0,0,0,0.3));
    flex-shrink: 0;
}
.wf-weather-temp {
    font-size: 48px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -2px;
}
.wf-weather-desc {
    font-size: 20px;
    font-weight: 600;
    color: rgba(255,255,255,0.95);
}
.wf-weather-addr {
    font-size: 16px;
    color: rgba(255,255,255,0.85);
    font-weight: 500;
    background: rgba(255,255,255,0.12);
    padding: 6px 16px;
    border-radius: 20px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    align-self: flex-start;
    backdrop-filter: blur(4px);
}
.wf-weather-details {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.wf-detail-item {
    font-size: 15px;
    color: rgba(255,255,255,0.9);
    background: rgba(255,255,255,0.14);
    padding: 6px 14px;
    border-radius: 12px;
    font-weight: 600;
    white-space: nowrap;
}
.wf-weather-alerts {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: auto;
}
.wf-alert-tag {
    font-size: 14px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 14px;
    white-space: nowrap;
    animation: wfAlertPulse 2s ease-in-out infinite;
}
.wf-alert-red { background: rgba(239,68,68,0.45); border: 1px solid rgba(239,68,68,0.85); }
.wf-alert-orange { background: rgba(249,115,22,0.45); border: 1px solid rgba(249,115,22,0.85); }
.wf-alert-yellow { background: rgba(234,179,8,0.45); border: 1px solid rgba(234,179,8,0.85); }
.wf-alert-blue { background: rgba(59,130,246,0.45); border: 1px solid rgba(59,130,246,0.85); }
.wf-alert-white { background: rgba(255,255,255,0.25); border: 1px solid rgba(255,255,255,0.6); }
@keyframes wfAlertPulse { 0%,100%{opacity:1;} 50%{opacity:0.75;} }

/* ===== 竖分隔线 ===== */
.wf-vdivider {
    width: 1px;
    background: rgba(255,255,255,0.15);
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

/* ===== 右侧：节日倒计时 ===== */
.wf-right {
    flex: 1;
    min-width: 0;
    padding: 20px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
    z-index: 1;
}
.wf-fest-title {
    font-size: 17px;
    font-weight: 700;
    color: rgba(255,255,255,0.9);
    white-space: nowrap;
}
.wf-festival-body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}
.wf-festival-loading {
    font-size: 15px;
    color: rgba(255,255,255,0.6);
}
.wf-fest-top {
    display: flex;
    align-items: center;
    gap: 10px;
}
.wf-fest-icon {
    font-size: 36px;
    line-height: 1;
    flex-shrink: 0;
}
.wf-fest-name {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
}
.wf-fest-dates {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.wf-fest-solar {
    font-size: 15px;
    color: rgba(255,255,255,0.85);
    font-weight: 500;
}
.wf-fest-lunar {
    font-size: 15px;
    color: rgba(255,255,255,0.7);
    padding: 2px 12px;
    border-radius: 10px;
    background: rgba(255,255,255,0.12);
    align-self: flex-start;
}
.wf-fest-count {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-top: 4px;
}
.wf-fest-days {
    font-size: 44px;
    font-weight: 800;
    line-height: 1;
}
.wf-fest-unit {
    font-size: 18px;
    font-weight: 700;
}
.wf-fest-time {
    font-size: 18px;
    color: rgba(255,255,255,0.8);
    font-variant-numeric: tabular-nums;
    font-weight: 600;
    letter-spacing: 1px;
}
.wf-fest-time i {
    font-style: normal;
    opacity: 0.5;
    margin: 0 2px;
}

/* 底部日期信息 */
.wf-date-info {
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid rgba(255,255,255,0.12);
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.wf-date-row {
    font-size: 14px;
    color: rgba(255,255,255,0.75);
    font-weight: 500;
}

/* 暗色模式 */
html body.theme-dark .weather-festival-card {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%);
    box-shadow: 0 6px 24px rgba(0,0,0,0.45);
}

/* 移动端 */
@media (max-width: 600px) {
    .weather-festival-card {
        flex-direction: column;
        min-height: auto;
        margin-bottom: 10px;
        border-radius: 16px;
    }
    .wf-vdivider {
        width: 100%;
        height: 1px;
    }
    .wf-left { padding: 10px 14px; gap: 6px; }
    .wf-right { padding: 8px 14px 10px; gap: 6px; }
    .wf-weather-top { gap: 10px; }
    .wf-weather-icon { font-size: 44px; }
    .wf-weather-temp { font-size: 38px; letter-spacing: -1px; }
    .wf-weather-desc { font-size: 17px; }
    .wf-weather-addr { font-size: 14px; padding: 4px 14px; }
    .wf-detail-item { font-size: 13px; padding: 4px 12px; border-radius: 12px; }
    .wf-alert-tag { font-size: 12px; padding: 4px 12px; border-radius: 12px; }
    .wf-fest-title { font-size: 15px; }
    .wf-festival-body { gap: 6px; }
    .wf-fest-top { gap: 10px; }
    .wf-fest-icon { font-size: 28px; }
    .wf-fest-name { font-size: 18px; }
    .wf-fest-dates { gap: 2px; }
    .wf-fest-solar { font-size: 13px; }
    .wf-fest-lunar { font-size: 13px; padding: 2px 12px; border-radius: 10px; }
    .wf-fest-count { margin-top: 0; gap: 4px; }
    .wf-fest-days { font-size: 34px; }
    .wf-fest-unit { font-size: 15px; }
    .wf-fest-time { font-size: 15px; letter-spacing: 1px; }
    .wf-date-info { padding-top: 6px; gap: 2px; }
    .wf-date-row { font-size: 12px; }
}

/* 问候语+天气横幅（旧） */
.greeting-weather-banner {
    display: flex;
    flex-direction: column;
    padding: 22px 22px 16px;
    margin-bottom: 14px;
    border-radius: 22px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #6b8cce 100%);
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.35);
    overflow: hidden;
    position: relative;
    transition: transform 0.3s, box-shadow 0.3s;
}
.greeting-weather-banner:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 28px rgba(102, 126, 234, 0.45);
}
.greeting-weather-banner::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.gw-greeting {
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
    margin-bottom: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 天气内容：左侧图标+描述，右侧温度+详情 */
.gw-weather-content {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
}
.gw-weather-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex-shrink: 0;
}
.gw-weather-icon {
    font-size: 52px;
    line-height: 1;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.25));
}
.gw-weather-desc {
    font-size: 17px;
    color: rgba(255,255,255,0.95);
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}
.gw-weather-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    flex: 1;
    gap: 6px;
}
.gw-temp-main {
    display: flex;
    align-items: baseline;
    gap: 4px;
}
.gw-weather-temp {
    font-size: 44px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    letter-spacing: -1px;
}
.gw-temp-detail {
    display: flex;
    align-items: center;
    gap: 8px;
}
.gw-weather-maxmin {
    font-size: 16px;
    color: rgba(255,255,255,0.9);
    white-space: nowrap;
    font-weight: 600;
}
.gw-weather-extra {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
    margin-top: 4px;
}
.gw-extra-item {
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    background: rgba(255,255,255,0.15);
    padding: 4px 10px;
    border-radius: 10px;
    white-space: nowrap;
    font-weight: 500;
}

/* 省份城市地址（居中显示） */
.gw-province-city {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid rgba(255,255,255,0.15);
    font-size: 15px;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
}
.gw-pc-icon { font-size: 16px; }

/* 暗色模式适配 */
.theme-dark .greeting-weather-banner {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 50%, #2d3748 100%);
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}
.theme-dark .gw-greeting { color: #f0f0f5; }
.theme-dark .gw-weather-temp { color: #f0f0f5; }
.theme-dark .gw-weather-desc { color: rgba(200,200,220,0.85); }
.theme-dark .gw-weather-maxmin { color: rgba(200,200,220,0.7); }
.theme-dark .gw-extra-item {
    color: rgba(200,200,220,0.7);
    background: rgba(255,255,255,0.08);
}
.theme-dark .gw-province-city {
    color: rgba(200,200,220,0.7);
    border-top-color: rgba(255,255,255,0.08);
}

/* 移动端适配 */
@media (max-width: 600px) {
    .greeting-weather-banner {
        padding: 18px 16px 14px;
    }
    .gw-greeting { font-size: 19px; margin-bottom: 12px; }
    .gw-weather-content { gap: 12px; }
    .gw-weather-icon { font-size: 44px; }
    .gw-weather-desc { font-size: 15px; }
    .gw-weather-temp { font-size: 36px; }
    .gw-weather-maxmin { font-size: 14px; }
    .gw-extra-item { font-size: 12px; padding: 3px 8px; }
    .gw-province-city { font-size: 13px; margin-top: 12px; padding-top: 10px; }
}

/* 欢迎区 */
.welcome-section {
    margin-bottom: 20px;
}

.welcome-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 6px 0;
    color: var(--text-primary);
}

.welcome-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
}

/* 统计行 */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 24px;
}

.stat-mini {
    background: var(--bg-card);
    border-radius: var(--radius-md);
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--border-color);
}

.stat-mini-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.stat-mini-info {
    flex: 1;
    min-width: 0;
}

.stat-mini-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stat-mini-label {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* 模块分区 */
.module-section {
    margin-bottom: 28px;
}

.module-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 14px 0;
    padding-left: 10px;
    border-left: 4px solid var(--primary-color);
    letter-spacing: 0.3px;
}

/* 图标网格 - 双列布局 */
.icon-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.icon-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 24px 16px;
    text-align: center;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.icon-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.25s;
}

.icon-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.1);
    border-color: transparent;
}

.icon-card:hover::before {
    opacity: 1;
}

.icon-card:active {
    transform: scale(0.96);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.icon-card-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(139, 92, 246, 0.18));
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.1);
}

.icon-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.3;
    letter-spacing: 0.2px;
}

/* 图标颜色变体 */
.icon-blue .icon-card-icon { background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.2)); }
.icon-cyan .icon-card-icon { background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(8, 145, 178, 0.2)); }
.icon-yellow .icon-card-icon { background: linear-gradient(135deg, rgba(234, 179, 8, 0.15), rgba(202, 138, 4, 0.2)); }
.icon-green .icon-card-icon { background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(22, 163, 74, 0.2)); }
.icon-purple .icon-card-icon { background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(147, 51, 234, 0.2)); }
.icon-orange .icon-card-icon { background: linear-gradient(135deg, rgba(249, 115, 22, 0.15), rgba(234, 88, 12, 0.2)); }
.icon-teal .icon-card-icon { background: linear-gradient(135deg, rgba(20, 184, 166, 0.15), rgba(13, 148, 136, 0.2)); }
.icon-red .icon-card-icon { background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(220, 38, 38, 0.2)); }
.icon-indigo .icon-card-icon { background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(79, 70, 229, 0.2)); }
.icon-amber .icon-card-icon { background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.2)); }
.icon-pink .icon-card-icon { background: linear-gradient(135deg, rgba(236, 72, 153, 0.15), rgba(219, 39, 119, 0.2)); }
.icon-rose .icon-card-icon { background: linear-gradient(135deg, rgba(244, 63, 94, 0.15), rgba(225, 29, 72, 0.2)); }
.icon-sky .icon-card-icon { background: linear-gradient(135deg, rgba(14, 165, 233, 0.15), rgba(2, 132, 199, 0.2)); }
.icon-emerald .icon-card-icon { background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(5, 150, 105, 0.2)); }
.icon-lime .icon-card-icon { background: linear-gradient(135deg, rgba(132, 204, 22, 0.15), rgba(101, 163, 13, 0.2)); }
.icon-violet .icon-card-icon { background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(124, 58, 237, 0.2)); }
.icon-fuchsia .icon-card-icon { background: linear-gradient(135deg, rgba(217, 70, 239, 0.15), rgba(192, 38, 211, 0.2)); }

/* 版本更新区域 */
.version-update-section {
    margin-top: 24px;
}

.version-update-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.version-update-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.version-icon {
    font-size: 18px;
}

.version-update-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.version-fields {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.version-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.version-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

.version-label-icon {
    font-size: 14px;
}

.version-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    background: var(--bg-primary);
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.version-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    background: var(--bg-white);
}

.version-save-btn {
    align-self: flex-start;
    padding: 10px 24px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
}

/* API对接配置区域 */
.api-config-section {
    margin-top: 20px;
}

.api-config-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px;
    box-shadow: var(--shadow-sm);
}

.api-config-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.api-config-icon {
    font-size: 18px;
}

.api-config-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.api-fields {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.api-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.api-field-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

.api-field-icon {
    font-size: 14px;
}

.api-field-input {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 13px;
    color: var(--text-primary);
    background: var(--bg-primary);
    transition: border-color 0.2s, box-shadow 0.2s;
    font-family: inherit;
}

.api-field-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
    background: var(--bg-white);
}

.api-save-btn {
    align-self: flex-start;
    padding: 10px 24px;
    font-size: 13px;
    font-weight: 500;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.api-save-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.api-save-btn:active {
    transform: scale(0.97);
}

/* 主功能卡片网格（MIUI风格横向圆角矩形，双列排列） */
.main-card-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
    margin-top: 6px;
}

/* 表单卡片作为网格项 */
.main-card-grid > .main-card-form {
    margin: 0;
    display: flex;
    min-width: 0;
}
.main-card-grid > .main-card-form > .main-card {
    width: 100%;
    flex: 1;
}
.main-card-grid button.main-card {
    -webkit-appearance: none;
    appearance: none;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    outline: none;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    min-width: 0;
}

.main-card {
    background: var(--bg-card);
    border-radius: 22px;
    padding: 16px 14px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 14px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    border: 1px solid var(--border-color);
    min-height: 72px;
}

.main-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
    border-color: transparent;
}

.main-card:active {
    transform: scale(0.97);
}

.main-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.main-card-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.main-card-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.main-card-desc {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.main-card-stat {
    display: none;
}

/* 主卡片图标颜色变体 */
.main-card-blue .main-card-icon { background: linear-gradient(135deg, #3b82f6, #6366f1); }
.main-card-purple .main-card-icon { background: linear-gradient(135deg, #8b5cf6, #a855f7); }
.main-card-orange .main-card-icon { background: linear-gradient(135deg, #f97316, #f59e0b); }
.main-card-emerald .main-card-icon { background: linear-gradient(135deg, #10b981, #14b8a6); }
.main-card-red .main-card-icon { background: linear-gradient(135deg, #ef4444, #f97316); }
.main-card-indigo .main-card-icon { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.main-card-green .main-card-icon { background: linear-gradient(135deg, #10b981, #34d399); }
.main-card-amber .main-card-icon { background: linear-gradient(135deg, #f59e0b, #fbbf24); }
.main-card-cyan .main-card-icon { background: linear-gradient(135deg, #06b6d4, #22d3ee); }
.main-card-lime .main-card-icon { background: linear-gradient(135deg, #84cc16, #a3e635); }
.main-card-pink .main-card-icon { background: linear-gradient(135deg, #ec4899, #f472b6); }
.main-card-teal .main-card-icon { background: linear-gradient(135deg, #14b8a6, #2dd4bf); }

/* 欢迎区样式 */
.welcome-section {
    margin-bottom: 20px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08), rgba(118, 75, 162, 0.08));
    border-radius: 20px;
    padding: 24px 20px;
    border: 1px solid rgba(102, 126, 234, 0.12);
}

/* ===== 日志信息按钮区 ===== */
.log-info-section {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.06), rgba(99, 102, 241, 0.06));
}

.log-info-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #3b82f6, #6366f1);
    color: #fff;
    padding: 10px 18px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    font-size: 15px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.25);
    margin-bottom: 10px;
}
.log-info-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.35);
    color: #fff;
}

.log-info-btn-icon {
    font-size: 20px;
}

.log-info-btn-count {
    font-size: 12px;
    font-weight: 500;
    opacity: 0.9;
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 8px;
    border-radius: 6px;
}

.log-info-latest {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.log-info-version {
    font-size: 14px;
    font-weight: 700;
    color: var(--primary-color);
    background: rgba(59, 130, 246, 0.1);
    padding: 2px 10px;
    border-radius: 6px;
}

.log-info-date {
    font-size: 12px;
    color: var(--text-tertiary, #999);
}

.log-info-preview {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.5;
    max-width: 500px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

html body.theme-dark .log-info-section {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(99, 102, 241, 0.1));
}

.welcome-greet {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 4px 0;
    font-weight: 500;
}

.welcome-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 6px 0;
    line-height: 1.25;
}

.welcome-title-en {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0 0 6px 0;
    font-weight: 400;
    opacity: 0.8;
}

.welcome-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
}

/* 数据统计区域 */
.stats-section {
    margin-top: 28px;
}

.stats-section-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 14px 0;
    padding-left: 10px;
    border-left: 4px solid var(--primary-color);
}

/* ===== 融合预览 - 长条卡片 ===== */
.fusion-stats {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.fusion-bar-card {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 12px 16px;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.fusion-bar-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* 左侧色条 */
.fusion-bar-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    border-radius: 4px 0 0 4px;
}

.fusion-bar-blue::before { background: linear-gradient(180deg, #3b82f6, #2563eb); }
.fusion-bar-purple::before { background: linear-gradient(180deg, #8b5cf6, #7c3aed); }
.fusion-bar-green::before { background: linear-gradient(180deg, #10b981, #059669); }
.fusion-bar-orange::before { background: linear-gradient(180deg, #f59e0b, #d97706); }
.fusion-bar-indigo::before { background: linear-gradient(180deg, #6366f1, #4f46e5); }
.fusion-bar-teal::before { background: linear-gradient(180deg, #14b8a6, #0d9488); }
.fusion-bar-amber::before { background: linear-gradient(180deg, #f59e0b, #ea580c); }
.fusion-bar-violet::before { background: linear-gradient(180deg, #a855f7, #9333ea); }

.fusion-bar-icon {
    font-size: 22px;
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    flex-shrink: 0;
}

.fusion-bar-blue .fusion-bar-icon { background: rgba(59, 130, 246, 0.12); }
.fusion-bar-purple .fusion-bar-icon { background: rgba(139, 92, 246, 0.12); }
.fusion-bar-green .fusion-bar-icon { background: rgba(16, 185, 129, 0.12); }
.fusion-bar-orange .fusion-bar-icon { background: rgba(245, 158, 11, 0.12); }
.fusion-bar-indigo .fusion-bar-icon { background: rgba(99, 102, 241, 0.12); }
.fusion-bar-teal .fusion-bar-icon { background: rgba(20, 184, 166, 0.12); }
.fusion-bar-amber .fusion-bar-icon { background: rgba(245, 158, 11, 0.12); }
.fusion-bar-violet .fusion-bar-icon { background: rgba(168, 85, 247, 0.12); }

.fusion-bar-body {
    flex: 1;
    min-width: 0;
}

.fusion-bar-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fusion-bar-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.fusion-bar-unit {
    font-size: 12px;
    font-weight: 400;
    color: var(--text-secondary);
    margin-left: 3px;
}

.fusion-bar-side {
    text-align: right;
    flex-shrink: 0;
    min-width: 56px;
}

.fusion-bar-percent {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.2;
}

.fusion-bar-blue .fusion-bar-percent { color: #3b82f6; }
.fusion-bar-purple .fusion-bar-percent { color: #8b5cf6; }
.fusion-bar-green .fusion-bar-percent { color: #10b981; }
.fusion-bar-orange .fusion-bar-percent { color: #f59e0b; }
.fusion-bar-indigo .fusion-bar-percent { color: #6366f1; }
.fusion-bar-teal .fusion-bar-percent { color: #14b8a6; }
.fusion-bar-amber .fusion-bar-percent { color: #ea580c; }
.fusion-bar-violet .fusion-bar-percent { color: #a855f7; }

.fusion-bar-sublabel {
    font-size: 10px;
    color: var(--text-tertiary, #999);
    margin-top: 1px;
}

/* 底部进度条 */
.fusion-bar-track {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.fusion-bar-fill {
    height: 100%;
    border-radius: 0 3px 3px 0;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.fusion-fill-blue { background: linear-gradient(90deg, #60a5fa, #3b82f6); }
.fusion-fill-purple { background: linear-gradient(90deg, #a78bfa, #8b5cf6); }
.fusion-fill-green { background: linear-gradient(90deg, #34d399, #10b981); }
.fusion-fill-orange { background: linear-gradient(90deg, #fbbf24, #f59e0b); }
.fusion-fill-indigo { background: linear-gradient(90deg, #818cf8, #6366f1); }
.fusion-fill-teal { background: linear-gradient(90deg, #2dd4bf, #14b8a6); }
.fusion-fill-amber { background: linear-gradient(90deg, #fb923c, #ea580c); }
.fusion-fill-violet { background: linear-gradient(90deg, #c084fc, #a855f7); }

/* 暗色模式适配 */
html body.theme-dark .fusion-bar-card {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.08);
}

html body.theme-dark .fusion-bar-track {
    background: rgba(255, 255, 255, 0.06);
}

html body.theme-dark .fusion-bar-blue .fusion-bar-icon { background: rgba(59, 130, 246, 0.18); }
html body.theme-dark .fusion-bar-purple .fusion-bar-icon { background: rgba(139, 92, 246, 0.18); }
html body.theme-dark .fusion-bar-green .fusion-bar-icon { background: rgba(16, 185, 129, 0.18); }
html body.theme-dark .fusion-bar-orange .fusion-bar-icon { background: rgba(245, 158, 11, 0.18); }
html body.theme-dark .fusion-bar-indigo .fusion-bar-icon { background: rgba(99, 102, 241, 0.18); }
html body.theme-dark .fusion-bar-teal .fusion-bar-icon { background: rgba(20, 184, 166, 0.18); }
html body.theme-dark .fusion-bar-amber .fusion-bar-icon { background: rgba(245, 158, 11, 0.18); }
html body.theme-dark .fusion-bar-violet .fusion-bar-icon { background: rgba(168, 85, 247, 0.18); }

/* 移动端适配 */
@media (max-width: 640px) {
    .fusion-bar-card {
        padding: 10px 12px;
        gap: 10px;
    }
    .fusion-bar-icon {
        width: 36px;
        height: 36px;
        font-size: 18px;
    }
    .fusion-bar-value {
        font-size: 17px;
    }
    .fusion-bar-percent {
        font-size: 16px;
    }
    .fusion-bar-side {
        min-width: 44px;
    }
}

.stats-card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.stats-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 18px 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.stats-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    opacity: 0;
    transition: opacity 0.25s;
}

.stats-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.stats-card:hover::before {
    opacity: 1;
}

.stats-card-icon {
    font-size: 28px;
    line-height: 1;
}

.stats-card-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.stats-card-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stats-card-label {
    font-size: 12px;
    color: var(--text-secondary);
}

/* 统计卡片颜色变体 */
.stats-card-user { border-top: 3px solid #3b82f6; }
.stats-card-user .stats-card-icon { color: #3b82f6; }
.stats-card-user::before { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.stats-card-sign { border-top: 3px solid #10b981; }
.stats-card-sign .stats-card-icon { color: #10b981; }
.stats-card-sign::before { background: linear-gradient(90deg, #10b981, #34d399); }
.stats-card-comment { border-top: 3px solid #f59e0b; }
.stats-card-comment .stats-card-icon { color: #f59e0b; }
.stats-card-comment::before { background: linear-gradient(90deg, #f59e0b, #fbbf24); }

/* 数据概览卡片 */
.stats-overview-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stats-overview-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    padding: 18px 16px;
    display: flex;
    align-items: flex-start;
    gap: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.stats-overview-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
}

.stats-overview-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.stats-overview-user { background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(99, 102, 241, 0.2)); }
.stats-overview-card-icon { background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(168, 85, 247, 0.2)); }
.stats-overview-sign { background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(20, 184, 166, 0.2)); }
.stats-overview-comment { background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(249, 115, 22, 0.2)); }

.stats-overview-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stats-overview-label {
    font-size: 12.5px;
    color: var(--text-secondary);
    font-weight: 500;
}

.stats-overview-value {
    font-size: 26px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.stats-overview-unit {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    margin-left: 2px;
}

.stats-overview-bar {
    height: 8px;
    background: var(--bg-primary);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 4px;
}

.stats-overview-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.6s ease;
}

.stats-fill-user { background: linear-gradient(90deg, #3b82f6, #6366f1); }
.stats-fill-card { background: linear-gradient(90deg, #8b5cf6, #a855f7); }
.stats-fill-sign { background: linear-gradient(90deg, #10b981, #14b8a6); }
.stats-fill-comment { background: linear-gradient(90deg, #f59e0b, #f97316); }

.stats-overview-percent {
    font-size: 11.5px;
    color: var(--text-secondary);
    font-weight: 500;
    margin-top: 2px;
}

/* 功能模块统计列表 */
.module-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.module-stat-item {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 16px 14px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    transition: all 0.2s;
}

.module-stat-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.module-stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
    color: white;
}

.module-stat-info {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.module-stat-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.module-stat-desc {
    font-size: 12px;
    color: var(--text-secondary);
}

.module-stat-percent {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    align-self: flex-end;
    margin-top: auto;
}

/* 分组二级页面 */
.group-page {
    padding: 4px 0 20px;
    max-width: 900px;
    margin: 0 auto;
}

/* 分组头部 */
.group-header {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 22px;
    padding: 18px 20px;
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.group-header-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
}

.group-header-blue .group-header-icon { background: linear-gradient(135deg, #3b82f6, #6366f1); }
.group-header-purple .group-header-icon { background: linear-gradient(135deg, #8b5cf6, #a855f7); }
.group-header-orange .group-header-icon { background: linear-gradient(135deg, #f97316, #f59e0b); }
.group-header-emerald .group-header-icon { background: linear-gradient(135deg, #10b981, #14b8a6); }
.group-header-red .group-header-icon { background: linear-gradient(135deg, #ef4444, #f97316); }
.group-header-indigo .group-header-icon { background: linear-gradient(135deg, #6366f1, #8b5cf6); }

.group-header-info {
    flex: 1;
    min-width: 0;
}

.group-header-info {
    flex: 1;
}

.group-header-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px 0;
}

.group-header-desc {
    font-size: 12.5px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
}

/* 分组头部颜色变体 */
.group-header-blue { background: linear-gradient(135deg, #3b82f6, #6366f1); box-shadow: 0 10px 24px rgba(59, 130, 246, 0.35); }
.group-header-purple { background: linear-gradient(135deg, #8b5cf6, #a855f7); box-shadow: 0 10px 24px rgba(139, 92, 246, 0.35); }
.group-header-orange { background: linear-gradient(135deg, #f97316, #f59e0b); box-shadow: 0 10px 24px rgba(249, 115, 22, 0.35); }
.group-header-emerald { background: linear-gradient(135deg, #10b981, #14b8a6); box-shadow: 0 10px 24px rgba(16, 185, 129, 0.35); }
.group-header-red { background: linear-gradient(135deg, #ef4444, #f97316); box-shadow: 0 10px 24px rgba(239, 68, 68, 0.35); }
.group-header-indigo { background: linear-gradient(135deg, #6366f1, #8b5cf6); box-shadow: 0 10px 24px rgba(99, 102, 241, 0.35); }

/* 二级功能图标网格（MIUI风格横向圆角矩形，双列排列） */
.sub-icon-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px;
}

.sub-icon-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 22px;
    padding: 18px 16px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 14px;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    min-height: 78px;
    aspect-ratio: auto;
}

.sub-icon-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
    border-color: transparent;
}

.sub-icon-card:active {
    transform: scale(0.97);
}

.sub-icon-wrapper {
    display: flex;
    align-items: center;
}

.sub-icon-badge {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    line-height: 1;
    flex-shrink: 0;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
}

.sub-icon-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    min-width: 0;
}

.sub-icon-name {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sub-icon-desc {
    font-size: 12px;
    color: var(--text-secondary);
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sub-icon-arrow {
    display: none;
}

/* 子图标颜色变体 */
.sub-icon-blue .sub-icon-badge { background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.2)); }
.sub-icon-cyan .sub-icon-badge { background: linear-gradient(135deg, rgba(6, 182, 212, 0.15), rgba(8, 145, 178, 0.2)); }
.sub-icon-yellow .sub-icon-badge { background: linear-gradient(135deg, rgba(234, 179, 8, 0.15), rgba(202, 138, 4, 0.2)); }
.sub-icon-green .sub-icon-badge { background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(22, 163, 74, 0.2)); }
.sub-icon-purple .sub-icon-badge { background: linear-gradient(135deg, rgba(168, 85, 247, 0.15), rgba(147, 51, 234, 0.2)); }
.sub-icon-orange .sub-icon-badge { background: linear-gradient(135deg, rgba(249, 115, 22, 0.15), rgba(234, 88, 12, 0.2)); }
.sub-icon-teal .sub-icon-badge { background: linear-gradient(135deg, rgba(20, 184, 166, 0.15), rgba(13, 148, 136, 0.2)); }
.sub-icon-red .sub-icon-badge { background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(220, 38, 38, 0.2)); }
.sub-icon-indigo .sub-icon-badge { background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(79, 70, 229, 0.2)); }
.sub-icon-amber .sub-icon-badge { background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.2)); }
.sub-icon-pink .sub-icon-badge { background: linear-gradient(135deg, rgba(236, 72, 153, 0.15), rgba(219, 39, 119, 0.2)); }
.sub-icon-rose .sub-icon-badge { background: linear-gradient(135deg, rgba(244, 63, 94, 0.15), rgba(225, 29, 72, 0.2)); }
.sub-icon-sky .sub-icon-badge { background: linear-gradient(135deg, rgba(14, 165, 233, 0.15), rgba(2, 132, 199, 0.2)); }
.sub-icon-emerald .sub-icon-badge { background: linear-gradient(135deg, rgba(16, 185, 129, 0.15), rgba(5, 150, 105, 0.2)); }
.sub-icon-lime .sub-icon-badge { background: linear-gradient(135deg, rgba(132, 204, 22, 0.15), rgba(101, 163, 13, 0.2)); }
.sub-icon-violet .sub-icon-badge { background: linear-gradient(135deg, rgba(139, 92, 246, 0.15), rgba(124, 58, 237, 0.2)); }
.sub-icon-fuchsia .sub-icon-badge { background: linear-gradient(135deg, rgba(217, 70, 239, 0.15), rgba(192, 38, 211, 0.2)); }

/* 设置页面 */
.setting-page {
    padding: 4px 0 20px;
    max-width: 900px;
    margin: 0 auto;
}

.page-header {
    margin-bottom: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 22px;
    padding: 18px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    display: flex;
    align-items: center;
    gap: 14px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.page-header-icon {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
}

.page-header-icon.icon-blue { background: linear-gradient(135deg, #3b82f6, #6366f1); }
.page-header-icon.icon-purple { background: linear-gradient(135deg, #8b5cf6, #a855f7); }
.page-header-icon.icon-orange { background: linear-gradient(135deg, #f97316, #f59e0b); }
.page-header-icon.icon-emerald { background: linear-gradient(135deg, #10b981, #14b8a6); }
.page-header-icon.icon-red { background: linear-gradient(135deg, #ef4444, #f97316); }
.page-header-icon.icon-indigo { background: linear-gradient(135deg, #6366f1, #8b5cf6); }
.page-header-icon.icon-green { background: linear-gradient(135deg, #10b981, #34d399); }
.page-header-icon.icon-amber { background: linear-gradient(135deg, #f59e0b, #fbbf24); }

.page-header-info {
    flex: 1;
    min-width: 0;
}

.page-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 4px 0;
}

.page-desc {
    font-size: 12.5px;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 22px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}

.card-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.card-body {
    padding: 20px;
}

.card-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
    align-items: center;
}

.form-label-icon {
    margin-right: 4px;
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
}

.btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
}

/* 底部版权 */
.dashboard-footer {
    text-align: center;
    padding: 14px 0 8px;
    color: var(--text-secondary);
    font-size: 11px;
    opacity: 0.6;
}

.dashboard-footer p {
    margin: 0;
}

/* ========================================
   节日倒计时
======================================== */
.festival-countdown {
    margin: 14px 0 0;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 18px;
    overflow: hidden;
}
.fc-header {
    padding: 16px 20px 10px;
    border-bottom: 1px solid var(--border-color);
}
.fc-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--text-primary);
}
.fc-list {
    padding: 6px 8px;
}
.fc-single {
    padding: 10px;
}
.fc-loading {
    text-align: center;
    padding: 20px;
    color: var(--text-tertiary, #999);
    font-size: 14px;
}
.fc-single-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.06) 0%, rgba(118, 75, 162, 0.06) 100%);
    border: 1px solid rgba(102, 126, 234, 0.12);
    transition: transform 0.2s, box-shadow 0.2s;
    width: 100%;
    box-sizing: border-box;
}
.fc-single-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.15);
}
.fc-single-left {
    flex-shrink: 0;
}
.fc-single-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 38px;
    border-radius: 16px;
    background: rgba(102, 126, 234, 0.1);
}
.fc-single-body {
    flex: 1;
    min-width: 0;
}
.fc-single-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.3;
}
.fc-single-dates {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 6px;
    flex-wrap: wrap;
}
.fc-single-solar {
    font-size: 14px;
    color: var(--text-secondary);
    font-weight: 500;
}
.fc-single-lunar {
    font-size: 14px;
    color: var(--text-tertiary, #999);
    padding: 2px 10px;
    border-radius: 12px;
    background: rgba(102, 126, 234, 0.08);
}
.fc-single-desc {
    font-size: 13px;
    color: var(--text-tertiary, #999);
    margin-top: 4px;
}
.fc-single-right {
    flex-shrink: 0;
    text-align: center;
    padding: 10px 20px;
    border-left: 4px solid #667eea;
    min-width: 90px;
}
.fc-single-days {
    font-size: 36px;
    font-weight: 800;
    line-height: 1;
}
.fc-single-label {
    font-size: 13px;
    color: var(--text-tertiary, #999);
    margin-top: 4px;
    font-weight: 600;
}
.fc-single-time {
    font-size: 13px;
    color: var(--text-secondary);
    font-variant-numeric: tabular-nums;
    margin-top: 6px;
    letter-spacing: 0.5px;
}

/* 暗色模式 */
html body.theme-dark .festival-countdown { background: rgba(255,255,255,0.04); }
html body.theme-dark .fc-single-card { background: rgba(255,255,255,0.03); border-color: rgba(255,255,255,0.06); }
html body.theme-dark .fc-single-card:hover { box-shadow: 0 6px 16px rgba(0,0,0,0.3); }
html body.theme-dark .fc-single-icon { background: rgba(255,255,255,0.06); }
html body.theme-dark .fc-single-lunar { background: rgba(255,255,255,0.05); }

/* 移动端 */
@media (max-width: 600px) {
    .fc-header { padding: 14px 16px 8px; }
    .fc-title { font-size: 15px; }
    .fc-single { padding: 8px; }
    .fc-single-card { padding: 14px 12px; gap: 12px; }
    .fc-single-icon { width: 52px; height: 52px; font-size: 30px; border-radius: 14px; }
    .fc-single-name { font-size: 17px; }
    .fc-single-solar { font-size: 12px; }
    .fc-single-lunar { font-size: 12px; }
    .fc-single-desc { font-size: 12px; }
    .fc-single-right { padding: 8px 14px; min-width: 72px; }
    .fc-single-days { font-size: 28px; }
    .fc-single-label { font-size: 12px; }
    .fc-single-time { font-size: 11px; }
}

/* ========================================
   响应式适配 - 全端自由适配
   ======================================== */

/* 平板横屏 / 小屏笔记本 (1025px - 1280px) */
@media (max-width: 1280px) {
    :root {
        --sidebar-width: 200px;
    }
    
    .sidebar {
        width: 200px;
    }
    
    .sidebar.collapsed {
        width: 64px;
    }
    
    .main-content {
        margin-left: 200px;
    }
    
    .main-content.sidebar-collapsed {
        margin-left: 64px;
    }
    
    .sidebar-logo {
        padding: 14px 16px;
    }
    
    .sidebar-logo .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 15px;
    }
    
    .sidebar-logo .logo-text {
        font-size: 15px;
    }
    
    .menu-item {
        padding: 9px 16px;
        font-size: 12.5px;
    }
    
    .submenu-item {
        padding: 7px 16px 7px 44px;
        font-size: 12px;
    }
    
    .grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 14px;
    }
    
    .stat-card {
        padding: 14px;
        gap: 12px;
    }
    
    .stat-icon {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }
    
    .stat-info .stat-value {
        font-size: 18px;
    }
    
    .content {
        padding: 18px;
    }
}

/* 平板竖屏 (769px - 1024px) */
@media (max-width: 1024px) {
    :root {
        --sidebar-width: 180px;
        --header-height: 50px;
    }
    
    .sidebar {
        width: 180px;
    }
    
    .sidebar.collapsed {
        width: 60px;
    }
    
    .main-content {
        margin-left: 180px;
    }
    
    .main-content.sidebar-collapsed {
        margin-left: 60px;
    }
    
    .sidebar-logo {
        padding: 12px 14px;
        gap: 8px;
    }
    
    .sidebar-logo .logo-icon {
        width: 30px;
        height: 30px;
        font-size: 14px;
        border-radius: 7px;
    }
    
    .sidebar-logo .logo-text {
        font-size: 14.5px;
    }
    
    .sidebar-menu {
        padding: 6px 0;
    }
    
    .menu-item {
        padding: 8px 14px;
        font-size: 12px;
        gap: 8px;
    }
    
    .menu-item .menu-icon {
        font-size: 15px;
        width: 18px;
    }
    
    .submenu-item {
        padding: 7px 14px 7px 40px;
        font-size: 11.5px;
    }
    
    .sidebar-footer {
        padding: 10px 14px;
    }
    
    .sidebar-version {
        font-size: 10.5px;
    }
    
    .header {
        padding: 0 16px;
    }
    
    .header-title {
        font-size: 15px;
    }
    
    .content {
        padding: 16px;
    }
    
    .page-title {
        font-size: 17px;
    }
    
    .grid-3,
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .stat-card {
        padding: 12px;
        gap: 10px;
    }
    
    .stat-icon {
        width: 40px;
        height: 40px;
        font-size: 17px;
        border-radius: 9px;
    }
    
    .stat-info .stat-value {
        font-size: 17px;
    }
    
    .stat-info .stat-label {
        font-size: 11.5px;
    }
    
    .card-header {
        padding: 11px 14px;
    }
    
    .card-title {
        font-size: 13.5px;
    }
    
    .card-body {
        padding: 14px;
    }
    
    .btn {
        padding: 5px 12px;
        font-size: 12px;
    }
    
    .btn-sm {
        padding: 3px 7px;
        font-size: 11px;
    }
    
    .data-table th,
    .data-table td {
        padding: 8px 10px;
        font-size: 12px;
    }
    
    /* 模态框适配 */
    .modal {
        max-width: 420px;
    }
    
    .modal-header {
        padding: 14px 16px;
    }
    
    .modal-body {
        padding: 16px;
    }
    
    .modal-footer {
        padding: 10px 16px;
    }
}

/* 大屏手机 / 小屏平板 (481px - 768px) */
@media (max-width: 768px) {
    :root {
        --sidebar-width: 150px;
        --header-height: 46px;
    }
    
    body {
        font-size: 12.5px;
    }
    
    .sidebar {
        width: 150px;
    }
    
    .sidebar.collapsed {
        width: 56px;
    }
    
    .main-content {
        margin-left: 150px;
    }
    
    .main-content.sidebar-collapsed {
        margin-left: 56px;
    }
    
    .sidebar-logo {
        padding: 10px 12px;
        gap: 7px;
    }
    
    .sidebar-logo .logo-icon {
        width: 26px;
        height: 26px;
        font-size: 12px;
        border-radius: 6px;
    }
    
    .sidebar-logo .logo-text {
        font-size: 13px;
    }
    
    .sidebar-menu {
        padding: 4px 0;
    }
    
    .menu-item {
        padding: 8px 12px;
        font-size: 11.5px;
        gap: 7px;
    }
    
    .menu-item .menu-icon {
        font-size: 13px;
        width: 16px;
    }
    
    .menu-item .menu-arrow {
        font-size: 9px;
    }
    
    .submenu-item {
        padding: 6px 12px 6px 34px;
        font-size: 11px;
        gap: 7px;
    }
    
    .submenu-item .submenu-dot {
        width: 4px;
        height: 4px;
    }
    
    .sidebar-footer {
        padding: 8px 12px;
    }
    
    .sidebar-version {
        font-size: 10px;
    }
    
    .mobile-menu-btn {
        display: none;
    }
    
    /* 顶部导航 */
    .header {
        padding: 0 12px;
    }
    
    .header-title {
        font-size: 14px;
    }
    
    .admin-info {
        gap: 6px;
        padding: 4px 8px;
    }
    
    .admin-avatar {
        width: 26px;
        height: 26px;
        font-size: 11px;
    }
    
    .admin-name {
        display: none;
    }
    
    /* 内容区 */
    .content {
        padding: 12px;
    }
    
    .page-header {
        margin-bottom: 14px;
    }
    
    .page-title {
        font-size: 15px;
    }
    
    .page-desc {
        font-size: 12px;
    }
    
    /* 网格布局全部单列 */
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    /* 统计卡片 */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        margin-bottom: 16px;
    }
    
    .stat-card {
        padding: 10px 12px;
        gap: 10px;
    }
    
    .stat-icon {
        width: 36px;
        height: 36px;
        font-size: 15px;
        border-radius: 8px;
    }
    
    .stat-info .stat-value {
        font-size: 16px;
    }
    
    .stat-info .stat-label {
        font-size: 10.5px;
    }
    
    /* 卡片 */
    .card {
        margin-bottom: 12px;
    }
    
    .card-header {
        padding: 9px 12px;
    }
    
    .card-title {
        font-size: 12.5px;
    }
    
    .card-body {
        padding: 12px;
    }
    
    .card-footer {
        padding: 10px 12px;
    }
    
    /* 表单 */
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .form-group {
        margin-bottom: 14px;
    }
    
    .form-label {
        font-size: 12px;
        margin-bottom: 5px;
    }
    
    .form-input,
    .form-select,
    .form-textarea {
        padding: 6px 10px;
        font-size: 12px;
    }
    
    /* 按钮 */
    .btn {
        padding: 5px 10px;
        font-size: 11.5px;
    }
    
    .btn-sm {
        padding: 3px 6px;
        font-size: 10.5px;
    }
    
    .btn-lg {
        padding: 8px 16px;
        font-size: 13px;
    }
    
    /* 表格 - 横向滚动 */
    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .data-table {
        min-width: 600px;
    }
    
    .data-table th,
    .data-table td {
        padding: 7px 10px;
        font-size: 11.5px;
        white-space: nowrap;
    }
    
    .data-table td img {
        max-width: 36px;
        max-height: 36px;
    }
    
    .table-actions {
        gap: 4px;
    }
    
    /* 分页 */
    .pagination {
        gap: 4px;
    }
    
    .page-btn {
        min-width: 28px;
        height: 26px;
        padding: 0 8px;
        font-size: 11.5px;
    }
    
    /* 搜索栏 */
    .search-bar {
        gap: 8px;
        margin-bottom: 12px;
    }
    
    .search-bar .form-group {
        min-width: 120px;
    }
    
    /* 工具栏 */
    .toolbar {
        gap: 8px;
        margin-bottom: 12px;
    }
    
    /* 状态标签 */
    .status-badge {
        padding: 1px 6px;
        font-size: 10px;
    }
    
    /* 提示消息 */
    .alert {
        padding: 8px 12px;
        font-size: 12px;
        gap: 6px;
        margin-bottom: 12px;
    }
    
    /* 模态框 */
    .modal-overlay {
        padding: 12px;
    }
    
    .modal {
        max-width: 100%;
        border-radius: var(--radius-md);
    }
    
    .modal-header {
        padding: 12px 14px;
    }
    
    .modal-title {
        font-size: 14px;
    }
    
    .modal-close {
        font-size: 20px;
    }
    
    .modal-body {
        padding: 14px;
    }
    
    .modal-footer {
        padding: 10px 14px;
        gap: 8px;
    }
    
    /* 上传区域 */
    .upload-area {
        padding: 20px;
    }
    
    .upload-area .upload-icon {
        font-size: 28px;
    }
    
    .upload-area .upload-text {
        font-size: 12px;
    }
    
    .upload-area .upload-hint {
        font-size: 11px;
    }
    
    /* 登录页 */
    .login-container {
        padding: 24px 20px;
        max-width: 340px;
    }
    
    .login-header .logo {
        width: 48px;
        height: 48px;
        font-size: 20px;
        border-radius: 12px;
    }
    
    .login-header h1 {
        font-size: 18px;
    }
    
    .login-header p {
        font-size: 12px;
    }
    
    .login-form input {
        padding: 9px 12px;
        font-size: 12.5px;
    }
    
    .login-btn {
        padding: 9px;
        font-size: 13px;
    }
    
    /* 空状态 */
    .empty-state {
        padding: 30px 12px;
    }
    
    .empty-state .empty-icon {
        font-size: 40px;
    }
    
    /* 首页响应式 */
    .dashboard-home {
        padding: 0 0 12px;
    }
    
    .welcome-title {
        font-size: 18px;
    }
    
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .icon-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .icon-card {
        padding: 20px 14px;
        border-radius: 14px;
    }
    
    .icon-card-icon {
        width: 56px;
        height: 56px;
        font-size: 26px;
        border-radius: 16px;
    }
    
    .icon-card-name {
        font-size: 13px;
    }
    
    /* 版本更新区域响应式 */
    .version-update-card {
        padding: 16px;
    }
    
    .version-update-title {
        font-size: 14px;
        margin-bottom: 12px;
    }
    
    .version-fields {
        gap: 12px;
    }
    
    .version-input {
        padding: 9px 12px;
        font-size: 13px;
    }
    
    .version-save-btn {
        width: 100%;
        padding: 10px;
    }
    
    /* API配置区域响应式 */
    .api-config-card {
        padding: 16px;
    }
    
    .api-config-title {
        font-size: 14px;
        margin-bottom: 12px;
    }
    
    .api-fields {
        gap: 12px;
    }
    
    .api-field-input {
        padding: 9px 12px;
        font-size: 12.5px;
    }
    
    .api-save-btn {
        width: 100%;
        padding: 10px;
    }
    
    /* 主卡片网格响应式（平板端） - 双列横向圆角矩形 */
    .main-card-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 14px;
        margin-top: 10px;
    }
    
    .main-card {
        padding: 18px 16px;
        gap: 14px;
        border-radius: 22px;
        min-height: 80px;
        flex-direction: row;
        align-items: center;
    }
    
    .main-card-icon {
        width: 52px;
        height: 52px;
        font-size: 26px;
        border-radius: 50%;
    }
    
    .main-card-info {
        flex: 1;
        gap: 5px;
    }
    
    .main-card-name {
        font-size: 17px;
    }
    
    .main-card-desc {
        font-size: 13px;
    }
    
    /* 数据概览响应式 - 双列横向 */
    .stats-overview-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px;
    }
    
    .stats-overview-card {
        padding: 14px 12px;
        gap: 12px;
        border-radius: 16px;
    }
    
    .stats-overview-icon {
        width: 42px;
        height: 42px;
        font-size: 20px;
        border-radius: 12px;
    }
    
    .stats-overview-value {
        font-size: 22px;
    }
    
    .stats-overview-unit {
        font-size: 12px;
    }
    
    .stats-overview-bar {
        height: 6px;
    }
    
    .stats-overview-percent {
        font-size: 11px;
    }
    
    /* 功能模块响应式 - 双列 */
    .module-stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px;
    }
    
    .module-stat-item {
        padding: 14px 12px;
        gap: 10px;
        border-radius: 14px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .module-stat-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
        border-radius: 12px;
    }
    
    .module-stat-info {
        width: 100%;
    }
    
    .module-stat-name {
        font-size: 13px;
    }
    
    .module-stat-desc {
        font-size: 11.5px;
    }
    
    .module-stat-percent {
        font-size: 16px;
        align-self: flex-end;
    }
    
    /* 统计卡片响应式 */
    .stats-card-grid {
        gap: 10px;
    }
    
    .stats-card {
        padding: 16px 12px;
        gap: 8px;
    }
    
    .stats-card-icon {
        font-size: 24px;
    }
    
    .stats-card-value {
        font-size: 20px;
    }
    
    .stats-card-label {
        font-size: 11px;
    }
    
    /* 分组页面响应式 */
    .group-page {
        padding: 2px 0 16px;
    }
    
    .group-header {
        padding: 16px 18px;
        gap: 14px;
        border-radius: 20px;
    }
    
    .group-header-icon {
        width: 48px;
        height: 48px;
        font-size: 24px;
        border-radius: 50%;
    }
    
    .group-header-title {
        font-size: 17px;
    }
    
    .group-header-desc {
        font-size: 12px;
    }
    
    /* 二级图标响应式（平板端） - 双列横向圆角矩形 */
    .sub-icon-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px;
    }
    
    .sub-icon-card {
        padding: 16px 14px;
        gap: 12px;
        border-radius: 20px;
        min-height: 72px;
        flex-direction: row;
        align-items: center;
    }
    
    .sub-icon-badge {
        width: 48px;
        height: 48px;
        font-size: 24px;
        border-radius: 50%;
    }
    
    .sub-icon-content {
        flex: 1;
    }
    
    .sub-icon-name {
        font-size: 15px;
    }
    
    .sub-icon-desc {
        font-size: 11.5px;
    }
    
    /* 设置页面响应式 */
    .setting-page {
        padding: 2px 0 16px;
    }
    
    .page-title {
        font-size: 18px;
    }
    
    .page-desc {
        font-size: 12px;
    }
    
    .card-body {
        padding: 16px;
    }
}

/* 小屏手机 (≤ 480px) */
@media (max-width: 480px) {
    :root {
        --sidebar-width: 60px;
        --header-height: 44px;
    }
    
    body {
        font-size: 12px;
    }
    
    /* 侧边栏 - 图标模式 */
    .sidebar {
        width: 60px;
    }
    
    /* 小屏手机下收缩状态：完全隐藏 */
    .sidebar.collapsed {
        width: 0;
        overflow: hidden;
    }
    
    .main-content {
        margin-left: 60px;
    }
    
    .main-content.sidebar-collapsed {
        margin-left: 0;
    }
    
    .sidebar-logo {
        padding: 10px 8px;
        justify-content: center;
    }
    
    .sidebar-logo .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 14px;
        border-radius: 8px;
    }
    
    .sidebar-logo .logo-text {
        display: none;
    }
    
    .sidebar-menu {
        padding: 4px 0;
    }
    
    .menu-item {
        padding: 10px 8px;
        justify-content: center;
        position: relative;
    }
    
    .menu-item .menu-icon {
        font-size: 18px;
        width: auto;
    }
    
    .menu-item .menu-text {
        display: none;
    }
    
    .menu-item .menu-arrow {
        display: none;
    }
    
    /* 子菜单 - 小屏手机改为展开式，全宽显示 */
    .submenu {
        max-height: none;
        background: rgba(0, 0, 0, 0.3);
    }
    
    .submenu-item {
        padding: 8px 8px;
        justify-content: center;
        font-size: 10px;
    }
    
    .submenu-item .submenu-dot {
        display: none;
    }
    
    .submenu-item span:last-child {
        display: none;
    }
    
    /* 小屏下隐藏底部版权文字 */
    .sidebar-footer {
        display: none;
    }
    
    /* 顶部导航 */
    .header {
        padding: 0 10px;
        height: 44px;
    }
    
    .header-left {
        gap: 8px;
    }
    
    .header-title {
        font-size: 13px;
    }
    
    .header-right {
        gap: 8px;
    }
    
    .admin-info {
        padding: 3px 6px;
    }
    
    .admin-avatar {
        width: 24px;
        height: 24px;
        font-size: 10px;
    }
    
    /* 内容区 */
    .content {
        padding: 10px;
    }
    
    .page-header {
        margin-bottom: 12px;
        padding: 14px 16px;
        border-radius: 18px;
        gap: 12px;
    }
    
    .page-header-icon {
        width: 44px;
        height: 44px;
        font-size: 22px;
    }
    
    .page-title {
        font-size: 16px;
    }
    
    .page-desc {
        font-size: 11.5px;
    }
    
    /* 统计卡片 - 单列 */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .stat-card {
        padding: 12px;
    }
    
    .stat-icon {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }
    
    .stat-info .stat-value {
        font-size: 17px;
    }
    
    .stat-info .stat-label {
        font-size: 11px;
    }
    
    /* 卡片 */
    .card-header {
        padding: 8px 10px;
    }
    
    .card-title {
        font-size: 12px;
    }
    
    .card-body {
        padding: 10px;
    }
    
    .card-footer {
        padding: 8px 10px;
    }
    
    /* 表单 */
    .form-group {
        margin-bottom: 12px;
    }
    
    .form-label {
        font-size: 11.5px;
    }
    
    .form-input,
    .form-select,
    .form-textarea {
        padding: 6px 9px;
        font-size: 11.5px;
    }
    
    /* 按钮 */
    .btn {
        padding: 5px 9px;
        font-size: 11px;
    }
    
    .btn-sm {
        padding: 2px 5px;
        font-size: 10px;
    }
    
    /* 表格 */
    .data-table {
        min-width: 500px;
    }
    
    .data-table th,
    .data-table td {
        padding: 6px 8px;
        font-size: 11px;
    }
    
    /* 分页 */
    .page-btn {
        min-width: 26px;
        height: 24px;
        padding: 0 6px;
        font-size: 11px;
    }
    
    /* 模态框 */
    .modal-header {
        padding: 10px 12px;
    }
    
    .modal-title {
        font-size: 13px;
    }
    
    .modal-body {
        padding: 12px;
    }
    
    .modal-footer {
        padding: 8px 12px;
    }
    
    /* 登录页 */
    .login-container {
        padding: 20px 16px;
        max-width: 100%;
    }
    
    .login-header {
        margin-bottom: 20px;
    }
    
    .login-header .logo {
        width: 44px;
        height: 44px;
        font-size: 18px;
        border-radius: 10px;
        margin-bottom: 10px;
    }
    
    .login-header h1 {
        font-size: 17px;
    }
    
    .login-form .form-group {
        margin-bottom: 14px;
    }
    
    .login-form input {
        padding: 8px 11px;
        font-size: 12px;
    }
    
    .login-btn {
        padding: 8px;
        font-size: 12.5px;
    }
    
    /* 上传区域 */
    .upload-area {
        padding: 16px;
    }
    
    .upload-area .upload-icon {
        font-size: 24px;
        margin-bottom: 6px;
    }
    
    /* 空状态 */
    .empty-state {
        padding: 24px 10px;
    }
    
    .empty-state .empty-icon {
        font-size: 36px;
        margin-bottom: 10px;
    }
    
    /* 搜索栏 */
    .search-bar .form-group {
        min-width: 100%;
        flex: 1 1 100%;
    }
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 40px 16px;
    color: var(--text-light);
}

.empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.empty-state .empty-text {
    font-size: 14px;
    margin-bottom: 4px;
}

.empty-state .empty-desc {
    font-size: 12.5px;
}

/* Tab 切换 */
.tabs {
    display: flex;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 16px;
}

.tab-item {
    padding: 10px 16px;
    cursor: pointer;
    color: var(--text-secondary);
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    font-weight: 500;
    font-size: 13px;
}

.tab-item:hover {
    color: var(--text-primary);
}

.tab-item.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-content {
    display: none;
}

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

/* 排序提示 */
.sort-hint {
    font-size: 11.5px;
    color: var(--text-light);
    margin-bottom: 10px;
}

/* 聊天消息 */
.chat-message {
    padding: 10px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    gap: 10px;
}

.chat-message .chat-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    flex-shrink: 0;
}

.chat-message .chat-content {
    flex: 1;
}

.chat-message .chat-meta {
    font-size: 11px;
    color: var(--text-light);
    margin-bottom: 3px;
}

.chat-message .chat-text {
    font-size: 12.5px;
    color: var(--text-primary);
}

/* 徽标 */
.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
}

/* 代码样式 */
code {
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 12px;
}

/* 小屏手机首页适配 */
@media (max-width: 480px) {
    .dashboard-home {
        padding: 0 0 10px;
    }
    
    .welcome-greet {
        font-size: 12px;
    }
    
    .welcome-title {
        font-size: 18px;
    }
    
    .welcome-title-en {
        font-size: 13px;
    }
    
    .welcome-desc {
        font-size: 11px;
    }
    
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
        margin-bottom: 18px;
    }
    
    .stat-mini {
        padding: 10px;
        gap: 8px;
    }
    
    .stat-mini-icon {
        width: 34px;
        height: 34px;
        font-size: 16px;
    }
    
    .stat-mini-value {
        font-size: 15px;
    }
    
    .stat-mini-label {
        font-size: 10px;
    }
    
    .module-section {
        margin-bottom: 20px;
    }
    
    .module-title {
        font-size: 13px;
        margin-bottom: 10px;
    }
    
    .icon-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .icon-card {
        padding: 18px 12px;
        gap: 10px;
        border-radius: 14px;
    }
    
    .icon-card-icon {
        width: 52px;
        height: 52px;
        font-size: 24px;
        border-radius: 14px;
    }
    
    .icon-card-name {
        font-size: 12.5px;
    }
    
    .back-btn {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }
    
    .home-logo {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    
    .header-title {
        font-size: 14px;
    }
    
    /* 版本更新区域小屏适配 */
    .version-update-section {
        margin-top: 16px;
    }
    
    .version-update-card {
        padding: 14px;
    }
    
    .version-update-title {
        font-size: 13px;
        margin-bottom: 10px;
    }
    
    .version-icon {
        font-size: 16px;
    }
    
    .version-fields {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .version-label {
        font-size: 12px;
    }
    
    .version-input {
        padding: 8px 11px;
        font-size: 13px;
    }
    
    .version-save-btn {
        width: 100%;
        padding: 9px;
        font-size: 12.5px;
    }
    
    /* API配置区域小屏适配 */
    .api-config-section {
        margin-top: 16px;
    }
    
    .api-config-card {
        padding: 14px;
    }
    
    .api-config-title {
        font-size: 13px;
        margin-bottom: 10px;
    }
    
    .api-config-icon {
        font-size: 16px;
    }
    
    .api-fields {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .api-field-label {
        font-size: 12px;
    }
    
    .api-field-input {
        padding: 8px 11px;
        font-size: 12.5px;
    }
    
    .api-save-btn {
        width: 100%;
        padding: 9px;
        font-size: 12.5px;
    }
    
    /* 主卡片网格小屏适配 - 强制双列横向圆角矩形 */
    .main-card-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 12px;
        margin-top: 8px;
    }
    
    .main-card {
        padding: 16px 14px;
        gap: 12px;
        border-radius: 20px;
        min-height: 72px;
        flex-direction: row;
        align-items: center;
        aspect-ratio: auto;
    }
    
    .main-card-icon {
        width: 48px;
        height: 48px;
        font-size: 24px;
        border-radius: 50%;
    }
    
    .main-card-info {
        flex: 1;
        gap: 4px;
    }
    
    .main-card-name {
        font-size: 15px;
    }
    
    .main-card-desc {
        font-size: 12px;
    }
    
    /* 数据概览小屏适配 - 双列横向 */
    .stats-overview-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px;
    }
    
    .stats-overview-card {
        padding: 14px 10px;
        gap: 8px;
        border-radius: 14px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .stats-overview-icon {
        width: 40px;
        height: 40px;
        font-size: 20px;
        border-radius: 12px;
    }
    
    .stats-overview-info {
        width: 100%;
    }
    
    .stats-overview-label {
        font-size: 11px;
    }
    
    .stats-overview-value {
        font-size: 22px;
    }
    
    .stats-overview-unit {
        font-size: 11px;
    }
    
    .stats-overview-bar {
        height: 5px;
    }
    
    .stats-overview-percent {
        font-size: 10.5px;
    }
    
    /* 功能模块小屏适配 - 双列 */
    .module-stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 8px;
    }
    
    .module-stat-item {
        padding: 12px 10px;
        gap: 8px;
        border-radius: 12px;
        flex-direction: column;
        align-items: flex-start;
    }
    
    .module-stat-icon {
        width: 36px;
        height: 36px;
        font-size: 18px;
        border-radius: 10px;
    }
    
    .module-stat-info {
        width: 100%;
    }
    
    .module-stat-name {
        font-size: 12.5px;
    }
    
    .module-stat-desc {
        font-size: 11px;
    }
    
    .module-stat-percent {
        font-size: 15px;
        align-self: flex-end;
    }
    
    /* 统计卡片小屏适配 */
    .stats-section {
        margin-top: 22px;
    }
    
    .stats-section-title {
        font-size: 14px;
        margin-bottom: 12px;
    }
    
    .stats-card-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    
    .stats-card {
        padding: 14px 10px;
        gap: 6px;
        border-radius: 12px;
    }
    
    .stats-card-icon {
        font-size: 22px;
    }
    
    .stats-card-value {
        font-size: 18px;
    }
    
    .stats-card-label {
        font-size: 10.5px;
    }
    
    /* 分组页面小屏适配 */
    .group-page {
        padding: 0 0 14px;
    }
    
    .group-header {
        padding: 14px 16px;
        gap: 12px;
        border-radius: 18px;
    }
    
    .group-header-icon {
        width: 44px;
        height: 44px;
        font-size: 22px;
        border-radius: 50%;
    }
    
    .group-header-title {
        font-size: 16px;
    }
    
    .group-header-desc {
        font-size: 11.5px;
    }
    
    /* 二级图标小屏适配 - 双列横向圆角矩形 */
    .sub-icon-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px;
    }
    
    .sub-icon-card {
        padding: 14px 12px;
        gap: 10px;
        border-radius: 18px;
        min-height: 66px;
        flex-direction: row;
        align-items: center;
    }
    
    .sub-icon-badge {
        width: 42px;
        height: 42px;
        font-size: 20px;
        border-radius: 50%;
    }
    
    .sub-icon-content {
        flex: 1;
    }
    
    .sub-icon-name {
        font-size: 13.5px;
    }
    
    .sub-icon-desc {
        font-size: 10.5px;
    }
    
    .sub-icon-arrow {
        display: none;
    }
    
    /* 设置页面小屏适配 */
    .setting-page {
        padding: 0 0 14px;
    }
    
    .page-title {
        font-size: 16px;
    }
    
    .page-desc {
        font-size: 11.5px;
    }
    
    .card-body {
        padding: 14px;
    }
    
    .card-footer {
        padding: 14px;
        flex-direction: column;
    }
    
    .card-footer .btn {
        width: 100%;
    }
}

/* ========================================
   MIUI 双列横向卡片 - 强制覆盖样式
   ======================================== */

/* 首页主卡片 - 强制双列横向 */
body .main-card-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    width: 100% !important;
}

body .main-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    background: #ffffff !important;
    border-radius: 22px !important;
    padding: 18px 16px !important;
    gap: 14px !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04) !important;
    border: 1px solid #e5e7eb !important;
    text-decoration: none !important;
    min-height: 78px !important;
    aspect-ratio: auto !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

body .main-card-icon {
    width: 52px !important;
    height: 52px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 26px !important;
    flex-shrink: 0 !important;
    color: #ffffff !important;
}

body .main-card-info {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    flex: 1 !important;
    min-width: 0 !important;
    text-align: left !important;
}

body .main-card-name {
    font-size: 17px !important;
    font-weight: 600 !important;
    color: #1f2937 !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 0 !important;
}

body .main-card-desc {
    font-size: 12px !important;
    color: #6b7280 !important;
    line-height: 1.4 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 0 !important;
}

/* 主卡片图标颜色 */
body .main-card-blue .main-card-icon { background: linear-gradient(135deg, #3b82f6, #6366f1) !important; }
body .main-card-purple .main-card-icon { background: linear-gradient(135deg, #8b5cf6, #a855f7) !important; }
body .main-card-orange .main-card-icon { background: linear-gradient(135deg, #f97316, #f59e0b) !important; }
body .main-card-emerald .main-card-icon { background: linear-gradient(135deg, #10b981, #14b8a6) !important; }
body .main-card-red .main-card-icon { background: linear-gradient(135deg, #ef4444, #f97316) !important; }
body .main-card-indigo .main-card-icon { background: linear-gradient(135deg, #6366f1, #8b5cf6) !important; }

/* 数据概览 - 强制双列 */
body .stats-overview-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
    width: 100% !important;
}

body .stats-overview-card {
    background: #ffffff !important;
    border-radius: 16px !important;
    padding: 14px 12px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 8px !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04) !important;
    border: 1px solid #e5e7eb !important;
    box-sizing: border-box !important;
}

body .stats-overview-icon {
    width: 40px !important;
    height: 40px !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 20px !important;
}

body .stats-overview-info {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
}

body .stats-overview-label {
    font-size: 12px !important;
    color: #6b7280 !important;
    font-weight: 500 !important;
}

body .stats-overview-value {
    font-size: 22px !important;
    font-weight: 700 !important;
    color: #1f2937 !important;
    line-height: 1.2 !important;
}

body .stats-overview-unit {
    font-size: 12px !important;
    font-weight: 500 !important;
    color: #6b7280 !important;
    margin-left: 2px !important;
}

body .stats-overview-bar {
    height: 6px !important;
    background: #f3f4f6 !important;
    border-radius: 3px !important;
    overflow: hidden !important;
}

body .stats-overview-fill {
    height: 100% !important;
    border-radius: 3px !important;
}

body .stats-fill-user { background: linear-gradient(90deg, #3b82f6, #6366f1) !important; }
body .stats-fill-card { background: linear-gradient(90deg, #8b5cf6, #a855f7) !important; }
body .stats-fill-sign { background: linear-gradient(90deg, #10b981, #14b8a6) !important; }
body .stats-fill-comment { background: linear-gradient(90deg, #f59e0b, #f97316) !important; }

body .stats-overview-percent {
    font-size: 11px !important;
    color: #6b7280 !important;
    font-weight: 500 !important;
}

/* 功能模块 - 强制双列 */
body .module-stats-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
    width: 100% !important;
}

body .module-stat-item {
    background: #ffffff !important;
    border-radius: 16px !important;
    padding: 14px 12px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 10px !important;
    box-shadow: 0 1px 4px rgba(0,0,0,0.03) !important;
    border: 1px solid #e5e7eb !important;
    box-sizing: border-box !important;
}

body .module-stat-icon {
    width: 44px !important;
    height: 44px !important;
    border-radius: 14px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 22px !important;
    color: #ffffff !important;
}

body .module-stat-info {
    width: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 2px !important;
}

body .module-stat-name {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #1f2937 !important;
}

body .module-stat-desc {
    font-size: 12px !important;
    color: #6b7280 !important;
}

body .module-stat-percent {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #6366f1 !important;
    align-self: flex-end !important;
    margin-top: auto !important;
}

/* 二级页面卡片 - 强制双列横向 */
body .sub-icon-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
    width: 100% !important;
}

body .sub-icon-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    background: #ffffff !important;
    border-radius: 22px !important;
    padding: 18px 16px !important;
    gap: 14px !important;
    box-shadow: 0 2px 10px rgba(0,0,0,0.04) !important;
    border: 1px solid #e5e7eb !important;
    text-decoration: none !important;
    min-height: 78px !important;
    aspect-ratio: auto !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

body .sub-icon-badge {
    width: 52px !important;
    height: 52px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 26px !important;
    flex-shrink: 0 !important;
    color: #ffffff !important;
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
}

body .sub-icon-content {
    display: flex !important;
    flex-direction: column !important;
    gap: 4px !important;
    flex: 1 !important;
    min-width: 0 !important;
    text-align: left !important;
}

body .sub-icon-name {
    font-size: 17px !important;
    font-weight: 600 !important;
    color: #1f2937 !important;
    line-height: 1.3 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 0 !important;
}

body .sub-icon-desc {
    font-size: 12px !important;
    color: #6b7280 !important;
    line-height: 1.4 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    margin: 0 !important;
}

body .sub-icon-arrow {
    display: none !important;
}

/* 板块标题 */
body .stats-section-title {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: #1f2937 !important;
    margin: 24px 0 14px 0 !important;
}

/* 欢迎区 */
body .welcome-section {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.08)) !important;
    border-radius: 20px !important;
    padding: 24px 20px !important;
    border: 1px solid rgba(99, 102, 241, 0.12) !important;
    margin-bottom: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
}

body .welcome-greet {
    font-size: 14px !important;
    color: #6b7280 !important;
    margin: 0 0 3px 0 !important;
    font-weight: 500 !important;
}

body .welcome-title {
    font-size: 22px !important;
    font-weight: 700 !important;
    color: #1f2937 !important;
    margin: 0 0 4px 0 !important;
    line-height: 1.25 !important;
}

body .welcome-title-en {
    font-size: 13px !important;
    color: #9ca3af !important;
    margin: 0 0 6px 0 !important;
    font-weight: 400 !important;
    opacity: 0.8 !important;
}

body .welcome-desc {
    font-size: 13px !important;
    color: #6b7280 !important;
    margin: 0 !important;
}

/* 底部版权 */
body .dashboard-footer {
    text-align: center !important;
    padding: 30px 20px 20px !important;
    color: #9ca3af !important;
    font-size: 13px !important;
}

/* MIUI 风格 - 平板端响应式 */
@media (max-width: 768px) {
    body .main-card-grid {
        gap: 14px !important;
        margin-top: 10px !important;
    }
    body .main-card {
        padding: 18px 16px !important;
        gap: 14px !important;
        border-radius: 22px !important;
        min-height: 80px !important;
    }
    body .main-card-icon {
        width: 52px !important;
        height: 52px !important;
        font-size: 26px !important;
    }
    body .main-card-info {
        gap: 5px !important;
    }
    body .main-card-name {
        font-size: 17px !important;
    }
    body .main-card-desc {
        font-size: 13px !important;
    }
    body .dashboard-footer {
        padding: 14px 16px 10px !important;
        font-size: 12px !important;
    }
}

/* MIUI 风格 - 小屏手机响应式 */
@media (max-width: 480px) {
    body .main-card-grid {
        gap: 12px !important;
        margin-top: 8px !important;
    }
    body .main-card {
        padding: 16px 14px !important;
        gap: 12px !important;
        border-radius: 20px !important;
        min-height: 72px !important;
    }
    body .main-card-icon {
        width: 48px !important;
        height: 48px !important;
        font-size: 24px !important;
    }
    body .main-card-info {
        gap: 4px !important;
    }
    body .main-card-name {
        font-size: 15px !important;
    }
    body .main-card-desc {
        font-size: 12px !important;
    }
    body .dashboard-footer {
        padding: 10px 12px 6px !important;
        font-size: 11px !important;
    }
}


/* ========================================
   渐变卡片背景样式 v2.1
   ======================================== */

/* 主卡片渐变背景 - 白色文字 */
body .main-card {
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
    border: none !important;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3) !important;
}

body .main-card-name {
    color: #ffffff !important;
}

body .main-card-desc {
    color: rgba(255, 255, 255, 0.8) !important;
}

body .main-card-icon {
    background: rgba(255, 255, 255, 0.25) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* 主卡片各颜色渐变变体 */
body .main-card-blue {
    background: linear-gradient(135deg, #3b82f6, #6366f1) !important;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.35) !important;
}
body .main-card-purple {
    background: linear-gradient(135deg, #8b5cf6, #a855f7) !important;
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.35) !important;
}
body .main-card-orange {
    background: linear-gradient(135deg, #f97316, #fbbf24) !important;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.35) !important;
}
body .main-card-emerald {
    background: linear-gradient(135deg, #10b981, #34d399) !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.35) !important;
}
body .main-card-red {
    background: linear-gradient(135deg, #ef4444, #f97316) !important;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.35) !important;
}
body .main-card-indigo {
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35) !important;
}

/* 二级卡片渐变背景 */
body .sub-icon-card {
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
    border: none !important;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3) !important;
}

body .sub-icon-name {
    color: #ffffff !important;
}

body .sub-icon-desc {
    color: rgba(255, 255, 255, 0.8) !important;
}

body .sub-icon-badge {
    background: rgba(255, 255, 255, 0.25) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

/* 数据概览渐变卡片 */
body .stats-overview-card {
    background: linear-gradient(135deg, #ffffff, #f9fafb) !important;
    border: 1px solid #e5e7eb !important;
}

/* 功能模块渐变卡片 */
body .module-stat-item {
    background: linear-gradient(135deg, #ffffff, #f9fafb) !important;
    border: 1px solid #e5e7eb !important;
}

/* ===== 支付管理页面样式 ===== */

/* 支付方式总览网格 */
.payment-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}

.payment-overview-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: 16px;
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #ffffff, #f9fafb);
}

.payment-overview-card.is-enabled {
    border-color: #10b981;
    box-shadow: 0 2px 12px rgba(16, 185, 129, 0.15);
}

.payment-overview-card.is-disabled {
    opacity: 0.6;
}

.payment-overview-icon {
    font-size: 2rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(99, 102, 241, 0.1);
    flex-shrink: 0;
}

.payment-overview-info {
    flex: 1;
    min-width: 0;
}

.payment-overview-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.payment-overview-status {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.payment-mode-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 500;
}

.payment-mode-badge.mode-qr {
    background: #fef3c7;
    color: #92400e;
}

.payment-mode-badge.mode-api {
    background: #dbeafe;
    color: #1e40af;
}

.payment-status-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 500;
}

.payment-status-badge.status-on {
    background: #d1fae5;
    color: #065f46;
}

.payment-status-badge.status-off {
    background: #fee2e2;
    color: #991b1b;
}

/* 支付配置卡片 */
.payment-config-card {
    margin-bottom: 20px !important;
}

/* 支付方式标题栏 */
.payment-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f3f4f6;
}

.payment-card-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.payment-card-icon {
    font-size: 1.8rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(99, 102, 241, 0.1);
    flex-shrink: 0;
}

.payment-card-icon.payment-color-blue { background: rgba(59, 130, 246, 0.1); }
.payment-card-icon.payment-color-green { background: rgba(34, 197, 94, 0.1); }
.payment-card-icon.payment-color-sky { background: rgba(14, 165, 233, 0.1); }
.payment-card-icon.payment-color-red { background: rgba(239, 68, 68, 0.1); }
.payment-card-icon.payment-color-indigo { background: rgba(99, 102, 241, 0.1); }

.payment-card-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1f2937;
}

.payment-card-type {
    font-size: 0.8rem;
    color: #9ca3af;
    margin-top: 2px;
}

/* 开关组件 */
.payment-toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
    cursor: pointer;
    flex-shrink: 0;
}

.payment-toggle-checkbox {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.payment-toggle-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #d1d5db;
    border-radius: 28px;
    transition: 0.3s;
}

.payment-toggle-slider::before {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    left: 3px;
    bottom: 3px;
    background: #ffffff;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.payment-toggle-checkbox:checked + .payment-toggle-slider {
    background: #10b981;
}

.payment-toggle-checkbox:checked + .payment-toggle-slider::before {
    transform: translateX(22px);
}

/* 模式切换标签 */
.payment-mode-switcher {
    margin-bottom: 20px;
}

.mode-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.mode-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 16px 12px;
    border: 2px solid #e5e7eb;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    background: #f9fafb;
    position: relative;
}

.mode-tab:hover {
    border-color: #c4b5fd;
    background: #f5f3ff;
}

.mode-tab.active {
    border-color: #667eea;
    background: linear-gradient(135deg, #eef2ff, #f5f3ff);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
}

.mode-tab input[type="radio"] {
    display: none;
}

.mode-tab-icon {
    font-size: 1.8rem;
    line-height: 1;
}

.mode-tab-text {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
}

.mode-tab-desc {
    font-size: 0.72rem;
    color: #9ca3af;
    line-height: 1.3;
}

.mode-tab.active .mode-tab-text {
    color: #4f46e5;
}

/* 二维码上传区域 */
.qr-upload-area {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.qr-preview-box {
    width: 200px;
    height: 200px;
    border: 2px dashed #d1d5db;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: #f9fafb;
    flex-shrink: 0;
}

.qr-preview-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.qr-preview-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    opacity: 0;
    transition: opacity 0.3s;
}

.qr-preview-box:hover .qr-preview-overlay {
    opacity: 1;
}

.qr-preview-overlay span {
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    background: rgba(0, 0, 0, 0.6);
    padding: 4px 12px;
    border-radius: 8px;
}

.qr-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #9ca3af;
}

.qr-placeholder-icon {
    font-size: 3rem;
}

.qr-placeholder-text {
    font-size: 0.85rem;
}

.qr-upload-controls {
    flex: 1;
    min-width: 200px;
}

.qr-file-input {
    padding: 10px !important;
}

/* API模式区域 */
.mode-api-section .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

/* 支付颜色类 */
.payment-color-blue { color: #3b82f6; }
.payment-color-green { color: #22c55e; }
.payment-color-sky { color: #0ea5e9; }
.payment-color-red { color: #ef4444; }
.payment-color-indigo { color: #6366f1; }

/* 响应式适配 */
@media (max-width: 768px) {
    .payment-overview-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .mode-tabs {
        grid-template-columns: 1fr;
    }

    .qr-upload-area {
        flex-direction: column;
        align-items: stretch;
    }

    .qr-preview-box {
        width: 100%;
        max-width: 240px;
        margin: 0 auto;
    }

    .mode-api-section .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .payment-overview-grid {
        grid-template-columns: 1fr;
    }

    .payment-overview-card {
        padding: 12px;
    }

    .payment-overview-icon {
        font-size: 1.5rem;
        width: 40px;
        height: 40px;
    }

    .payment-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .payment-toggle {
        align-self: flex-end;
    }
}

/* ===== 官网管理页面样式 ===== */

.card-section-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 16px;
}

.card-section-desc {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 16px;
    margin-top: -10px;
}

/* 模板网格 */
.template-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
}

.template-card {
    position: relative;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
}

.template-card:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.15);
}

.template-card.selected {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.template-preview {
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.template-icon {
    font-size: 2.5rem;
}

.template-info {
    padding: 12px;
    text-align: center;
}

.template-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.template-desc {
    font-size: 0.75rem;
    color: #9ca3af;
}

.template-check {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background: #667eea;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
}

/* 颜色选择器行 */
.color-picker-row {
    display: flex;
    align-items: center;
}

.color-picker-row input[type="color"] {
    width: 48px;
    height: 42px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    cursor: pointer;
}

/* 复选框组 */
.checkbox-group {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 20px;
    padding: 16px;
    background: #f9fafb;
    border-radius: 12px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #374151;
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #667eea;
}

/* 网站列表 */
.website-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.website-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    flex-wrap: wrap;
    gap: 12px;
}

.website-item.is-offline {
    opacity: 0.6;
}

.website-item-info {
    flex: 1;
    min-width: 200px;
}

.website-item-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.website-item-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1f2937;
}

.website-item-template {
    font-size: 0.72rem;
    padding: 2px 8px;
    background: #eef2ff;
    color: #4f46e5;
    border-radius: 6px;
}

.website-item-domain {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 4px;
}

.website-item-status {
    font-size: 0.75rem;
    font-weight: 500;
}

.website-item-status.status-online { color: #10b981; }
.website-item-status.status-offline { color: #9ca3af; }

.website-item-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ===== 一键部署页面样式 ===== */

/* 部署步骤 */
.deploy-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.deploy-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #eef2ff, #f5f3ff);
    border-radius: 14px;
    border: 1px solid #c7d2fe;
}

.deploy-step-num {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.deploy-step-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
}

.deploy-step-desc {
    font-size: 0.75rem;
    color: #6b7280;
}

.deploy-step-arrow {
    font-size: 1.2rem;
    color: #9ca3af;
}

/* APK上传区 */
.apk-upload-zone {
    border: 2px dashed #d1d5db;
    border-radius: 16px;
    padding: 32px 20px;
    text-align: center;
    margin-bottom: 20px;
    background: #f9fafb;
    transition: all 0.3s ease;
    position: relative;
    cursor: pointer;
}

.apk-upload-zone:hover,
.apk-upload-zone.drag-over {
    border-color: #667eea;
    background: #f5f3ff;
}

.apk-upload-icon {
    font-size: 3rem;
    margin-bottom: 8px;
}

.apk-upload-text {
    font-size: 0.95rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 4px;
}

.apk-upload-hint {
    font-size: 0.8rem;
    color: #9ca3af;
}

.apk-upload-zone input[type="file"] {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
}

.apk-file-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
    padding: 8px 16px;
    background: #d1fae5;
    border-radius: 8px;
    font-size: 0.85rem;
}

.apk-file-name {
    font-weight: 600;
    color: #065f46;
}

.apk-file-size {
    color: #047857;
}

/* 部署配置区 */
.deploy-config-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #f3f4f6;
}

.deploy-config-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #4f46e5;
    margin-bottom: 16px;
}

/* 自动对接后台状态提示 */
.deploy-api-status {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(139, 92, 246, 0.08));
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.15);
    margin-top: 16px;
}

.deploy-api-status-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.deploy-api-status-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.deploy-api-status-text strong {
    font-size: 14px;
    font-weight: 600;
    color: #4338ca;
}

.deploy-api-status-text span {
    font-size: 12px;
    color: #6b7280;
    line-height: 1.4;
}

@media (max-width: 480px) {
    .deploy-api-status {
        flex-wrap: wrap;
    }
    .deploy-api-status .btn {
        width: 100%;
        margin-top: 8px;
    }
}

/* 部署列表 */
.deploy-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.deploy-item {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: #f9fafb;
    border-radius: 14px;
    border: 1px solid #e5e7eb;
    align-items: flex-start;
    flex-wrap: wrap;
}

.deploy-item.is-deployed {
    border-color: #86efac;
    background: #f0fdf4;
}

.deploy-item.is-pending {
    border-color: #fde68a;
    background: #fffbeb;
}

.deploy-item-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.deploy-item-info {
    flex: 1;
    min-width: 200px;
}

.deploy-item-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.deploy-item-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1f2937;
}

.deploy-item-version {
    font-size: 0.75rem;
    padding: 2px 8px;
    background: #eef2ff;
    color: #4f46e5;
    border-radius: 6px;
}

.deploy-item-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.deploy-meta-tag {
    font-size: 0.75rem;
    color: #6b7280;
    background: #fff;
    padding: 2px 8px;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}

.deploy-status-tag {
    font-size: 0.75rem;
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 500;
}

.deploy-status-deployed {
    background: #d1fae5;
    color: #065f46;
}

.deploy-status-pending {
    background: #fef3c7;
    color: #92400e;
}

.deploy-item-changelog {
    font-size: 0.8rem;
    color: #6b7280;
    margin-bottom: 8px;
    line-height: 1.5;
}

.deploy-item-download {
    margin-bottom: 4px;
}

.deploy-download-link {
    font-size: 0.8rem;
    color: #4f46e5;
    text-decoration: none;
}

.deploy-download-link:hover {
    text-decoration: underline;
}

.deploy-item-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    align-items: center;
}

/* ===== 主题模式页面样式 ===== */

/* 主题预览区 */
.theme-preview-area {
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.theme-preview-label {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 12px;
}

.theme-preview-device {
    width: 280px;
    max-width: 100%;
    border: 4px solid #1f2937;
    border-radius: 28px;
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.theme-preview-screen {
    background: #f0f2f5;
    min-height: 400px;
    transition: background 0.3s ease;
}

.theme-preview-statusbar {
    display: flex;
    justify-content: space-between;
    padding: 8px 16px;
    font-size: 0.75rem;
    color: inherit;
}

.theme-preview-navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    background: #667eea;
    color: #fff;
    font-size: 0.85rem;
    transition: background 0.3s ease;
}

.theme-preview-nav-icon,
.theme-preview-nav-action {
    font-size: 0.8rem;
}

.theme-preview-nav-title {
    font-weight: 600;
}

.theme-preview-content {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.theme-preview-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: background 0.3s ease, color 0.3s ease;
}

.theme-preview-card-icon {
    font-size: 1.5rem;
}

.theme-preview-card-title {
    font-size: 0.85rem;
    font-weight: 600;
}

.theme-preview-card-desc {
    font-size: 0.72rem;
    color: #6b7280;
}

/* 主题模式网格 */
.theme-mode-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.theme-mode-card {
    position: relative;
    border: 2px solid #e5e7eb;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fff;
}

.theme-mode-card:hover {
    border-color: #a5b4fc;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.12);
}

.theme-mode-card.selected {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.theme-mode-card input[type="radio"] {
    display: none;
}

.theme-mode-preview {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
}

.theme-mode-mini-card {
    width: 60px;
    height: 50px;
    border-radius: 8px;
    border: 1px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-direction: column;
}

.theme-mode-mini-icon {
    font-size: 1rem;
}

.theme-mode-mini-text {
    font-size: 0.7rem;
    font-weight: 600;
}

.theme-mode-info {
    padding: 12px;
    text-align: center;
}

.theme-mode-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
}

.theme-mode-desc {
    font-size: 0.72rem;
    color: #9ca3af;
}

.theme-mode-check {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 24px;
    height: 24px;
    background: #667eea;
    color: #fff;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
}

.theme-mode-card.selected .theme-mode-check {
    display: flex;
}

/* 主题配置摘要 */
.theme-config-summary {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.theme-config-item {
    flex: 1;
    min-width: 180px;
    padding: 16px;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.theme-config-label {
    display: block;
    font-size: 0.8rem;
    color: #6b7280;
    margin-bottom: 4px;
}

.theme-config-value {
    display: block;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
}

/* 响应式 */
@media (max-width: 768px) {
    .template-grid,
    .theme-mode-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .deploy-steps {
        flex-direction: column;
    }

    .deploy-step-arrow {
        transform: rotate(90deg);
    }

    .checkbox-group {
        grid-template-columns: 1fr;
    }

    .theme-config-summary {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .template-grid,
    .theme-mode-grid {
        grid-template-columns: 1fr;
    }

    .theme-preview-device {
        width: 100%;
    }
}

/* ===== 域名管理页面样式 ===== */

/* 主域名卡片 */
.domain-primary-card {
    background: linear-gradient(135deg, #667eea, #764ba2) !important;
    border: none !important;
}

.domain-primary-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.domain-primary-icon {
    font-size: 2.5rem;
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.domain-primary-label {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 4px;
}

.domain-primary-name {
    font-size: 1.4rem;
    font-weight: 700;
    color: #fff;
}

.domain-primary-badge {
    margin-left: auto;
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.25);
    color: #fff;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 600;
    flex-shrink: 0;
}

.domain-primary-desc {
    margin-top: 12px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

/* 域名列表 */
.domain-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.domain-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    flex-wrap: wrap;
    gap: 12px;
}

.domain-item.is-disabled {
    opacity: 0.5;
}

.domain-item-main {
    flex: 1;
    min-width: 180px;
}

.domain-item-name {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1f2937;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.domain-item-icon {
    font-size: 1.1rem;
}

.domain-redirect-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    background: #fef3c7;
    color: #92400e;
    border-radius: 6px;
    font-weight: 500;
}

.domain-item-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.domain-meta-tag {
    font-size: 0.72rem;
    padding: 2px 8px;
    border-radius: 6px;
    background: #fff;
    color: #6b7280;
    border: 1px solid #e5e7eb;
}

.domain-meta-tag.tag-active {
    background: #d1fae5;
    color: #065f46;
    border-color: #6ee7b7;
}

.domain-meta-tag.tag-inactive {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fca5a5;
}

.domain-item-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* Nginx配置框 */
.nginx-config-box {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
}

.nginx-config-toolbar {
    display: flex;
    gap: 8px;
    padding: 12px;
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    flex-wrap: wrap;
}

.nginx-config-text {
    width: 100%;
    min-height: 300px;
    padding: 16px;
    font-family: 'Courier New', monospace;
    font-size: 0.82rem;
    line-height: 1.5;
    background: #1e293b;
    color: #e2e8f0;
    border: none;
    border-radius: 0;
    resize: vertical;
}

.nginx-config-text:focus {
    outline: none;
}

/* 修复步骤 */
.domain-fix-card {
    border-color: #fde68a !important;
    background: #fffbeb !important;
}

.fix-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.fix-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: #fff;
    border-radius: 12px;
    border: 1px solid #fde68a;
}

.fix-step-num {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.fix-step-content {
    flex: 1;
}

.fix-step-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1f2937;
}

.fix-step-desc {
    font-size: 0.78rem;
    color: #6b7280;
    margin-top: 2px;
}

/* 响应式 */
@media (max-width: 768px) {
    .domain-primary-header {
        flex-wrap: wrap;
    }

    .domain-primary-badge {
        margin-left: 0;
    }

    .domain-item {
        flex-direction: column;
        align-items: stretch;
    }

    .domain-item-actions {
        justify-content: flex-start;
    }
}

/* ===== 登录页面增强样式 ===== */

/* 首页欢迎区快捷登录配置方形卡片（与控制台主卡片统一风格） */
.welcome-oauth-card {
    width: auto;
    min-width: 140px;
    height: auto;
    border-radius: 22px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    flex-shrink: 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    padding: 14px 16px;
}

.welcome-oauth-card::before {
    display: none;
}

.welcome-oauth-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}

.welcome-oauth-card:active {
    transform: scale(0.98);
}

.oauth-card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}

.oauth-card-label {
    font-size: 15px;
    color: var(--text-primary);
    font-weight: 600;
    position: relative;
    z-index: 1;
}

/* 欢迎区右侧操作组（双卡片垂直排列） */
.welcome-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex-shrink: 0;
}

/* 退出登录表单 */
.welcome-logout-form {
    margin: 0;
    padding: 0;
    display: block;
}

/* 退出登录卡片按钮 */
.welcome-logout-card {
    width: 100%;
    border: none;
    outline: none;
    font-family: inherit;
    text-align: left;
}

.welcome-logout-card .oauth-card-icon {
    background: linear-gradient(135deg, #ef4444, #f97316);
}

@media (max-width: 480px) {
    .welcome-oauth-card {
        min-width: 120px;
        border-radius: 20px;
        gap: 10px;
        padding: 12px 14px;
    }
    .oauth-card-icon {
        width: 42px;
        height: 42px;
        border-radius: 50%;
    }
    .oauth-card-icon svg {
        width: 24px;
        height: 24px;
    }
    .oauth-card-label {
        font-size: 14px;
    }
}

/* 欢迎区英文标题 */
.welcome-title-en {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0 0 6px 0;
    font-weight: 400;
    opacity: 0.8;
}

/* body前缀高优先级覆盖 - 确保登录配置卡片与主卡片统一风格 */
body .welcome-oauth-card {
    width: auto !important;
    min-width: 140px !important;
    height: auto !important;
    border-radius: 22px !important;
    background: var(--bg-card) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04) !important;
    flex-direction: row !important;
    padding: 14px 16px !important;
    gap: 12px !important;
}

body .oauth-card-icon {
    width: 48px !important;
    height: 48px !important;
    border-radius: 50% !important;
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
}

body .oauth-card-label {
    font-size: 15px !important;
    color: var(--text-primary) !important;
    font-weight: 600 !important;
}

@media (max-width: 480px) {
    body .welcome-oauth-card {
        min-width: 120px !important;
        border-radius: 20px !important;
        padding: 12px 14px !important;
        gap: 10px !important;
    }
    body .oauth-card-icon {
        width: 42px !important;
        height: 42px !important;
    }
    body .oauth-card-label {
        font-size: 14px !important;
    }
}

/* 欢迎区右侧操作组 */
body .welcome-actions {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    flex-shrink: 0 !important;
}

/* 退出登录表单 */
.welcome-logout-form {
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
}

/* 退出登录卡片按钮 */
body .welcome-logout-card {
    width: 100% !important;
    cursor: pointer !important;
    font-family: inherit !important;
    text-align: left !important;
}

body .welcome-logout-card .oauth-card-icon {
    background: linear-gradient(135deg, #ef4444, #f97316) !important;
}

body .welcome-logout-card:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08) !important;
}

body .welcome-logout-card:active {
    transform: scale(0.98) !important;
}

@media (max-width: 480px) {
    body .welcome-actions {
        gap: 10px !important;
    }
}

/* 密码可见性切换 */
.password-input-wrapper {
    position: relative;
}

.password-input-wrapper input {
    width: 100%;
    padding-right: 42px !important;
    box-sizing: border-box;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.password-toggle:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.password-toggle.active {
    color: #667eea;
}

/* Tab切换 - 登录/注册 */
.login-tabs {
    display: flex;
    gap: 0;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 4px;
}

.login-tab {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    color: #9ca3af;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s;
}

.login-tab.active {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
}

/* 登录方式切换 */
.login-method-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.login-method-tab {
    flex: 1;
    text-align: center;
    padding: 8px 0;
    color: #9ca3af;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 0.82rem;
    transition: all 0.3s;
}

.login-method-tab.active {
    color: #fff;
    background: rgba(102, 126, 234, 0.2);
    border-color: #667eea;
}

/* SMS验证码输入 */
.sms-group .sms-input-row {
    display: flex;
    gap: 10px;
}

.sms-group .sms-input-row input {
    flex: 1;
}

.sms-btn {
    white-space: nowrap;
    padding: 0 16px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: all 0.3s;
    min-width: 100px;
}

.sms-btn:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-1px);
}

.sms-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.sms-msg {
    text-align: center;
    font-size: 0.78rem;
    margin-top: 8px;
    min-height: 16px;
}

/* 快捷登录分割线 */
.quick-login-divider {
    text-align: center;
    margin: 24px 0 16px;
    position: relative;
    color: #6b7280;
    font-size: 0.8rem;
}

.quick-login-divider::before,
.quick-login-divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 30%;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.quick-login-divider::before { left: 0; }
.quick-login-divider::after { right: 0; }

/* 快捷登录按钮 */
.quick-login-buttons {
    display: flex;
    justify-content: center;
    gap: 16px;
}

.quick-login-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #9ca3af;
    text-decoration: none;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.3s;
    width: 72px;
    text-align: center;
}

.quick-login-btn:hover {
    transform: translateY(-3px);
    border-color: rgba(255, 255, 255, 0.2);
}

.quick-login-btn svg {
    width: 28px;
    height: 28px;
}

.qq-btn:hover { background: rgba(18, 183, 245, 0.1); color: #12B7F5; }
.wechat-btn:hover { background: rgba(9, 184, 63, 0.1); color: #09B83F; }
.phone-btn:hover { background: rgba(255, 107, 53, 0.1); color: #FF6B35; }

/* OAuth弹窗 */
.oauth-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.oauth-modal.show {
    display: flex;
}

.oauth-modal-content {
    background: #1e293b;
    border-radius: 20px;
    padding: 0;
    width: 90%;
    max-width: 360px;
    overflow: hidden;
    animation: modalSlideIn 0.3s ease;
}

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

.oauth-modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.oauth-modal-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}

.qq-icon { background: linear-gradient(135deg, #12B7F5, #0d8ecf); }
.wechat-icon { background: linear-gradient(135deg, #09B83F, #07a135); font-size: 0.65rem; }

.oauth-modal-header h3 {
    font-size: 1.05rem;
    color: #fff;
    margin: 0;
}

.oauth-close {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9ca3af;
    font-size: 1.1rem;
    cursor: pointer;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.oauth-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.oauth-modal-body {
    padding: 24px 20px;
}

.oauth-desc {
    color: #9ca3af;
    font-size: 0.82rem;
    margin-bottom: 16px;
    line-height: 1.5;
}

.oauth-input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: #fff;
    font-size: 0.9rem;
    margin-bottom: 16px;
    box-sizing: border-box;
    transition: all 0.3s;
}

.oauth-input:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
}

.oauth-input::placeholder { color: #6b7280; }

.oauth-submit-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 10px;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.qq-submit { background: linear-gradient(135deg, #12B7F5, #0d8ecf); }
.wechat-submit { background: linear-gradient(135deg, #09B83F, #07a135); }

.oauth-submit-btn:hover:not(:disabled) {
    opacity: 0.9;
    transform: translateY(-1px);
}

.oauth-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* 登录页底部 */
.login-footer {
    margin-top: 24px;
    text-align: center;
    color: #6b7280;
    font-size: 0.75rem;
}

/* 头像图片样式 */
.admin-avatar-img {
    overflow: hidden;
}

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

.admin-avatar-auto {
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
}

/* 响应式 - 手机端 */
@media (max-width: 480px) {
    .quick-login-buttons {
        gap: 10px;
    }
    
    .quick-login-btn {
        width: 64px;
        padding: 10px 6px;
    }
    
    .quick-login-btn svg {
        width: 24px;
        height: 24px;
    }
    
    .quick-login-btn span {
        font-size: 0.7rem;
    }
    
    .sms-group .sms-input-row {
        flex-direction: row;
    }
    
    .sms-btn {
        min-width: 90px;
        font-size: 0.72rem;
        padding: 0 12px;
    }
    
    .oauth-modal-content {
        width: 92%;
    }
}

/* ============================================================
   主题模式 - 深色 / 白色 全局覆盖（放在最后确保优先级最高）
   ============================================================ */

/* ---------- 深色模式覆盖 ---------- */
html body.theme-dark {
    background: #0f0f1a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .layout {
    background: #0f0f1a !important;
}

html body.theme-dark .main-content {
    background: #0f0f1a !important;
}

html body.theme-dark .content {
    background: #0f0f1a !important;
}

/* 头部 */
html body.theme-dark .header {
    background: #1a1a2e !important;
    border-bottom: 1px solid #2d2d4a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .header-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .back-btn {
    color: #f3f4f6 !important;
}

html body.theme-dark .admin-name {
    color: #f3f4f6 !important;
}

/* 卡片 */
html body.theme-dark .card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .card-body {
    color: #f3f4f6 !important;
}

html body.theme-dark .card-section-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .card-section-desc {
    color: #9ca3af !important;
}

html body.theme-dark .card-footer {
    border-top-color: #2d2d4a !important;
    background: #16162a !important;
}

/* 表单 */
html body.theme-dark .form-input,
html body.theme-dark input.form-input,
html body.theme-dark textarea.form-input,
html body.theme-dark select.form-input {
    background: #16162a !important;
    border: 1px solid #2d2d4a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .form-input:focus {
    border-color: #818cf8 !important;
    outline: none !important;
}

html body.theme-dark .form-input::placeholder {
    color: #9ca3af !important;
}

html body.theme-dark .form-label {
    color: #e5e7eb !important;
}

html body.theme-dark .form-hint {
    color: #9ca3af !important;
}

/* 文件输入框深色模式 - 修复"未选择任何文件"文字颜色 */
html body.theme-dark input[type="file"] {
    color: #e5e7eb !important;
    color-scheme: dark !important;
}
html body.theme-dark input[type="file"]::file-selector-button {
    background: #2d2d4a !important;
    color: #f3f4f6 !important;
    border: 1px solid #3d3d5a !important;
    border-radius: 8px !important;
    padding: 6px 14px !important;
    margin-right: 10px !important;
    cursor: pointer !important;
}
html body.theme-dark input[type="file"]::file-selector-button:hover {
    background: #3d3d5a !important;
}

/* 欢迎区 */
html body.theme-dark .welcome-section {
    background: linear-gradient(135deg, rgba(129, 140, 248, 0.12), rgba(118, 75, 162, 0.12)) !important;
    border: 1px solid rgba(129, 140, 248, 0.2) !important;
}

html body.theme-dark .welcome-greet {
    color: #9ca3af !important;
}

html body.theme-dark .welcome-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .welcome-title-en {
    color: #6b7280 !important;
}

html body.theme-dark .welcome-desc {
    color: #9ca3af !important;
}

/* 数据概览 */
html body.theme-dark .stats-section-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .stats-overview-card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .stats-overview-label {
    color: #9ca3af !important;
}

html body.theme-dark .stats-overview-value {
    color: #f3f4f6 !important;
}

html body.theme-dark .stats-overview-unit {
    color: #9ca3af !important;
}

html body.theme-dark .stats-overview-bar {
    background: #2d2d4a !important;
}

html body.theme-dark .stats-overview-percent span {
    color: #9ca3af !important;
}

/* 功能模块 - 深色模式覆盖（修复微信内置浏览器颜色不一致问题） */
html body.theme-dark .module-stat-item {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .module-stat-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .module-stat-desc {
    color: #9ca3af !important;
}

html body.theme-dark .module-stat-percent {
    color: #818cf8 !important;
}

/* 二级页面卡片深色模式 */
html body.theme-dark .sub-icon-card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .sub-icon-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .sub-icon-desc {
    color: #9ca3af !important;
}

/* 支付管理卡片深色模式 */
html body.theme-dark .payment-overview-card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

/* 主功能卡片 */
html body.theme-dark .main-card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .main-card-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .main-card-desc {
    color: #9ca3af !important;
}

html body.theme-dark .main-card-stat-text {
    color: #9ca3af !important;
}

html body.theme-dark .main-card-stat-bar {
    background: #2d2d4a !important;
}

/* 主题选择卡片 */
html body.theme-dark .theme-select-card {
    background: #1e1e3a !important;
    border-color: transparent !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .theme-select-card.active {
    border-color: #818cf8 !important;
    box-shadow: 0 4px 16px rgba(129, 140, 248, 0.3) !important;
}

html body.theme-dark .theme-select-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .theme-select-desc {
    color: #9ca3af !important;
}

html body.theme-dark .theme-tip-item strong {
    color: #f3f4f6 !important;
}

html body.theme-dark .theme-tip-item p {
    color: #9ca3af !important;
}

html body.theme-dark .theme-tip-icon {
    background: rgba(129, 140, 248, 0.15) !important;
}

/* 部署步骤 */
html body.theme-dark .deploy-step {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .deploy-step-num {
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
    color: #fff !important;
}

html body.theme-dark .deploy-step-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .deploy-step-desc {
    color: #9ca3af !important;
}

html body.theme-dark .deploy-step-arrow {
    color: #6b7280 !important;
}

/* 部署列表 */
html body.theme-dark .deploy-item {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .deploy-item-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .deploy-item-version {
    color: #818cf8 !important;
}

html body.theme-dark .deploy-meta-tag {
    background: rgba(129, 140, 248, 0.15) !important;
    color: #a5b4fc !important;
}

html body.theme-dark .deploy-item-changelog {
    color: #9ca3af !important;
}

html body.theme-dark .deploy-download-link {
    color: #818cf8 !important;
}

/* 自动对接状态卡片 */
html body.theme-dark .deploy-api-status {
    background: linear-gradient(135deg, rgba(129, 140, 248, 0.1), rgba(139, 92, 246, 0.1)) !important;
    border-color: rgba(129, 140, 248, 0.2) !important;
}

html body.theme-dark .deploy-api-status-text strong {
    color: #a5b4fc !important;
}

html body.theme-dark .deploy-api-status-text span {
    color: #9ca3af !important;
}

/* 状态标签 */
html body.theme-dark .deploy-status-tag.deploy-status-deployed {
    background: rgba(16, 185, 129, 0.15) !important;
    color: #34d399 !important;
}

html body.theme-dark .deploy-status-tag.deploy-status-pending {
    background: rgba(245, 158, 11, 0.15) !important;
    color: #fbbf24 !important;
}

/* 按钮 */
html body.theme-dark .btn-outline {
    border-color: #2d2d4a !important;
    color: #f3f4f6 !important;
    background: transparent !important;
}

html body.theme-dark .btn-outline:hover {
    background: rgba(129, 140, 248, 0.1) !important;
    border-color: #818cf8 !important;
}

html body.theme-dark .btn-sm {
    color: #f3f4f6 !important;
}

/* 页脚 */
html body.theme-dark .dashboard-footer p {
    color: #6b7280 !important;
}

/* 页面标题 */
html body.theme-dark .page-header {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .page-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .page-desc {
    color: #9ca3af !important;
}

/* 分组头部 - 深色模式 */
html body.theme-dark .group-header {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .group-header-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .group-header-desc {
    color: #9ca3af !important;
}

/* 表格 */
html body.theme-dark table {
    color: #f3f4f6 !important;
}

html body.theme-dark th {
    background: #16162a !important;
    color: #f3f4f6 !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark td {
    border-color: #2d2d4a !important;
}

/* 提示弹窗 */
html body.theme-dark .alert {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    color: #f3f4f6 !important;
}

/* 登录页 - 修复类名匹配实际HTML */
html body.theme-dark .login-page {
    background: linear-gradient(135deg, #0f0f1a 0%, #1a1a3e 100%) !important;
}

html body.theme-dark .login-container {
    background: #1a1a2e !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
}

html body.theme-dark .login-header h1 {
    color: #f3f4f6 !important;
}

html body.theme-dark .login-header p {
    color: #9ca3af !important;
}

html body.theme-dark .login-form label {
    color: #e5e7eb !important;
}

html body.theme-dark .login-form input {
    background: #16162a !important;
    border-color: #2d2d4a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .login-form input::placeholder {
    color: #6b7280 !important;
}

html body.theme-dark .login-form input:focus {
    border-color: #818cf8 !important;
    box-shadow: 0 0 0 3px rgba(129, 140, 248, 0.15) !important;
}

html body.theme-dark .login-tab {
    color: #9ca3af !important;
}

html body.theme-dark .login-tab.active {
    background: linear-gradient(135deg, #6366f1, #8b5cf6) !important;
    color: #fff !important;
}

html body.theme-dark .login-tabs {
    background: rgba(255, 255, 255, 0.05) !important;
}

html body.theme-dark .quick-login-text {
    color: #6b7280 !important;
}

html body.theme-dark .quick-login-divider::before,
html body.theme-dark .quick-login-divider::after {
    background: #2d2d4a !important;
}

html body.theme-dark .quick-login-btn {
    background: rgba(255, 255, 255, 0.05) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #9ca3af !important;
}

html body.theme-dark .login-footer {
    color: #6b7280 !important;
}

html body.theme-dark .password-toggle {
    color: #6b7280 !important;
}

html body.theme-dark .alert {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    color: #f3f4f6 !important;
}

/* OAuth 弹窗 */
html body.theme-dark .oauth-modal-content {
    background: #1e1e3a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .oauth-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .oauth-desc {
    color: #9ca3af !important;
}

/* 快捷登录配置卡片 - 深色模式 */
html body.theme-dark .welcome-oauth-card {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .oauth-card-label {
    color: #f3f4f6 !important;
}

/* ===== 全面深色模式修复 - 补全所有界面缺失的深色覆盖 ===== */

/* 数据概览百分比（元素本身） */
html body.theme-dark .stats-overview-percent {
    color: #9ca3af !important;
}

/* 支付管理页面 */
html body.theme-dark .payment-overview-name { color: #f3f4f6 !important; }
html body.theme-dark .payment-config-card {
    background: #1e1e3a !important; border-color: #2d2d4a !important; color: #f3f4f6 !important;
}
html body.theme-dark .payment-config-label { color: #9ca3af !important; }
html body.theme-dark .mode-tab { background: #16162a !important; border-color: #2d2d4a !important; }
html body.theme-dark .mode-tab.active {
    background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(139,92,246,0.15)) !important;
    border-color: #818cf8 !important;
}
html body.theme-dark .mode-tab-text { color: #f3f4f6 !important; }
html body.theme-dark .mode-tab.active .mode-tab-text { color: #a5b4fc !important; }
html body.theme-dark .payment-toggle-slider { background: #2d2d4a !important; }
html body.theme-dark .payment-toggle-slider::before { background: #f3f4f6 !important; }

/* 支付状态标签 */
html body.theme-dark .payment-mode-badge.mode-qr { background: rgba(245,158,11,0.15) !important; color: #fbbf24 !important; }
html body.theme-dark .payment-mode-badge.mode-api { background: rgba(59,130,246,0.15) !important; color: #60a5fa !important; }
html body.theme-dark .payment-status-badge.status-on { background: rgba(16,185,129,0.15) !important; color: #34d399 !important; }
html body.theme-dark .payment-status-badge.status-off { background: rgba(239,68,68,0.15) !important; color: #f87171 !important; }

/* 支付管理文字颜色优化 - 深色模式下全部改为白色/浅色 */
html body.theme-dark .payment-card-name { color: #ffffff !important; }
html body.theme-dark .payment-card-type { color: #f3f4f6 !important; }
html body.theme-dark .payment-card-header { border-bottom-color: #2d2d4a !important; }
html body.theme-dark .mode-tab-desc { color: #e5e7eb !important; }
html body.theme-dark .mode-tab-icon { opacity: 1 !important; }
html body.theme-dark .qr-placeholder { color: #e5e7eb !important; }
html body.theme-dark .qr-placeholder-text { color: #e5e7eb !important; }
html body.theme-dark .qr-placeholder-icon { opacity: 0.8 !important; }
html body.theme-dark .qr-preview-overlay span { color: #ffffff !important; }
html body.theme-dark .qr-upload-area { color: #f3f4f6 !important; }
html body.theme-dark .qr-upload-controls { color: #f3f4f6 !important; }
html body.theme-dark .payment-mode-section { color: #f3f4f6 !important; }
html body.theme-dark .payment-form { color: #f3f4f6 !important; }
html body.theme-dark .payment-overview-status { color: #f3f4f6 !important; }
html body.theme-dark .payment-card-title { color: #f3f4f6 !important; }
html body.theme-dark .payment-overview-info { color: #f3f4f6 !important; }
html body.theme-dark .payment-overview-card.is-disabled { opacity: 0.7 !important; }
html body.theme-dark .mode-tab input[type="radio"] { color: #f3f4f6 !important; }

/* 模板卡片 */
html body.theme-dark .template-card { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .template-name { color: #f3f4f6 !important; }
html body.theme-dark .template-desc { color: #9ca3af !important; }

/* 主题预览/模式卡片 */
html body.theme-dark .theme-preview-card { background: #1e1e3a !important; box-shadow: 0 1px 3px rgba(0,0,0,0.3) !important; }
html body.theme-dark .theme-preview-name { color: #f3f4f6 !important; }
html body.theme-dark .theme-preview-card-desc { color: #9ca3af !important; }
html body.theme-dark .theme-mode-card { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .theme-mode-name { color: #f3f4f6 !important; }
html body.theme-dark .theme-mode-desc { color: #9ca3af !important; }
html body.theme-dark .theme-config-item { background: #16162a !important; border-color: #2d2d4a !important; }
html body.theme-dark .theme-config-label { color: #9ca3af !important; }
html body.theme-dark .theme-config-value { color: #f3f4f6 !important; }
html body.theme-dark .theme-preview-label { color: #9ca3af !important; }

/* 网站管理 */
html body.theme-dark .website-item-name { color: #f3f4f6 !important; }
html body.theme-dark .website-item-domain { color: #9ca3af !important; }
html body.theme-dark .website-item-template { background: rgba(99,102,241,0.15) !important; color: #a5b4fc !important; }

/* 域名管理 */
html body.theme-dark .domain-item-name { color: #f3f4f6 !important; }
html body.theme-dark .domain-meta-tag { background: #16162a !important; color: #9ca3af !important; border-color: #2d2d4a !important; }
html body.theme-dark .domain-meta-tag.tag-active { background: rgba(16,185,129,0.15) !important; color: #34d399 !important; }
html body.theme-dark .domain-meta-tag.tag-inactive { background: rgba(107,114,128,0.15) !important; color: #9ca3af !important; }
html body.theme-dark .domain-redirect-badge { background: rgba(245,158,11,0.15) !important; color: #fbbf24 !important; }
html body.theme-dark .domain-fix-card { background: rgba(245,158,11,0.08) !important; border-color: rgba(245,158,11,0.2) !important; }
html body.theme-dark .fix-step { background: #1e1e3a !important; border-color: rgba(245,158,11,0.2) !important; }
html body.theme-dark .fix-step-title { color: #f3f4f6 !important; }
html body.theme-dark .fix-step-desc { color: #9ca3af !important; }
html body.theme-dark .nginx-config-text { background: #16162a !important; border-color: #2d2d4a !important; color: #f3f4f6 !important; }

/* 部署列表 */
html body.theme-dark .deploy-item { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .deploy-item.is-deployed { background: rgba(16,185,129,0.08) !important; border-color: rgba(16,185,129,0.2) !important; }
html body.theme-dark .deploy-item-version { background: rgba(99,102,241,0.15) !important; color: #a5b4fc !important; }
html body.theme-dark .deploy-status-deployed { background: rgba(16,185,129,0.15) !important; color: #34d399 !important; }
html body.theme-dark .deploy-status-pending { background: rgba(245,158,11,0.15) !important; color: #fbbf24 !important; }

/* 上传区域 */
html body.theme-dark .apk-upload-zone { background: #16162a !important; border-color: #2d2d4a !important; }
html body.theme-dark .apk-upload-zone:hover,
html body.theme-dark .apk-upload-zone.drag-over { background: rgba(99,102,241,0.1) !important; border-color: #818cf8 !important; }
html body.theme-dark .qr-preview-box { border-color: #2d2d4a !important; background: #16162a !important; }

/* 充值二维码区域 */
html body.theme-dark .recharge-qr-section { background: linear-gradient(135deg, #1a1a2e, #1e1e3a) !important; border-color: #2d2d4a !important; }
html body.theme-dark .recharge-qr-title { color: #f3f4f6 !important; }

/* 选择框/下拉框深色适配 */
html body.theme-dark select.form-select {
    background: #16162a !important; border: 1px solid #2d2d4a !important; color: #f3f4f6 !important;
}
html body.theme-dark select.form-select option { background: #16162a !important; color: #f3f4f6 !important; }

/* 模态弹窗深色适配 */
html body.theme-dark .modal {
    background: #1e1e3a !important; border-color: #2d2d4a !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
}
html body.theme-dark .modal-header { border-bottom-color: #2d2d4a !important; }
html body.theme-dark .modal-title { color: #f3f4f6 !important; }
html body.theme-dark .modal-close { color: #9ca3af !important; }
html body.theme-dark .modal-footer { border-top-color: #2d2d4a !important; }

/* 搜索栏深色适配 */
html body.theme-dark .search-bar { gap: 8px !important; }

/* 分页深色适配 */
html body.theme-dark .pagination a,
html body.theme-dark .pagination span {
    background: #1e1e3a !important; border-color: #2d2d4a !important; color: #9ca3af !important;
}
html body.theme-dark .pagination .active a,
html body.theme-dark .pagination .active span {
    background: #6366f1 !important; border-color: #6366f1 !important; color: #fff !important;
}

/* 状态标签通用深色适配 */
html body.theme-dark .status-badge.status-active { background: rgba(16,185,129,0.15) !important; color: #34d399 !important; }
html body.theme-dark .status-badge.status-disabled { background: rgba(107,114,128,0.15) !important; color: #9ca3af !important; }

/* 数据表格行hover深色适配 */
html body.theme-dark .data-table tbody tr:hover { background: rgba(129,140,248,0.05) !important; }

/* 补充遗漏的深色模式覆盖 */
html body.theme-dark .mode-tab:hover { background: rgba(99,102,241,0.1) !important; border-color: #818cf8 !important; }
html body.theme-dark .checkbox-group { background: #16162a !important; border-radius: 12px !important; }
html body.theme-dark .website-item { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .domain-item { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .nginx-config-toolbar { background: #16162a !important; border-bottom-color: #2d2d4a !important; }

/* 签到页面深色适配 */
html body.theme-dark .sign-calendar { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .sign-day { background: #16162a !important; border-color: #2d2d4a !important; color: #9ca3af !important; }
html body.theme-dark .sign-day.signed { background: rgba(16,185,129,0.15) !important; color: #34d399 !important; }
html body.theme-dark .sign-day.today { border-color: #818cf8 !important; }

/* 评论/聊天深色适配 */
html body.theme-dark .comment-item { background: #1e1e3a !important; border-color: #2d2d4a !important; }
html body.theme-dark .comment-content { color: #f3f4f6 !important; }
html body.theme-dark .comment-meta { color: #9ca3af !important; }

/* 通用文本颜色兜底 */
html body.theme-dark .text-primary { color: #f3f4f6 !important; }
html body.theme-dark .text-secondary { color: #9ca3af !important; }
html body.theme-dark .text-muted { color: #6b7280 !important; }

/* ---------- 白色模式覆盖 ---------- */
html body.theme-light {
    background-color: #ffffff !important;
    color: #1f2937 !important;
}

html body.theme-light .layout,
html body.theme-light .main-content,
html body.theme-light .content {
    background: #ffffff !important;
}

html body.theme-light .card {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #f3f4f6 !important;
}

html body.theme-light .welcome-section {
    background: linear-gradient(135deg, #f8fafc, #ffffff) !important;
    border: 1px solid #e5e7eb !important;
}

html body.theme-light .header {
    background: #ffffff !important;
    border-bottom: 1px solid #e5e7eb !important;
}

html body.theme-light .main-card {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #f3f4f6 !important;
}

html body.theme-light .stats-overview-card {
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05) !important;
    border: 1px solid #f3f4f6 !important;
}

html body.theme-light .form-input {
    background: #ffffff !important;
    border: 1px solid #e5e7eb !important;
}

html body.theme-light .deploy-api-status {
    background: linear-gradient(135deg, #f5f3ff, #ede9fe) !important;
    border: 1px solid #ddd6fe !important;
}

html body.theme-light .deploy-api-status-text strong {
    color: #5b21b6 !important;
}

/* ===== 钱包管理页面 ===== */
.wallet-balance-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 24px;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.35);
    position: relative;
    overflow: hidden;
}

.wallet-balance-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.wallet-balance-card::after {
    content: '';
    position: absolute;
    bottom: -30%;
    right: 10%;
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 50%;
}

.wallet-balance-left {
    position: relative;
    z-index: 1;
}

.wallet-balance-label {
    font-size: 14px;
    opacity: 0.85;
    margin-bottom: 8px;
}

.wallet-balance-amount {
    font-size: 36px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.wallet-balance-frozen {
    font-size: 12px;
    opacity: 0.75;
}

.wallet-balance-right {
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.wallet-balance-stat {
    text-align: right;
    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    backdrop-filter: blur(10px);
}

.wallet-stat-label {
    display: block;
    font-size: 11px;
    opacity: 0.8;
    margin-bottom: 2px;
}

.wallet-stat-value {
    display: block;
    font-size: 16px;
    font-weight: 600;
}

.wallet-action-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 8px;
}

.wallet-action-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 20px 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.wallet-action-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.wallet-action-icon {
    font-size: 32px;
    margin-bottom: 4px;
}

.wallet-action-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.wallet-action-desc {
    font-size: 11px;
    color: var(--text-secondary);
}

.wallet-action-recharge .wallet-action-icon { filter: hue-rotate(0deg); }
.wallet-action-withdraw .wallet-action-icon { filter: hue-rotate(0deg); }
.wallet-action-bind .wallet-action-icon { filter: hue-rotate(0deg); }

/* 快捷充值 */
.quick-recharge-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 14px;
}

.quick-recharge-item {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border: 2px solid transparent;
    border-radius: 14px;
    padding: 16px 10px;
    text-align: center;
    cursor: pointer;
    transition: all 0.25s;
}

.quick-recharge-item:hover {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, #eef2ff, #e0e7ff);
    transform: translateY(-2px);
}

.quick-recharge-amount {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.quick-recharge-hint {
    font-size: 11px;
    color: var(--text-secondary);
}

/* 钱包记录列表 */
.wallet-record-list {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 1px;
    background: var(--border-color);
    border-radius: 12px;
    overflow: hidden;
}

.wallet-record-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    background: var(--bg-card);
}

.wallet-record-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.wallet-record-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    flex-shrink: 0;
}

.wallet-record-icon.wechat { background: #dcfce7; }
.wallet-record-icon.alipay { background: #dbeafe; }
.wallet-record-icon.qq { background: #ede9fe; }

.wallet-record-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.wallet-record-time {
    font-size: 11px;
    color: var(--text-light);
}

.wallet-record-right {
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.wallet-record-amount {
    font-size: 15px;
    font-weight: 700;
}

.wallet-record-amount.recharge {
    color: #10b981;
}

.wallet-record-amount.withdraw {
    color: #ef4444;
}

.wallet-record-status {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 8px;
    display: inline-block;
}

.wallet-record-status.status-0 {
    background: #fef3c7;
    color: #d97706;
}

.wallet-record-status.status-1 {
    background: #dcfce7;
    color: #059669;
}

.wallet-record-status.status-2 {
    background: #dbeafe;
    color: #2563eb;
}

.wallet-record-status.status-3 {
    background: #fee2e2;
    color: #dc2626;
}

/* 绑定账户列表 */
.binding-list {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.binding-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.binding-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.binding-icon.binding-wechat { background: #dcfce7; }
.binding-icon.binding-alipay { background: #dbeafe; }
.binding-icon.binding-qq { background: #ede9fe; }

.binding-info {
    flex: 1;
}

.binding-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.binding-default {
    font-size: 10px;
    padding: 1px 6px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: #fff;
    border-radius: 6px;
    font-weight: 500;
}

.binding-account {
    font-size: 12px;
    color: var(--text-secondary);
}

.binding-status {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 8px;
    flex-shrink: 0;
}

.binding-status.binding-active {
    background: #dcfce7;
    color: #059669;
}

/* 绑定账户操作按钮 */
.binding-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.binding-btn {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s ease;
}

.binding-btn-default {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
    border: 1px solid rgba(245, 158, 11, 0.2);
}

.binding-btn-default:hover {
    background: rgba(245, 158, 11, 0.2);
}

.binding-btn-delete {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.binding-btn-delete:hover {
    background: rgba(239, 68, 68, 0.2);
}

/* 弹窗 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
}

.modal-content {
    background: var(--bg-card);
    border-radius: 20px;
    width: 100%;
    max-width: 420px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlideUp 0.3s ease;
}

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

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    width: 28px;
    height: 28px;
    border: none;
    background: transparent;
    font-size: 24px;
    color: var(--text-secondary);
    cursor: pointer;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    display: flex;
    gap: 10px;
    padding: 16px 20px;
    border-top: 1px solid var(--border-color);
}

.modal-footer .btn {
    flex: 1;
}

/* 支付方式选择 */
.pay-method-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.pay-method-item input {
    display: none;
}

.pay-method-box {
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.25s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.pay-method-item input:checked + .pay-method-box {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08), rgba(118, 75, 162, 0.08));
}

.pay-method-icon {
    font-size: 26px;
}

.pay-method-name {
    font-size: 12px;
    color: var(--text-primary);
    font-weight: 500;
}

/* 充值模式选择 */
.pay-mode-options {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pay-mode-item {
    flex: 1;
    min-width: 80px;
}

.pay-mode-item input {
    display: none;
}

.pay-mode-item span {
    display: block;
    text-align: center;
    padding: 10px 8px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    font-size: 12px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.25s;
}

.pay-mode-item input:checked + span {
    border-color: var(--primary-color);
    color: var(--primary-color);
    background: rgba(102, 126, 234, 0.08);
}

/* 提现余额提示 */
.withdraw-balance-tip {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 16px;
}

.withdraw-balance-tip strong {
    font-size: 16px;
    font-weight: 700;
}

/* 表单复选框 */
.form-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 13px;
    color: var(--text-secondary);
}

.form-checkbox input {
    width: 16px;
    height: 16px;
    accent-color: var(--primary-color);
}

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 30px 20px;
    color: var(--text-secondary);
}

.empty-icon {
    font-size: 40px;
    margin-bottom: 10px;
    opacity: 0.6;
}

.empty-state p {
    margin: 0;
    font-size: 13px;
}

/* 大弹窗 */
.modal-large {
    max-width: 520px !important;
}

/* 记录Tab切换 */
.records-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    background: var(--bg-secondary, #f1f5f9);
    border-radius: 12px;
    padding: 4px;
}

.records-tab {
    flex: 1;
    text-align: center;
    padding: 10px 12px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary, #6b7280);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.records-tab:hover {
    background: var(--bg-card, #fff);
}

.records-tab-active {
    background: var(--bg-card, #fff);
    color: var(--text-primary, #1f2937);
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

.records-tab-badge {
    background: var(--primary-color, #6366f1);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 10px;
    line-height: 1.4;
}

.records-panel {
    animation: fadeIn 0.3s ease;
}

/* 弹窗内绑定列表微调 */
.binding-list-modal .binding-item {
    padding: 12px 14px;
}

.binding-list-modal .binding-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 20px;
}

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

/* 深色模式适配 - 钱包 */
html body.theme-dark .wallet-action-card {
    background: #1e1e3a !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3) !important;
}

html body.theme-dark .wallet-action-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .wallet-action-desc {
    color: #9ca3af !important;
}

html body.theme-dark .quick-recharge-item {
    background: #16162a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .quick-recharge-item:hover {
    border-color: #818cf8 !important;
    background: rgba(129, 140, 248, 0.1) !important;
}

html body.theme-dark .quick-recharge-amount {
    color: #f3f4f6 !important;
}

html body.theme-dark .wallet-record-item {
    background: #1e1e3a !important;
}

html body.theme-dark .wallet-record-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .wallet-record-time {
    color: #6b7280 !important;
}

html body.theme-dark .binding-item {
    background: #1e1e3a !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .binding-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .binding-account {
    color: #9ca3af !important;
}

/* 深色模式 - 绑定按钮 */
html body.theme-dark .binding-btn {
    border-color: transparent !important;
}
html body.theme-dark .binding-btn-default {
    background: rgba(245, 158, 11, 0.15) !important;
    color: #fbbf24 !important;
}
html body.theme-dark .binding-btn-delete {
    background: rgba(239, 68, 68, 0.15) !important;
    color: #f87171 !important;
}
html body.theme-dark .binding-status.binding-active {
    background: rgba(34, 197, 94, 0.15) !important;
    color: #4ade80 !important;
}

html body.theme-dark .modal-content {
    background: #1e1e3a !important;
}

html body.theme-dark .modal-header {
    border-color: #2d2d4a !important;
}

html body.theme-dark .modal-header h3 {
    color: #f3f4f6 !important;
}

html body.theme-dark .modal-footer {
    border-color: #2d2d4a !important;
}

html body.theme-dark .pay-method-box {
    border-color: #2d2d4a !important;
}

html body.theme-dark .pay-method-item input:checked + .pay-method-box {
    border-color: #818cf8 !important;
    background: rgba(129, 140, 248, 0.15) !important;
}

html body.theme-dark .pay-method-name {
    color: #f3f4f6 !important;
}

html body.theme-dark .pay-mode-item span {
    border-color: #2d2d4a !important;
    color: #9ca3af !important;
}

html body.theme-dark .pay-mode-item input:checked + span {
    border-color: #818cf8 !important;
    color: #a5b4fc !important;
    background: rgba(129, 140, 248, 0.15) !important;
}

html body.theme-dark .withdraw-balance-tip {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(251, 191, 36, 0.1)) !important;
    color: #fbbf24 !important;
}

html body.theme-dark .form-checkbox {
    color: #9ca3af !important;
}

html body.theme-dark .wallet-record-list {
    background: #2d2d4a !important;
}

html body.theme-dark .records-tabs {
    background: #16162a !important;
}

html body.theme-dark .records-tab {
    color: #9ca3af !important;
}

html body.theme-dark .records-tab:hover {
    background: #2d2d4a !important;
}

html body.theme-dark .records-tab-active {
    background: #2d2d4a !important;
    color: #f3f4f6 !important;
}

html body.theme-dark .records-tab-badge {
    background: #6366f1 !important;
    color: #fff !important;
}

html body.theme-dark .empty-state {
    color: #6b7280 !important;
}

/* 充值二维码区域 */
.recharge-qr-section {
    margin-top: 20px;
    padding: 20px;
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border-radius: 18px;
    border: 1px solid var(--border-color);
    display: none;
    animation: qrFadeIn 0.4s ease;
}

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

.recharge-qr-title {
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 16px;
}

.recharge-qr-title span {
    color: #07c160;
}

.recharge-qr-box {
    display: flex;
    justify-content: center;
    margin-bottom: 16px;
}

.recharge-qr-placeholder {
    width: 180px;
    height: 180px;
    border: 2px dashed #07c16040;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(135deg, #07c16008, #07c16015);
    transition: all 0.3s;
}

.qr-icon {
    font-size: 48px;
}

.qr-amount {
    font-size: 22px;
    font-weight: 700;
    color: var(--text-primary);
}

.qr-tip {
    font-size: 12px;
    color: var(--text-secondary);
}

/* 二维码图片显示区 */
.recharge-qr-image-wrap {
    width: 200px;
    height: 200px;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e5e7eb;
    background: #ffffff;
}

.recharge-qr-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.recharge-qr-amount-badge {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    text-align: center;
    padding: 4px 0;
    font-size: 14px;
    font-weight: 700;
    color: #ffffff;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.recharge-qr-info {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 14px 16px;
    margin-bottom: 12px;
}

.qr-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 0;
    font-size: 13px;
}

.qr-info-row span {
    color: var(--text-secondary);
}

.qr-info-row strong {
    color: var(--text-primary);
    font-weight: 600;
}

.qr-pending {
    color: #f59e0b !important;
}

.recharge-qr-tip {
    font-size: 12px;
    color: var(--text-secondary);
    text-align: center;
    line-height: 1.5;
    padding: 10px 14px;
    background: rgba(245, 158, 11, 0.08);
    border-radius: 10px;
}

/* 深色模式 - 充值二维码 */
html body.theme-dark .recharge-qr-section {
    background: linear-gradient(135deg, #16162a, #1e1e3a) !important;
    border-color: #2d2d4a !important;
}

html body.theme-dark .recharge-qr-title {
    color: #f3f4f6 !important;
}

html body.theme-dark .qr-amount {
    color: #f3f4f6 !important;
}

html body.theme-dark .qr-tip {
    color: #9ca3af !important;
}

html body.theme-dark .recharge-qr-info {
    background: #16162a !important;
}

html body.theme-dark .qr-info-row span {
    color: #9ca3af !important;
}

html body.theme-dark .qr-info-row strong {
    color: #f3f4f6 !important;
}

html body.theme-dark .recharge-qr-tip {
    background: rgba(251, 191, 36, 0.1) !important;
    color: #fbbf24 !important;
}

/* 深色模式 - 二维码图片区 */
html body.theme-dark .recharge-qr-image-wrap {
    border-color: #2d2d4a !important;
    background: #ffffff !important;
}

html body.theme-dark .recharge-qr-placeholder {
    border-color: #2d2d4a !important;
    background: linear-gradient(135deg, #16162a, #1e1e3a) !important;
}

/* 响应式 */
@media (max-width: 480px) {
    .wallet-balance-card {
        padding: 20px;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .wallet-balance-right {
        flex-direction: row;
        width: 100%;
        gap: 10px;
    }
    .wallet-balance-stat {
        flex: 1;
        text-align: center;
        padding: 10px 8px;
    }
    .wallet-balance-amount {
        font-size: 30px;
    }
    .wallet-action-grid {
        gap: 8px;
    }
    .wallet-action-card {
        padding: 16px 8px;
        border-radius: 14px;
    }
    .wallet-action-icon {
        font-size: 28px;
    }
    .wallet-action-title {
        font-size: 12px;
    }
    .wallet-action-desc {
        font-size: 10px;
    }
    .quick-recharge-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    .quick-recharge-item {
        padding: 14px 8px;
        border-radius: 12px;
    }
    .quick-recharge-amount {
        font-size: 16px;
    }
    .pay-method-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
    }
    .pay-method-box {
        padding: 12px 6px;
        border-radius: 10px;
    }
    .pay-method-icon {
        font-size: 22px;
    }
    .pay-method-name {
        font-size: 11px;
    }
    .recharge-qr-section {
        padding: 16px;
        border-radius: 14px;
    }
    .recharge-qr-placeholder {
        width: 150px;
        height: 150px;
    }
    .qr-icon {
        font-size: 38px;
    }
    .qr-amount {
        font-size: 18px;
    }
}

/* ========== QQ/X5内置浏览器背景透明彻底修复 ========== */
/* QQ浏览器X5内核对透明/半透明背景和backdrop-filter支持极差，必须全部强制不透明 */

/* 最顶层 - html和body强制纯色背景 */
html {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

body {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    background-image: none !important;
    opacity: 1 !important;
}

/* 布局容器 */
.layout {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

/* 主内容区 */
.main-content {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    min-height: 100vh;
}

/* 内容区 */
.content {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
    min-height: calc(100vh - 60px);
}

/* 侧边栏 */
.sidebar {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

/* 顶部导航 - 禁用毛玻璃，使用纯色 */
.header {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    background-color: #1a1a2e !important;
    background: #1a1a2e !important;
}

/* 所有卡片强制不透明背景 */
.card {
    background-color: #1e1e3a !important;
    background: #1e1e3a !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    opacity: 1 !important;
}

.card-body {
    background-color: #1e1e3a !important;
}

/* 首页大卡片 */
.home-grid-card {
    background-color: #1e1e3a !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

/* 天气卡片 - 强制不透明渐变背景 */
.weather-card,
.hero-weather-card {
    background-color: #1a1a3e !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

/* 所有带rgba背景的元素强制替换为纯色 */
* {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

/* 深色模式下双重确保 */
html body.theme-dark {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

html body.theme-dark .layout,
html body.theme-dark .main-content,
html body.theme-dark .content,
html body.theme-dark .sidebar {
    background-color: #0f0f1a !important;
    background: #0f0f1a !important;
}

html body.theme-dark .card,
html body.theme-dark .card-body {
    background-color: #1e1e3a !important;
    background: #1e1e3a !important;
}

html body.theme-dark .header {
    background-color: #1a1a2e !important;
    background: #1a1a2e !important;
}

/* 确保英雄卡片和各种功能卡片都不透明 */
.hero-card,
.rank-card,
.fw-card,
.setting-card,
.stat-card {
    background-color: #1e1e3a !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

/* 按钮、输入框等也确保不透明 */
.btn,
.form-input,
.form-control,
select,
input,
textarea {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

