/* =========================================================
   SMM LockedIn — dark professional theme
   Brand: cyan #22d3ee → blue #2563eb → violet #7c3aed
   ========================================================= */
:root {
  --bg: #050507;
  --bg-2: #09090c;
  --surface: #0e0e12;
  --surface-2: #14141a;
  --surface-3: #1b1b23;
  --border: rgba(var(--ink), 0.08);
  --border-strong: rgba(var(--ink), 0.14);
  --text: #f5f5f7;
  --muted: #a1a1aa;
  --dim: #71717a;
  --cyan: #22d3ee;
  --blue: #2563eb;
  --blue-2: #3b82f6;
  --violet: #7c3aed;
  --brand: linear-gradient(135deg, #22d3ee 0%, #2563eb 48%, #7c3aed 100%);
  --brand-soft: linear-gradient(135deg, rgba(34, 211, 238, .14), rgba(37, 99, 235, .14) 50%, rgba(124, 58, 237, .14));
  --ok: #22c55e;
  --warn: #f59e0b;
  --bad: #ef4444;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 0 rgba(255, 255, 255, .04) inset, 0 20px 50px -20px rgba(0, 0, 0, .8);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Plus Jakarta Sans", "Inter", system-ui, sans-serif;
  --ink: 255, 255, 255;
  --strong: #ffffff;
  --label: #d4d4d8;
  --code-bg: #000000;
  --code-text: #e4e4e7;
  --input-focus: #000000;
  --glass-bg: rgba(5, 5, 7, .78);
  --quote-bg: rgba(0, 0, 0, .35);
  color-scheme: dark;
}

/* ---------- Light theme ---------- */
:root[data-theme="light"] {
  --bg: #f5f6fa;
  --bg-2: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f4f8;
  --surface-3: #e8eaf0;
  --border: rgba(15, 23, 42, .09);
  --border-strong: rgba(15, 23, 42, .16);
  --text: #0b0d14;
  --muted: #4b5262;
  --dim: #6b7280;
  --ink: 15, 23, 42;
  --strong: #000000;
  --label: #374151;
  --code-bg: #f3f4f6;
  --code-text: #111827;
  --input-focus: #ffffff;
  --glass-bg: rgba(255, 255, 255, .82);
  --quote-bg: rgba(255, 255, 255, .75);
  --shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 12px 32px -18px rgba(15, 23, 42, .18);
  --brand-soft: linear-gradient(135deg, rgba(34, 211, 238, .12), rgba(37, 99, 235, .1) 50%, rgba(124, 58, 237, .1));
  color-scheme: light;
}
:root[data-theme="light"] .badge.ok { color: #15803d; }
:root[data-theme="light"] .badge.warn { color: #b45309; }
:root[data-theme="light"] .badge.bad { color: #b91c1c; }
:root[data-theme="light"] .btn-light { background: #0b0d14; color: #fff; border-color: #0b0d14; }
:root[data-theme="light"] .btn-light:hover { background: #262a36; color: #fff; border-color: #262a36; }
:root[data-theme="light"] .stat:nth-child(4n+4) .ico { color: #16a34a; }
:root[data-theme="light"] .stat:nth-child(4n+3) .ico { color: #7c3aed; }
:root[data-theme="light"] .stat:nth-child(4n+2) .ico { color: #0891b2; }
:root[data-theme="light"] .feature .ico, :root[data-theme="light"] .quick a .icon, :root[data-theme="light"] .nav a.active .icon, :root[data-theme="light"] .api-band li .icon { color: #2563eb; }
:root[data-theme="light"] .alert-success .icon { color: #16a34a; }
:root[data-theme="light"] .error { color: #dc2626; }
:root[data-theme="light"] .btn-danger { color: #b91c1c; }
:root[data-theme="light"] .preview-bar i { background: #d4d4d8; }
:root[data-theme="light"] .hero::after { opacity: .5; }
:root[data-theme="light"] .scrim { background: rgba(15, 23, 42, .4); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv11", "ss01";
}
::selection { background: rgba(37, 99, 235, .45); color: #fff; }
a { color: var(--blue-2); text-decoration: none; }
a:hover { color: var(--cyan); }
h1, h2, h3, h4 { font-family: var(--display); line-height: 1.2; margin: 0 0 .5rem; letter-spacing: -.02em; font-weight: 700; }
h1 { font-size: 1.55rem; }
h2 { font-size: 1.08rem; }
h3 { font-size: .98rem; }
p { margin: 0 0 .75rem; }
small, .muted { color: var(--muted); }
ul { padding-left: 1.1rem; }
code, pre, .mono { font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .84em; }
pre { background: var(--code-bg); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; overflow-x: auto; white-space: pre; margin: 0; }
code { background: rgba(var(--ink), .06); padding: 2px 6px; border-radius: 6px; color: var(--code-text); }
pre code { background: none; padding: 0; }
hr { border: 0; border-top: 1px solid var(--border); margin: 1.1rem 0; }
img { max-width: 100%; height: auto; }

.icon { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.icon-lg { width: 24px; height: 24px; }
.grad { background: var(--brand); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Surfaces ---------- */
.card, .glass {
  background: linear-gradient(180deg, rgba(var(--ink), .025), rgba(var(--ink), 0) 40%), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.card { padding: 20px; margin-bottom: 18px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.card-head a { font-size: .85rem; font-weight: 500; }

/* ---------- Brand ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-family: var(--display); font-weight: 800; font-size: 1.12rem; letter-spacing: -.02em; }
.brand:hover { color: var(--text); }
.brand img { width: 34px; height: 34px; display: block; filter: drop-shadow(0 4px 14px rgba(37, 99, 235, .45)); }
.brand .wm-a { color: var(--strong); }
.brand .wm-b { background: var(--brand); -webkit-background-clip: text; background-clip: text; color: transparent; }
.brand span { white-space: nowrap; }

/* ---------- App layout ---------- */
.app { display: flex; min-height: 100vh; background: var(--bg); }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: 264px; z-index: 40;
  display: flex; flex-direction: column;
  padding: 18px 14px 16px; overflow-y: auto;
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  transform: translateX(-100%); transition: transform .25s ease;
}
.sidebar.open { transform: none; box-shadow: 30px 0 60px rgba(0, 0, 0, .6); }
.sidebar > .brand { padding: 4px 8px 18px; }
.side-balance {
  margin: 0 4px 14px; padding: 14px; border-radius: 12px;
  background: var(--brand-soft); border: 1px solid rgba(59, 130, 246, .25);
}
.side-balance .lbl { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.side-balance .val { font-family: var(--display); font-size: 1.35rem; font-weight: 800; margin: 2px 0 10px; }
.nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.nav-label { font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--dim); margin: 18px 12px 6px; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 9px 12px; border-radius: 9px; color: var(--muted); font-weight: 500; font-size: .9rem; position: relative; }
.nav a:hover { background: rgba(var(--ink), .04); color: var(--text); }
.nav a.active { background: rgba(var(--ink), .06); color: var(--strong); }
.nav a.active::before { content: ""; position: absolute; left: -14px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: var(--brand); }
.nav a.active .icon { color: var(--cyan); }
.nav .badge { margin-left: auto; }
.side-foot { border-top: 1px solid var(--border); padding-top: 14px; margin-top: 14px; }
.user-chip { display: flex; align-items: center; gap: 10px; padding: 6px 8px; margin-bottom: 10px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .85rem; color: #fff; background: var(--brand); flex-shrink: 0; }
.user-chip .who { min-width: 0; }
.user-chip .who strong { display: block; font-size: .88rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-chip .who small { display: block; font-size: .75rem; color: var(--dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.scrim { position: fixed; inset: 0; background: rgba(0, 0, 0, .65); z-index: 30; display: none; }
.scrim.show { display: block; }

.main { flex: 1; min-width: 0; }
.topbar {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 12px;
  height: 60px; padding: 0 18px;
  background: var(--glass-bg); border-bottom: 1px solid var(--border);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
}
.topbar .crumb { font-weight: 600; font-size: .95rem; }
.topbar .spacer { flex: 1; }
.balance-pill { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-weight: 700; color: var(--text); font-size: .88rem; }
.balance-pill:hover { color: var(--strong); border-color: var(--border-strong); }
.balance-pill .icon { color: var(--cyan); }
.content { padding: 20px 16px 40px; max-width: 1240px; margin: 0 auto; }
.page-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 4px 0 18px; flex-wrap: wrap; }
.page-title h1 { margin: 0; }
.page-title p { margin: 4px 0 0; color: var(--muted); }

@media (min-width: 992px) {
  .sidebar { transform: none; }
  .main { margin-left: 264px; }
  .menu-btn { display: none !important; }
  .content { padding: 28px 32px 48px; }
  .topbar { padding: 0 32px; }
}

/* ---------- Grid ---------- */
.grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 992px) { .grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } .grid-main { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); } }

/* ---------- Stats ---------- */
.stat { padding: 18px; display: flex; gap: 14px; align-items: center; position: relative; overflow: hidden; }
.stat .ico { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; background: rgba(37, 99, 235, .12); color: var(--blue-2); border: 1px solid rgba(59, 130, 246, .22); flex-shrink: 0; }
.stat:nth-child(4n+2) .ico { background: rgba(34, 211, 238, .1); color: var(--cyan); border-color: rgba(34, 211, 238, .22); }
.stat:nth-child(4n+3) .ico { background: rgba(124, 58, 237, .14); color: #a78bfa; border-color: rgba(124, 58, 237, .28); }
.stat:nth-child(4n+4) .ico { background: rgba(34, 197, 94, .1); color: #4ade80; border-color: rgba(34, 197, 94, .22); }
.stat .val { font-family: var(--display); font-size: 1.35rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.stat .lbl { color: var(--muted); font-size: .8rem; }

/* Welcome banner */
.hello {
  position: relative; overflow: hidden; padding: 24px; margin-bottom: 18px; border-radius: var(--radius);
  border: 1px solid rgba(59, 130, 246, .25);
  background: radial-gradient(600px 220px at 100% 0%, rgba(124, 58, 237, .35), transparent 70%), radial-gradient(500px 200px at 0% 100%, rgba(34, 211, 238, .18), transparent 70%), var(--surface);
}
.hello h1 { font-size: 1.45rem; margin-bottom: 4px; }
.hello p { color: var(--muted); margin: 0; }
.hello .actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.hello img.mark { position: absolute; right: -30px; bottom: -40px; width: 200px; opacity: .14; pointer-events: none; }
@media (min-width: 768px) { .hello { padding: 30px 32px; } .hello h1 { font-size: 1.7rem; } .hello img.mark { right: 24px; bottom: -30px; width: 210px; opacity: .22; } }

/* Bar chart */
.bars { display: flex; align-items: flex-end; gap: 8px; height: 150px; padding-top: 8px; }
.bars .bar { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; justify-content: flex-end; min-width: 0; }
.bars .fill { width: 100%; max-width: 38px; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, var(--cyan), var(--blue) 60%, var(--violet)); min-height: 3px; opacity: .9; }
.bars .bar:hover .fill { opacity: 1; box-shadow: 0 0 20px rgba(37, 99, 235, .5); }
.bars .bl { font-size: .7rem; color: var(--dim); white-space: nowrap; }
.bars .bv { font-size: .7rem; color: var(--muted); white-space: nowrap; }
.legend-row { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.big-num { font-family: var(--display); font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong);
  background: var(--surface-2); color: var(--text); font: inherit; font-weight: 600; font-size: .88rem;
  cursor: pointer; transition: background .15s ease, border-color .15s ease, transform .1s ease, box-shadow .15s ease; text-decoration: none; white-space: nowrap;
}
.btn:hover { background: var(--surface-3); color: var(--strong); border-color: rgba(var(--ink), .22); }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--blue-2); outline-offset: 2px; }
.btn-primary { background: var(--brand); border: 0; color: #fff; box-shadow: 0 8px 24px -8px rgba(37, 99, 235, .7), inset 0 1px 0 rgba(255, 255, 255, .2); }
.btn-primary:hover { background: var(--brand); filter: brightness(1.12); color: #fff; }
.btn-light { background: #fff; color: #09090b; border-color: #fff; }
.btn-light:hover { background: #e4e4e7; color: #09090b; border-color: #e4e4e7; }
.btn-danger { background: rgba(239, 68, 68, .1); border-color: rgba(239, 68, 68, .35); color: #fca5a5; }
.btn-danger:hover { background: rgba(239, 68, 68, .18); color: #fecaca; border-color: rgba(239, 68, 68, .5); }
.btn-sm { height: 32px; padding: 0 11px; font-size: .8rem; border-radius: 8px; }
.btn-lg { height: 48px; padding: 0 22px; font-size: .95rem; border-radius: 12px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.icon-btn { background: none; border: 1px solid transparent; color: var(--text); padding: 7px; cursor: pointer; border-radius: 9px; display: inline-flex; }
.icon-btn:hover { background: var(--surface-2); border-color: var(--border); }
.inline { display: inline; }

/* ---------- Forms ---------- */
.field { margin-bottom: 15px; }
label { display: block; font-weight: 500; font-size: .84rem; margin-bottom: 6px; color: var(--label); }
.input, select, textarea, input[type=text], input[type=email], input[type=password], input[type=number], input[type=url], input[type=search] {
  width: 100%; height: 42px; padding: 0 13px; border-radius: var(--radius-sm); border: 1px solid var(--border-strong);
  background: var(--bg-2); color: var(--text); font: inherit; font-size: .9rem; outline: none;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
textarea { height: auto; min-height: 110px; padding: 11px 13px; resize: vertical; line-height: 1.5; }
select { appearance: none; -webkit-appearance: none; padding-right: 36px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23a1a1aa' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 13px center; }
select option { background: var(--surface); color: var(--text); }
input::placeholder, textarea::placeholder { color: var(--dim); }
.input:hover, select:hover, textarea:hover, input:hover { border-color: rgba(var(--ink), .22); }
.input:focus, select:focus, textarea:focus, input:focus { border-color: var(--blue-2); box-shadow: 0 0 0 3px rgba(59, 130, 246, .22); background: var(--input-focus); }
input:disabled { opacity: .6; }
.check { display: flex; align-items: center; gap: 9px; font-weight: 500; color: var(--muted); margin: 0; }
.check input { width: 17px; height: 17px; accent-color: var(--blue); flex-shrink: 0; }
.hint { font-size: .78rem; color: var(--dim); margin-top: 5px; }
.error { color: #f87171; font-size: .8rem; margin-top: 4px; }
.row { display: flex; gap: 12px; flex-wrap: wrap; align-items: flex-end; }
.row > * { flex: 1 1 160px; }
.row > .shrink { flex: 0 0 auto; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Alerts ---------- */
.alert { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 16px; border: 1px solid var(--border); background: var(--surface); font-size: .88rem; }
.alert .icon { margin-top: 2px; }
.alert-success { border-color: rgba(34, 197, 94, .35); background: rgba(34, 197, 94, .07); }
.alert-success .icon { color: var(--ok); }
.alert-error { border-color: rgba(239, 68, 68, .35); background: rgba(239, 68, 68, .07); }
.alert-error .icon { color: var(--bad); }
.alert-info { border-color: rgba(59, 130, 246, .35); background: rgba(59, 130, 246, .07); }
.alert-info .icon { color: var(--blue-2); }
.alert ul { margin: 0; padding-left: 16px; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -20px; padding: 0 20px; }
table { width: 100%; border-collapse: collapse; font-size: .86rem; }
th, td { text-align: left; padding: 11px 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
th { color: var(--dim); font-weight: 600; font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; white-space: nowrap; }
tbody tr { transition: background .12s ease; }
tbody tr:hover { background: rgba(var(--ink), .02); }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.link-cell { max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nowrap { white-space: nowrap; }
@media (min-width: 641px) { td[data-label="Service"] { min-width: 220px; } }

@media (max-width: 640px) {
  table.stack thead { display: none; }
  table.stack tr { display: block; padding: 12px 0; border-bottom: 1px solid var(--border); }
  table.stack tr:last-child { border-bottom: 0; }
  table.stack td { display: flex; justify-content: space-between; align-items: center; gap: 14px; border: 0; padding: 4px 0; text-align: right; }
  table.stack td::before { content: attr(data-label); color: var(--dim); font-size: .76rem; text-align: left; flex-shrink: 0; }
  table.stack td:not([data-label])::before { content: none; }
  table.stack td.link-cell { max-width: none; }
}

/* ---------- Badges ---------- */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 9px; border-radius: 999px; font-size: .72rem; font-weight: 600; border: 1px solid var(--border); background: rgba(var(--ink), .04); white-space: nowrap; color: var(--muted); }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.ok { color: #4ade80; border-color: rgba(34, 197, 94, .3); background: rgba(34, 197, 94, .08); }
.badge.warn { color: #fbbf24; border-color: rgba(245, 158, 11, .3); background: rgba(245, 158, 11, .08); }
.badge.bad { color: #f87171; border-color: rgba(239, 68, 68, .3); background: rgba(239, 68, 68, .08); }
.badge.muted { color: var(--muted); }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; overflow-x: auto; padding: 4px; margin-bottom: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { padding: 7px 13px; border-radius: 8px; color: var(--muted); white-space: nowrap; font-size: .83rem; font-weight: 500; }
.tabs a:hover { color: var(--text); background: rgba(var(--ink), .04); }
.tabs a.active { color: var(--strong); background: var(--surface-3); box-shadow: inset 0 0 0 1px var(--border-strong); }

/* ---------- Pagination ---------- */
.pagination { display: flex; gap: 6px; justify-content: center; align-items: center; margin-top: 18px; flex-wrap: wrap; font-size: .85rem; }
.pagination a, .pagination span { padding: 6px 12px; border-radius: 8px; border: 1px solid var(--border); color: var(--text); }
.pagination a:hover { border-color: var(--border-strong); background: var(--surface-2); }
.pagination .current { border-color: transparent; color: var(--muted); }
.pagination .disabled { opacity: .35; }

/* ---------- Order form ---------- */
.svc-info { padding: 14px; border-radius: var(--radius-sm); background: var(--bg-2); border: 1px solid var(--border); font-size: .86rem; }
.svc-info:empty::before { content: "Select a service to see its details."; color: var(--dim); }
.svc-info dl { display: grid; grid-template-columns: auto 1fr; gap: 7px 14px; margin: 0; }
.svc-info dt { color: var(--dim); }
.svc-info dd { margin: 0; font-weight: 500; }
.svc-info .hint { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); white-space: pre-line; }
.charge-box { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--brand-soft); border: 1px solid rgba(59, 130, 246, .3); margin-bottom: 14px; }
.charge-box span { color: var(--muted); font-weight: 500; }
.charge-box strong { font-family: var(--display); font-size: 1.3rem; }
.hidden { display: none !important; }

/* ---------- Tickets ---------- */
.thread { display: flex; flex-direction: column; gap: 12px; }
.msg { max-width: 85%; padding: 12px 15px; border-radius: 14px 14px 14px 4px; background: var(--surface-2); border: 1px solid var(--border); white-space: pre-wrap; word-wrap: break-word; font-size: .9rem; }
.msg.me { align-self: flex-end; border-radius: 14px 14px 4px 14px; background: linear-gradient(135deg, rgba(37, 99, 235, .25), rgba(124, 58, 237, .2)); border-color: rgba(59, 130, 246, .3); }
.msg .meta { display: block; font-size: .72rem; color: var(--dim); margin-top: 6px; }

/* ---------- Misc ---------- */
.keybox { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: .85rem; word-break: break-all; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--code-bg); border: 1px dashed rgba(34, 211, 238, .5); }
.copy-row { display: flex; gap: 8px; align-items: center; }
.copy-row .keybox { flex: 1; }
.cat-row { margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--border); }
.logout-form { margin: 0; }
.mt { margin-top: 16px; } .mb0 { margin-bottom: 0; } .right { text-align: right; } .center { text-align: center; }
.gap { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.gap input[type=search] { flex: 1; min-width: 0; }
.page-title form.gap { flex-wrap: nowrap; }
.notice { margin-bottom: 16px; }
.quick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.quick a { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 12px; border: 1px solid var(--border); background: var(--bg-2); color: var(--text); font-weight: 600; font-size: .86rem; transition: border-color .15s ease, background .15s ease; }
.quick a:hover { border-color: rgba(59, 130, 246, .45); background: rgba(37, 99, 235, .06); color: var(--strong); }
.quick a .icon { color: var(--cyan); }
.quick a small { font-weight: 400; color: var(--dim); font-size: .76rem; margin-top: -6px; }
.list-plain { list-style: none; padding: 0; margin: 0; }
.list-plain li { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--border); font-size: .86rem; }
.list-plain li:last-child { border-bottom: 0; }

/* =========================================================
   Public site
   ========================================================= */
.site { background: var(--bg); overflow-x: hidden; }
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--glass-bg); border-bottom: 1px solid transparent;
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
}
.site-header.scrolled { border-bottom-color: var(--border); }
.site-header .inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 68px; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.site-header nav { display: flex; gap: 6px; align-items: center; }
.site-header nav a.plain { color: var(--muted); padding: 8px 12px; font-weight: 500; font-size: .9rem; border-radius: 8px; }
.site-header nav a.plain:hover { color: var(--strong); }
@media (max-width: 760px) { .site-header nav a.plain { display: none; } }

.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.section { max-width: 1200px; margin: 0 auto; padding: 64px 20px; }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 40px; }
.section-head h2 { font-size: 1.9rem; margin-bottom: 10px; }
.section-head p { color: var(--muted); font-size: 1rem; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 6px; border-radius: 999px; border: 1px solid var(--border-strong); background: rgba(var(--ink), .03); color: var(--muted); font-size: .8rem; font-weight: 500; margin-bottom: 18px; }
.eyebrow b { padding: 2px 8px; border-radius: 999px; background: var(--brand); color: #fff; font-size: .7rem; font-weight: 700; }
@media (min-width: 768px) { .section { padding: 96px 20px; } .section-head h2 { font-size: 2.4rem; } }

.hero { position: relative; padding: 56px 20px 40px; text-align: center; isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: -120px 0 auto; height: 720px; z-index: -1;
  background:
    radial-gradient(520px 320px at 50% 0%, rgba(37, 99, 235, .35), transparent 70%),
    radial-gradient(420px 280px at 22% 20%, rgba(34, 211, 238, .16), transparent 70%),
    radial-gradient(420px 280px at 78% 20%, rgba(124, 58, 237, .22), transparent 70%);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .35;
  background-image: linear-gradient(rgba(var(--ink), .05) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--ink), .05) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 70%); mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 70%);
}
.hero h1 { font-size: 2.35rem; font-weight: 800; letter-spacing: -.035em; line-height: 1.08; max-width: 900px; margin: 0 auto 18px; }
.hero p.lead { color: var(--muted); font-size: 1.05rem; max-width: 640px; margin: 0 auto; }
.hero .cta { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 28px; }
.hero .trust { display: flex; gap: 8px 22px; justify-content: center; flex-wrap: wrap; margin-top: 22px; color: var(--dim); font-size: .84rem; }
.hero .trust span { display: inline-flex; align-items: center; gap: 6px; }
.hero .trust .icon { width: 15px; height: 15px; color: var(--ok); }
@media (min-width: 768px) { .hero { padding: 96px 20px 56px; } .hero h1 { font-size: 4rem; } .hero p.lead { font-size: 1.15rem; } }

/* Hero preview card */
.preview { max-width: 980px; margin: 52px auto 0; padding: 10px; border-radius: 20px; background: linear-gradient(180deg, rgba(var(--ink), .08), rgba(var(--ink), .02)); border: 1px solid var(--border-strong); box-shadow: 0 40px 120px -30px rgba(37, 99, 235, .45); text-align: left; }
.preview-inner { border-radius: 14px; background: var(--bg-2); border: 1px solid var(--border); overflow: hidden; }
.preview-bar { display: flex; align-items: center; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.preview-bar i { width: 10px; height: 10px; border-radius: 50%; background: #27272a; }
.preview-bar span { margin-left: 10px; font-size: .75rem; color: var(--dim); }
.preview-body { display: grid; gap: 14px; padding: 16px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) { .preview-body { grid-template-columns: 1.3fr 1fr; padding: 22px; } }
.mini-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.mini-stats div { padding: 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); }
.mini-stats b { display: block; font-family: var(--display); font-size: 1.05rem; }
.mini-stats small { font-size: .7rem; color: var(--dim); }
.mini-order { padding: 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.mini-order .f { height: 34px; border-radius: 8px; border: 1px solid var(--border); background: var(--bg-2); margin-bottom: 8px; display: flex; align-items: center; padding: 0 10px; font-size: .76rem; color: var(--muted); }
.mini-order .go { height: 36px; border-radius: 8px; background: var(--brand); display: grid; place-items: center; font-size: .8rem; font-weight: 700; }
.mini-feed { display: flex; flex-direction: column; gap: 8px; }
.mini-feed div { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-radius: 10px; background: var(--surface); border: 1px solid var(--border); font-size: .78rem; }
.mini-feed div span:first-child { color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Logos strip */
.platforms { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.platform { display: inline-flex; align-items: center; gap: 9px; padding: 10px 16px; border-radius: 12px; border: 1px solid var(--border); background: var(--surface); color: var(--label); font-weight: 600; font-size: .88rem; }
.platform svg { width: 18px; height: 18px; fill: currentColor; }

/* Number band */
.numbers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.numbers div { background: var(--bg-2); padding: 24px 18px; text-align: center; }
.numbers b { display: block; font-family: var(--display); font-size: 1.8rem; font-weight: 800; letter-spacing: -.03em; }
.numbers span { color: var(--muted); font-size: .85rem; }
@media (min-width: 768px) { .numbers { grid-template-columns: repeat(4, minmax(0, 1fr)); } .numbers b { font-size: 2.3rem; } }

.feature { padding: 24px; transition: border-color .2s ease, transform .2s ease; }
.feature:hover { border-color: rgba(59, 130, 246, .35); transform: translateY(-2px); }
.feature .ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 16px; background: var(--brand-soft); border: 1px solid rgba(59, 130, 246, .3); color: var(--cyan); }
.feature h3 { font-size: 1.05rem; margin-bottom: 6px; }
.feature p { color: var(--muted); margin: 0; font-size: .9rem; }

.steps { counter-reset: step; }
.step { padding: 24px; position: relative; }
.step::before { counter-increment: step; content: "0" counter(step); font-family: var(--display); font-weight: 800; font-size: .85rem; color: transparent; background: var(--brand); -webkit-background-clip: text; background-clip: text; display: block; margin-bottom: 12px; letter-spacing: .05em; }
.step h3 { margin-bottom: 6px; }
.step p { color: var(--muted); margin: 0; font-size: .9rem; }

.api-band { display: grid; gap: 28px; align-items: center; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 900px) { .api-band { grid-template-columns: 1fr 1.1fr; gap: 56px; } }
.api-band h2 { font-size: 1.9rem; }
.api-band ul { list-style: none; padding: 0; margin: 18px 0 24px; }
.api-band li { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; color: var(--label); }
.api-band li .icon { color: var(--cyan); margin-top: 3px; }
.code-card { border-radius: var(--radius); border: 1px solid var(--border-strong); background: #000; overflow: hidden; box-shadow: 0 30px 80px -30px rgba(124, 58, 237, .45); }
.code-card .bar { display: flex; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.code-card .bar i { width: 10px; height: 10px; border-radius: 50%; background: #27272a; }
.code-card pre { background: #000; color: #e4e4e7; border: 0; border-radius: 0; padding: 18px; line-height: 1.7; }
.tok-k { color: #a78bfa; } .tok-s { color: #67e8f9; } .tok-c { color: #52525b; } .tok-n { color: #fbbf24; }

.faq details { border-bottom: 1px solid var(--border); padding: 18px 4px; }
.faq summary { cursor: pointer; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--muted); font-size: 1.2rem; line-height: 1; }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--muted); margin: 10px 0 0; }

.cta-band { position: relative; overflow: hidden; text-align: center; padding: 56px 24px; border-radius: 22px; border: 1px solid rgba(59, 130, 246, .3);
  background: radial-gradient(500px 240px at 50% 0%, rgba(37, 99, 235, .4), transparent 70%), radial-gradient(400px 200px at 100% 100%, rgba(124, 58, 237, .3), transparent 70%), var(--surface); }
.cta-band h2 { font-size: 1.9rem; }
.cta-band p { color: var(--muted); max-width: 520px; margin: 0 auto 24px; }
@media (min-width: 768px) { .cta-band { padding: 72px 24px; } .cta-band h2 { font-size: 2.5rem; } }

.chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chip { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); font-size: .82rem; color: var(--muted); }

.site-footer { border-top: 1px solid var(--border); margin-top: 40px; padding: 44px 20px 30px; color: var(--muted); font-size: .86rem; }
.site-footer .cols { max-width: 1200px; margin: 0 auto; display: grid; gap: 28px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 768px) { .site-footer .cols { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.site-footer h4 { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--dim); margin-bottom: 12px; font-family: var(--font); }
.site-footer a { display: block; color: var(--muted); padding: 3px 0; }
.site-footer a:hover { color: var(--strong); }
.site-footer .legal { max-width: 1200px; margin: 30px auto 0; padding-top: 20px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; color: var(--dim); font-size: .8rem; }

/* =========================================================
   Auth (split screen)
   ========================================================= */
.auth { display: grid; min-height: 100vh; grid-template-columns: minmax(0, 1fr); background: var(--bg); }
@media (min-width: 992px) { .auth { grid-template-columns: 1fr 1fr; } }
.auth-side { display: none; position: relative; overflow: hidden; padding: 40px; border-right: 1px solid var(--border);
  background: radial-gradient(600px 400px at 0% 0%, rgba(34, 211, 238, .18), transparent 60%), radial-gradient(600px 400px at 100% 100%, rgba(124, 58, 237, .28), transparent 60%), radial-gradient(500px 360px at 50% 50%, rgba(37, 99, 235, .18), transparent 70%), var(--bg-2); }
@media (min-width: 992px) { .auth-side { display: flex; flex-direction: column; justify-content: space-between; } }
.auth-side .big-mark { width: 240px; margin: 40px 0 28px; filter: drop-shadow(0 20px 60px rgba(37, 99, 235, .55)); }
.auth-side h2 { font-size: 2.1rem; letter-spacing: -.03em; max-width: 440px; }
.auth-side p { color: var(--muted); max-width: 420px; }
.auth-side .quote { padding: 18px; border-radius: 14px; border: 1px solid var(--border); background: var(--quote-bg); max-width: 440px; font-size: .9rem; color: var(--label); }
.auth-side .quote small { display: block; margin-top: 8px; }
.auth-main { display: flex; flex-direction: column; padding: 22px 20px; }
.auth-main .top { display: flex; justify-content: space-between; align-items: center; }
.auth-main .top .muted a { font-weight: 600; }
.auth-wrap { flex: 1; display: grid; place-items: center; padding: 30px 0; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card h1 { font-size: 1.75rem; margin-bottom: 6px; }
.auth-card .sub { color: var(--muted); margin-bottom: 26px; }
.auth-card .btn-block { height: 46px; }
.auth-foot { color: var(--dim); font-size: .78rem; text-align: center; }
.divider { display: flex; align-items: center; gap: 12px; color: var(--dim); font-size: .78rem; margin: 18px 0; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 44px; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); background: none; border: 0; color: var(--dim); cursor: pointer; padding: 6px; border-radius: 6px; display: inline-flex; }
.pw-toggle:hover { color: var(--text); }

/* Error pages */
.err { min-height: 100vh; display: grid; place-items: center; text-align: center; padding: 20px; }
.err h1 { font-size: 4rem; margin: 0; }
.err p { color: var(--muted); margin-bottom: 22px; }
.narrow { max-width: 760px; }
@media (min-width: 992px) { .auth-mobile-brand { visibility: hidden; } }
.auth-side .quote .icon { color: var(--cyan); margin-bottom: 8px; display: block; }
@media (max-width: 639px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .grid-4 .stat { flex-direction: column; align-items: flex-start; gap: 10px; padding: 14px; }
  .grid-4 .stat .val { font-size: 1.1rem; word-break: break-word; }
  .grid-4 .stat .ico { width: 36px; height: 36px; }
}


/* ---------- Theme toggle ---------- */
.theme-toggle { width: 36px; height: 36px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface-2); color: var(--text); cursor: pointer; padding: 0; }
.theme-toggle:hover { background: var(--surface-3); }
.theme-toggle .i-sun { display: none; }
:root[data-theme="light"] .theme-toggle .i-sun { display: block; }
:root[data-theme="light"] .theme-toggle .i-moon { display: none; }

/* ---------- WhatsApp channel popup ---------- */
.wa-dialog { width: min(420px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--border-strong); border-radius: 20px; background: var(--surface); color: var(--text); box-shadow: 0 30px 80px -20px rgba(0, 0, 0, .6); overflow: hidden; }
.wa-dialog::backdrop { background: rgba(0, 0, 0, .6); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.wa-dialog[open] { animation: wa-in .28s ease-out; }
@keyframes wa-in { from { opacity: 0; transform: translateY(14px) scale(.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .wa-dialog[open] { animation: none; } }
.wa-top { position: relative; padding: 28px 24px 22px; text-align: center; background: radial-gradient(320px 160px at 50% 0%, rgba(37, 211, 102, .28), transparent 70%), var(--surface); }
.wa-badge { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 18px; display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 14px 34px -10px rgba(37, 211, 102, .7); }
.wa-badge .icon { width: 30px; height: 30px; }
.wa-top h2 { font-size: 1.3rem; margin-bottom: 6px; }
.wa-top p { color: var(--muted); margin: 0; font-size: .92rem; }
.wa-perks { list-style: none; margin: 0; padding: 0 24px 6px; }
.wa-perks li { display: flex; gap: 10px; align-items: center; padding: 7px 0; font-size: .9rem; color: var(--label); }
.wa-perks .icon { color: #25d366; }
.wa-actions { display: grid; gap: 8px; padding: 16px 24px 24px; }
.btn-wa { background: #25d366; border: 0; color: #fff; height: 46px; font-size: .95rem; box-shadow: 0 10px 26px -10px rgba(37, 211, 102, .8); }
.btn-wa:hover { background: #20bd5a; color: #fff; }
.wa-close { position: absolute; top: 12px; right: 12px; }
.wa-fab { position: fixed; right: 18px; bottom: 18px; z-index: 60; display: inline-flex; align-items: center; gap: 8px; height: 48px; padding: 0 18px 0 14px; border-radius: 999px; background: #25d366; color: #fff; font-weight: 700; font-size: .88rem; border: 0; cursor: pointer; box-shadow: 0 12px 30px -8px rgba(37, 211, 102, .7); }
.wa-fab:hover { background: #20bd5a; color: #fff; }
.wa-fab .icon { width: 20px; height: 20px; }
@media (max-width: 480px) { .wa-fab span { display: none; } .wa-fab { padding: 0; width: 52px; height: 52px; justify-content: center; } }

/* Settings favicon preview */
.fav-preview { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.fav-preview img { width: 40px; height: 40px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface-2); padding: 4px; object-fit: contain; }

/* ---------- Web app install ---------- */
.install-slot { margin-bottom: 8px; }
.install-slot:has(> [data-install][hidden]) { display: none; }
[hidden] { display: none !important; }
.app-band { display: grid; gap: 24px; align-items: center; padding: 28px; grid-template-columns: minmax(0, 1fr); background: radial-gradient(420px 220px at 100% 50%, rgba(37, 99, 235, .25), transparent 70%), var(--surface); }
.app-band h2 { font-size: 1.7rem; }
.app-visual { display: none; justify-content: center; }
.app-visual img { width: 180px; height: 180px; border-radius: 40px; box-shadow: 0 30px 70px -20px rgba(37, 99, 235, .6); }
@media (min-width: 768px) { .app-band { grid-template-columns: 1.6fr 1fr; padding: 40px 48px; } .app-visual { display: flex; } .app-band h2 { font-size: 2.1rem; } }
.ios-icon { width: 64px; height: 64px; border-radius: 16px; margin: 0 auto 14px; display: block; }
.ios-steps { list-style: decimal; padding-left: 44px; }
.ios-steps li { display: list-item; }
@media (max-width: 760px) { .hide-sm { display: none; } }
.show-sm { display: none; }
@media (max-width: 520px) { .hide-xs { display: none; } .show-sm { display: block; } }
.login-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.login-row a { font-size: .85rem; font-weight: 600; }
