/* ========== 变量名生成工具 - 编程主题样式 ========== */

/* ===== 主容器 ===== */
.vng-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 200px);
    min-height: 600px;
    background: #f0f4f8;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.vng-container.fullscreen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 9999;
    border-radius: 0;
    margin: 0;
}

/* ===== 顶部工具栏 ===== */
.vng-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 14px;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    color: white;
    flex-wrap: wrap;
    gap: 8px;
    flex-shrink: 0;
    box-shadow: 0 2px 10px rgba(15, 52, 96, 0.4);
}

.toolbar-group {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: wrap;
}

.toolbar-brand {
    font-size: 13px;
    font-weight: 700;
    color: #e2e8f0;
    letter-spacing: 0.5px;
    font-family: 'Consolas', 'Monaco', monospace;
    margin-right: 4px;
}

.vng-btn {
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    color: #e2e8f0;
    transition: all 0.2s;
    white-space: nowrap;
}

.vng-btn:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.22);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
}

.vng-btn:active:not(:disabled) {
    transform: translateY(0);
}

.vng-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.vng-btn-primary {
    background: linear-gradient(135deg, #00b09b 0%, #96c93d 100%);
    border-color: transparent;
    color: white;
    font-weight: 600;
    box-shadow: 0 2px 6px rgba(0, 176, 155, 0.35);
}

.vng-btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #00c4ac 0%, #a8db44 100%);
    box-shadow: 0 3px 10px rgba(0, 176, 155, 0.45);
}

.vng-btn-cancel {
    background: linear-gradient(135deg, #e53e3e 0%, #c53030 100%);
    border-color: transparent;
    color: white;
}

.vng-btn-cancel:hover {
    background: linear-gradient(135deg, #fc5f5f 0%, #e03030 100%);
}

/* ===== 主内容区 ===== */
.vng-main-content {
    display: flex;
    flex: 1;
    overflow: hidden;
}

/* ===== 左栏：历史记录 ===== */
.vng-history-panel {
    width: 210px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    background: white;
    border-right: 1px solid #e2e8f0;
    overflow: hidden;
}

.history-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.history-panel-header h3 {
    margin: 0;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 4px;
}

.history-count-badge {
    background: #0f3460;
    color: white;
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 10px;
    margin-left: 4px;
    font-weight: 600;
}

.history-clear-btn {
    background: #fff0f0;
    border: none;
    color: #ef4444;
    font-size: 11px;
    cursor: pointer;
    padding: 3px 7px;
    border-radius: 4px;
    transition: all 0.2s;
    white-space: nowrap;
}

.history-clear-btn:hover {
    background: #fde8e8;
}

.history-search-wrap {
    padding: 8px;
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.history-search-wrap input {
    width: 100%;
    padding: 5px 10px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 12px;
    outline: none;
    box-sizing: border-box;
    transition: all 0.2s;
}

.history-search-wrap input:focus {
    border-color: #0f3460;
    box-shadow: 0 0 0 2px rgba(15, 52, 96, 0.1);
}

.history-list {
    flex: 1;
    overflow-y: auto;
    padding: 6px;
    scrollbar-width: thin;
    scrollbar-color: rgba(15,52,96,.2) transparent;
}

.history-list::-webkit-scrollbar { width: 5px; }
.history-list::-webkit-scrollbar-track { background: transparent; }
.history-list::-webkit-scrollbar-thumb {
    background: rgba(15,52,96,.18);
    border-radius: 3px;
}
.history-list::-webkit-scrollbar-thumb:hover {
    background: rgba(15,52,96,.35);
}

.history-empty {
    padding: 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
}

.history-item {
    display: flex;
    flex-direction: column;
    padding: 10px 12px;
    margin: 3px 0;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    animation: fadeIn 0.2s ease;
}

.history-item:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    transform: translateX(2px);
}

.history-item.active {
    background: #e8f4fd;
    border-color: #0f3460;
    box-shadow: inset 3px 0 0 #3b82f6;
}

.history-item-title {
    font-size: 12px;
    font-weight: 600;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 3px;
}

.history-item-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.history-item-lang {
    font-size: 10px;
    color: white;
    background: #0f3460;
    padding: 1px 6px;
    border-radius: 8px;
    font-weight: 500;
}

.history-item-time {
    font-size: 10px;
    color: #94a3b8;
}

.history-item-del {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    background: #fde8e8;
    color: #ef4444;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    opacity: 0;
    transition: opacity 0.2s;
    cursor: pointer;
    border: none;
}

.history-item:hover .history-item-del {
    opacity: 1;
}

.history-item-del:hover {
    background: #ef4444;
    color: white;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ===== 中栏：输入表单 ===== */
.vng-input-panel {
    width: 340px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    background: white;
    border-right: 1px solid #e2e8f0;
    overflow: hidden;
}

.panel-header {
    padding: 12px 16px;
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.panel-header h3 {
    margin: 0 0 3px 0;
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
}

.panel-tip {
    font-size: 11px;
    color: #94a3b8;
}

.vng-input-body {
    flex: 1;
    overflow-y: auto;
    padding: 14px;
    scrollbar-width: thin;
    scrollbar-color: rgba(15,52,96,.2) transparent;
}

.vng-input-body::-webkit-scrollbar { width: 5px; }
.vng-input-body::-webkit-scrollbar-track { background: transparent; }
.vng-input-body::-webkit-scrollbar-thumb {
    background: rgba(15,52,96,.18);
    border-radius: 3px;
}
.vng-input-body::-webkit-scrollbar-thumb:hover {
    background: rgba(15,52,96,.35);
}

.form-group {
    margin-bottom: 14px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
}

.required-mark {
    color: #ef4444;
    margin-left: 2px;
}

.label-tip {
    font-size: 11px;
    font-weight: 400;
    color: #94a3b8;
}

.vng-textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 13px;
    line-height: 1.6;
    font-family: inherit;
    resize: vertical;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    min-height: 90px;
    color: #1e293b;
}

.vng-textarea:focus {
    border-color: #0f3460;
    box-shadow: 0 0 0 2px rgba(15, 52, 96, 0.1);
}

.vng-textarea-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
}

.input-shortcut-tip {
    font-size: 11px;
    color: #94a3b8;
}

.char-count {
    font-size: 11px;
    color: #94a3b8;
}

.char-count.warn {
    color: #f59e0b;
}

.vng-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 13px;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    color: #1e293b;
}

.vng-input:focus {
    border-color: #0f3460;
    box-shadow: 0 0 0 2px rgba(15, 52, 96, 0.1);
}

.vng-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 13px;
    outline: none;
    transition: all 0.2s;
    box-sizing: border-box;
    background: white;
    color: #1e293b;
    cursor: pointer;
}

