/* ============ VOLX design system ============ */
:root {
  --bg: #07070d;
  --bg-2: #0b0b14;
  --surface: #11111c;
  --surface-2: #171726;
  --surface-3: #1e1e31;
  --border: #24243a;
  --border-2: #31314d;
  --text: #ededf6;
  --muted: #a0a0ba;
  --dim: #6c6c88;
  --accent: #7c5cff;
  --accent-hi: #9b84ff;
  --cyan: #22d3ee;
  --good: #22c55e;
  --bad: #ef4444;
  --warn: #f5a524;
  --grad: linear-gradient(135deg, #7c5cff 0%, #22d3ee 100%);
  --glow: 0 0 0 1px rgba(124, 92, 255, .35), 0 8px 40px -8px rgba(124, 92, 255, .45);
  --radius: 14px;
  --radius-sm: 10px;
  --font: 'IBM Plex Sans Arabic', system-ui, -apple-system, 'Segoe UI', Tahoma, sans-serif;
  --display: 'Space Grotesk', 'IBM Plex Sans Arabic', system-ui, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
::selection { background: rgba(124, 92, 255, .45); }
:focus-visible { outline: 2px solid var(--accent-hi); outline-offset: 2px; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--surface-3); border-radius: 10px; border: 2px solid var(--bg); }
::-webkit-scrollbar-track { background: transparent; }

.container { width: min(1180px, 100% - 32px); margin-inline: auto; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }
.mono { font-family: var(--display); font-feature-settings: 'tnum'; }
.hidden { display: none !important; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 42px; padding: 0 18px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-2); background: var(--surface-2);
  font-weight: 600; font-size: 14px; cursor: pointer; white-space: nowrap;
  transition: transform .15s ease, background .2s, border-color .2s, box-shadow .2s, opacity .2s;
}
.btn:hover { background: var(--surface-3); border-color: #3d3d5e; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--accent); border-color: transparent; color: #fff; box-shadow: 0 6px 24px -8px rgba(124, 92, 255, .8); }
.btn-primary:hover { background: var(--accent-hi); border-color: transparent; }
.btn-grad { background: var(--grad); border: 0; color: #fff; box-shadow: var(--glow); }
.btn-grad:hover { filter: brightness(1.1); background: var(--grad); }
.btn-ghost { background: transparent; }
.btn-danger { background: rgba(239, 68, 68, .12); border-color: rgba(239, 68, 68, .35); color: #fca5a5; }
.btn-danger:hover { background: rgba(239, 68, 68, .2); }
.btn-good { background: var(--good); border-color: transparent; color: #04170b; }
.btn-good:hover { background: #34d46c; border-color: transparent; }
.btn-lg { height: 52px; padding: 0 26px; font-size: 16px; border-radius: 12px; }
.btn-sm { height: 34px; padding: 0 12px; font-size: 13px; }
.btn-icon { width: 38px; padding: 0; }
.btn.loading { pointer-events: none; opacity: .75; }
.btn.loading::after {
  content: ''; width: 14px; height: 14px; border-radius: 50%;
  border: 2px solid currentColor; border-top-color: transparent; animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- top nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 7, 13, .72); backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255, 255, 255, .05);
}
.nav-inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--display); font-weight: 700; font-size: 20px; letter-spacing: .5px; }
.brand img { width: 34px; height: 34px; }
.brand span small { color: var(--dim); font-size: 12px; font-weight: 500; margin-inline-start: 4px; }
.nav-links { display: flex; gap: 22px; margin-inline-start: 12px; }
.nav-links a { color: var(--muted); font-weight: 500; font-size: 14px; transition: color .2s; }
.nav-links a:hover { color: var(--text); }
.nav-actions { margin-inline-start: auto; display: flex; gap: 10px; align-items: center; }

.user-chip {
  display: flex; align-items: center; gap: 10px; padding: 5px 6px 5px 12px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--surface); cursor: pointer; position: relative;
}
.user-chip img { width: 30px; height: 30px; border-radius: 50%; }
.user-chip .name { font-weight: 600; font-size: 14px; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu {
  position: absolute; inset-inline-end: 0; top: calc(100% + 8px); min-width: 200px;
  background: var(--surface-2); border: 1px solid var(--border-2); border-radius: 12px; padding: 6px;
  box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .7); display: none; z-index: 60;
}
.menu.open { display: block; animation: pop .15s ease; }
.menu a, .menu button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border-radius: 8px;
  background: none; border: 0; cursor: pointer; font-size: 14px; color: var(--muted); text-align: start;
}
.menu a:hover, .menu button:hover { background: var(--surface-3); color: var(--text); }
.menu svg { width: 16px; height: 16px; }
.menu .danger { color: #fca5a5; }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } }

/* ---------- shared marketing bits ---------- */
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--dim); margin-inline-end: 6px; vertical-align: middle; }
.dot.on { background: var(--good); box-shadow: 0 0 0 4px rgba(34, 197, 94, .18); animation: pulse 2s infinite; }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, .05); } }

