/* assets/theme.css —— 全站共享的暗色模式规则 */

html.dark-mode body {
    background: #0b0f19 !important;
    color: #f1f5f9 !important;
}

/* ===== 通用输入控件 ===== */
html.dark-mode input[type="text"],
html.dark-mode input[type="password"],
html.dark-mode textarea,
html.dark-mode select {
    background: #1f2937 !important;
    border-color: #374151 !important;
    color: #f9fafb !important;
}

html.dark-mode input[type="text"]:focus,
html.dark-mode input[type="password"]:focus,
html.dark-mode textarea:focus,
html.dark-mode select:focus {
    border-color: #3b82f6 !important;
    background: #111827 !important;
    box-shadow: 0 0 0 4px rgba(59,130,246,0.2) !important;
}

html.dark-mode label { color: #cbd5e1 !important; }

/* ===== 主题切换按钮 ===== */
html.dark-mode .theme-toggle-btn { color: #9ca3af !important; }
html.dark-mode .theme-toggle-btn:hover { background: rgba(255,255,255,0.08) !important; }

/* ===== 标题区域 ===== */
html.dark-mode .header-title h2 { color: #f9fafb !important; }
html.dark-mode .header-title p  { color: #9ca3af !important; }

/* ===== 模态框共享样式 ===== */
html.dark-mode .modal-backdrop { background: rgba(11, 15, 25, 0.8) !important; }
html.dark-mode .modal-box {
    background: #111827 !important;
    color: #f1f5f9 !important;
    border: 1px solid #1f2937 !important;
    box-shadow: 0 25px 50px -12px rgba(0,0,0,0.6) !important;
}
html.dark-mode .modal-header  { border-bottom-color: #1f2937 !important; }
html.dark-mode .modal-title   { color: #f9fafb !important; }
html.dark-mode .modal-close   { color: #9ca3af !important; }
html.dark-mode .modal-card-gray {
    background: #1f2937 !important;
    border-color: #374151 !important;
    color: #f9fafb !important;
}
html.dark-mode .modal-input {
    background: #1f2937 !important;
    border-color: #374151 !important;
    color: #f1f5f9 !important;
}
html.dark-mode .modal-input:focus {
    border-color: #3b82f6 !important;
    background: #111827 !important;
    box-shadow: 0 0 0 4px rgba(59,130,246,0.2) !important;
}
html.dark-mode .modal-btn-cancel { background: #374151 !important; color: #e5e7eb !important; }
html.dark-mode .modal-btn-cancel:hover { background: #4b5563 !important; }
html.dark-mode .modal-table th {
    background: #182232 !important;
    color: #cbd5e1 !important;
    border-bottom-color: #2d3748 !important;
}
html.dark-mode .modal-table td {
    border-bottom-color: #1f2937 !important;
    color: #e5e7eb !important;
}
html.dark-mode .modal-table tr:hover { background: #1f2937 !important; }
html.dark-mode .uuid-box-modal   { background: #1f2937 !important; border-color: #374151 !important; }
html.dark-mode .uuid-code-modal  { background: #182232 !important; border-color: #374151 !important; color: #60a5fa !important; }
html.dark-mode .token-code-modal { background: #182232 !important; border-color: #7f1d1d !important; color: #f87171 !important; }
html.dark-mode .modal-desc       { color: #9ca3af !important; }

/* ===== 密码可见性切换图标 ===== */
.password-wrapper { position: relative; width: 100%; }
.password-wrapper input { width: 100%; box-sizing: border-box; padding-right: 40px !important; }
.toggle-password {
    position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
    cursor: pointer; font-size: 16px; user-select: none;
    opacity: 0.6; transition: opacity 0.2s;
}
.toggle-password:hover { opacity: 1; }