.vng-select:focus {
    border-color: #0f3460;
    box-shadow: 0 0 0 2px rgba(15, 52, 96, 0.1);
}

.vng-select-sm {
    width: auto;
}

/* 命名风格选择器 */
.style-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.style-option {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.style-option input[type="radio"] {
    display: none;
}

.style-label {
    display: inline-block;
    padding: 4px 10px;
    border: 1.5px solid #e0e0e0;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    font-family: 'Consolas', 'Monaco', monospace;
    cursor: pointer;
    transition: all 0.2s;
    color: #64748b;
    background: white;
    white-space: nowrap;
}

.style-option input[type="radio"]:checked + .style-label {
    border-color: transparent;
    color: white;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.style-all { background: white; }
.style-option input[type="radio"]:checked + .style-all {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.style-camel { background: white; }
.style-option input[type="radio"]:checked + .style-camel {
    background: linear-gradient(135deg, #11998e, #38ef7d);
    color: white;
}

.style-pascal { background: white; }
.style-option input[type="radio"]:checked + .style-pascal {
    background: linear-gradient(135deg, #4facfe, #00f2fe);
    color: white;
}

.style-snake { background: white; }
.style-option input[type="radio"]:checked + .style-snake {
    background: linear-gradient(135deg, #f093fb, #f5576c);
    color: white;
}

.style-screaming { background: white; }
.style-option input[type="radio"]:checked + .style-screaming {
    background: linear-gradient(135deg, #f7971e, #ffd200);
    color: white;
}

.style-kebab { background: white; }
.style-option input[type="radio"]:checked + .style-kebab {
    background: linear-gradient(135deg, #a8edea, #fed6e3);
    color: #1e293b;
}

/* ===== 右栏：结果展示 ===== */
.vng-result-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    overflow: hidden;
    min-width: 300px;
}

.vng-result-panel .panel-header {
    background: linear-gradient(to bottom, #fafafa, #f5f5f5);
    border-bottom: 1px solid #e2e8f0;
}

.vng-result-panel .panel-header h3 {
    color: #1e293b;
    font-family: 'Consolas', 'Monaco', monospace;
}

.vng-result-panel .panel-tip {
    color: #94a3b8;
}

.result-meta {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.result-meta-lang {
    font-size: 11px;
    background: #1f6feb;
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: 500;
}

.result-time {
    font-size: 11px;
    color: #8b949e;
}

.vng-result-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    scrollbar-width: thin;
    scrollbar-color: rgba(15,52,96,.2) transparent;
}

.vng-result-body::-webkit-scrollbar {
    width: 5px;
}

.vng-result-body::-webkit-scrollbar-track {
    background: transparent;
}

.vng-result-body::-webkit-scrollbar-thumb {
    background: rgba(15,52,96,.18);
    border-radius: 3px;
}

.vng-result-body::-webkit-scrollbar-thumb:hover {
    background: rgba(15,52,96,.35);
}

/* 占位区 */
.result-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #94a3b8;
    text-align: center;
    padding: 20px;
}

.placeholder-icon {
    margin-bottom: 16px;
}

.placeholder-code {
    display: block;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 28px;
    color: #94a3b8;
    line-height: 1.4;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px 24px;
    text-align: left;
    background: #f8fafc;
}

.placeholder-title {
    font-size: 15px;
    font-weight: 600;
    color: #475569;
    margin: 8px 0 4px;
}

.placeholder-desc {
    font-size: 12px;
    color: #94a3b8;
    margin: 2px 0;
}

/* 加载中 */
.result-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 16px;
    padding: 20px;
}

.loading-terminal {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 15px;
    color: #0f3460;
}

.terminal-cursor {
    animation: blink 0.8s infinite;
    color: #0f3460;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ===== 抖动动画（输入校验失败反馈） ===== */
@keyframes vng-shake {
    0%, 100% { transform: translateX(0); }
    15%       { transform: translateX(-6px); }
    30%       { transform: translateX(5px); }
    45%       { transform: translateX(-4px); }
    60%       { transform: translateX(3px); }
    75%       { transform: translateX(-2px); }
    90%       { transform: translateX(1px); }
}

.vng-textarea.shake,
.vng-input.shake {
    animation: vng-shake 0.5s ease;
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.15) !important;
}

.loading-text {
    color: #475569;
    font-size: 13px;
}

.loading-progress {
    width: 200px;
    height: 3px;
    background: #e2e8f0;
    border-radius: 2px;
    overflow: hidden;
}

.loading-bar {
    height: 100%;
    width: 5%;
    background: linear-gradient(90deg, #0f3460, #1f6feb);
    border-radius: 2px;
    animation: progress 1.8s ease-in-out infinite alternate;
}

@keyframes progress {
    from { width: 5%; }
    to   { width: 95%; }
}

/* 结果内容 */
.result-content {
    color: #1e293b;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.7;
}

/* 命名规范分组 */
.naming-group {
    margin-bottom: 20px;
    background: white;
    border: 1.5px solid #e2e8f0;
    border-left: 3px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s, border-color 0.2s;
}

.naming-group:hover {
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* 各规范左侧彩色边框标识 */
.naming-group.camel     { border-left-color: #3fb950; }
.naming-group.pascal    { border-left-color: #58a6ff; }
.naming-group.snake     { border-left-color: #ffa657; }
.naming-group.screaming { border-left-color: #e3b341; }
.naming-group.kebab     { border-left-color: #d2a8ff; }
.naming-group.tip       { border-left-color: #6e7681; }

.naming-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    cursor: default;
}

.naming-group-title {
    font-size: 13px;
    font-weight: 700;
    font-family: 'Consolas', 'Monaco', monospace;
    letter-spacing: 0.5px;
}

/* 不同规范的颜色标识 */
.naming-group.camel .naming-group-title     { color: #16a34a; }
.naming-group.pascal .naming-group-title    { color: #2563eb; }
.naming-group.snake .naming-group-title     { color: #c2410c; }
.naming-group.screaming .naming-group-title { color: #b45309; }
.naming-group.kebab .naming-group-title     { color: #7c3aed; }
.naming-group.tip .naming-group-title       { color: #64748b; }

.naming-group-badge {
    font-size: 10px;
    color: #64748b;
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 10px;
}

.naming-items {
    padding: 8px 0;
}

.naming-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 4px;
    margin: 2px 6px;
    transition: background 0.15s, box-shadow 0.15s;
    cursor: pointer;
    border-left: 2px solid transparent;
}

.naming-item:hover {
    background: rgba(15, 52, 96, 0.05);
    border-left-color: #0f3460;
    padding-left: 14px;
}

.naming-item-rank {
    font-size: 10px;
    color: #8b949e;
    width: 16px;
    flex-shrink: 0;
    margin-top: 2px;
    text-align: right;
}

.naming-item-main {
    flex: 1;
    min-width: 0;
}

.naming-item-name {
    font-size: 14px;
    font-weight: 700;
    font-family: 'Consolas', 'Monaco', monospace;
    margin-bottom: 2px;
    word-break: break-all;
}

.naming-group.camel .naming-item-name     { color: #15803d; }
.naming-group.pascal .naming-item-name    { color: #1d4ed8; }
.naming-group.snake .naming-item-name     { color: #c2410c; }
.naming-group.screaming .naming-item-name { color: #92400e; }
.naming-group.kebab .naming-item-name     { color: #6d28d9; }

.naming-item-desc {
    font-size: 11px;
    color: #64748b;
    font-family: inherit;
    line-height: 1.4;
}

.naming-item-copy {
    width: 26px;
    height: 26px;
    background: transparent;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    color: #94a3b8;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.naming-item-copy:hover {
    background: #f1f5f9;
    border-color: #0f3460;
    color: #0f3460;
}

/* 建议/提示分组 */
.naming-group.tip {
    border-color: #e2e8f0;
}

.naming-group.tip .naming-group-header {
    background: #f8fafc;
}

.tip-content {
    padding: 12px 14px;
    color: #64748b;
    font-family: inherit;
    font-size: 12px;
    line-height: 1.7;
    white-space: normal;
}

/* ===== Toast 提示 ===== */
.vng-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(60px);
    background: #1e293b;
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 13px;
    z-index: 99999;
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    pointer-events: none;
}

.vng-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.vng-toast.success { background: #15803d; }
.vng-toast.error   { background: #b91c1c; }
.vng-toast.info    { background: #1d4ed8; }

/* ===== 示例模态框 ===== */
.vng-modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    backdrop-filter: blur(2px);
}

.vng-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 100001;
    width: 560px;
    max-width: 92vw;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.vng-modal-content {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    max-height: 80vh;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    animation: modalIn 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes modalIn {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1); }
}

.vng-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 18px;
    background: linear-gradient(135deg, #1a1a2e, #0f3460);
    color: white;
    flex-shrink: 0;
}

.vng-modal-header h3 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.vng-modal-close {
    width: 28px;
    height: 28px;
    background: rgba(255,255,255,0.15);
    border: none;
    color: white;
    font-size: 14px;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.vng-modal-close:hover {
    background: rgba(255,255,255,0.25);
}

.vng-modal-body {
    overflow-y: auto;
    padding: 16px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.example-card {
    padding: 14px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.example-card:hover {
    border-color: #0f3460;
    background: #eef2ff;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(15, 52, 96, 0.12);
}

.example-card-title {
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 4px;
}

.example-card-desc {
    font-size: 11px;
    color: #64748b;
    line-height: 1.5;
    margin-bottom: 6px;
}

.example-card-lang {
    display: inline-block;
    font-size: 10px;
    background: #0f3460;
    color: white;
    padding: 1px 7px;
    border-radius: 8px;
    font-weight: 500;
}

/* ===== 暗黑模式 ===== */
body.dark .vng-container {
    background: #111827;
}

body.dark .vng-toolbar {
    background: linear-gradient(135deg, #0d1117 0%, #161b22 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

body.dark .vng-history-panel {
    background: #161b22;
    border-color: #30363d;
}

body.dark .history-panel-header {
    background: linear-gradient(to bottom, #21262d, #1c2128);
    border-color: #30363d;
}

body.dark .history-panel-header h3 {
    color: #e6edf3;
}

/* 暗黑模式下徽章和语言标签用更亮的蓝色 */
body.dark .history-count-badge {
    background: #1f6feb;
}

body.dark .history-item-lang {
    background: #1f6feb;
}

body.dark .history-search-wrap {
    border-color: #30363d;
}

body.dark .history-search-wrap input {
    background: #0d1117;
    border-color: #30363d;
    color: #e6edf3;
}

body.dark .history-search-wrap input::placeholder {
    color: #6e7681;
}

body.dark .history-search-wrap input:focus {
    border-color: #58a6ff;
    box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.15);
}

body.dark .history-item {
    background: #21262d;
    border-color: #30363d;
}

body.dark .history-item:hover {
    background: #2d333b;
    border-color: #444c56;
}

body.dark .history-item.active {
    background: #1c2128;
    border-color: #58a6ff;
    box-shadow: inset 3px 0 0 #3b82f6;
}

body.dark .history-item-title {
    color: #e6edf3;
}

body.dark .history-empty {
    color: #6e7681;
}

body.dark .vng-input-panel {
    background: #161b22;
    border-color: #30363d;
}

body.dark .panel-header {
    background: linear-gradient(to bottom, #21262d, #1c2128);
    border-color: #30363d;
}

body.dark .panel-header h3 {
    color: #e6edf3;
}

body.dark .panel-tip {
    color: #6e7681;
}

body.dark .form-group label {
    color: #8b949e;
}

body.dark .label-tip {
    color: #6e7681;
}

body.dark .vng-textarea,
body.dark .vng-input,
body.dark .vng-select {
    background: #0d1117;
    border-color: #30363d;
    color: #e6edf3;
}

body.dark .vng-textarea::placeholder,
body.dark .vng-input::placeholder {
    color: #6e7681;
}

body.dark .vng-textarea:focus,
body.dark .vng-input:focus,
body.dark .vng-select:focus {
    border-color: #58a6ff;
    box-shadow: 0 0 0 2px rgba(88, 166, 255, 0.15);
}

body.dark .style-label {
    border-color: #30363d;
    color: #8b949e;
    background: #21262d;
}

body.dark .input-shortcut-tip,
body.dark .char-count {
    color: #6e7681;
}

body.dark .vng-result-panel { background: #0d1117; }
body.dark .vng-result-panel .panel-header {
    background: #161b22;
    border-color: #30363d;
}
body.dark .vng-result-panel .panel-header h3 { color: #e6edf3; }
body.dark .vng-result-panel .panel-tip       { color: #8b949e; }

/* 暗黑模式 - 占位区 */
body.dark .result-placeholder { color: #8b949e; }
body.dark .placeholder-code   { color: #30363d; border-color: #30363d; background: transparent; }
body.dark .placeholder-title  { color: #6e7681; }
body.dark .placeholder-desc   { color: #6e7681; }

/* 暗黑模式 - 加载中 */
body.dark .loading-terminal { color: #3fb950; }
body.dark .terminal-cursor  { color: #3fb950; }
body.dark .loading-text     { color: #e6edf3; }
body.dark .loading-progress { background: #30363d; }
body.dark .loading-bar      { background: linear-gradient(90deg, #3fb950, #58a6ff); }

/* 暗黑模式 - 命名组 */
body.dark .result-content { color: #e6edf3; }
body.dark .naming-group   { background: #161b22; border-color: #30363d; }
body.dark .naming-group:hover { box-shadow: 0 2px 12px rgba(0,0,0,.3); }
body.dark .naming-group-header { background: #21262d; border-color: #30363d; }
body.dark .naming-group.camel .naming-group-title     { color: #3fb950; }
body.dark .naming-group.pascal .naming-group-title    { color: #58a6ff; }
body.dark .naming-group.snake .naming-group-title     { color: #f78166; }
body.dark .naming-group.screaming .naming-group-title { color: #e3b341; }
body.dark .naming-group.kebab .naming-group-title     { color: #bc8cff; }
body.dark .naming-group.tip .naming-group-title       { color: #8b949e; }
body.dark .naming-group-badge { color: #8b949e; background: #30363d; }
body.dark .naming-item:hover  { background: rgba(88,166,255,.08); border-left-color: #58a6ff; }
body.dark .naming-group.camel .naming-item-name     { color: #3fb950; }
body.dark .naming-group.pascal .naming-item-name    { color: #79c0ff; }
body.dark .naming-group.snake .naming-item-name     { color: #ffa657; }
body.dark .naming-group.screaming .naming-item-name { color: #e3b341; }
body.dark .naming-group.kebab .naming-item-name     { color: #d2a8ff; }
body.dark .naming-item-desc { color: #8b949e; }
body.dark .naming-item-copy { border-color: #30363d; color: #8b949e; }
body.dark .naming-item-copy:hover { background: #21262d; border-color: #58a6ff; color: #58a6ff; }
body.dark .naming-group.tip { border-color: #30363d; }
body.dark .naming-group.tip .naming-group-header { background: #1c2128; }
body.dark .tip-content { color: #8b949e; }

/* 暗黑模式 - 结果区滚动条 */
body.dark .vng-result-body { scrollbar-color: #30363d #0d1117; }
body.dark .vng-result-body::-webkit-scrollbar-track { background: #0d1117; }
body.dark .vng-result-body::-webkit-scrollbar-thumb { background: #30363d; }
body.dark .vng-result-body::-webkit-scrollbar-thumb:hover { background: #444c56; }

body.dark .vng-modal-content {
    background: #161b22;
}

body.dark .vng-modal-body {
    background: #161b22;
}

body.dark .example-card {
    background: #21262d;
    border-color: #30363d;
}

body.dark .example-card:hover {
    background: #2d333b;
    border-color: #58a6ff;
}

body.dark .example-card-title {
    color: #e6edf3;
}

body.dark .example-card-desc {
    color: #8b949e;
}

body.dark .history-clear-btn {
    background: rgba(239, 68, 68, 0.1);
    color: #f87171;
}

body.dark .history-clear-btn:hover {
    background: rgba(239, 68, 68, 0.2);
}

body.dark .history-item-del {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
}

body.dark .history-item-del:hover {
    background: #ef4444;
    color: white;
}

body.dark .example-card-lang {
    background: #1f6feb;
}

body.dark .vng-input-body {
    scrollbar-width: thin;
    scrollbar-color: #30363d #161b22;
}

body.dark .vng-input-body::-webkit-scrollbar {
    width: 5px;
}

body.dark .vng-input-body::-webkit-scrollbar-track {
    background: #161b22;
}

body.dark .vng-input-body::-webkit-scrollbar-thumb {
    background: #30363d;
    border-radius: 3px;
}

body.dark .vng-input-body::-webkit-scrollbar-thumb:hover {
    background: #444c56;
}

body.dark .history-list::-webkit-scrollbar { width: 5px; }
body.dark .history-list::-webkit-scrollbar-track { background: #161b22; }
body.dark .history-list::-webkit-scrollbar-thumb {
    background: #30363d;
    border-radius: 3px;
}
body.dark .history-list::-webkit-scrollbar-thumb:hover {
    background: #444c56;
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
    .vng-main-content {
        flex-direction: column;
    }

    .vng-history-panel {
        width: 100%;
        height: 150px;
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
        flex-direction: row;
        overflow-x: auto;
    }

    .vng-input-panel {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e2e8f0;
    }

    .vng-result-panel {
        min-width: auto;
    }

    .vng-modal-body {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .vng-toolbar {
        gap: 4px;
        padding: 6px 10px;
    }

    .toolbar-brand {
        display: none;
    }

    .style-selector {
        gap: 4px;
    }

    .style-label {
        font-size: 10px;
        padding: 3px 7px;
    }
}