/* discord-like mock */
.mock { background: #1a1a2b; border: 1px solid var(--border-2); border-radius: 18px; padding: 18px; }
.msg { display: flex; gap: 12px; margin-bottom: 14px; }
.msg img { width: 40px; height: 40px; border-radius: 50%; flex: none; }
.msg .who { font-weight: 700; font-size: 14px; display: flex; gap: 6px; align-items: center; }
.tag-bot { background: var(--accent); color: #fff; font-size: 10px; padding: 1px 5px; border-radius: 4px; font-weight: 700; }
.dc-embed {
  margin-top: 6px; background: #12121e; border-radius: 6px; border-inline-start: 4px solid var(--bad);
  padding: 12px 14px; font-size: 13.5px; max-width: 440px;
}
.dc-embed .t { font-weight: 700; margin-bottom: 8px; }
.dc-embed .f { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dc-embed .f b { display: block; font-size: 12px; color: var(--muted); }

.section { padding: 90px 0; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 50px; }
.section-head .eyebrow { color: var(--accent-hi); font-weight: 700; font-size: 13px; letter-spacing: 1px; }
.section-head h3 { font-size: clamp(28px, 4vw, 40px); margin: 8px 0 12px; line-height: 1.2; }
.section-head p { color: var(--muted); margin: 0; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }

.cmds { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.cmd { font-family: var(--display); padding: 8px 14px; border-radius: 10px; background: rgba(17, 17, 28, .8); border: 1px solid var(--border); color: var(--muted); font-size: 14px; direction: ltr; transition: border-color .2s, color .2s; }
.cmd:hover { border-color: rgba(124, 92, 255, .5); color: var(--text); }
.cmd b { color: var(--accent-hi); }

.footer { border-top: 1px solid var(--border); padding: 30px 0; color: var(--dim); font-size: 14px; }
.footer .container { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center; }

/* ---------- server picker ---------- */
.page-head { padding: 48px 0 28px; display: flex; align-items: end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-head h1 { margin: 0; font-size: 32px; }
.page-head p { margin: 4px 0 0; color: var(--muted); }
.search {
  display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 12px; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--border); min-width: 260px;
}
.search input { background: none; border: 0; outline: 0; flex: 1; }
.search svg { width: 18px; height: 18px; color: var(--dim); }
.servers { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; padding-bottom: 60px; }
.server {
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); overflow: hidden;
  transition: transform .2s, border-color .2s; display: flex; flex-direction: column;
}
.server:hover { transform: translateY(-3px); border-color: var(--border-2); }
.server .banner { height: 86px; position: relative; overflow: hidden; background: var(--surface-3); }
.server .banner img { width: 100%; height: 100%; object-fit: cover; filter: blur(22px) saturate(1.4); transform: scale(1.4); opacity: .6; }
.server .avatar {
  width: 68px; height: 68px; border-radius: 20px; margin: -36px auto 0; position: relative; border: 4px solid var(--surface);
  background: var(--surface-3); display: grid; place-items: center; font-weight: 700; font-size: 22px; overflow: hidden;
}
.server .avatar img { width: 100%; height: 100%; object-fit: cover; }
.server .body { padding: 12px 18px 18px; text-align: center; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.server h3 { margin: 0; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.server .meta { color: var(--dim); font-size: 13px; margin-bottom: 12px; }
.server .btn { margin-top: auto; width: 100%; }
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; }
.badge.owner { background: rgba(245, 165, 36, .12); color: var(--warn); }

.empty { text-align: center; padding: 70px 20px; color: var(--muted); border: 1px dashed var(--border-2); border-radius: var(--radius); }
.empty svg { width: 42px; height: 42px; color: var(--dim); margin-bottom: 10px; }

.skeleton { background: linear-gradient(90deg, var(--surface) 25%, var(--surface-2) 50%, var(--surface) 75%); background-size: 200% 100%; animation: sk 1.4s infinite; border-radius: var(--radius); }
@keyframes sk { to { background-position: -200% 0; } }

/* ---------- dashboard app ---------- */
.app { display: grid; grid-template-columns: 290px 1fr; min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto; background: var(--bg-2);
  border-inline-end: 1px solid var(--border); padding: 16px 14px 30px; display: flex; flex-direction: column; gap: 6px;
}
.side-brand { display: flex; align-items: center; justify-content: space-between; padding: 4px 6px 14px; }
.guild-switch {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; background: var(--surface);
  border: 1px solid var(--border); cursor: pointer; position: relative; margin-bottom: 10px;
}
.guild-switch img, .guild-switch .ph { width: 34px; height: 34px; border-radius: 10px; flex: none; }
.guild-switch .ph { background: var(--surface-3); display: grid; place-items: center; font-weight: 700; }
.guild-switch .nm { font-weight: 700; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.guild-switch svg { width: 18px; height: 18px; color: var(--dim); }
.guild-switch .menu { inset-inline: 0; max-height: 320px; overflow-y: auto; }
.guild-switch .menu img { width: 24px; height: 24px; border-radius: 6px; }

.side-cat { font-size: 12px; font-weight: 700; color: var(--dim); padding: 14px 10px 6px; letter-spacing: .3px; }
.side-item {
  display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 10px; color: var(--muted);
  cursor: pointer; font-weight: 500; font-size: 14.5px; border: 1px solid transparent; transition: background .15s, color .15s;
  background: none; width: 100%; text-align: start;
}
.side-item svg { width: 19px; height: 19px; flex: none; }
.side-item:hover { background: var(--surface); color: var(--text); }
.side-item.active { background: rgba(124, 92, 255, .12); color: #fff; border-color: rgba(124, 92, 255, .3); }
.side-item.active svg { color: var(--accent-hi); }
.side-item .st { margin-inline-start: auto; width: 7px; height: 7px; border-radius: 50%; background: transparent; }
.side-item .st.on { background: var(--good); box-shadow: 0 0 8px rgba(34, 197, 94, .7); }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  height: 64px; display: flex; align-items: center; gap: 12px; padding: 0 28px; border-bottom: 1px solid var(--border);
  position: sticky; top: 0; background: rgba(7, 7, 13, .85); backdrop-filter: blur(12px); z-index: 30;
}
.topbar .crumbs { color: var(--dim); font-size: 14px; display: flex; gap: 8px; align-items: center; }
.topbar .crumbs b { color: var(--text); }
.topbar .crumbs svg { width: 14px; height: 14px; }
.menu-toggle { display: none; }
.content { padding: 28px; max-width: 1100px; width: 100%; padding-bottom: 140px; }

.mod-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.mod-head .ic {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; flex: none;
  background: var(--grad); color: #fff; box-shadow: var(--glow);
}
.mod-head .ic svg { width: 26px; height: 26px; }
.mod-head h1 { margin: 0; font-size: 26px; line-height: 1.2; }
.mod-head p { margin: 4px 0 0; color: var(--muted); }
.mod-head .grow { flex: 1; min-width: 200px; }
.mod-head .switch-big { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); font-weight: 600; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; margin-bottom: 16px; }
.card-title { font-weight: 700; margin: 0 0 16px; display: flex; align-items: center; gap: 8px; font-size: 15px; }
.card-title svg { width: 18px; height: 18px; color: var(--accent-hi); }
.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 20px; }
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field > label { font-weight: 600; font-size: 14px; color: #d6d6e6; }
.field .help { font-size: 12.5px; color: var(--dim); margin-top: -2px; }

.input, .select, textarea.input {
  width: 100%; height: 44px; padding: 0 14px; border-radius: var(--radius-sm); background: var(--bg-2);
  border: 1px solid var(--border-2); outline: 0; transition: border-color .2s, box-shadow .2s;
}
textarea.input { height: auto; min-height: 96px; padding: 12px 14px; resize: vertical; line-height: 1.6; }
.input:focus, .select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(124, 92, 255, .2); }
.select { appearance: none; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%236c6c88' stroke-width='2'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: left 12px center; padding-inline-end: 36px; }
input[type=number].input { font-family: var(--display); }
.color-row { display: flex; gap: 10px; }
.color-row input[type=color] { width: 54px; height: 44px; padding: 4px; border-radius: var(--radius-sm); border: 1px solid var(--border-2); background: var(--bg-2); cursor: pointer; }
.color-row .input { font-family: var(--display); direction: ltr; text-align: start; }

/* toggle */
.toggle-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px;
  border-radius: var(--radius-sm); background: var(--bg-2); border: 1px solid var(--border); cursor: pointer;
}
.toggle-row span { font-weight: 600; font-size: 14px; }
.switch { position: relative; width: 46px; height: 26px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch i {
  position: absolute; inset: 0; border-radius: 99px; background: #2c2c44; transition: background .2s; cursor: pointer;
}
.switch i::after {
  content: ''; position: absolute; top: 3px; inset-inline-start: 3px; width: 20px; height: 20px; border-radius: 50%;
  background: #fff; transition: transform .2s cubic-bezier(.3, 1.4, .6, 1);
}
.switch input:checked + i { background: var(--good); }
.switch input:checked + i::after { transform: translateX(-20px); }
[dir=ltr] .switch input:checked + i::after { transform: translateX(20px); }

/* picker */
.picker { position: relative; }
.picker-box {
  min-height: 44px; padding: 6px 10px; border-radius: var(--radius-sm); background: var(--bg-2); border: 1px solid var(--border-2);
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center; cursor: pointer; padding-inline-end: 34px; position: relative;
}
.picker-box::after {
  content: ''; position: absolute; inset-inline-end: 12px; top: 50%; width: 8px; height: 8px; margin-top: -6px;
  border-right: 2px solid var(--dim); border-bottom: 2px solid var(--dim); transform: rotate(45deg);
}
.picker.open .picker-box { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(124, 92, 255, .2); }
.picker .ph { color: var(--dim); font-size: 14px; padding: 0 4px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 6px 3px 10px; border-radius: 8px; font-size: 13px;
  background: var(--surface-3); border: 1px solid var(--border-2); max-width: 100%;
}
.chip .c { width: 10px; height: 10px; border-radius: 50%; flex: none; background: #99aab5; }
.chip .x { width: 18px; height: 18px; border-radius: 5px; display: grid; place-items: center; cursor: pointer; color: var(--dim); border: 0; background: none; padding: 0; }
.chip .x:hover { background: rgba(239, 68, 68, .2); color: #fca5a5; }
.chip .x svg { width: 12px; height: 12px; }
.chip.single { background: none; border: 0; padding: 2px 4px; font-size: 14px; }
.picker-drop {
  position: absolute; inset-inline: 0; top: calc(100% + 6px); z-index: 40; background: var(--surface-2); border: 1px solid var(--border-2);
  border-radius: 12px; box-shadow: 0 24px 60px -12px rgba(0, 0, 0, .8); display: none; overflow: hidden;
}
.picker.open .picker-drop { display: block; animation: pop .12s ease; }
.picker-drop input { width: 100%; height: 42px; border: 0; border-bottom: 1px solid var(--border); background: transparent; padding: 0 14px; outline: 0; }
.picker-list { max-height: 260px; overflow-y: auto; padding: 6px; }
.picker-opt { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 14px; }
.picker-opt:hover, .picker-opt.hl { background: var(--surface-3); }
.picker-opt.sel { color: var(--accent-hi); }
.picker-opt.sel::after { content: '✓'; margin-inline-start: auto; font-weight: 700; }
.picker-opt.disabled { opacity: .4; }
.picker-opt .c { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.picker-opt .h { color: var(--dim); font-family: var(--display); width: 14px; text-align: center; }
.picker-group { font-size: 11px; font-weight: 700; color: var(--dim); padding: 10px 10px 4px; text-transform: uppercase; }
.picker-none { padding: 18px; text-align: center; color: var(--dim); font-size: 13px; }

/* list & items */
.list-rows { display: flex; flex-direction: column; gap: 8px; }
.list-row { display: flex; gap: 8px; align-items: center; }
.list-row .n { width: 26px; text-align: center; color: var(--dim); font-family: var(--display); font-size: 13px; flex: none; }
.items { display: flex; flex-direction: column; gap: 12px; }
.item { border: 1px solid var(--border-2); border-radius: 12px; background: var(--bg-2); padding: 16px; position: relative; }
.item-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; font-weight: 700; font-size: 13px; color: var(--muted); }
.item .fields { gap: 12px 14px; }
.add-row { border: 1px dashed var(--border-2); background: transparent; color: var(--muted); width: 100%; height: 44px; border-radius: var(--radius-sm); cursor: pointer; display: flex; gap: 8px; align-items: center; justify-content: center; font-weight: 600; }
.add-row:hover { border-color: var(--accent); color: var(--accent-hi); background: rgba(124, 92, 255, .05); }
.add-row svg { width: 16px; height: 16px; }
.count-note { font-size: 12px; color: var(--dim); font-weight: 500; }

.actions-card { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; background: linear-gradient(135deg, rgba(124, 92, 255, .1), rgba(34, 211, 238, .05)); border-color: rgba(124, 92, 255, .3); }
.actions-card p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
.actions-card .btns { display: flex; gap: 10px; flex-wrap: wrap; }

/* save bar */
.savebar {
  position: fixed; bottom: 22px; z-index: 70; inset-inline-start: calc(290px + 28px); inset-inline-end: 28px; max-width: 1044px;
  display: flex; align-items: center; gap: 12px; padding: 12px 12px 12px 18px; padding-inline-start: 18px;
  background: #0f0f19; border: 1px solid var(--border-2); border-radius: 14px; box-shadow: 0 20px 60px -10px rgba(0, 0, 0, .9);
  transform: translateY(140%); transition: transform .3s cubic-bezier(.3, 1.3, .5, 1);
}
.savebar.show { transform: none; }
.savebar.shake { animation: shake .4s; background: #2a1013; border-color: rgba(239, 68, 68, .6); }
.savebar span { flex: 1; font-weight: 600; }
@keyframes shake { 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }

/* overview */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
@media (max-width: 1100px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; position: relative; overflow: hidden; }
.stat .ic { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; margin-bottom: 12px; background: rgba(124, 92, 255, .12); color: var(--accent-hi); }
.stat .ic svg { width: 18px; height: 18px; }
.stat b { display: block; font-family: var(--display); font-size: 28px; line-height: 1.1; }
.stat span { color: var(--dim); font-size: 13px; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.row-list { display: flex; flex-direction: column; }
.row-list .r { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 14px; }
.row-list .r:last-child { border-bottom: 0; }
.row-list .r img, .row-list .r .av { width: 32px; height: 32px; border-radius: 50%; background: var(--surface-3); flex: none; }
.row-list .r .grow { flex: 1; min-width: 0; }
.row-list .r .grow div { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-list .r small { color: var(--dim); }
.tag { font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 6px; background: var(--surface-3); white-space: nowrap; }
.prot-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.prot { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--border); cursor: pointer; font-weight: 600; font-size: 14px; }
.prot:hover { border-color: var(--border-2); }
.prot svg { width: 18px; height: 18px; }
.prot .s { margin-inline-start: auto; font-size: 12px; font-weight: 700; }
.prot .s.on { color: var(--good); }
.prot .s.off { color: var(--dim); }
.alert { display: flex; gap: 12px; align-items: center; padding: 14px 16px; border-radius: 12px; margin-bottom: 18px; font-size: 14px; background: rgba(245, 165, 36, .08); border: 1px solid rgba(245, 165, 36, .3); color: #fcd38a; }
.alert svg { width: 20px; height: 20px; flex: none; }

/* embed preview */
.preview-wrap { background: #1d1d2d; border-radius: 12px; padding: 16px; border: 1px solid var(--border); }
.preview-wrap .dc-embed { border-inline-start-color: var(--accent); max-width: 100%; }
.preview-wrap .dc-embed .d { white-space: pre-wrap; color: #d4d4e0; }
.preview-wrap .dc-embed img.big { margin-top: 10px; border-radius: 6px; max-height: 260px; }
.preview-wrap .dc-embed .row { display: flex; gap: 12px; justify-content: space-between; }
.preview-wrap .dc-embed img.th { width: 72px; height: 72px; border-radius: 6px; object-fit: cover; }
.preview-wrap .dc-embed .ft { margin-top: 8px; font-size: 12px; color: var(--muted); }

/* toast */
.toasts { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  display: flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 12px; background: var(--surface-2);
  border: 1px solid var(--border-2); box-shadow: 0 20px 40px -10px rgba(0, 0, 0, .7); font-weight: 600; font-size: 14px;
  animation: toastIn .3s cubic-bezier(.3, 1.4, .5, 1);
}
.toast svg { width: 18px; height: 18px; }
.toast.ok svg { color: var(--good); }
.toast.err { border-color: rgba(239, 68, 68, .5); }
.toast.err svg { color: var(--bad); }
.toast.out { opacity: 0; transform: translateY(-10px); transition: .3s; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-14px) scale(.95); } }

.center-screen { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 20px; }
.center-screen h1 { font-family: var(--display); font-size: 90px; margin: 0; line-height: 1; }
.loader { width: 44px; height: 44px; border-radius: 50%; border: 3px solid var(--surface-3); border-top-color: var(--accent); animation: spin .8s linear infinite; margin: auto; }

.scrim { display: none; }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; inset-block: 0; inset-inline-start: 0; width: 290px; z-index: 80;
    transform: translateX(100%); transition: transform .25s ease;
  }
  .sidebar.open { transform: none; }
  .scrim.show { display: block; position: fixed; inset: 0; background: rgba(0, 0, 0, .6); z-index: 75; }
  .menu-toggle { display: inline-flex; }
  .content { padding: 20px 16px 140px; }
  .topbar { padding: 0 16px; }
  .savebar { inset-inline: 16px; bottom: 16px; }
  .fields { grid-template-columns: 1fr; }
  .nav-links { display: none; }
}
@media (max-width: 560px) {
  .nav-actions .btn-ghost { display: none; }
  .savebar span { font-size: 13px; }
  .search { min-width: 0; width: 100%; }
  .user-chip .name { display: none; }
  .user-chip { padding: 4px; }
}

/* ---------- app identity (servers + dashboard) ---------- */
body.appbg { background: #05050a; }
body.appbg::before {
  content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(700px 420px at 85% -10%, rgba(91, 61, 255, .22), transparent 70%),
    radial-gradient(600px 380px at 0% 110%, rgba(14, 165, 198, .12), transparent 70%);
}
body.appbg .nav { background: rgba(5, 5, 10, .6); }
body.appbg .sidebar { background: rgba(9, 9, 17, .85); backdrop-filter: blur(14px); }
body.appbg .topbar { background: rgba(5, 5, 10, .7); }
body.appbg .card, body.appbg .stat, body.appbg .server { background: rgba(17, 17, 28, .78); backdrop-filter: blur(8px); }

.brand .tagline { font-family: var(--display); font-size: 10px; font-weight: 700; letter-spacing: 2px; color: var(--cyan); background: rgba(46, 230, 255, .08); border: 1px solid rgba(46, 230, 255, .25); padding: 1px 7px; border-radius: 6px; }

.side-item { position: relative; }
.side-item.active { background: linear-gradient(90deg, rgba(124, 92, 255, .05), rgba(124, 92, 255, .18)); }
.side-item.active::before {
  content: ''; position: absolute; inset-inline-start: -14px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 4px 4px 0;
  background: var(--grad); box-shadow: 0 0 12px rgba(124, 92, 255, .9);
}
[dir=rtl] .side-item.active::before { border-radius: 4px 0 0 4px; }

.mod-head .ic { position: relative; }
.mod-head .ic::after { content: ''; position: absolute; inset: -5px; border-radius: 18px; border: 1px solid rgba(124, 92, 255, .35); }
.stat { transition: border-color .25s, transform .25s; }
.stat:hover { border-color: rgba(124, 92, 255, .4); transform: translateY(-2px); }
.stat::after { content: ''; position: absolute; inset-inline-end: -30px; top: -30px; width: 90px; height: 90px; border-radius: 50%; background: radial-gradient(circle, rgba(124, 92, 255, .18), transparent 70%); }

.page-head h1 { font-size: 36px; }
.page-head h1 span { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- language ---------- */
.user-slot { display: flex; align-items: center; gap: 8px; }
.lang-btn span { font-family: var(--font); }
[dir=ltr] .switch input:checked + i::after { transform: translateX(20px); }
[dir=ltr] .select { background-position: right 12px center; }
[dir=ltr] .side-item.active::before { border-radius: 0 4px 4px 0; }
@media (max-width: 860px) { [dir=ltr] .sidebar { transform: translateX(-100%); } [dir=ltr] .sidebar.open { transform: none; } }
@media (max-width: 560px) { .lang-btn span { display: none; } .lang-btn { width: 38px; padding: 0; } }

/* ---------- SOON surprise ---------- */
.soon-fab {
  position: fixed; bottom: 22px; right: 22px; z-index: 90; border: 0; cursor: pointer; color: #fff;
  display: flex; align-items: center; gap: 8px; padding: 10px 16px 10px 12px; border-radius: 999px;
  background: linear-gradient(135deg, #7c5cff, #2ee6ff); font-family: var(--display);
  box-shadow: 0 12px 40px -8px rgba(124, 92, 255, .9), inset 0 0 0 1px rgba(255, 255, 255, .25);
  animation: soonBob 3s ease-in-out infinite;
}
.soon-fab svg { width: 20px; height: 20px; animation: soonWiggle 2.4s ease-in-out infinite; }
.soon-fab b { font-size: 15px; letter-spacing: 2px; }
.soon-fab small { font-family: var(--font); font-weight: 600; font-size: 12px; opacity: .85; }
.soon-ring { position: absolute; inset: -4px; border-radius: inherit; border: 2px solid rgba(124, 92, 255, .6); animation: soonPing 2s ease-out infinite; pointer-events: none; }
body:has(.savebar.show) .soon-fab { bottom: 92px; }
@keyframes soonBob { 50% { transform: translateY(-5px); } }
@keyframes soonWiggle { 0%, 70%, 100% { transform: rotate(0); } 75% { transform: rotate(-14deg); } 85% { transform: rotate(12deg); } }
@keyframes soonPing { 0% { opacity: .9; transform: scale(1); } 100% { opacity: 0; transform: scale(1.35); } }

.soon-modal {
  position: fixed; inset: 0; z-index: 120; display: none; place-items: center; padding: 16px;
  background: rgba(3, 3, 8, .72); backdrop-filter: blur(10px);
}
.soon-modal.open { display: grid; animation: fadeIn .25s ease; }
@keyframes fadeIn { from { opacity: 0; } }
.soon-card {
  position: relative; width: min(520px, 100%); text-align: center; padding: 40px 28px 30px; border-radius: 28px; overflow: hidden;
  background: radial-gradient(500px 260px at 50% -10%, rgba(124, 92, 255, .45), transparent 70%), #0d0c1a;
  border: 1px solid rgba(124, 92, 255, .4); box-shadow: 0 40px 120px -20px rgba(124, 92, 255, .6);
  animation: popIn .45s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes popIn { from { opacity: 0; transform: scale(.85) translateY(20px); } }
.soon-x { position: absolute; top: 14px; inset-inline-end: 14px; width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--border-2); background: var(--surface-2); cursor: pointer; display: grid; place-items: center; color: var(--muted); }
.soon-x svg { width: 18px; height: 18px; }
.soon-gift {
  width: 76px; height: 76px; margin: 0 auto 14px; border-radius: 24px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, #7c5cff, #2ee6ff); box-shadow: 0 16px 50px -10px rgba(124, 92, 255, .9);
  animation: soonBob 2.6s ease-in-out infinite;
}
.soon-gift svg { width: 36px; height: 36px; }
.soon-tag { display: inline-block; font-family: var(--display); font-weight: 700; letter-spacing: 6px; font-size: 13px; color: var(--cyan); padding: 4px 12px; border-radius: 99px; border: 1px solid rgba(46, 230, 255, .35); background: rgba(46, 230, 255, .08); }
.soon-card h3 { font-size: 26px; margin: 14px 0 6px; }
.soon-card p { color: var(--muted); margin: 0 0 24px; }
.soon-clock { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; direction: ltr; }
.soon-clock div { padding: 14px 4px; border-radius: 16px; background: rgba(255, 255, 255, .04); border: 1px solid var(--border-2); }
.soon-clock b { display: block; font-family: var(--display); font-size: 36px; line-height: 1.1; background: linear-gradient(180deg, #fff, #a99bff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.soon-clock span { font-size: 12px; color: var(--dim); }
.soon-bar { height: 6px; border-radius: 99px; background: var(--surface-3); margin-top: 22px; overflow: hidden; }
.soon-bar i { display: block; height: 100%; width: 0; background: var(--grad); border-radius: inherit; transition: width .6s ease; }
@media (max-width: 560px) { .soon-fab small { display: none; } .soon-clock b { font-size: 28px; } .soon-fab { bottom: 16px; right: 16px; } }
@media (prefers-reduced-motion: reduce) { .soon-fab, .soon-fab svg, .soon-ring, .soon-gift { animation: none; } }

/* ---------- security score + backups + badges ---------- */
.score { display: grid; grid-template-columns: auto 1fr; gap: 26px; align-items: center; }
.score-ring { width: 128px; height: 128px; border-radius: 50%; display: grid; place-items: center; position: relative;
  background: conic-gradient(var(--c, var(--good)) calc(var(--p) * 1%), var(--surface-3) 0); }
.score-ring::before { content: ''; position: absolute; inset: 10px; border-radius: 50%; background: var(--surface); }
.score-ring div { position: relative; text-align: center; }
.score-ring b { display: block; font-family: var(--display); font-size: 34px; line-height: 1; }
.score-ring span { font-family: var(--display); font-weight: 700; color: var(--c); }
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; padding: 8px 10px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--border); }
.check svg { width: 16px; height: 16px; flex: none; }
.check.ok svg { color: var(--good); }
.check.bad svg { color: var(--warn); }
.check .fix { margin-inline-start: auto; font-size: 12px; font-weight: 700; color: var(--accent-hi); background: none; border: 0; cursor: pointer; }
@media (max-width: 760px) { .score { grid-template-columns: 1fr; justify-items: center; } .checks { grid-template-columns: 1fr; width: 100%; } }
.side-item .nb { margin-inline-start: auto; font-size: 10px; font-weight: 700; color: var(--cyan); background: rgba(46, 230, 255, .1); border: 1px solid rgba(46, 230, 255, .25); padding: 0 6px; border-radius: 6px; font-family: var(--display); }
.side-item .nb + .st { margin-inline-start: 6px; }
.locked-note { display: flex; gap: 10px; align-items: center; padding: 12px 16px; border-radius: 12px; margin-bottom: 16px; background: rgba(124, 92, 255, .08); border: 1px solid rgba(124, 92, 255, .3); font-size: 14px; }
.locked-note svg { width: 18px; height: 18px; color: var(--accent-hi); flex: none; }
fieldset.locked { border: 0; padding: 0; margin: 0; opacity: .6; pointer-events: none; }
[dir=ltr] .crumb-sep { transform: scaleX(-1); }
