/* WatsapBro — satu stylesheet, tanpa build step
   Arah: minimal terang. Putih + kanvas abu kehijauan, garis tipis, tanpa bayangan di dashboard.
   Font: Geist (UI), Bricolage Grotesque (judul situs publik), Geist Mono (kode). */
:root {
  --paper: #ffffff;
  --canvas: #f6f7f6;
  --canvas-2: #eef1ef;
  --ink: #1a2421;
  --ink-2: #47544f;
  --muted: #76817c;
  --line: #e3e7e5;
  --line-2: #d4dad7;
  --brand: #128c5e;
  --brand-ink: #0c6b47;
  --brand-soft: #e7f4ee;
  --bubble: #dcf8c6;
  --bubble-ai: #e6f0fa;
  --chat-bg: #f2efe9;
  --danger: #c8333c;
  --danger-soft: #fcedee;
  --warn: #9a6408;
  --warn-soft: #fdf4e1;
  --info: #2457c5;
  --info-soft: #ebf1fd;
  --r-sm: 6px;
  --r: 8px;
  --r-lg: 12px;
  --ring: 0 0 0 3px rgba(18, 140, 94, .18);
  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Bricolage Grotesque", "Geist", ui-sans-serif, system-ui, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --topbar-h: 56px;
}

/* ---------- Dasar ---------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--canvas); line-height: 1.55; font-size: 14.5px; -webkit-font-smoothing: antialiased; }
body.site { background: var(--paper); font-size: 16px; }
a { color: var(--brand-ink); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
img { max-width: 100%; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.015em; font-weight: 600; }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.02rem; }
h4 { font-size: .92rem; }
p { margin: 0 0 1em; }
code, pre, kbd, .mono { font-family: var(--mono); font-size: .88em; }
code { background: var(--canvas-2); padding: .1em .38em; border-radius: 5px; }
pre { background: #14201b; color: #dbe9e2; padding: 16px 18px; border-radius: var(--r-lg); overflow-x: auto; line-height: 1.6; font-size: .84rem; }
pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
::selection { background: var(--bubble); }

/* ---------- Utilitas ---------- */
.container { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.center { text-align: center; }
.mt-0 { margin-top: 0; } .mt-1 { margin-top: 8px; } .mt-2 { margin-top: 16px; } .mt-3 { margin-top: 24px; } .mt-4 { margin-top: 40px; }
.mb-0 { margin-bottom: 0 !important; } .mb-2 { margin-bottom: 16px; }
.p-2 { padding: 12px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; }
.grid { display: grid; gap: 16px; }
.g-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.g-3 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.g-4 { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.inline-form { display: inline; }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; background: var(--muted); flex-shrink: 0; }
.dot-ok { background: var(--brand); }
.dot-bad { background: var(--danger); }

/* ---------- Tombol ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: var(--r); border: 1px solid transparent; font: inherit; font-weight: 500; font-size: .9rem; line-height: 1; cursor: pointer; text-decoration: none !important; white-space: nowrap; transition: background-color .12s, border-color .12s, color .12s; }
.btn:focus-visible { outline: 0; box-shadow: var(--ring); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-ink); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #2c3a35; }
.btn-ghost { background: var(--paper); color: var(--ink); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--canvas); border-color: #c3cbc7; }
.btn-danger { background: var(--paper); color: var(--danger); border-color: #efc6c9; }
.btn-danger:hover { background: var(--danger-soft); }
.btn-light { background: #fff; color: var(--ink); border-color: #fff; }
.btn-sm { height: 30px; padding: 0 10px; font-size: .83rem; border-radius: var(--r-sm); gap: 6px; }
.btn-lg { height: 46px; padding: 0 22px; font-size: 1rem; border-radius: 10px; }
.btn-block { width: 100%; }
.btn[disabled], .btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.is-loading { opacity: .85; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--brand-ink); cursor: pointer; }
.link-btn:hover { text-decoration: underline; }
.icon-btn { width: 32px; height: 32px; display: inline-grid; place-items: center; border: 0; background: transparent; border-radius: var(--r-sm); color: var(--ink-2); cursor: pointer; font-size: .95rem; }
.icon-btn:hover { background: var(--canvas-2); color: var(--ink); }

/* ---------- Form ---------- */
.field { margin-bottom: 16px; }
.field > label, .field label:first-child { display: block; font-weight: 500; font-size: .86rem; margin-bottom: 6px; color: var(--ink); }
.input, select.input, textarea.input { width: 100%; height: 38px; padding: 0 11px; border: 1px solid var(--line-2); border-radius: var(--r); font: inherit; font-size: .92rem; background: var(--paper); color: var(--ink); transition: border-color .12s, box-shadow .12s; }
textarea.input { height: auto; min-height: 112px; padding: 9px 11px; resize: vertical; line-height: 1.5; }
select.input { padding-right: 30px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%2376817c' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 11px center; }
select.input[multiple] { height: auto; padding: 6px; background-image: none; }
input[type=file].input { padding: 6px; height: auto; }
.input::placeholder { color: #9aa49f; }
.input:hover { border-color: #c3cbc7; }
.input:focus { outline: 0; border-color: var(--brand); box-shadow: var(--ring); }
.input[readonly] { background: var(--canvas); }
.input.is-invalid, .is-invalid { border-color: var(--danger) !important; }
.input.is-invalid:focus { box-shadow: 0 0 0 3px rgba(200, 51, 60, .15); }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: .9rem; cursor: pointer; }
.check input { margin: 3px 0 0; accent-color: var(--brand); width: 15px; height: 15px; flex-shrink: 0; }
.error-text { color: var(--danger); font-size: .8rem; margin-top: 5px; }
.input-hint { font-size: .8rem; color: var(--muted); margin-top: 5px; }
input[type=range] { accent-color: var(--brand); }
.copy-field { display: flex; gap: 6px; }
.copy-field input { font-family: var(--mono); font-size: .82rem; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 8px 14px; }

/* ---------- Kartu, alert, badge ---------- */
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 20px; }
.card-tight { padding: 14px; }
.card > h3:first-child, .card > .row:first-child h3 { margin-bottom: 4px; }
.alert { padding: 11px 14px; border-radius: var(--r); margin-bottom: 16px; font-size: .9rem; border: 1px solid transparent; }
.alert-success { background: var(--brand-soft); color: var(--brand-ink); border-color: #c9e7d8; }
.alert-error { background: var(--danger-soft); color: var(--danger); border-color: #f2cdd0; }
.alert-info { background: var(--info-soft); color: var(--info); border-color: #cfdcf7; }
.alert-warn { background: var(--warn-soft); color: var(--warn); border-color: #f1dfb6; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 9px 2px 8px; border-radius: 999px; font-size: .76rem; font-weight: 500; background: var(--canvas-2); color: var(--ink-2); white-space: nowrap; border: 1px solid transparent; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-ok { background: var(--brand-soft); color: var(--brand-ink); }
.badge-warn { background: var(--warn-soft); color: var(--warn); }
.badge-bad { background: var(--danger-soft); color: var(--danger); }
.badge-info { background: var(--info-soft); color: var(--info); }
.tag { display: inline-block; font-size: .74rem; font-weight: 500; padding: 1px 8px; border-radius: 999px; background: var(--canvas-2); color: var(--ink-2); }
.stat .label { color: var(--muted); font-size: .84rem; font-weight: 500; }
.stat .value { font-size: 1.65rem; font-weight: 600; margin-top: 4px; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.value small { font-size: .55em; font-weight: 500; color: var(--muted); }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 8px 18px; margin: 0; font-size: .9rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; }
.meter { height: 6px; background: var(--canvas-2); border-radius: 99px; overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--brand); border-radius: 99px; transition: width .3s; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }
.state-icon { font-size: 56px; color: var(--ink-2); }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 2.5px solid var(--canvas-2); border-top-color: var(--brand); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.section-head { max-width: 640px; margin-bottom: 20px; }
.danger-zone { border-color: #efc6c9; }
.secret-state { font-size: .8rem; margin-left: 6px; }

/* ---------- Tabel ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--paper); }
table.table { width: 100%; border-collapse: collapse; font-size: .89rem; }
.table th, .table td { padding: 10px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table th { font-size: .8rem; color: var(--muted); font-weight: 500; white-space: nowrap; background: var(--paper); }
.table tbody tr:hover td { background: #fafbfa; }
.table tr:last-child td { border-bottom: 0; }
.table .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.card .table-wrap { border-radius: var(--r); }

/* ---------- Paginasi ---------- */
.pagination { display: flex; gap: 4px; justify-content: center; margin-top: 18px; flex-wrap: wrap; }
.pagination a, .pagination span { min-width: 32px; height: 32px; padding: 0 10px; display: inline-grid; place-items: center; border: 1px solid var(--line); border-radius: var(--r-sm); background: var(--paper); font-size: .85rem; color: var(--ink-2); text-decoration: none; }
.pagination a:hover { background: var(--canvas); }
.pagination .active { background: var(--ink); color: #fff; border-color: var(--ink); }
.pagination .disabled { opacity: .45; }

/* ================= Shell dashboard ================= */
.app { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--paper); border-right: 1px solid var(--line); padding: 14px 10px 10px; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; overflow-y: auto; z-index: 40; }
.logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 600; font-size: 1.02rem; letter-spacing: -.02em; color: var(--ink) !important; text-decoration: none !important; }
.logo b { font-weight: 700; color: var(--brand); }
.logo-mark { width: 28px; height: 28px; border-radius: 8px; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 15px; }
.sidebar .logo { padding: 4px 8px 16px; }
.logo-brand { display: inline-flex; align-items: center; gap: 9px; }
.logo-img { height: 30px; width: auto; max-width: 140px; border-radius: 6px; object-fit: contain; }
.side-nav { display: flex; flex-direction: column; gap: 1px; }
.side-nav a { color: var(--ink-2); padding: 0 10px; height: 34px; border-radius: var(--r-sm); font-weight: 450; font-size: .9rem; display: flex; gap: 10px; align-items: center; text-decoration: none; position: relative; }
.side-nav a i.fa-fw { width: 1.15em; color: var(--muted); font-size: .92em; }
.side-nav a:hover { background: var(--canvas); color: var(--ink); }
.side-nav a.active { background: var(--canvas-2); color: var(--ink); font-weight: 550; }
.side-nav a.active i.fa-fw { color: var(--brand); }
.side-nav a .ext { font-size: .62rem; color: var(--muted); margin-left: auto; }
.side-label { font-size: .76rem; color: var(--muted); padding: 16px 10px 5px; font-weight: 500; }
.nav-badge { margin-left: auto; background: var(--brand); color: #fff; border-radius: 99px; font-size: .7rem; line-height: 18px; min-width: 18px; padding: 0 6px; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; }
.side-foot { margin-top: auto; padding: 12px 6px 2px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 8px; }
.side-user { display: flex; align-items: center; gap: 9px; min-width: 0; flex: 1; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--canvas-2); color: var(--ink-2); display: grid; place-items: center; font-weight: 600; font-size: .82rem; flex-shrink: 0; }
.side-user-meta { min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.side-user-meta b { font-weight: 550; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-user-meta span { font-size: .76rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-backdrop { display: none; }
.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: var(--topbar-h); padding: 0 28px; border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 20; }
.topbar h1 { font-size: 1rem; font-weight: 600; margin: 0; letter-spacing: -.01em; }
.menu-btn { display: none; }
.content { padding: 28px; width: 100%; max-width: 1200px; }
.content.content-flush { padding: 0; max-width: none; }
.plan-pill { display: inline-flex; align-items: center; gap: 7px; font-size: .82rem; color: var(--ink-2); padding: 0 11px; height: 28px; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); text-decoration: none !important; }
.plan-pill:hover { background: var(--canvas); }
.plan-pill.off { color: var(--danger); border-color: #efc6c9; }
.plan-pill.admin { color: var(--ink); }

/* admin: aksen netral grafit, bukan hijau — supaya selalu sadar sedang di panel admin */
.admin-mode { --brand-acc: #2b3138; }
.admin-mode .side-nav a.active i.fa-fw { color: var(--ink); }
.admin-mode .side-nav a.active { background: #e9ecee; }
.admin-mode .logo-mark { background: var(--ink); }
.admin-tag { font-size: .7rem; font-weight: 500; border: 1px solid var(--line-2); color: var(--ink-2); padding: 1px 7px; border-radius: 999px; }
.impersonation-bar { position: sticky; top: 0; z-index: 60; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 8px 16px; background: var(--ink); color: #eef2f0; font-size: .88rem; }
.settings-tabs { display: flex; gap: 2px; flex-wrap: wrap; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.settings-tabs a { padding: 8px 12px; color: var(--ink-2); font-weight: 450; font-size: .9rem; text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.settings-tabs a:hover { color: var(--ink); }
.settings-tabs a.active { color: var(--ink); border-bottom-color: var(--ink); font-weight: 550; }
.settings-section { border-top: 1px solid var(--line); padding-top: 18px; margin-top: 18px; }
.settings-section:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.faq-row { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 10px; background: var(--canvas); }

/* device & key */
.qr-box { width: 280px; height: 280px; border: 1px dashed var(--line-2); border-radius: var(--r-lg); display: grid; place-items: center; background: var(--paper); margin: 0 auto; overflow: hidden; }
.qr-box img { width: 264px; height: 264px; image-rendering: pixelated; }
.key-box { display: flex; gap: 8px; align-items: center; background: var(--canvas); border: 1px solid var(--line); color: var(--ink); border-radius: var(--r); padding: 10px 12px; font-family: var(--mono); font-size: .84rem; word-break: break-all; }
.key-box span { flex: 1; }
.method { display: inline-block; font-family: var(--mono); font-weight: 500; font-size: .74rem; padding: 2px 7px; border-radius: 5px; margin-right: 6px; vertical-align: middle; }
.m-get { background: var(--info-soft); color: var(--info); }
.m-post { background: var(--brand-soft); color: var(--brand-ink); }

/* invoice */
.invoice-sheet { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 36px; max-width: 760px; margin: 0 auto; }

/* AI agent */
.agent-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
.agent-side { position: sticky; top: calc(var(--topbar-h) + 16px); }
.agent-card { transition: border-color .12s; }
.agent-card:hover { border-color: var(--line-2); }
.playground { display: flex; flex-direction: column; }
.pg-log { height: 380px; overflow-y: auto; background: var(--chat-bg); border-radius: var(--r); padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.pg-msg { display: flex; flex-direction: column; align-items: flex-start; }
.pg-msg.user { align-items: flex-end; }
.pg-bubble { background: #fff; border-radius: 8px; padding: 6px 10px; max-width: 88%; font-size: .9rem; box-shadow: 0 1px 0 rgba(0, 0, 0, .06); white-space: pre-wrap; }
.pg-msg.user .pg-bubble { background: var(--bubble); }
.pg-msg.err .pg-bubble { background: var(--danger-soft); color: var(--danger); }
.pg-note { font-size: .72rem; color: var(--muted); margin-top: 2px; }
.pg-src { font-size: .75rem; margin-top: 3px; max-width: 88%; background: rgba(255, 255, 255, .7); border-radius: 6px; padding: 4px 8px; }
.pg-src > div { margin-top: 6px; }
.kb-hit { border: 1px solid var(--line); border-radius: var(--r); padding: 9px 11px; margin-bottom: 8px; background: var(--paper); }
.sched-extra { margin-top: 8px; }
.qr-list { max-height: 260px; overflow-y: auto; }
.qr-item { display: flex; gap: 10px; justify-content: space-between; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); }
.qr-item .small { white-space: pre-wrap; }

/* ================= Lapisan AJAX ================= */
.progress-bar { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 200; pointer-events: none; opacity: 0; transition: opacity .2s; }
.progress-bar.on { opacity: 1; }
.progress-bar.done { opacity: 0; transition-delay: .15s; }
.progress-bar span { display: block; height: 100%; width: 0; background: var(--brand); transition: width .35s ease; }
.toasts { position: fixed; right: 16px; bottom: 16px; z-index: 150; display: flex; flex-direction: column; gap: 8px; width: min(380px, calc(100vw - 32px)); }
.toast { display: flex; align-items: flex-start; gap: 10px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 11px 10px 11px 14px; font-size: .9rem; box-shadow: 0 8px 28px rgba(26, 36, 33, .12); animation: toast-in .18s ease-out; }
.toast > i { margin-top: 3px; }
.toast span { flex: 1; min-width: 0; }
.toast button { border: 0; background: none; color: var(--muted); cursor: pointer; padding: 2px 4px; border-radius: 4px; }
.toast button:hover { color: var(--ink); background: var(--canvas); }
.toast-success > i { color: var(--brand); }
.toast-error > i { color: var(--danger); }
.toast-info > i { color: var(--info); }
.toast-warn > i { color: var(--warn); }
.toast.out { opacity: 0; transform: translateY(4px); transition: opacity .2s, transform .2s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(6px); } }
.confirm-modal, .ib-modal { border: 1px solid var(--line); border-radius: 14px; padding: 22px; width: min(440px, calc(100vw - 32px)); box-shadow: 0 24px 64px rgba(26, 36, 33, .2); color: var(--ink); }
.confirm-modal::backdrop, .ib-modal::backdrop { background: rgba(26, 36, 33, .35); }
.confirm-modal[open] { animation: toast-in .15s ease-out; }
.confirm-text { margin: 0 0 20px; font-size: .95rem; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 8px; }

/* ================= Inbox (gaya WhatsApp Web) ================= */
.inbox { display: grid; grid-template-columns: minmax(300px, 370px) 1fr; height: calc(100vh - var(--topbar-h) - 1px); background: var(--paper); }
.ib-list { display: flex; flex-direction: column; border-right: 1px solid var(--line); min-height: 0; background: var(--paper); }
.ib-device-bar { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.ib-device-bar > i { color: var(--brand); font-size: 1.1rem; }
.ib-device-switch { flex: 1; min-width: 0; height: 34px; border: 1px solid var(--line-2); border-radius: var(--r); padding: 0 10px; font: inherit; font-weight: 550; font-size: .88rem; background: var(--paper); cursor: pointer; color: var(--ink); }
.ib-device-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.ib-device-status.on { background: var(--brand); }
.ib-device-status.off { background: var(--danger); }
.ib-list-head { display: flex; gap: 4px; align-items: center; padding: 10px 12px 8px; position: relative; }
.ib-search { flex: 1; display: flex; align-items: center; gap: 8px; background: var(--canvas); border: 1px solid transparent; border-radius: var(--r); padding: 0 10px; }
.ib-search:focus-within { border-color: var(--brand); background: var(--paper); box-shadow: var(--ring); }
.ib-search i { color: var(--muted); font-size: .82rem; }
.ib-search input { border: 0; background: transparent; height: 34px; font: inherit; font-size: .9rem; width: 100%; outline: none; color: var(--ink); }
.ib-icon-btn { border: 0; background: transparent; width: 34px; height: 34px; border-radius: var(--r-sm); color: var(--ink-2); cursor: pointer; display: inline-grid; place-items: center; font-size: .95rem; flex-shrink: 0; }
.ib-icon-btn:hover { background: var(--canvas-2); color: var(--ink); }
.ib-icon-btn:disabled { opacity: .5; cursor: default; }
.ib-menu { position: absolute; right: 12px; top: 48px; z-index: 30; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 12px 32px rgba(26, 36, 33, .12); padding: 5px; min-width: 240px; }
.ib-menu button, .ib-menu a { display: flex; gap: 9px; align-items: center; width: 100%; border: 0; background: none; padding: 8px 10px; border-radius: var(--r-sm); font: inherit; font-size: .88rem; color: var(--ink); text-align: left; cursor: pointer; text-decoration: none; }
.ib-menu button:hover, .ib-menu a:hover { background: var(--canvas); }
.ib-menu i { width: 1.1em; color: var(--muted); }
.ib-filters { display: flex; gap: 6px; padding: 0 12px 10px; flex-wrap: wrap; align-items: center; border-bottom: 1px solid var(--line); }
.ib-chip { border: 1px solid var(--line); background: var(--paper); color: var(--ink-2); border-radius: 99px; padding: 0 10px; height: 26px; font: inherit; font-size: .8rem; font-weight: 500; cursor: pointer; display: inline-flex; align-items: center; gap: 5px; }
.ib-chip:hover { border-color: var(--line-2); }
.ib-chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }
.ib-chip span:empty { display: none; }
.ib-chip span { font-weight: 600; font-variant-numeric: tabular-nums; }
.ib-chats { flex: 1; overflow-y: auto; min-height: 0; }
.ib-row { display: flex; gap: 11px; width: 100%; text-align: left; border: 0; background: var(--paper); padding: 10px 14px; cursor: pointer; font: inherit; color: inherit; border-bottom: 1px solid #f1f3f2; }
.ib-row:hover { background: #fafbfa; }
.ib-row.active { background: var(--canvas-2); }
.ib-row-main { flex: 1; min-width: 0; }
.ib-row-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.ib-row-top b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 500; font-size: .93rem; }
.ib-row.unread .ib-row-top b { font-weight: 650; }
.ib-time { font-size: .73rem; color: var(--muted); flex-shrink: 0; font-variant-numeric: tabular-nums; }
.ib-row.unread .ib-time { color: var(--brand-ink); font-weight: 600; }
.ib-row-bottom { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.ib-preview { flex: 1; min-width: 0; color: var(--muted); font-size: .84rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ib-preview i { font-size: .7rem; }
.ib-badge { background: var(--brand); color: #fff; border-radius: 99px; font-size: .7rem; font-weight: 600; min-width: 19px; height: 19px; display: inline-grid; place-items: center; padding: 0 6px; }
.ib-tag { color: var(--muted); font-size: .74rem; position: relative; }
.ib-tag.human { color: var(--warn); }
.ib-slash { position: absolute; left: 0; top: 2px; font-size: .74rem; }
.ib-avatar { width: 42px; height: 42px; border-radius: 50%; background: #e3e9e6; color: var(--ink-2); display: grid; place-items: center; font-weight: 600; flex-shrink: 0; font-size: 1rem; }
.ib-avatar.group { background: #e5e8ed; }
.ib-none { text-align: center; color: var(--muted); padding: 40px 20px; font-size: .9rem; }
.ib-none i { font-size: 1.8rem; margin-bottom: 8px; display: block; }
.ib-loading { display: grid; place-items: center; padding: 40px; }
.ib-pane { display: flex; flex-direction: column; min-width: 0; min-height: 0; background: var(--chat-bg); }
.ib-placeholder { margin: auto; text-align: center; max-width: 420px; padding: 24px; color: var(--ink-2); }
.ib-placeholder > i { font-size: 3rem; color: var(--muted); }
.ib-chat { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.ib-chat-head { display: flex; align-items: center; gap: 12px; padding: 8px 14px; background: var(--paper); border-bottom: 1px solid var(--line); min-height: 58px; }
.ib-chat-title { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.3; }
.ib-chat-title b { cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.ib-chat-actions { display: flex; align-items: center; gap: 2px; }
.ib-back { display: none; }
.ib-ai-pill { border: 1px solid var(--line); background: var(--paper); border-radius: 99px; padding: 0 11px; height: 28px; font: inherit; font-size: .8rem; font-weight: 500; cursor: pointer; color: var(--ink-2); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.ib-ai-pill.on { border-color: #bfe0cf; color: var(--brand-ink); background: var(--brand-soft); }
.ib-ai-pill.paused { border-color: #ecd9ae; color: var(--warn); background: var(--warn-soft); }
.ib-ai-pill.off, .ib-ai-pill.noagent { color: var(--muted); }
.ib-banner { padding: 8px 16px; font-size: .85rem; background: var(--warn-soft); color: var(--warn); border-bottom: 1px solid #f1dfb6; }
.ib-banner.error { background: var(--danger-soft); color: var(--danger); border-color: #f2cdd0; }
.ib-banner .link-btn { font-weight: 600; color: inherit; text-decoration: underline; }
.ib-messages { flex: 1; overflow-y: auto; padding: 18px 6%; display: flex; flex-direction: column; gap: 3px; min-height: 0;
  background-color: var(--chat-bg); background-image: radial-gradient(rgba(26, 36, 33, .045) 1px, transparent 1px); background-size: 16px 16px; }
.ib-day { text-align: center; margin: 12px 0 6px; }
.ib-day span { background: var(--paper); color: var(--ink-2); font-size: .74rem; padding: 3px 11px; border-radius: 7px; box-shadow: 0 1px 0 rgba(0, 0, 0, .05); }
.ib-more { text-align: center; margin-bottom: 8px; }
.ib-msg { display: flex; }
.ib-msg.out { justify-content: flex-end; }
.ib-bubble { max-width: min(72%, 560px); background: #fff; border-radius: 9px; padding: 6px 9px 4px; box-shadow: 0 1px 0 rgba(0, 0, 0, .07); font-size: .92rem; line-height: 1.45; overflow-wrap: anywhere; }
.ib-msg.out .ib-bubble { background: var(--bubble); }
.ib-msg.out.ai .ib-bubble { background: var(--bubble-ai); }
.ib-sender { font-size: .77rem; font-weight: 600; color: var(--brand-ink); margin-bottom: 2px; }
.ib-text code { background: rgba(0, 0, 0, .06); padding: 0 4px; border-radius: 4px; }
.ib-meta { display: flex; gap: 5px; justify-content: flex-end; align-items: center; font-size: .67rem; color: var(--muted); margin-top: 2px; }
.ib-meta .ib-fail { color: var(--danger); font-size: .8rem; }
.ib-img { display: block; max-width: 100%; max-height: 320px; border-radius: 6px; margin-bottom: 4px; cursor: zoom-in; }
.ib-img.sticker { max-width: 140px; background: transparent; }
.ib-bubble audio { max-width: 260px; height: 36px; }
.ib-doc { display: flex; align-items: center; gap: 10px; background: rgba(0, 0, 0, .04); border-radius: 7px; padding: 9px 10px; margin-bottom: 4px; text-decoration: none !important; color: var(--ink); }
.ib-doc span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .87rem; }
.ib-composer { background: var(--paper); padding: 8px 12px; border-top: 1px solid var(--line); }
.ib-compose-row { display: flex; align-items: flex-end; gap: 4px; }
.ib-compose-row textarea { flex: 1; resize: none; border: 1px solid var(--line-2); border-radius: 10px; padding: 9px 12px; font: inherit; font-size: .93rem; max-height: 160px; background: var(--paper); outline: none; line-height: 1.4; color: var(--ink); }
.ib-compose-row textarea:focus { border-color: var(--brand); box-shadow: var(--ring); }
.ib-send { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--brand); color: #fff; cursor: pointer; flex-shrink: 0; font-size: .95rem; }
.ib-send:hover { background: var(--brand-ink); }
.ib-send:disabled { opacity: .6; }
.ib-file-chip { display: inline-flex; gap: 8px; align-items: center; background: var(--canvas); border: 1px solid var(--line); border-radius: 99px; padding: 3px 12px; font-size: .82rem; margin-bottom: 6px; }
.ib-qr-pop { position: relative; margin: 0 0 6px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 12px 32px rgba(26, 36, 33, .1); max-height: 260px; overflow-y: auto; }
.ib-qr-pop button { display: flex; flex-direction: column; width: 100%; text-align: left; border: 0; background: none; padding: 8px 12px; font: inherit; cursor: pointer; border-bottom: 1px solid #f1f3f2; color: var(--ink); }
.ib-qr-pop button:hover { background: var(--canvas); }
.ib-qr-pop span { font-size: .82rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ib-lightbox { position: fixed; inset: 0; background: rgba(10, 14, 12, .86); z-index: 100; display: grid; place-items: center; cursor: zoom-out; }
.ib-lightbox img { max-width: 92vw; max-height: 92vh; border-radius: 6px; }
.inbox-empty-state { text-align: center; padding: 80px 20px; }
.inbox-empty-state > i { font-size: 2.6rem; color: var(--muted); }

/* ================= Situs publik ================= */
.announcement-bar { background: var(--brand-soft); color: var(--brand-ink); text-align: center; padding: 8px 16px; font-size: .88rem; border-bottom: 1px solid #cfe7da; }
.announcement-bar a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.site-header { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .88); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--line); }
.site-header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 12px; }
.site .logo { font-size: 1.08rem; }
.nav { display: flex; gap: 26px; align-items: center; }
.nav a:not(.btn) { color: var(--ink-2); font-size: .93rem; font-weight: 450; }
.nav a:not(.btn):hover, .nav a.active { color: var(--ink); text-decoration: none; }
.nav-sep { width: 1px; height: 18px; background: var(--line); }
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: var(--r); width: 38px; height: 38px; font: inherit; cursor: pointer; color: var(--ink); }
.site main > .alert { max-width: 1112px; margin: 16px auto 0; }

.display { font-family: var(--display); font-weight: 750; letter-spacing: -.035em; line-height: 1.02; font-optical-sizing: auto; }
.site h2 { font-family: var(--display); font-weight: 700; font-size: clamp(1.7rem, 3.2vw, 2.4rem); letter-spacing: -.03em; line-height: 1.08; }
.site h3 { font-size: 1.05rem; font-weight: 600; }
.site .muted { color: #66716c; }
.section { padding: 96px 0; }
.section-alt { background: var(--canvas); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.site .section-head { max-width: 620px; margin-bottom: 44px; }
.site .section-head p { font-size: 1.06rem; }

/* hero */
.hero { padding: 72px 0 96px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 56px; align-items: center; }
.hero h1 { font-size: clamp(2.6rem, 6.2vw, 4.7rem); margin-bottom: 22px; }
.h1-line { display: block; }
.h1-line + .h1-line { color: var(--brand-ink); }
.hero .lead { font-size: 1.16rem; color: var(--ink-2); max-width: 520px; line-height: 1.6; }
.hero-note { margin-top: 18px; font-size: .9rem; color: var(--muted); }

/* telepon: satu-satunya animasi otomatis di halaman */
.phone { width: 100%; max-width: 370px; justify-self: end; border-radius: 30px; border: 1px solid var(--line-2); background: var(--paper); padding: 8px; box-shadow: 0 1px 0 rgba(26, 36, 33, .04), 0 30px 70px -20px rgba(18, 60, 44, .28); }
.phone-head { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--brand-ink); color: #fff; border-radius: 22px 22px 0 0; }
.phone-head b { display: block; font-weight: 600; font-size: .95rem; line-height: 1.2; }
.phone-head span { font-size: .76rem; opacity: .85; }
.phone-avatar { width: 36px; height: 36px; border-radius: 50%; background: rgba(255, 255, 255, .18); display: grid; place-items: center; font-weight: 600; font-size: .8rem; }
.phone-body { background-color: var(--chat-bg); background-image: radial-gradient(rgba(26, 36, 33, .05) 1px, transparent 1px); background-size: 14px 14px; padding: 16px 12px; min-height: 360px; display: flex; flex-direction: column; gap: 6px; }
.bub { max-width: 84%; border-radius: 10px; padding: 7px 10px 5px; font-size: .88rem; line-height: 1.45; box-shadow: 0 1px 0 rgba(0, 0, 0, .07); position: relative; animation: bub-in .35s cubic-bezier(.2, .8, .3, 1) both; animation-delay: calc(.4s + var(--d, 0) * .9s); }
.bub p { margin: 0 0 4px; }
.bub time { display: block; text-align: right; font-size: .66rem; color: var(--muted); }
.bub time i { color: #3a9bdc; }
.bub.in { background: #fff; align-self: flex-start; border-top-left-radius: 3px; }
.bub.out { background: var(--bubble); align-self: flex-end; border-top-right-radius: 3px; }
.bub.out.ai { background: var(--bubble); }
.bub.typing { align-self: flex-start; background: #fff; display: flex; gap: 4px; padding: 11px 12px; max-height: 40px; overflow: hidden;
  animation: bub-in .3s ease-out both, bub-gone .2s ease-in forwards; animation-delay: calc(.4s + var(--d) * .9s), calc(.25s + (var(--d) + 1) * .9s); }
.bub.typing span { width: 6px; height: 6px; border-radius: 50%; background: #9aa49f; animation: blink 1s infinite; }
.bub.typing span:nth-child(2) { animation-delay: .15s; }
.bub.typing span:nth-child(3) { animation-delay: .3s; }
.kb-cite { align-self: flex-end; font-size: .72rem; color: var(--brand-ink); background: rgba(255, 255, 255, .75); border: 1px solid #cfe7da; border-radius: 99px; padding: 2px 9px; animation: bub-in .35s ease-out both; animation-delay: calc(.4s + var(--d) * .9s); }
.phone-foot { padding: 11px 14px 9px; font-size: .78rem; color: var(--muted); display: flex; gap: 8px; align-items: center; }
@keyframes bub-in { from { opacity: 0; transform: translateY(8px) scale(.98); } }
@keyframes bub-gone { to { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; margin-top: -6px; } }
@keyframes blink { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) {
  .bub, .kb-cite { animation: none !important; }
  .bub.typing { display: none; }
}

/* alur bernomor: memang urutan */
.flow { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; counter-reset: step; position: relative; }
.flow::before { content: ""; position: absolute; top: 15px; left: 16px; right: calc((100% - 84px) / 4 - 16px); height: 1px; background: var(--line-2); }
.flow li { counter-increment: step; position: relative; padding-top: 50px; }
.flow li::before { content: counter(step); position: absolute; top: 0; left: 0; width: 32px; height: 32px; border-radius: 50%; background: var(--paper); border: 1px solid var(--line-2); display: grid; place-items: center; font-weight: 600; font-size: .9rem; font-variant-numeric: tabular-nums; }
.flow li:nth-child(3)::before { background: var(--brand); border-color: var(--brand); color: #fff; }
.flow p { color: var(--ink-2); font-size: .95rem; margin: 0; }

.feature-split, .dev-split, .faq-split { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 64px; align-items: start; }
.feature-split > div:first-child, .faq-split > h2 { position: sticky; top: 100px; }
.feature-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 32px 36px; }
.feature-list li { display: flex; gap: 14px; }
.feature-list li > i { width: 36px; height: 36px; flex-shrink: 0; border-radius: 9px; border: 1px solid var(--line-2); background: var(--paper); display: grid; place-items: center; color: var(--ink); font-size: .95rem; }
.feature-list b { display: block; font-weight: 600; margin-bottom: 4px; }
.feature-list span { color: var(--ink-2); font-size: .93rem; line-height: 1.55; }

.dev-split { align-items: center; }
.code-tabs { border-radius: 14px; background: #14201b; overflow: hidden; border: 1px solid #14201b; }
.code-tabs-head { display: flex; gap: 2px; padding: 8px 8px 0; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.code-tabs-head button { border: 0; background: none; color: #93a59c; font: inherit; font-size: .84rem; padding: 7px 12px 9px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.code-tabs-head button:hover { color: #dbe9e2; }
.code-tabs-head button.active { color: #fff; border-bottom-color: #4fc58f; }
.code-tabs pre { margin: 0; border-radius: 0; padding: 20px; min-height: 170px; }

/* harga */
.price-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; align-items: stretch; }
.price-card { display: flex; flex-direction: column; position: relative; padding: 24px; }
.price-card.popular { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.price-card .tag { position: absolute; top: -11px; left: 22px; background: var(--brand); color: #fff; }
.price-card h3 { font-size: 1.05rem; margin-bottom: 2px; }
.price { font-size: 2rem; font-weight: 650; margin: 14px 0 2px; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.price small { font-size: .85rem; color: var(--muted); font-weight: 450; letter-spacing: 0; white-space: nowrap; }
.price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; line-height: 1.2; }
.price-specs { list-style: none; padding: 14px 0; margin: 14px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; font-size: .9rem; }
.price-specs li { display: flex; gap: 10px; align-items: baseline; }
.price-specs i { width: 1.1em; color: var(--muted); font-size: .85em; }
.price-card ul.price-feat { list-style: none; padding: 14px 0 0; margin: 16px 0 22px; border-top: 1px solid var(--line); flex: 1; font-size: .9rem; color: var(--ink-2); }
.price-card ul.price-feat li { padding: 4px 0 4px 22px; position: relative; }
.price-card ul.price-feat li::before { content: "\f00c"; font-family: "Font Awesome 6 Free"; font-weight: 900; font-size: .72em; position: absolute; left: 2px; top: 8px; color: var(--brand); }
.price-card .btn { margin-top: auto; }
.included { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px 24px; font-size: .93rem; color: var(--ink-2); }
.included i { color: var(--brand); margin-right: 6px; }

/* faq */
.faq details { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 550; font-size: 1.02rem; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "\2b"; font-family: "Font Awesome 6 Free"; font-weight: 900; font-size: .8rem; color: var(--muted); transition: transform .15s; margin-top: 4px; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 10px 0 0; color: var(--ink-2); max-width: 62ch; }

.closing { padding: 112px 0; border-top: 1px solid var(--line); }
.closing-inner { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); gap: 48px; align-items: end; }
.closing h2.display { font-size: clamp(2.2rem, 5vw, 3.8rem); margin: 0; }
.closing p { color: var(--ink-2); font-size: 1.05rem; }

/* halaman markdown & docs */
.md { line-height: 1.7; }
.md h2 { font-size: 1.3rem; margin-top: 1.8em; }
.md ul, .md ol { padding-left: 1.3em; }
.page-head { padding: 72px 0 8px; }
.page-head h1 { font-family: var(--display); font-weight: 750; letter-spacing: -.035em; font-size: clamp(2.2rem, 4.6vw, 3.4rem); line-height: 1.05; }
.page-head p { font-size: 1.08rem; color: var(--ink-2); max-width: 600px; }
.docs-grid { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 48px; }
.docs-nav { position: sticky; top: 88px; align-self: start; display: flex; flex-direction: column; gap: 1px; font-size: .9rem; max-height: calc(100vh - 110px); overflow-y: auto; }
.docs-nav a { color: var(--ink-2); padding: 5px 10px; border-radius: var(--r-sm); text-decoration: none; }
.docs-nav a:hover { background: var(--canvas); color: var(--ink); }
.docs { max-width: 780px; font-size: .97rem; }
.docs h2 { font-family: var(--font); font-size: 1.35rem; font-weight: 600; letter-spacing: -.02em; margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.docs h2:first-child { margin-top: 0; border-top: 0; padding-top: 0; }
.docs h3 { margin-top: 28px; }
.docs .table-wrap { margin-bottom: 18px; }
.docs pre { margin: 0 0 18px; }

/* footer */
.site-footer { border-top: 1px solid var(--line); padding: 56px 0 28px; color: var(--muted); font-size: .9rem; background: var(--canvas); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 32px; }
.footer-grid h4 { font-size: .86rem; color: var(--ink); font-weight: 600; margin-bottom: 12px; }
.footer-grid a:not(.logo) { display: block; color: var(--ink-2); padding: 3px 0; }
.footer-brand p { margin-top: 12px; max-width: 34ch; line-height: 1.6; }
.footer-base { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--line); font-size: .84rem; }

/* auth */
.auth-body { background: var(--canvas); }
.auth-wrap { min-height: 100vh; display: grid; place-items: center; padding: 40px 16px; }
.auth-card { width: 100%; max-width: 400px; }
.auth-card > .logo { display: flex; justify-content: center; margin-bottom: 22px; }
.auth-panel { padding: 28px; }
.auth-panel h2 { font-family: var(--font); font-size: 1.3rem; font-weight: 600; letter-spacing: -.02em; }

/* ================= Checkout & channel pembayaran ================= */
.checkout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 24px; align-items: start; }
.checkout-side { position: sticky; top: calc(var(--topbar-h) + 16px); }
.pay-group { border: 0; padding: 0; margin: 0 0 18px; }
.pay-group legend { font-size: .84rem; color: var(--muted); font-weight: 500; padding: 0; margin-bottom: 8px; }
.pay-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.pay-option { display: flex; align-items: center; gap: 10px; padding: 12px 14px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-lg); cursor: pointer; transition: border-color .12s, box-shadow .12s; }
.pay-option:hover { border-color: var(--line-2); }
.pay-option input { accent-color: var(--brand); margin: 0; }
.pay-option:has(input:checked) { border-color: var(--brand); box-shadow: 0 0 0 1px var(--brand); }
.pay-option:has(input:focus-visible) { box-shadow: var(--ring); }
.pay-name { flex: 1; font-weight: 500; font-size: .92rem; }
.pay-fee { font-size: .8rem; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.pay-fee.free { color: var(--brand-ink); }
.sum { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; margin: 18px 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: .92rem; }
.sum dt { color: var(--ink-2); }
.sum dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.sum .sum-total { font-weight: 650; font-size: 1.05rem; color: var(--ink); padding-top: 8px; border-top: 1px solid var(--line); }
.row-muted td { opacity: .55; }
.ent-grid { display: grid; grid-template-columns: minmax(0, 1fr) 460px; gap: 56px; align-items: start; }
.ent-list { grid-template-columns: 1fr; gap: 20px; margin-top: 16px; }
.ent-flow { grid-template-columns: repeat(3, 1fr); margin-top: 20px; }
.ent-flow::before { right: calc((100% - 56px) / 3 - 16px); }
.form-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
.ent-form { position: sticky; top: 88px; padding: 24px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.lead-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
.enterprise-card { border-style: dashed; }
@media (max-width: 960px) {
  .checkout, .lead-grid, .ent-grid { grid-template-columns: 1fr; }
  .ent-form { position: static; }
  .ent-flow { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .form-2 { grid-template-columns: 1fr; }
  .checkout-side { position: static; }
}

/* ================= Responsif ================= */
@media (max-width: 1100px) {
  .agent-layout { grid-template-columns: 1fr; }
  .agent-side { position: static; }
}
@media (max-width: 960px) {
  .hero-grid, .feature-split, .dev-split, .faq-split, .closing-inner, .docs-grid { grid-template-columns: 1fr; gap: 40px; }
  .feature-split > div:first-child, .faq-split > h2 { position: static; }
  .phone { justify-self: start; }
  .flow { grid-template-columns: 1fr 1fr; row-gap: 36px; }
  .flow::before { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .docs-nav { position: static; flex-direction: row; flex-wrap: wrap; max-height: none; border-bottom: 1px solid var(--line); padding-bottom: 12px; }

  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 264px; transform: translateX(-100%); transition: transform .2s ease; box-shadow: none; }
  .sidebar.open { transform: none; box-shadow: 0 0 40px rgba(26, 36, 33, .2); }
  .sidebar.open + .sidebar-backdrop { display: block; position: fixed; inset: 0; background: rgba(26, 36, 33, .3); z-index: 35; }
  .menu-btn { display: inline-grid; margin-left: -6px; }
  .topbar { padding: 0 16px; }
  .content { padding: 20px 16px; }
}
@media (max-width: 760px) {
  .container { padding: 0 16px; }
  .section { padding: 64px 0; }
  .hero { padding: 40px 0 64px; }
  .nav { display: none; position: absolute; top: 64px; left: 0; right: 0; background: var(--paper); flex-direction: column; padding: 12px 16px 16px; border-bottom: 1px solid var(--line); align-items: stretch; gap: 4px; }
  .nav.open { display: flex; }
  .nav a:not(.btn) { padding: 8px 0; }
  .nav-sep { display: none; }
  .nav .btn { margin-top: 6px; }
  .nav-toggle { display: inline-grid; place-items: center; }
  .feature-list, .flow { grid-template-columns: 1fr; }
  .closing { padding: 72px 0; }
  .card { padding: 16px; }
  .invoice-sheet { padding: 20px; }
  .plan-pill { font-size: .76rem; padding: 0 9px; }

  .inbox { grid-template-columns: 1fr; }
  .inbox .ib-pane { display: none; }
  .inbox.chat-open .ib-list { display: none; }
  .inbox.chat-open .ib-pane { display: flex; }
  .ib-back { display: inline-grid; }
  .ib-messages { padding: 12px 10px; }
  .ib-bubble { max-width: 86%; }
  .ib-ai-pill { padding: 0 8px; font-size: .74rem; }
  .toasts { right: 12px; left: 12px; bottom: 12px; width: auto; }
}

@media print {
  body { background: #fff; }
  .no-print, .sidebar, .topbar, .toasts, .progress-bar, .impersonation-bar { display: none !important; }
  .app { display: block; }
  .content { padding: 0; }
  .invoice-sheet { border: 0; padding: 0; }
}
