/* ReviewMate UI — premium SaaS styling, light + dark themes */
:root {
  --navy-950: #070d22; --navy-900: #0b1533; --navy-800: #13214a; --navy-700: #1c2d5e;
  --blue: #2563eb; --blue-600: #1d4ed8; --blue-50: #eff4ff; --blue-100: #dbe6ff;
  --bg: #f5f7fb; --surface: #ffffff; --surface-2: #f8fafc; --border: #e4e8f0; --border-strong: #cfd6e3;
  --text: #0f172a; --text-2: #475569; --text-3: #94a3b8;
  --green: #059669; --green-bg: #e7f7f0; --amber: #b45309; --amber-bg: #fff4e0; --red: #dc2626; --red-bg: #fdecec;
  --violet: #7c3aed; --violet-bg: #f1ebff; --star: #f59e0b;
  --shadow-sm: 0 1px 2px rgba(15,23,42,.06); --shadow: 0 1px 3px rgba(15,23,42,.08), 0 8px 24px -12px rgba(15,23,42,.12);
  --shadow-lg: 0 24px 60px -20px rgba(15,23,42,.35);
  --radius: 12px; --radius-sm: 8px;
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans Arabic", "Noto Sans Devanagari", sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sidebar-w: 248px;
}
[data-theme="dark"] {
  --bg: #0a1020; --surface: #111a2e; --surface-2: #0e1628; --border: #1f2a44; --border-strong: #2b3a5c;
  --text: #e6ebf5; --text-2: #a3b0c8; --text-3: #6b7a96; --blue-50: #13214a; --blue-100: #1c2d5e;
  --green-bg: #0d2a22; --amber-bg: #2d2010; --red-bg: #2e1216; --violet-bg: #211a3d;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.6);
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--text); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0 0 .4em; line-height: 1.25; letter-spacing: -.01em; }
h1 { font-size: 24px; } h2 { font-size: 18px; } h3 { font-size: 15px; }
p { margin: 0 0 .8em; }
small, .muted { color: var(--text-2); }
.faint { color: var(--text-3); }
code, .mono { font-family: var(--mono); font-size: 12.5px; }
hr { border: 0; border-top: 1px solid var(--border); margin: 16px 0; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: 500 13.5px var(--font); cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, box-shadow .15s; text-decoration: none !important; }
.btn:hover { background: var(--surface-2); border-color: var(--text-3); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--blue); border-color: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-600); border-color: var(--blue-600); }
.btn-danger { background: var(--red); border-color: var(--red); color: #fff; }
.btn-danger:hover { background: #b91c1c; }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-ghost:hover { background: var(--surface-2); border-color: transparent; }
.btn-sm { height: 30px; padding: 0 10px; font-size: 12.5px; }
.btn-lg { height: 46px; padding: 0 22px; font-size: 15px; border-radius: 10px; }
.btn-icon { width: 36px; padding: 0; }
.btn .spinner { width: 14px; height: 14px; border-width: 2px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ---------- forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field > label { font-weight: 600; font-size: 13px; }
.field .hint { font-size: 12px; color: var(--text-2); }
.input, select.input, textarea.input { width: 100%; height: 38px; padding: 0 12px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); font: 14px var(--font); transition: border-color .15s, box-shadow .15s; }
textarea.input { height: auto; min-height: 90px; padding: 10px 12px; resize: vertical; line-height: 1.5; }
.input:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.18); }
.input[readonly] { background: var(--surface-2); }
.check { display: flex; gap: 8px; align-items: flex-start; cursor: pointer; font-size: 13.5px; }
.check input { margin-top: 3px; accent-color: var(--blue); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 16px; }
.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); overflow: hidden; background: var(--surface); flex-wrap: wrap; }
.seg button { border: 0; background: transparent; padding: 8px 14px; font: 500 13px var(--font); color: var(--text-2); cursor: pointer; border-right: 1px solid var(--border); }
.seg button:last-child { border-right: 0; }
.seg button.on { background: var(--blue); color: #fff; }
.form-error { background: var(--red-bg); color: var(--red); padding: 10px 12px; border-radius: var(--radius-sm); margin-bottom: 12px; font-size: 13px; }

/* ---------- cards & layout ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.card-pad { padding: 20px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.card-head h2, .card-head h3 { margin: 0; }
.card-body { padding: 20px; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.row { display: flex; gap: 12px; align-items: center; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.cols-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.cols-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cols-main { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 16px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.kpi { padding: 18px 20px; }
.kpi .label { color: var(--text-2); font-size: 12.5px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.kpi .value { font-size: 28px; font-weight: 700; letter-spacing: -.02em; margin: 6px 0 2px; }
.kpi .sub { font-size: 12.5px; color: var(--text-2); }
.kpi .sub.up { color: var(--green); } .kpi .sub.warn { color: var(--amber); }
.empty { text-align: center; padding: 40px 20px; color: var(--text-2); }
.empty .icon { font-size: 30px; margin-bottom: 8px; opacity: .6; }
.note { font-size: 12px; color: var(--text-3); }
.callout { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--blue-50); color: var(--text); border: 1px solid var(--blue-100); font-size: 13.5px; }
.callout.warn { background: var(--amber-bg); border-color: transparent; }
.callout.danger { background: var(--red-bg); border-color: transparent; }
.callout.ok { background: var(--green-bg); border-color: transparent; }

/* ---------- badges ---------- */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; background: var(--surface-2); color: var(--text-2); border: 1px solid var(--border); white-space: nowrap; }
.badge.green { background: var(--green-bg); color: var(--green); border-color: transparent; }
.badge.amber { background: var(--amber-bg); color: var(--amber); border-color: transparent; }
.badge.red { background: var(--red-bg); color: var(--red); border-color: transparent; }
.badge.blue { background: var(--blue-50); color: var(--blue); border-color: transparent; }
.badge.violet { background: var(--violet-bg); color: var(--violet); border-color: transparent; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: var(--text-3); }
.dot.green { background: #10b981; box-shadow: 0 0 0 3px rgba(16,185,129,.18); }
.dot.red { background: var(--red); } .dot.amber { background: #f59e0b; }
.stars { color: var(--star); letter-spacing: 1px; white-space: nowrap; }
.stars .off { color: var(--border-strong); }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; }
table.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font-size: 12px; font-weight: 600; color: var(--text-2); text-transform: uppercase; letter-spacing: .03em; padding: 10px 16px; border-bottom: 1px solid var(--border); background: var(--surface-2); white-space: nowrap; }
.tbl td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: 0; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: var(--surface-2); }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; }
.pager { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; border-top: 1px solid var(--border); font-size: 13px; color: var(--text-2); }

