163 lines
6.5 KiB
CSS
163 lines
6.5 KiB
CSS
* { margin: 0; padding: 0; box-sizing: border-box; }
|
|
:root {
|
|
--bg: #0d1117;
|
|
--surface: #161b22;
|
|
--border: #30363d;
|
|
--text: #e6edf3;
|
|
--text-muted: #8b949e;
|
|
--accent: #00d4ff;
|
|
--accent-hover: #33ddff;
|
|
--danger: #f85149;
|
|
--success: #3fb950;
|
|
--warning: #d29922;
|
|
--radius: 8px;
|
|
}
|
|
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; }
|
|
#app { display: flex; min-height: 100vh; }
|
|
.sidebar { width: 220px; background: var(--surface); border-right: 1px solid var(--border); padding: 16px 0; position: fixed; height: 100vh; overflow-y: auto; }
|
|
.logo { padding: 0 16px 16px; font-size: 18px; font-weight: 700; border-bottom: 1px solid var(--border); }
|
|
.nav-links { list-style: none; padding: 12px 0; }
|
|
.nav-links a { display: block; padding: 10px 16px; color: var(--text-muted); text-decoration: none; font-size: 14px; transition: all 0.15s; }
|
|
.nav-links a:hover, .nav-links a.active { color: var(--text); background: rgba(0,212,255,0.1); border-right: 2px solid var(--accent); }
|
|
.content { flex: 1; margin-left: 220px; padding: 24px; }
|
|
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
|
|
.panel h2 { margin-bottom: 16px; font-size: 20px; }
|
|
/* Mobile */
|
|
@media (max-width: 768px) {
|
|
.sidebar { width: 100%; height: auto; position: relative; display: flex; flex-wrap: wrap; padding: 8px 0; }
|
|
.logo { width: 100%; padding: 8px 16px; border-bottom: none; }
|
|
.nav-links { display: flex; width: 100%; padding: 0; overflow-x: auto; }
|
|
.nav-links a { padding: 8px 14px; white-space: nowrap; border-right: none; border-bottom: 2px solid transparent; }
|
|
.nav-links a.active { border-right: none; border-bottom-color: var(--accent); }
|
|
.content { margin-left: 0; padding: 12px; }
|
|
}
|
|
|
|
/* ── Config Panel ───────────────────────────────────────────────── */
|
|
.config-panel { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
|
|
.config-panel h2 { margin: 0; font-size: 16px; }
|
|
|
|
.config-file-list,
|
|
.config-editor {
|
|
padding: 20px;
|
|
}
|
|
|
|
/* File List */
|
|
.config-header {
|
|
display: flex; align-items: center; justify-content: space-between;
|
|
margin-bottom: 12px;
|
|
}
|
|
.config-count {
|
|
font-size: 12px; color: var(--text-muted);
|
|
}
|
|
.config-files-container {
|
|
max-height: 520px; overflow-y: auto;
|
|
}
|
|
.config-file-item {
|
|
display: flex; align-items: center; justify-content: space-between;
|
|
padding: 10px 12px; border-radius: 6px; cursor: pointer;
|
|
transition: background 0.12s; border: 1px solid transparent;
|
|
margin-bottom: 4px;
|
|
}
|
|
.config-file-item:hover { background: rgba(0,212,255,0.06); border-color: var(--border); }
|
|
.config-file-item.selected {
|
|
background: rgba(0,212,255,0.1); border-color: var(--accent);
|
|
}
|
|
.file-item-name { font-size: 14px; font-weight: 500; flex: 1; }
|
|
.file-item-meta { font-size: 11px; color: var(--text-muted); margin-left: 12px; white-space: nowrap; }
|
|
|
|
/* Editor */
|
|
.editor-header {
|
|
display: flex; align-items: center; gap: 12px;
|
|
margin-bottom: 12px; padding-bottom: 12px;
|
|
border-bottom: 1px solid var(--border);
|
|
}
|
|
.editor-filename {
|
|
font-size: 16px; font-weight: 600; flex: 1;
|
|
overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
|
|
}
|
|
.editor-actions { display: flex; gap: 8px; }
|
|
.editor-body {
|
|
display: flex; position: relative;
|
|
border: 1px solid var(--border); border-radius: var(--radius);
|
|
overflow: hidden; background: #0a0e14;
|
|
}
|
|
.editor-line-numbers {
|
|
flex: 0 0 48px; padding: 10px 0; overflow: hidden;
|
|
background: #0d1117; border-right: 1px solid var(--border);
|
|
text-align: right; user-select: none;
|
|
font-family: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', 'Consolas', monospace;
|
|
font-size: 13px; line-height: 1.5;
|
|
color: var(--text-muted); min-height: 200px;
|
|
}
|
|
.editor-line-numbers .ln {
|
|
padding: 0 8px; height: 19.5px;
|
|
}
|
|
.editor-textarea {
|
|
flex: 1; padding: 10px 12px; border: none; outline: none; resize: none;
|
|
font-family: 'JetBrains Mono', 'Fira Code', 'Cascadia Code', 'Consolas', monospace;
|
|
font-size: 13px; line-height: 1.5; tab-size: 4;
|
|
background: transparent; color: var(--text); min-height: 300px;
|
|
}
|
|
.editor-textarea:disabled {
|
|
opacity: 0.5; cursor: wait;
|
|
}
|
|
|
|
/* Status Bar */
|
|
.editor-status-bar {
|
|
display: flex; align-items: center; gap: 16px;
|
|
margin-top: 8px; padding: 6px 12px;
|
|
border: 1px solid var(--border); border-radius: var(--radius);
|
|
background: var(--surface);
|
|
font-size: 11px; color: var(--text-muted);
|
|
overflow: hidden;
|
|
}
|
|
#status-path {
|
|
flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
|
|
}
|
|
.status-saved { color: var(--success); flex-shrink: 0; }
|
|
|
|
/* Buttons */
|
|
.btn {
|
|
padding: 6px 14px; border: 1px solid var(--border); border-radius: 6px;
|
|
background: var(--surface); color: var(--text); cursor: pointer;
|
|
font-size: 13px; transition: all 0.12s; white-space: nowrap;
|
|
}
|
|
.btn:hover { border-color: var(--accent); color: var(--accent); }
|
|
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
|
|
.btn-primary {
|
|
background: var(--accent); color: #000; border-color: var(--accent);
|
|
font-weight: 600;
|
|
}
|
|
.btn-primary:hover { background: var(--accent-hover); }
|
|
.btn-sm { padding: 4px 10px; font-size: 12px; }
|
|
|
|
/* Toast Notification */
|
|
.config-toast {
|
|
position: fixed; z-index: 9999;
|
|
padding: 10px 20px; border-radius: var(--radius);
|
|
font-size: 13px; font-weight: 500;
|
|
box-shadow: 0 4px 20px rgba(0,0,0,0.4);
|
|
max-width: 80%; text-align: center;
|
|
animation: toast-in 0.2s ease;
|
|
}
|
|
.toast-success { background: #1a3a2a; border: 1px solid var(--success); color: var(--success); }
|
|
.toast-error { background: #3a1a1a; border: 1px solid var(--danger); color: var(--danger); }
|
|
.toast-info { background: #1a2a3a; border: 1px solid var(--accent); color: var(--accent); }
|
|
@keyframes toast-in {
|
|
from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
|
|
to { opacity: 1; transform: translateX(-50%) translateY(0); }
|
|
}
|
|
|
|
/* Mobile */
|
|
@media (max-width: 768px) {
|
|
.config-panel { padding: 0; }
|
|
.config-file-list, .config-editor { padding: 12px; }
|
|
.config-file-item { padding: 8px 10px; }
|
|
.editor-body { flex-direction: column; }
|
|
.editor-line-numbers { display: none; }
|
|
.editor-textarea { min-height: 250px; }
|
|
.editor-header { flex-wrap: wrap; }
|
|
.editor-filename { width: 100%; font-size: 14px; }
|
|
.editor-status-bar { flex-wrap: wrap; gap: 8px; }
|
|
}
|