/* Dashboard theme: deep blue-grey panels, a left sidebar with a server switcher, card grids, tabs and toggle switches. */
:root {
  --bg: #262935; --side: #1d2029; --card: #1f222c; --card2: #2d313e; --card3: #3a3f50; --field: #181b23;
  --text: #f3f5fa; --muted: #8c92a4; --line: #2f3341;
  --accent: #2f8bff; --accent2: #8b6cf0; --ok: #3ecf8e; --warn: #f5a524; --bar: #2f8bff;
  --gold: #f5c242; --gold-bg: rgba(245, 194, 66, .14);
  --radius: 14px;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.5 "Inter", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; } a:hover { text-decoration: underline; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mark { width: 30px; height: 30px; flex: none; } .mark-bg { fill: var(--accent); } .mark-fg { fill: #fff; }
.mark-lg .mark { width: 72px; height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-size: 1.05rem; font-weight: 700; } .brand:hover { text-decoration: none; } .brand b { color: var(--accent); }

/* ---- Frame ---- */
.top { display: flex; justify-content: space-between; align-items: center; padding: 14px 40px; min-height: 64px; }
body.has-side .top { justify-content: flex-end; }
.crumb { display: none; }
.account { display: flex; gap: 10px; align-items: center; margin: 0; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--card3); display: grid; place-items: center; font-weight: 700; }
button.link { background: none; border: 0; color: var(--muted); cursor: pointer; font: inherit; padding: 0; } button.link:hover { color: var(--text); }
.shell { min-height: 100vh; } main { max-width: 1180px; margin: 0 auto; padding: 8px 40px 40px; }
body.has-side .shell { margin-left: 290px; }

/* ---- Sidebar ---- */
.side { position: fixed; inset: 0 auto 0 0; width: 290px; background: var(--side); padding: 18px 14px 24px; overflow-y: auto; }
.switcher { position: relative; margin: 18px 0 14px; }
.switcher summary { list-style: none; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; background: #20232d; cursor: pointer; user-select: none; }
.switcher summary::-webkit-details-marker { display: none; }
.switcher summary:hover, .switcher[open] summary { border-color: #3b6fc4; }
.switcher img, .switcher .ph { border-radius: 50%; flex: none; }
.sw-name { flex: 1; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.chev { color: var(--muted); transition: transform .15s; } .switcher[open] .chev { transform: rotate(180deg); }
.switcher .menu { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 6px); background: #20232d; border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: 0 12px 32px rgba(0, 0, 0, .45); }
.menu-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; color: var(--text); font-weight: 600; }
.menu-item:hover { background: var(--card2); text-decoration: none; } .menu-item.current { background: var(--card2); }
.menu hr { border: 0; border-top: 1px solid var(--line); margin: 6px 4px; }
.side nav { margin-top: 6px; }
.nav-group { margin-top: 18px; }
.nav-group summary { list-style: none; display: flex; justify-content: space-between; align-items: center; padding: 6px 10px; cursor: pointer; font-size: .72rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; color: #aeb4c4; }
.nav-group summary::-webkit-details-marker { display: none; }
.nav-group summary .chev { font-size: 1rem; transform: rotate(180deg); } .nav-group:not([open]) summary .chev { transform: none; }
.nav-item { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 10px; color: #c9cedb; font-weight: 500; }
.nav-item:hover { background: #262a36; text-decoration: none; color: #fff; }
.nav-item.on { background: #2c303e; color: #fff; font-weight: 700; }
.nav-item.sub::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: #6b7185; flex: none; margin-right: -2px; }
.ico { width: 24px; text-align: center; filter: grayscale(1) brightness(1.35); opacity: .9; } .nav-item.on .ico { filter: none; opacity: 1; }
.gem { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--gold-bg); font-size: .8rem; flex: none; }
.nav-item .gem { margin-left: auto; }

/* ---- Typography ---- */
.page-title { font-size: 1.9rem; font-weight: 800; margin: 6px 0 22px; text-align: left; letter-spacing: -.01em; }
h1 { font-size: 1.7rem; margin: 0 0 14px; } h2 { font-size: 1.15rem; margin-top: 0; } h3 { margin: 0 0 6px; font-size: 1.02rem; }
h2.group { margin: 34px 0 18px; font-size: 1.45rem; font-weight: 800; padding-bottom: 8px; border-bottom: 2px solid var(--text); display: inline-block; }
.muted { color: var(--muted); font-size: .9em; } .warn { color: var(--warn); }

/* ---- Cards ---- */
.card, .stat, .plugin, .server-card { background: var(--card); border: 1px solid transparent; border-radius: var(--radius); }
.card { padding: 22px; margin: 16px 0; }
.btn, button.btn { background: var(--accent); color: #fff; border: 0; border-radius: 10px; padding: 10px 20px; font: inherit; font-weight: 600; cursor: pointer; display: inline-block; transition: background .12s, filter .12s; }
.btn:hover { text-decoration: none; filter: brightness(1.1); }
.btn.alt { background: var(--card2); color: var(--text); } .btn.alt:hover { background: var(--card3); filter: none; }
.btn.ghost { background: rgba(47, 139, 255, .14); color: var(--accent); } .btn.ghost:hover { background: rgba(47, 139, 255, .24); filter: none; }
.btn.big { padding: 13px 28px; font-size: 1.05rem; border-radius: 12px; }
.hero { text-align: center; margin-top: -64px; padding: 174px 16px 90px; background: radial-gradient(60% 60% at 50% 0%, rgba(47, 139, 255, .22), transparent 70%); }
.hero p { color: var(--muted); max-width: 46ch; margin: 0 auto 26px; } .hero h1 { font-size: 2.8rem; font-weight: 800; margin-top: 16px; letter-spacing: -.02em; }
.server-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 24px; }
.server-card { overflow: hidden; transition: transform .12s, border-color .12s; } .server-card:hover { transform: translateY(-2px); border-color: var(--line); }
.banner { position: relative; height: 150px; display: grid; place-items: center; background: var(--side); overflow: hidden; }
.banner-bg { position: absolute; inset: -20px; width: calc(100% + 40px); height: calc(100% + 40px); object-fit: cover; filter: blur(18px) brightness(.55); }
.badge { position: relative; width: 80px; height: 80px; border-radius: 50%; border: 3px solid #fff; object-fit: cover; background: var(--card2); }
.ph { display: grid; place-items: center; font-weight: 700; text-transform: uppercase; font-size: 1.4rem; background: var(--card3); border-radius: 50%; } .ph.sm { width: 32px; height: 32px; font-size: 1rem; }
.server-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 16px; } .server-foot strong { display: block; line-height: 1.3; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
.stat { padding: 18px; text-align: left; color: var(--muted); font-size: .9rem; } .stat span { display: block; font-size: 1.8rem; font-weight: 800; color: var(--text); line-height: 1.2; }

/* ---- Plugin cards, tabs and search ---- */
.plugin-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; border-bottom: 1px solid var(--line); margin: 34px 0 6px; }
.tabs { display: flex; flex-wrap: wrap; gap: 4px 26px; }
.tab { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); font: inherit; font-weight: 600; padding: 12px 0; margin-bottom: -1px; cursor: pointer; } .tab:hover { color: var(--text); }
.tab.on { color: var(--text); border-bottom-color: var(--text); }
.searchbox { margin: 0 0 8px; } .searchbox input { width: 260px; max-width: 100%; border-radius: 10px; background: var(--card); border-color: transparent; padding: 9px 14px; }
.plugin-group + .plugin-group { margin-top: 0; }
.plugins { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; }
.plugin { position: relative; padding: 22px; display: flex; flex-direction: column; gap: 4px; min-height: 230px; transition: border-color .12s, transform .12s; }
.plugin:hover { border-color: var(--line); transform: translateY(-1px); }
.plugin h3 { font-size: 1.02rem; font-weight: 700; margin-top: 2px; }
.plugin p { color: var(--muted); margin: 0 0 16px; flex: 1; font-size: .92em; } .plugin .btn { align-self: flex-start; }
.tile { width: 58px; height: 58px; border-radius: 15px; background: linear-gradient(140deg, #3a79e8, #2347a8); display: grid; place-items: center; font-size: 1.7rem; margin-bottom: 14px; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .18); }
.state { position: absolute; top: 20px; right: 20px; font-size: .75rem; padding: 3px 11px; border-radius: 99px; background: var(--card2); color: var(--muted); font-weight: 700; } .state.live { background: rgba(62, 207, 142, .15); color: var(--ok); }
.premium-badge { position: absolute; top: 20px; right: 20px; font-size: .75rem; padding: 3px 11px; border-radius: 99px; background: var(--gold-bg); color: var(--gold); font-weight: 700; }
.empty-plugins { text-align: center; padding: 40px 16px; }

/* ---- Tables, filters, forms ---- */
.table-wrap { overflow-x: auto; } table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px 10px; border-bottom: 1px solid var(--line); vertical-align: top; } th { color: var(--muted); font-weight: 600; font-size: .85em; }
tbody tr:hover td { background: rgba(255, 255, 255, .02); }
.filters { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.range { display: flex; gap: 6px; margin: 0 0 16px; } .range a { padding: 7px 16px; border-radius: 99px; color: var(--muted); background: var(--card); } .range a:hover { text-decoration: none; color: var(--text); } .range a.on { background: var(--accent); color: #fff; font-weight: 600; }
label { display: block; font-size: .9em; } label input, label select, label textarea { display: block; width: 100%; margin-top: 6px; }
input, select, textarea { font: inherit; color: var(--text); background: var(--field); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; transition: border-color .12s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); }
textarea { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .9em; }
fieldset.card { min-width: 0; padding: 26px 28px; }
legend { font-weight: 800; font-size: 1.35rem; padding: 0; float: left; width: 100%; margin-bottom: 14px; } legend + * { clear: both; }
.field { margin: 16px 0; } fieldset h3 { color: var(--muted); margin-top: 26px; font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; }
.check { display: flex; gap: 12px; align-items: center; font-size: 1em; cursor: pointer; }
.check input[type=checkbox] { appearance: none; -webkit-appearance: none; flex: none; width: 44px; height: 24px; margin: 0; padding: 0; border: 0; border-radius: 99px; background: #4a4f61; position: relative; cursor: pointer; transition: background .15s; }
.check input[type=checkbox]::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .15s; }
.check input[type=checkbox]:checked { background: var(--accent); } .check input[type=checkbox]:checked::after { transform: translateX(20px); }
.check input[type=checkbox]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.js .panel { display: none; } .js .panel.show { display: block; }
.savebar { position: sticky; bottom: 0; background: linear-gradient(to top, var(--bg) 70%, transparent); padding: 18px 0 14px; display: flex; gap: 14px; align-items: center; }
#status.ok { color: var(--ok); } #status.err { color: var(--warn); white-space: pre-line; }
dl { display: grid; grid-template-columns: 120px 1fr; gap: 8px 14px; } dt { color: var(--muted); } dd { margin: 0; } .pre { white-space: pre-wrap; word-break: break-word; }
.chip { display: inline-block; background: var(--card2); border-radius: 99px; padding: 2px 12px; font-size: .85em; }
.pager { text-align: center; color: var(--muted); } .pager a { margin: 0 10px; }
.chart { width: 100%; height: auto; } .bar { fill: var(--bar); } .axis { fill: var(--muted); font-size: 11px; }
.center { text-align: center; padding: 40px 16px; } code { background: var(--field); padding: 1px 6px; border-radius: 6px; }
@media (max-width: 860px) {
  body.has-side .shell { margin-left: 0; }
  .side { position: static; width: auto; border-bottom: 1px solid var(--line); }
  .top { padding: 12px 18px; } main { padding: 8px 18px 30px; }
  .plugin-bar { align-items: stretch; } .searchbox input { width: 100%; }
}
[hidden] { display: none !important; }
/* picker */
.picker { margin-top: 5px; border: 1px solid var(--line); border-radius: 8px; background: var(--side); padding: 8px; position: relative; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.chip-x { display: inline-flex; align-items: center; gap: 6px; background: var(--card2); border-radius: 99px; padding: 2px 4px 2px 12px; font-size: .88rem; }
.chip-x button { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 1.1rem; line-height: 1; padding: 2px 6px; border-radius: 50%; } .chip-x button:hover { color: var(--text); background: var(--line); }
.picker input { margin: 0; }
.options { list-style: none; margin: 6px 0 0; padding: 4px; max-height: 220px; overflow-y: auto; background: var(--card); border: 1px solid var(--line); border-radius: 8px; }
.options li { padding: 6px 10px; border-radius: 6px; cursor: pointer; } .options li:hover { background: var(--card2); } .options li.empty { color: var(--muted); cursor: default; }
/* switch */
.switch { position: absolute; top: 20px; right: 20px; width: 58px; height: 28px; border-radius: 99px; border: 0; background: #4a4f61; cursor: pointer; padding: 0; transition: background .15s; }
.switch::before { content: "OFF"; position: absolute; top: 0; right: 9px; line-height: 28px; font-size: .62rem; font-weight: 800; letter-spacing: .04em; color: #c5cadb; }
.switch::after { content: ""; position: absolute; top: 4px; left: 4px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch[aria-checked="true"] { background: var(--accent); } .switch[aria-checked="true"]::before { content: "ON"; right: auto; left: 10px; color: #fff; } .switch[aria-checked="true"]::after { transform: translateX(30px); } .switch:disabled { opacity: .6; cursor: wait; }
.toast { min-height: 1.4em; margin-top: 18px; } .toast.ok { color: var(--ok); } .toast.err { color: var(--warn); }
/* feed */
.feed { list-style: none; margin: 0 0 10px; padding: 0; } .feed li { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); } .feed li > div { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 7px; flex: none; background: var(--muted); }
.t-warn { background: #f1c40f; } .t-timeout, .t-kick { background: #e67e22; } .t-ban { background: #e74c3c; } .t-untimeout, .t-unban { background: #2ecc71; } .t-note { background: #3498db; }
.stat small { color: var(--muted); }
form.dirty .savebar { border-top-color: var(--warn); }
/* invite button, call to action and footer */
.top-actions { display: flex; align-items: center; gap: 16px; }
.btn.small { padding: 7px 14px; font-size: .9rem; border-radius: 9px; }
.cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.hero .cta + .warn { margin-top: 18px; }
.add-card .badge { font-size: 2rem; border-style: dashed; }
.foot { max-width: 1180px; margin: 0 auto; padding: 22px 40px 40px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--muted); font-size: .88rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.foot a { color: var(--muted); } .foot a:hover { color: var(--text); }
/* terms of service and privacy policy */
.legal { max-width: 78ch; margin: 0 auto; }
.legal h1 { font-size: 2rem; margin-bottom: 4px; }
.legal h2 { margin: 2em 0 .5em; font-size: 1.2rem; }
.legal p, .legal li { color: #d5d9e4; line-height: 1.65; }
.legal ul { padding-left: 1.3em; } .legal li { margin: .45em 0; }
.legal .updated { color: var(--muted); margin-top: 0; }
@media (max-width: 860px) { .top { flex-wrap: wrap; gap: 10px; } .top-actions { gap: 12px; } .foot { padding: 18px; } }
/* premium and custom commands */
.premium-link { color: var(--gold); font-weight: 700; background: var(--gold-bg); padding: 6px 14px; border-radius: 99px; } .premium-link:hover { text-decoration: none; filter: brightness(1.15); }
.banner-msg { padding: 12px 16px; border-radius: 12px; border: 1px solid var(--line); margin: 0 0 16px; }
.banner-msg.ok { border-color: #2e7d57; background: rgba(46, 125, 87, .15); }
.banner-msg.err { border-color: #a94442; background: rgba(169, 68, 66, .15); }
.slots { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.slot.expired { opacity: .6; }
.slot h3 { margin: 0 0 4px; display: flex; align-items: center; gap: 10px; }
.slot .chip { font-size: .72rem; padding: 2px 8px; border-radius: 999px; background: rgba(155, 89, 182, .25); color: #d9b8ee; }
.inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; margin: 12px 0 6px; }
.inline-form label { flex: 1 1 200px; }
.table-wrap { overflow-x: auto; }
.table-wrap table { width: 100%; border-collapse: collapse; }
.table-wrap th, .table-wrap td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
td.actions { display: flex; gap: 8px; align-items: center; white-space: nowrap; }
td.actions form { margin: 0; }
.command-form fieldset.card { margin: 0 0 16px; border: 1px solid var(--line); }
.command-form legend { padding: 0 8px; font-weight: 700; }
.command-form textarea, .command-form input:not([type=checkbox]), .command-form select:not([multiple]) { width: 100%; box-sizing: border-box; }
.command-form .field { margin: 12px 0; }
.command-form .field.row { display: flex; gap: 10px; } .command-form .field.row select { flex: 1; }
.command-form .check { display: flex; align-items: center; gap: 8px; margin: 12px 0; }
.command-form .savebar { display: flex; align-items: center; gap: 18px; }
.command-form select[multiple]:not([hidden]) { width: 100%; min-height: 6em; }
.problems { border-color: #a94442; } .problems ul { margin: 8px 0 0; padding-left: 1.2em; }
.notice { padding: 8px 12px; border-radius: 8px; background: rgba(155, 89, 182, .15); border: 1px solid rgba(155, 89, 182, .4); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.lock { border: 0; padding: 0; margin: 0; opacity: .55; }

/* departments */
.gem { font-size: .9em; }
.nav-item .gem { margin-left: auto; opacity: .85; }
.premium-card { border-color: rgba(155, 89, 182, .5); background: linear-gradient(135deg, rgba(155, 89, 182, .16), transparent 70%); }
.premium-card ul { padding-left: 1.2em; }
.depts { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; margin-bottom: 8px; }
.dept header { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.dept h3 { margin: 0; } .dept-actions { display: flex; gap: 8px; align-items: center; } .dept-actions form { margin: 0; }
.dept dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 14px 0 10px; }
.dept dt { color: var(--muted); } .dept dd { margin: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.dept-stats { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 0; color: var(--muted); font-size: .92em; } .dept-stats b { color: var(--text); }
.chip.gone { opacity: .6; font-style: italic; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 10px 0 0; } .kv dt { color: var(--muted); } .kv dd { margin: 0; display: flex; flex-wrap: wrap; gap: 4px; }

/* Departments: the main server's link code */
.link-code { margin: 12px 0; }
.link-code code { font-size: 1.6rem; letter-spacing: 0.08em; user-select: all; }

/* ---- Custom command editor (cards, the Edit Embed dialog, the Components V2 builder) ---- */
.cc-editor, .cc-dialog { --cc-card: #181b20; --cc-line: #2a2e35; --cc-field: #0e1114; --cc-light: #7cc8ff; --cc-soft: #26282c; }
.cc-editor { max-width: 1000px; }
.cc-card { background: var(--cc-card); border: 1px solid var(--cc-line); border-radius: 14px; padding: 22px; margin: 0 0 16px; }
.cc-card h2 { font-size: 1.02rem; font-weight: 700; margin: 0; } .cc-card h3 { margin: 0 0 8px; font-size: .95rem; }
.cc-card > h2 { margin-bottom: 14px; }
.cc-card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; } .cc-card-head h2 { margin: 0; }
.cc-format { display: flex; align-items: center; gap: 10px; } .chip.on { background: rgba(47, 139, 255, .18); color: var(--accent); font-weight: 600; }
.cc-editor input:not([type=checkbox]):not([type=color]):not(.bare), .cc-editor select, .cc-editor textarea, .cc-dialog input:not([type=checkbox]):not([type=color]):not(.bare), .cc-dialog select, .cc-dialog textarea { background: var(--cc-field); border-color: var(--cc-line); }
.cc-editor label small { display: block; margin-top: 6px; }
.cc-collapse > summary { list-style: none; display: flex; justify-content: space-between; align-items: center; cursor: pointer; } .cc-collapse > summary::-webkit-details-marker { display: none; }
.cc-collapse[open] > summary { margin-bottom: 14px; } .cc-collapse:not([open]) .chev { transform: rotate(180deg); } .cc-collapse .chev { transform: none; }
.grid2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; } .grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cc-sub { margin: 22px 0 10px !important; font-weight: 700; }
.resp { margin-bottom: 14px; } .resp-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; } .resp textarea { width: 100%; font-family: inherit; font-size: .95rem; }
.cc-add { display: block; width: 100%; background: transparent; border: 1px dashed #3a3f48; border-radius: 12px; color: var(--text); font: inherit; font-weight: 600; padding: 14px; cursor: pointer; margin: 4px 0 0; }
.cc-add:hover:not(:disabled) { background: rgba(255, 255, 255, .03); } .cc-add:disabled { opacity: .55; cursor: not-allowed; }
.cc-boxed { margin-top: 16px; border: 1px solid var(--cc-line); background: var(--cc-field); border-radius: 10px; padding: 12px 14px; }
.cc-footer { position: sticky; bottom: 0; display: flex; justify-content: flex-end; gap: 12px; padding: 18px 0 14px; background: linear-gradient(to top, var(--bg) 70%, transparent); z-index: 3; }
.btn.outline { background: transparent; border: 1px solid #3a3f48; color: var(--text); } .btn.outline:hover { background: rgba(255, 255, 255, .06); filter: none; }
.btn.light { background: var(--cc-light, #7cc8ff); color: #08131f; } .btn.light:hover { filter: brightness(1.08); }
.icon-btn { background: none; border: 0; color: var(--muted); cursor: pointer; font: inherit; padding: 3px 9px; border-radius: 7px; } .icon-btn:hover:not(:disabled) { background: rgba(255, 255, 255, .08); color: var(--text); } .icon-btn:disabled { opacity: .3; cursor: default; }

/* The dialog */
.cc-dialog { border: 1px solid var(--cc-line); border-radius: 16px; padding: 0; width: min(1100px, 96vw); height: min(880px, 92vh); max-width: none; background: #1a1d21; color: var(--text); overflow: hidden; }
.cc-dialog[open] { display: flex; flex-direction: column; } .cc-dialog::backdrop { background: rgba(0, 0, 0, .62); }
.cc-tabs { display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 1px solid var(--cc-line); flex: none; }
.cc-tabs button { background: none; border: 0; border-bottom: 2px solid transparent; color: var(--muted); padding: 15px; font: inherit; font-weight: 600; cursor: pointer; } .cc-tabs button:hover { color: var(--text); }
.cc-tabs button.on { color: #fff; border-bottom-color: var(--cc-light); }
.cc-dialog-body { flex: 1; overflow: auto; padding: 24px 32px 30px; }
.cc-dialog-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 12px 20px; margin-bottom: 18px; } .cc-dialog-head h2 { margin: 0 0 2px; font-size: 1.05rem; }
.cc-head-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.seg { display: flex; border: 1px solid var(--cc-line); border-radius: 10px; padding: 3px; background: var(--cc-field); }
.seg button { background: none; border: 0; color: var(--muted); padding: 7px 16px; border-radius: 8px; font: inherit; font-weight: 600; cursor: pointer; } .seg button.on { background: #000; color: #fff; }
.cc-dialog-foot { flex: none; display: flex; justify-content: flex-end; gap: 12px; padding: 14px 24px; border-top: 1px solid var(--cc-line); }

/* A Discord-looking message (used for the editor and the preview) */
.dc { background: #202226; border: 1px solid var(--cc-line); border-radius: 14px; padding: 18px 20px; color: #dbdee1; }
.dc-profile { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; } .dc-avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(140deg, #3ddc97, #1f8f63); color: #06251a; display: grid; place-items: center; font-weight: 800; flex: none; }
.dc-app { background: #5865f2; color: #fff; font-size: .62rem; font-weight: 800; padding: 1px 6px; border-radius: 4px; }
.cc-dialog.no-profile .dc-profile { display: none; }
.emb-edit { display: grid; grid-template-columns: 1fr 190px; gap: 18px; background: var(--cc-soft); border-left: 4px solid #4e5058; border-radius: 8px; padding: 16px 18px; }
input.bare { background: transparent !important; border: 0 !important; border-radius: 0 !important; padding: 6px 0 !important; width: 100%; color: inherit; font-weight: 600; } input.bare:focus { box-shadow: inset 0 -1px 0 var(--cc-light); outline: none; } input.bare.title { font-size: 1.1rem; font-weight: 800; }
.emb-desc { min-height: 56px; padding: 8px 0; white-space: pre-wrap; overflow-wrap: anywhere; } .emb-desc.placeholder { color: #7d828f; } .emb-hint { margin: 0 0 10px; font-size: .8rem; }
.emb-fields-head { display: flex; justify-content: space-between; align-items: center; margin: 10px 0; font-size: .85rem; color: var(--muted); }
.fld { display: grid; grid-template-columns: 1fr 1.5fr auto auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.drop { display: block; border: 1px dashed #3a3f48; border-radius: 10px; padding: 10px 14px; margin: 14px 0; } .drop span { color: var(--muted); font-size: .82rem; } .drop input { border: 0 !important; background: transparent !important; padding: 6px 0 !important; }
.emb-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.emb-side label { color: var(--muted); font-size: .85rem; }
.cc-cards2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 18px; }
.color-row { display: flex; gap: 10px; margin-top: 6px; } .color-row input[type=text], .color-row input:not([type=color]) { flex: 1; }
input[type=color] { width: 46px; height: 42px; padding: 3px; border-radius: 10px; background: var(--cc-field); border: 1px solid var(--cc-line); cursor: pointer; flex: none; }
.v2-meter { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: .85rem; margin-bottom: 14px; } .v2-meter .over { color: var(--warn); font-weight: 700; }
.v2-blocks { display: grid; gap: 12px; margin: 4px 0; } .v2-empty { padding: 18px; border: 1px dashed #3a3f48; border-radius: 10px; margin: 0; text-align: center; }
.blk { background: var(--cc-soft); border: 1px solid #31353c; border-radius: 12px; padding: 14px 16px; } .blk-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; } .blk-tools { display: flex; gap: 2px; }
.blk-field { display: block; margin: 8px 0; } .blk-field > span { display: block; color: var(--muted); font-size: .82rem; margin-bottom: 4px; } .blk textarea { width: 100%; font-family: inherit; }
.v2-add { position: relative; margin-top: 12px; display: inline-block; }
.v2-menu { position: absolute; z-index: 6; left: 0; top: calc(100% + 6px); min-width: 320px; background: #1f2226; border: 1px solid var(--cc-line); border-radius: 12px; padding: 6px; box-shadow: 0 14px 34px rgba(0, 0, 0, .5); }
.v2-menu button { display: block; width: 100%; text-align: left; background: none; border: 0; color: var(--text); padding: 10px 12px; border-radius: 8px; font: inherit; cursor: pointer; } .v2-menu button:hover { background: #2d313e; }

/* Preview */
.dc-embed { display: flex; gap: 14px; background: #2b2d31; border-left: 4px solid #5865f2; border-radius: 6px; padding: 12px 14px; max-width: 540px; }
.dc-embed-main { flex: 1; min-width: 0; } .e-author { font-size: .85rem; font-weight: 700; margin-bottom: 4px; } .e-title { font-weight: 800; margin-bottom: 6px; } .e-desc { font-size: .92rem; overflow-wrap: anywhere; }
.e-fields { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px 12px; margin-top: 8px; font-size: .9rem; } .e-field { grid-column: 1 / -1; } .e-field.inline { grid-column: auto; } .e-field b { display: block; font-size: .85rem; }
.e-footer { font-size: .74rem; color: #949ba4; margin-top: 10px; }
.ph-img { display: grid; place-items: center; background: #1e1f22; border: 1px dashed #3a3f48; border-radius: 8px; color: #7d828f; font-size: .8rem; } .ph-img.wide { height: 140px; margin-top: 10px; width: 100%; } .ph-img.thumb { width: 72px; height: 72px; flex: none; }
.v2-container { max-width: 560px; background: #2b2d31; border-left: 4px solid #5865f2; border-radius: 8px; padding: 14px 16px; display: grid; gap: 10px; }
.v2-section { display: flex; gap: 14px; align-items: flex-start; justify-content: space-between; } .v2-sep { padding: 4px 0; } .v2-sep.large { padding: 10px 0; } .v2-sep.line { border-top: 1px solid #3f4147; }
.v2-btnrow { display: flex; flex-wrap: wrap; gap: 8px; } .lbtn { display: inline-block; background: #4e5058; color: #fff; border-radius: 6px; padding: 6px 14px; font-size: .85rem; font-weight: 600; white-space: nowrap; }
.dc-text, .v2-text { overflow-wrap: anywhere; }
.men { background: rgba(88, 101, 242, .3); color: #c9cdfb; border-radius: 4px; padding: 0 3px; } .lnk { color: #00a8fc; } .dc code { background: #1e1f22; padding: 1px 5px; border-radius: 4px; }
.h1 { font-size: 1.5rem; font-weight: 800; } .h2 { font-size: 1.25rem; font-weight: 800; } .h3 { font-size: 1.05rem; font-weight: 800; }
.cc-dialog.light .dc { background: #fff; border-color: #e3e5e8; color: #313338; } .cc-dialog.light .dc-embed, .cc-dialog.light .v2-container { background: #f2f3f5; } .cc-dialog.light .ph-img { background: #e3e5e8; color: #5c5e66; }
.cc-dialog.light .emb-edit { background: #f2f3f5; } .cc-dialog.light .emb-edit input.bare, .cc-dialog.light .emb-edit .emb-desc { color: #313338; } .cc-dialog.light .e-footer { color: #5c5e66; } .cc-dialog.light .men { background: #e0e3ff; color: #4150c9; }

/* Variables */
.vargroup h3 { color: var(--muted); font-size: .76rem; letter-spacing: .08em; text-transform: uppercase; margin: 22px 0 8px; }
.vargroup ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 8px; }
.var { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; text-align: left; background: #202226; border: 1px solid var(--cc-line); border-radius: 10px; padding: 10px 12px; color: var(--text); font: inherit; cursor: pointer; } .var:hover { border-color: var(--accent); }
.var code { background: transparent; padding: 0; color: #9ecbff; } .var span { color: var(--muted); font-size: .82rem; } .var-note { min-height: 1.4em; }
@media (max-width: 760px) { .grid2, .grid3, .cc-cards2, .emb-edit, .fld { grid-template-columns: 1fr; } .cc-dialog { width: 100vw; height: 100vh; border-radius: 0; } .cc-dialog-body { padding: 18px; } }
.wl-row { display: flex; align-items: center; gap: 14px; margin: 8px 0; } .wl-now, .wl-preview { border-radius: 50%; object-fit: cover; } .wl-preview { margin: 10px 0; } .wl-status.ok { color: #46b17b; }
.plans th:nth-child(n+2), .plans td:nth-child(n+2) { text-align: center; white-space: nowrap; } .plans th:last-child, .plans td:last-child { background: rgba(155, 89, 182, .1); } .slot .chip.plus { background: rgba(241, 196, 15, .2); color: #f4d36a; }

/* ---- Command permissions ---- */
.perm-table td:first-child { width: 38%; } .perm-table td:last-child { min-width: 260px; }
.perm-group h2 { margin: 0 0 6px; font-size: 1.2rem; }

/* ---- Applications ---- */
.app-q { margin: 0 0 12px; } .app-q-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.app-q-tools { display: flex; gap: 6px; } .app-q-opts { display: flex; gap: 18px; align-items: end; flex-wrap: wrap; margin: 10px 0; }
.app-q-opts label { flex: 1 1 200px; } label.check { display: flex; align-items: center; gap: 8px; } label.check input { width: auto; margin: 0; }
.answer { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
.apply { text-align: center; } .app-crest { border-radius: 50%; margin-bottom: 8px; }
.apply-list { display: grid; gap: 14px; max-width: 640px; margin: 0 auto; } .apply-card { display: block; text-decoration: none; color: inherit; } .apply-card:hover { border-color: var(--accent); } .apply-card h2 { margin: 0 0 6px; font-size: 1.1rem; }
form.command-form.card, .apply ~ form.command-form { max-width: 640px; margin-left: auto; margin-right: auto; }

/* ---- Reaction roles ---- */
.rr-num { font-size: .95rem; } [data-format][hidden], [data-for][hidden] { display: none; }

/* ---- Support tab ------------------------------------------------------------------------ */
.nav-title { color: var(--muted); font-size: .78rem; letter-spacing: .08em; text-transform: uppercase; margin: 14px 12px 8px; }
.side nav hr { border: 0; border-top: 1px solid var(--line); margin: 12px 4px; }
.radio-row { border: 0; padding: 0; margin: 16px 0; }
.radio-row legend { color: var(--muted); font-size: .85rem; margin-bottom: 6px; }
.pick-list { max-height: 320px; overflow-y: auto; border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin: 10px 0; }
.pick-row { display: flex; padding: 4px 0; }
.pick-row[hidden], #pick-box[hidden] { display: none; }
.preview-embed { border-left: 4px solid #5865f2; }
.pre { white-space: pre-wrap; word-break: break-word; }
/* The person's Discord picture in the top bar */
img.avatar { object-fit: cover; display: block; }

/* ---- Raid protection and Tickets ---- */
[data-show-when][hidden] { display: none !important; }
.raid-status.live { border-color: #e74c3c; background: rgba(231, 76, 60, .08); }
.raid-status h2 { margin-top: 0; }
.ticket-q { border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 10px 0; }
.ticket-msg { padding: 8px 0; border-bottom: 1px solid var(--line); } .ticket-msg:last-child { border-bottom: 0; }
.ticket-msg .when { color: var(--muted); font-size: .8em; margin-left: 8px; }
.status-pill { display: inline-block; padding: 2px 10px; border-radius: 99px; font-size: .8em; font-weight: 600; background: var(--card3); }
.status-pill.open { background: rgba(46, 204, 113, .18); color: #4be08a; }