/* ---------- app shell ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); min-height: 100vh; }
.sidebar { background: var(--navy-900); color: #c7d2ea; display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; padding: 20px 20px 16px; color: #fff; font-weight: 700; font-size: 16px; }
.brand .logo { width: 32px; height: 32px; border-radius: 9px; background: linear-gradient(135deg, #3b82f6, #1d4ed8); display: grid; place-items: center; font-size: 16px; color: #fff; box-shadow: 0 6px 18px -6px rgba(59,130,246,.7); }
.brand small { display: block; font-weight: 500; font-size: 11px; color: #7f8db0; }
.nav { padding: 8px 12px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.nav .group { font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; color: #5d6b8f; padding: 14px 10px 6px; font-weight: 600; }
.nav a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; color: #b6c2dc; font-weight: 500; text-decoration: none; font-size: 13.5px; }
.nav a:hover { background: var(--navy-800); color: #fff; }
.nav a.active { background: rgba(59,130,246,.16); color: #fff; box-shadow: inset 3px 0 0 #3b82f6; }
.nav a .ic { width: 18px; text-align: center; opacity: .9; }
.nav a .count { margin-left: auto; background: #ef4444; color: #fff; border-radius: 999px; font-size: 11px; padding: 0 7px; font-weight: 700; }
.side-foot { padding: 14px 16px; border-top: 1px solid var(--navy-800); font-size: 12.5px; }
.side-foot .who { color: #fff; font-weight: 600; }
.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 60px; background: var(--surface); border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; padding: 0 24px; position: sticky; top: 0; z-index: 20; }
.topbar .crumbs { font-size: 13px; color: var(--text-2); }
.topbar .crumbs b { color: var(--text); font-weight: 600; }
.topbar .spacer { flex: 1; }
.menu-btn { display: none; }
.content { padding: 24px; max-width: 1400px; width: 100%; }
.page-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head p { margin: 2px 0 0; color: var(--text-2); }
.banner { padding: 10px 24px; font-size: 13.5px; display: flex; gap: 12px; align-items: center; justify-content: center; flex-wrap: wrap; }
.banner.support { background: #7c3aed; color: #fff; }
.banner.warn { background: var(--amber-bg); color: var(--amber); }
.banner.danger { background: var(--red-bg); color: var(--red); }
.banner.info { background: var(--blue-50); color: var(--blue); }
.banner .btn { height: 28px; }
.pill-status { display: inline-flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--text-2); padding: 6px 10px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); }

/* dropdown / popover */
.pop { position: relative; }
.pop-panel { position: absolute; right: 0; top: calc(100% + 8px); min-width: 320px; max-height: 420px; overflow: auto; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); z-index: 50; }
.pop-panel .item { padding: 12px 16px; border-bottom: 1px solid var(--border); font-size: 13px; cursor: pointer; }
.pop-panel .item:hover { background: var(--surface-2); }
.pop-panel .item.unread { background: var(--blue-50); }
.bell { position: relative; }
.bell .n { position: absolute; top: 3px; right: 3px; background: var(--red); color: #fff; font-size: 10px; font-weight: 700; border-radius: 999px; padding: 0 5px; line-height: 16px; }

/* tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 16px; overflow-x: auto; }
.tabs button { background: none; border: 0; padding: 10px 14px; font: 500 13.5px var(--font); color: var(--text-2); border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap; display: flex; gap: 6px; align-items: center; }
.tabs button.on { color: var(--blue); border-bottom-color: var(--blue); }
.tabs .c { background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; font-size: 11px; padding: 0 7px; color: var(--text-2); }
.tabs button.on .c { background: var(--blue-50); color: var(--blue); border-color: transparent; }

/* review inbox */
.inbox { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 16px; align-items: start; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; padding: 12px 16px; border-bottom: 1px solid var(--border); }
.filters .input { height: 34px; width: auto; min-width: 120px; font-size: 13px; }
.filters .input.search { flex: 1; min-width: 180px; }
.rv { display: flex; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); cursor: pointer; position: relative; }
.rv:hover { background: var(--surface-2); }
.rv.sel { background: var(--blue-50); box-shadow: inset 3px 0 0 var(--blue); }
.rv .av { width: 36px; height: 36px; border-radius: 50%; background: var(--blue-100); color: var(--blue); display: grid; place-items: center; font-weight: 700; flex: none; font-size: 14px; }
.rv .txt { font-size: 13.5px; color: var(--text); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 2px; }
.rv .meta { font-size: 12px; color: var(--text-3); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.detail { position: sticky; top: 76px; }
.quote { font-size: 15px; line-height: 1.6; padding: 14px 16px; background: var(--surface-2); border-radius: var(--radius-sm); border-left: 3px solid var(--border-strong); white-space: pre-wrap; }
.reply-box { border: 1px solid var(--border-strong); border-radius: var(--radius); overflow: hidden; }
.reply-box .bar { display: flex; gap: 6px; align-items: center; padding: 8px 10px; background: var(--surface-2); border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.reply-box textarea { border: 0; border-radius: 0; min-height: 150px; box-shadow: none !important; }
.flags { background: var(--amber-bg); color: var(--amber); padding: 10px 12px; font-size: 12.5px; border-top: 1px solid var(--border); }
.flags ul { margin: 4px 0 0; padding-left: 18px; }
.timeline { font-size: 12.5px; color: var(--text-2); }
.timeline .t { padding: 8px 0; border-bottom: 1px dashed var(--border); }
.published-reply { background: var(--green-bg); border-radius: var(--radius-sm); padding: 12px 14px; font-size: 13.5px; white-space: pre-wrap; }

/* charts */
.chart { width: 100%; height: auto; display: block; }
.chart text { fill: var(--text-2); font-size: 12px; font-family: var(--font); }
.chart .grid line { stroke: var(--border); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.bars-h .r { display: grid; grid-template-columns: 54px 1fr 44px; gap: 10px; align-items: center; font-size: 12.5px; margin-bottom: 8px; }
.bars-h .track { height: 10px; background: var(--surface-2); border-radius: 999px; overflow: hidden; border: 1px solid var(--border); }
.bars-h .fill { height: 100%; background: var(--blue); border-radius: 999px; }

/* checklist */
.checklist .ci { display: flex; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13.5px; }
.checklist .ci:last-child { border-bottom: 0; }
.checklist .tick { width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--border-strong); display: grid; place-items: center; font-size: 11px; flex: none; }
.checklist .done .tick { background: var(--green); border-color: var(--green); color: #fff; }
.checklist .done span.l { color: var(--text-3); text-decoration: line-through; }

/* plans */
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.plan { padding: 22px; display: flex; flex-direction: column; gap: 10px; position: relative; }
.plan.current { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(37,99,235,.12); }
.plan .price { font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.plan .price small { font-size: 13px; font-weight: 500; }
.plan ul { list-style: none; padding: 0; margin: 4px 0 8px; font-size: 13px; color: var(--text-2); flex: 1; }
.plan li { padding: 4px 0 4px 22px; position: relative; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--green); font-weight: 700; }
.plan .ribbon { position: absolute; top: -10px; right: 16px; }
.meter { height: 8px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.meter > div { height: 100%; background: var(--blue); }
.meter.hot > div { background: var(--amber); }

/* calendar */
.cal { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border-left: 1px solid var(--border); border-top: 1px solid var(--border); }
.cal .dow { font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--text-2); padding: 8px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); background: var(--surface-2); }
.cal .day { min-height: 104px; padding: 6px; border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); font-size: 12px; cursor: pointer; }
.cal .day:hover { background: var(--surface-2); }
.cal .day.other { background: var(--surface-2); color: var(--text-3); }
.cal .day.today .n { background: var(--blue); color: #fff; border-radius: 999px; padding: 0 6px; }
.cal .ev { margin-top: 4px; padding: 3px 6px; border-radius: 6px; font-size: 11.5px; background: var(--blue-50); color: var(--blue); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; cursor: pointer; }
.cal .ev.published, .cal .ev.exported { background: var(--green-bg); color: var(--green); }
.cal .ev.failed { background: var(--red-bg); color: var(--red); }
.cal .ev.draft, .cal .ev.pending_approval { background: var(--surface-2); color: var(--text-2); border: 1px dashed var(--border-strong); }

/* modal & toast */
.overlay { position: fixed; inset: 0; background: rgba(7,13,34,.55); display: grid; place-items: center; z-index: 100; padding: 20px; animation: fade .15s; }
.modal { background: var(--surface); border-radius: 14px; width: min(560px, 100%); max-height: calc(100vh - 40px); display: flex; flex-direction: column; box-shadow: var(--shadow-lg); animation: pop .18s ease-out; }
.modal.wide { width: min(820px, 100%); }
.modal .mh { padding: 18px 22px; border-bottom: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.modal .mh h2 { margin: 0; font-size: 17px; }
.modal .mb { padding: 20px 22px; overflow-y: auto; }
.modal .mf { padding: 14px 22px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 8px; background: var(--surface-2); border-radius: 0 0 14px 14px; }
.toasts { position: fixed; bottom: 20px; right: 20px; display: flex; flex-direction: column; gap: 8px; z-index: 200; max-width: min(420px, calc(100vw - 40px)); }
.toast { background: var(--navy-900); color: #fff; padding: 12px 16px; border-radius: 10px; box-shadow: var(--shadow-lg); font-size: 13.5px; display: flex; gap: 10px; align-items: flex-start; animation: slide .2s ease-out; }
.toast.error { background: #991b1b; } .toast.success { background: #065f46; } .toast.warn { background: #92400e; }
@keyframes fade { from { opacity: 0; } } @keyframes pop { from { transform: scale(.97); opacity: 0; } } @keyframes slide { from { transform: translateY(10px); opacity: 0; } }
.spinner { width: 22px; height: 22px; border: 3px solid var(--border); border-top-color: var(--blue); border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading { display: grid; place-items: center; padding: 60px; }
.skeleton { background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2)); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 6px; height: 14px; }
@keyframes sk { to { background-position: -200% 0; } }

/* ---------- public site ---------- */
.pub-nav { position: sticky; top: 0; z-index: 30; background: rgba(255,255,255,.85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
[data-theme="dark"] .pub-nav { background: rgba(10,16,32,.85); }
.pub-nav .in { max-width: 1180px; margin: 0 auto; display: flex; align-items: center; gap: 24px; height: 66px; padding: 0 24px; }
.pub-nav .brand { padding: 0; color: var(--text); }
.pub-nav .links { display: flex; gap: 22px; flex: 1; }
.pub-nav .links a { color: var(--text-2); font-weight: 500; }
.pub-nav .links a.active, .pub-nav .links a:hover { color: var(--text); text-decoration: none; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.hero { background: radial-gradient(1200px 500px at 70% -10%, rgba(37,99,235,.35), transparent 60%), linear-gradient(180deg, var(--navy-950), var(--navy-900)); color: #fff; padding: 88px 0 96px; overflow: hidden; }
.hero .in { display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero h1 { font-size: 52px; line-height: 1.05; letter-spacing: -.03em; margin-bottom: 18px; }
.hero h1 span { background: linear-gradient(90deg, #60a5fa, #a78bfa); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 18px; color: #b9c5e0; max-width: 520px; margin-bottom: 28px; }
.hero .eyebrow { display: inline-flex; gap: 8px; align-items: center; padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); font-size: 12.5px; color: #c7d2ea; margin-bottom: 20px; }
.hero .btn { border: 0; }
.hero .btn-ghost-light { background: rgba(255,255,255,.08); color: #fff; border: 1px solid rgba(255,255,255,.2); }
.hero-card { background: #fff; color: var(--text); border-radius: 16px; box-shadow: 0 40px 80px -30px rgba(0,0,0,.6); padding: 18px; transform: rotate(-1deg); }
[data-theme="dark"] .hero-card { background: var(--surface); }
.hero-card .rv { cursor: default; border-radius: 10px; border: 1px solid var(--border); margin-bottom: 10px; }
.hero-card .ai { background: var(--blue-50); border-radius: 10px; padding: 12px; font-size: 13px; margin-top: 6px; }
.section { padding: 80px 0; }
.section.alt { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section h2.big { font-size: 34px; letter-spacing: -.02em; text-align: center; margin-bottom: 10px; }
.section p.sub { text-align: center; color: var(--text-2); max-width: 620px; margin: 0 auto 44px; font-size: 16px; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feature { padding: 24px; }
.feature .fi { width: 42px; height: 42px; border-radius: 10px; background: var(--blue-50); display: grid; place-items: center; font-size: 20px; margin-bottom: 14px; }
.feature p { color: var(--text-2); margin: 0; }
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; counter-reset: s; }
.step { padding: 22px; position: relative; }
.step::before { counter-increment: s; content: counter(s); width: 30px; height: 30px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; font-weight: 700; margin-bottom: 12px; }
.cta { background: linear-gradient(135deg, var(--blue), #4f46e5); color: #fff; border-radius: 20px; padding: 48px; display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.cta h2 { font-size: 28px; margin: 0 0 6px; }
.cta .btn { background: #fff; color: var(--blue); border: 0; }
.footer { padding: 40px 0; border-top: 1px solid var(--border); color: var(--text-2); font-size: 13px; }
.footer .in { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer a { color: var(--text-2); margin-right: 16px; }
.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: radial-gradient(800px 400px at 20% 0%, rgba(37,99,235,.35), transparent 60%), var(--navy-950); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side .brand { padding: 0; }
.auth-side blockquote { font-size: 22px; line-height: 1.4; margin: 0; max-width: 460px; letter-spacing: -.01em; }
.auth-main { display: grid; place-items: center; padding: 40px 24px; }
.auth-box { width: min(420px, 100%); }
.auth-box h1 { font-size: 26px; }
.prose { max-width: 760px; margin: 0 auto; padding: 56px 24px; }
.prose h1 { font-size: 34px; } .prose h2 { margin-top: 28px; } .prose p, .prose li { color: var(--text-2); font-size: 15px; }
.pricing-toggle { display: flex; justify-content: center; margin-bottom: 28px; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .inbox { grid-template-columns: 1fr; }
  .detail { position: static; }
  .cols-main { grid-template-columns: 1fr; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: var(--sidebar-w); z-index: 60; transform: translateX(-100%); transition: transform .2s; }
  .shell.nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
  .shell.nav-open::after { content: ""; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 55; }
  .menu-btn { display: inline-flex; }
  .content { padding: 16px; }
  .topbar { padding: 0 12px; }
  .cols-2, .cols-3, .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .hero .in { grid-template-columns: 1fr; }
  .hero h1 { font-size: 38px; }
  .hero-card { transform: none; }
  .pub-nav .links { display: none; }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .features, .steps { grid-template-columns: 1fr; }
  .cal .day { min-height: 70px; }
  .topbar .crumbs { display: none; }
  .hide-sm { display: none !important; }
}
@media (max-width: 520px) { .kpis { grid-template-columns: 1fr 1fr; } .kpi .value { font-size: 22px; } .kpi { padding: 14px; } }
@media print { .sidebar, .topbar, .banner { display: none; } .shell { display: block; } }

/* =====================================================================
   Marketing website v2 — sections & motion
   ===================================================================== */
.ico { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pub-nav { transition: box-shadow .25s, background .25s; }
.pub-nav.scrolled { box-shadow: 0 8px 30px -18px rgba(15,23,42,.35); }
.pub-nav .in { gap: 18px; }
.pub-nav .spacer { flex: 1; }
.pub-nav .links { flex: none; margin-left: 12px; }
.pub-nav .links a { position: relative; padding: 6px 0; }
.pub-nav .links a::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; background: var(--blue); transform: scaleX(0); transition: transform .25s; transform-origin: left; }
.pub-nav .links a:hover::after, .pub-nav .links a.active::after { transform: scaleX(1); }
.pub-menu { display: none; }

/* hero */
.hero { position: relative; padding: 96px 0 110px; isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: .35;
  background-image: linear-gradient(rgba(255,255,255,.06) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 44px 44px; mask-image: radial-gradient(ellipse at 60% 30%, #000 30%, transparent 75%); }
.orbs { position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.orb { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .55; animation: drift 18s ease-in-out infinite alternate; }
.o1 { width: 420px; height: 420px; background: #2563eb; top: -120px; right: 8%; }
.o2 { width: 320px; height: 320px; background: #7c3aed; bottom: -140px; right: 34%; animation-duration: 22s; opacity: .4; }
.o3 { width: 260px; height: 260px; background: #0ea5e9; top: 30%; left: -100px; animation-duration: 26s; opacity: .3; }
@keyframes drift { to { transform: translate(40px, 30px) scale(1.08); } }
.hero h1 { font-size: clamp(38px, 5.2vw, 60px); }
.hero .eyebrow .dot { width: 7px; height: 7px; }
.trust { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 26px; color: #9fb0d4; font-size: 13.5px; }
.rise { opacity: 0; transform: translateY(18px); animation: rise .8s cubic-bezier(.2,.7,.2,1) forwards; animation-delay: var(--d, 0ms); }
@keyframes rise { to { opacity: 1; transform: none; } }
.shine { position: relative; overflow: hidden; }
.shine::after { content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.35), transparent); animation: shine 3.8s ease-in-out infinite; }
@keyframes shine { 0%, 60% { left: -60%; } 100% { left: 130%; } }
.btn-primary { transition: transform .15s, box-shadow .2s, background .15s; }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -10px rgba(37,99,235,.7); }
.hero-visual { perspective: 1200px; }
.hero-card { transform: rotateY(-6deg) rotateX(3deg); transition: transform .6s; min-height: 370px; animation: floaty 7s ease-in-out infinite; }
.hero-visual:hover .hero-card { transform: none; animation-play-state: paused; }
@keyframes floaty { 50% { translate: 0 -8px; } }
.hc-top { margin-bottom: 12px; }
.hc-review { display: flex; gap: 12px; padding: 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.hc-review .av { width: 38px; height: 38px; border-radius: 50%; background: var(--blue-100); color: var(--blue); display: grid; place-items: center; font-weight: 700; flex: none; }
.hc-review .txt { font-size: 13.5px; margin-top: 2px; }
.hc-review .meta { margin-top: 6px; display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--text-3); }
.hc-ai { margin-top: 12px; background: var(--blue-50); border: 1px solid var(--blue-100); border-radius: 12px; padding: 12px 14px; font-size: 13.5px; min-height: 118px; }
.hc-ai .typed { margin-top: 6px; white-space: pre-wrap; }
.hc-ai:not(.done) .typed::after { content: "▍"; color: var(--blue); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.dots i { display: inline-block; width: 5px; height: 5px; margin-left: 3px; border-radius: 50%; background: var(--blue); animation: bounce 1s infinite; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
.hc-ai.done .dots { display: none; }
@keyframes bounce { 50% { transform: translateY(-4px); opacity: .5; } }
.hc-status { display: flex; gap: 8px; flex-wrap: wrap; min-height: 34px; margin-top: 12px; }
.chip { display: inline-flex; align-items: center; padding: 6px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; background: var(--violet-bg); color: var(--violet); }
.chip.ok { background: var(--green-bg); color: var(--green); }
.pop-in { animation: popin .45s cubic-bezier(.2,.9,.3,1.3) both; }
@keyframes popin { from { opacity: 0; transform: translateY(8px) scale(.96); } }

/* stats */
.stats-band { background: var(--navy-900); color: #fff; border-top: 1px solid rgba(255,255,255,.06); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding: 34px 24px; }
.stat { text-align: center; }
.stat b { display: block; font-size: 38px; font-weight: 800; letter-spacing: -.02em; background: linear-gradient(90deg, #93c5fd, #c4b5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { color: #9fb0d4; font-size: 14px; }

/* sections */
.section-head { text-align: center; margin-bottom: 44px; }
.section-head .sub { margin-bottom: 0; }
.eyebrow.dark { display: inline-block; font-size: 13px; font-weight: 600; color: var(--blue); background: var(--blue-50); padding: 5px 12px; border-radius: 999px; margin-bottom: 14px; }
.section h2.big.left { text-align: left; }
.lead-dark { font-size: 16.5px; line-height: 1.65; }
.feature { transition: transform .25s, box-shadow .25s, border-color .25s; }
.feature:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--blue-100); }
.feature .fi { color: var(--blue); transition: transform .3s; }
.feature:hover .fi { transform: scale(1.08) rotate(-4deg); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.ticks { list-style: none; padding: 0; margin: 18px 0 0; }
.ticks li { padding: 7px 0 7px 30px; position: relative; font-size: 15px; }
.ticks li::before { content: "✓"; position: absolute; left: 0; top: 6px; width: 20px; height: 20px; border-radius: 50%; background: var(--green-bg); color: var(--green); display: grid; place-items: center; font-size: 12px; font-weight: 700; }
.studio-mock, .analytics-mock { padding: 22px; box-shadow: var(--shadow); }
.seg-chip { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border-strong); font-size: 12.5px; color: var(--text-2); }
.seg-chip.on { background: var(--blue); color: #fff; border-color: var(--blue); }
.safety { display: flex; gap: 8px; align-items: center; margin-top: 12px; font-size: 13px; color: var(--green); }
.safety .ico { width: 18px; height: 18px; }
.timeline-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; position: relative; }
.timeline-steps::before { content: ""; position: absolute; top: 22px; left: 8%; right: 8%; height: 2px; background: linear-gradient(90deg, var(--blue), #7c3aed); opacity: .25; }
.tstep { position: relative; padding: 0 6px; text-align: center; }
.tstep .num { width: 46px; height: 46px; border-radius: 50%; margin: 0 auto 14px; display: grid; place-items: center; font-weight: 800; color: #fff; background: linear-gradient(135deg, #3b82f6, #4f46e5); box-shadow: 0 0 0 6px var(--bg), 0 10px 20px -8px rgba(37,99,235,.6); position: relative; }
.section.alt .tstep .num { box-shadow: 0 0 0 6px var(--surface), 0 10px 20px -8px rgba(37,99,235,.6); }
.grow-bars { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; align-items: end; height: 210px; margin-top: 20px; }
.gb { position: relative; height: 0; background: linear-gradient(180deg, #60a5fa, #2563eb); border-radius: 8px 8px 4px 4px; transition: height 1s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d); }
.grow-bars.in .gb { height: var(--h); }
.gb span { position: absolute; bottom: -22px; left: 0; right: 0; text-align: center; font-size: 12px; color: var(--text-2); }
.analytics-mock .grow-bars { margin-bottom: 26px; }
.industries { padding-bottom: 70px; }
.industries h2 { text-align: center; margin-bottom: 28px !important; }
.marquee { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee .track { display: flex; gap: 12px; width: max-content; animation: marquee 40s linear infinite; }
.marquee:hover .track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }
.pill { padding: 10px 18px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); font-weight: 500; white-space: nowrap; }
.faq-wrap { display: grid; grid-template-columns: 1fr 1.6fr; gap: 48px; align-items: start; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; margin-bottom: 10px; padding: 0 18px; transition: box-shadow .2s; }
.faq details[open] { box-shadow: var(--shadow); }
.faq summary { cursor: pointer; padding: 16px 0; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 20px; line-height: 1; color: var(--blue); transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { color: var(--text-2); margin: 0 0 16px; }
.cta { position: relative; overflow: hidden; }
.cta::after { content: ""; position: absolute; width: 360px; height: 360px; border-radius: 50%; right: -120px; top: -160px; background: rgba(255,255,255,.12); animation: drift 14s ease-in-out infinite alternate; }
.page-hero { background: radial-gradient(900px 340px at 75% -10%, rgba(37,99,235,.35), transparent 60%), linear-gradient(180deg, var(--navy-950), var(--navy-900)); color: #fff; padding: 72px 0 64px; }
.page-hero h1 { font-size: clamp(32px, 4.2vw, 48px); letter-spacing: -.02em; max-width: 760px; }
.page-hero .lead { color: #b9c5e0; font-size: 17px; max-width: 620px; margin: 0; }
.page-hero .eyebrow { display: inline-block; padding: 5px 12px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); font-size: 13px; color: #c7d2ea; margin-bottom: 16px; }
.contact-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 24px; align-items: start; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 28px; }
.footer h4 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); margin: 6px 0 12px; }
.footer-grid a { display: inline-block; padding: 4px 0; color: var(--text-2); }
.footer-bottom { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); font-size: 12.5px; color: var(--text-3); }

/* scroll reveal */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0ms); }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 960px) {
  .split, .faq-wrap, .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .timeline-steps { grid-template-columns: 1fr 1fr; } .timeline-steps::before { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero-card { transform: none; }
}
@media (max-width: 860px) {
  .pub-menu { display: inline-flex; }
  .pub-nav.open .links { display: flex; position: absolute; top: 66px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 24px 16px; margin: 0; box-shadow: var(--shadow); }
  .pub-nav.open .links a { padding: 12px 0; border-bottom: 1px solid var(--border); }
  .stats { grid-template-columns: 1fr 1fr; }
  .hero { padding: 64px 0 72px; }
}
@media (max-width: 560px) { .timeline-steps { grid-template-columns: 1fr; } .footer-grid { grid-template-columns: 1fr; } .stat b { font-size: 30px; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
  .reveal, .rise { opacity: 1; transform: none; }
}
