:root {
  --bg: #0b0d10;
  --card: #12151a;
  --muted: #1a1f27;
  --text: #e6edf3;
  --text-dim: #9fb0c0;
  --primary: #7c5cff;
  --primary-2: #5c40e6;
  --accent: #25d0a2;
  --danger: #ff4d67;
  --warning: #ffb020;
  --ok: #3bd671;
  --border: #222834;
  --chip: #1b2230;
  --chip-active: #7c5cff;
  --shadow: 0 10px 30px rgba(0,0,0,0.35);
}
* { box-sizing: border-box; }
html, body { height:100%; }
body {
  margin:0;
  font-family: ui-sans-serif, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, Arial, "Apple Color Emoji","Segoe UI Emoji";
  background: radial-gradient(1200px 800px at 70% -10%, #1c2030 0%, #0b0d10 55%);
  color: var(--text);
}
.container { max-width: 1200px; margin: 0 auto; padding: 24px; }
.navbar { position: sticky; top:0; z-index: 50; backdrop-filter: blur(6px); background: linear-gradient(180deg, rgba(10,12,16,.7), rgba(10,12,16,.35)); border-bottom: 1px solid var(--border); }
.navbar-inner { display:flex; align-items:center; justify-content:space-between; gap: 16px; padding: 12px 24px; }
.brand { display:flex; align-items:center; gap:10px; font-weight:700; letter-spacing: .3px; }
.brand .dot { width:10px; height:10px; border-radius:50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); }
.nav-links { display:flex; gap:14px; align-items:center; }
.nav-links a, .btn { color: var(--text); text-decoration:none; font-weight:600; padding: 10px 14px; border-radius: 12px; transition: .15s ease; border: 1px solid transparent; }
.nav-links a:hover { background: var(--muted); }
.btn-primary { background: linear-gradient(135deg, var(--primary), var(--primary-2)); box-shadow: 0 6px 20px rgba(124,92,255,.28); }
.btn-primary:hover { transform: translateY(-1px); }
.btn-ghost { background: transparent; border:1px solid var(--border); }
.btn-ghost:hover { background: var(--muted); }
.btn-danger { background: var(--danger); }
.btn-ok { background: var(--ok); color:#04110a; font-weight:800; }
.grid { display:grid; gap:16px; }
.card { background: linear-gradient(180deg, rgba(18,21,26,.9), rgba(12,14,18,.9)); border: 1px solid var(--border); border-radius: 16px; padding: 18px; box-shadow: var(--shadow); }
.card h2, .card h3 { margin: 0 0 10px; }
.badge { background: var(--chip); color: var(--text-dim); padding: 6px 10px; border-radius: 999px; font-size: 12px; border:1px solid var(--border); }
.stat { display:flex; flex-direction:column; gap:6px; padding:10px 12px; border-radius:12px; background: var(--muted); border:1px solid var(--border); }
.input, select, textarea { width:100%; background: #0d1117; color: var(--text); border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; outline: none; transition: .15s ease; }
.input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,92,255,.2); }
.row { display:flex; gap:14px; align-items:center; }
.row > * { flex:1; }
.chips { display:flex; flex-wrap:wrap; gap:8px; }
.chip { padding: 8px 12px; border-radius: 999px; background: var(--chip); color: var(--text-dim); border: 1px solid var(--border); cursor:pointer; user-select:none; }
.chip:hover { border-color: var(--primary); color: var(--text); }
.chip.active { background: var(--primary); color:#fff; border-color: transparent; }
.chip.single { }
.help { color: var(--text-dim); font-size: 12px; }
.split { display:grid; grid-template-columns: 1.2fr 1fr; gap:16px; }
.preview { background: linear-gradient(180deg, #0c1117, #0a0e14); border:1px dashed var(--border); border-radius: 16px; padding: 16px; position: relative; overflow: hidden; }
.preview pre { margin:0; white-space:pre-wrap; word-break:break-word; }
.preview.scrim::after { content: ""; position: absolute; inset: 0; backdrop-filter: blur(5px); background: repeating-linear-gradient(45deg, rgba(255,255,255,.04) 0 12px, rgba(255,255,255,.02) 12px 24px); pointer-events: none; }
.toolbar { display:flex; gap:8px; align-items:center; justify-content:flex-end; margin-top:12px; }
.kv { display:grid; grid-template-columns: 1fr 1fr; gap:16px; }
.kv .item { display:flex; flex-direction:column; gap:6px; }
.table { width:100%; border-collapse: collapse; }
.table th, .table td { text-align:left; padding:10px; border-bottom:1px solid var(--border); }
.table th { color: var(--text-dim); font-weight:600; }
.modal { position: fixed; inset:0; display:none; align-items:center; justify-content:center; background: rgba(0,0,0,.5); z-index:100; }
.modal.show { display:flex; }
.modal > .dialog { background: var(--card); border:1px solid var(--border); border-radius:14px; width: 480px; max-width: 95vw; padding: 18px; box-shadow: var(--shadow); }
.toast { position: fixed; right: 16px; bottom: 16px; z-index:200; display:flex; flex-direction:column; gap:12px; }
.toast .item { background: var(--card); border:1px solid var(--border); border-radius:12px; padding:12px 14px; box-shadow:var(--shadow); }
