/* ==========================================================================
   Site CMS design system: blue & white enterprise theme
   ========================================================================== */
:root {
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* brand */
  --accent: #2f6fed;
  --accent-hover: #2459cc;
  --accent-soft: #eaf1ff;
  --accent-ring: rgba(47, 111, 237, 0.25);
  --navy: #0b1f44;
  --navy-2: #12295a;
  --navy-line: rgba(255, 255, 255, 0.08);
  --navy-text: #b8c5e2;
  --navy-muted: #7387b3;

  /* neutrals */
  --ink: #0f172a;
  --ink-2: #3c4a63;
  --muted: #6b7a93;
  --line: #e3e8f1;
  --line-2: #eef2f8;
  --bg: #f4f7fc;
  --card: #ffffff;

  /* status (reserved: never used for data series) */
  --ok: #138a4b;
  --ok-soft: #e4f6ec;
  --warn: #a35f00;
  --warn-soft: #fff3df;
  --danger: #c62f2f;
  --danger-soft: #fdeaea;
  --info-soft: #eaf1ff;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.05), 0 1px 3px rgba(15, 23, 42, 0.06);
  --shadow-lg: 0 18px 50px rgba(15, 23, 42, 0.18);
  --sidebar-w: 256px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { font: 14px/1.5 var(--font); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.25; margin: 0 0 10px; letter-spacing: -0.01em; }
h1 { font-size: 24px; font-weight: 700; }
h2 { font-size: 16px; font-weight: 650; }
h3 { font-size: 14px; font-weight: 650; }
p { margin: 0 0 12px; }
code, pre, .mono { font-family: var(--mono); font-size: 12.5px; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent-ring); outline-offset: 1px; }
.muted { color: var(--muted); }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ==========================================================================
   App shell
   ========================================================================== */
.app { display: grid; grid-template-columns: var(--sidebar-w) 1fr; min-height: 100vh; }

.sidebar {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: linear-gradient(180deg, var(--navy) 0%, #0d2552 100%);
  color: var(--navy-text); display: flex; flex-direction: column; z-index: 20;
}
.sb-brand { display: flex; align-items: center; gap: 10px; padding: 18px 20px 14px; color: #fff; font-weight: 700; font-size: 16px; }
.sb-brand .logo { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); display: grid; place-items: center; font-size: 15px; box-shadow: 0 4px 12px rgba(47, 111, 237, 0.45); }
.sb-brand small { display: block; font-weight: 500; font-size: 11px; color: var(--navy-muted); letter-spacing: 0.04em; text-transform: uppercase; }

.site-switch { margin: 4px 14px 10px; position: relative; }
.site-switch > button {
  width: 100%; display: flex; align-items: center; gap: 10px; text-align: left; cursor: pointer;
  background: rgba(255, 255, 255, 0.06); border: 1px solid var(--navy-line); color: #fff;
  border-radius: 10px; padding: 9px 10px; font: inherit;
}
.site-switch > button:hover { background: rgba(255, 255, 255, 0.1); }
.site-switch .fav { width: 28px; height: 28px; border-radius: 7px; background: #fff; color: var(--navy); display: grid; place-items: center; font-weight: 700; flex: none; }
.site-switch .nm { flex: 1; min-width: 0; }
.site-switch .nm b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-switch .nm span { display: block; font-size: 11.5px; color: var(--navy-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-menu {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); background: #fff; color: var(--ink);
  border-radius: 10px; box-shadow: var(--shadow-lg); padding: 6px; z-index: 50; max-height: 360px; overflow: auto;
}
.site-menu a { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 7px; color: var(--ink); text-decoration: none; }
.site-menu a:hover, .site-menu a.on { background: var(--accent-soft); }
.site-menu a small { color: var(--muted); margin-left: auto; font-size: 11px; }
.site-menu hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0; }

.sb-nav { padding: 6px 10px 16px; flex: 1; }
.sb-group { margin-top: 14px; }
.sb-label { padding: 0 12px 6px; font-size: 10.5px; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase; color: var(--navy-muted); }
.sb-nav a {
  position: relative; display: flex; align-items: center; gap: 11px; padding: 8px 12px; margin: 1px 0;
  color: var(--navy-text); border-radius: 8px; font-weight: 500; text-decoration: none;
}
.sb-nav a svg { width: 18px; height: 18px; flex: none; opacity: 0.85; }
.sb-nav a:hover { background: rgba(255, 255, 255, 0.06); color: #fff; }
.sb-nav a.on { background: rgba(91, 140, 255, 0.18); color: #fff; }
.sb-nav a.on::before { content: ""; position: absolute; left: -10px; top: 8px; bottom: 8px; width: 3px; border-radius: 0 3px 3px 0; background: #6d9bff; }
.sb-nav a .pill { margin-left: auto; font-size: 11px; background: rgba(255, 255, 255, 0.12); color: #fff; border-radius: 10px; padding: 0 7px; line-height: 18px; }
.sb-nav a .pill.alert { background: var(--danger); }

.sb-foot { border-top: 1px solid var(--navy-line); padding: 12px 14px; display: flex; align-items: center; gap: 10px; }
.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.sb-foot .who { flex: 1; min-width: 0; font-size: 12.5px; }
.sb-foot .who b { display: block; color: #fff; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sb-foot .who span { color: var(--navy-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
.sb-foot button { background: none; border: 0; color: var(--navy-text); cursor: pointer; padding: 6px; border-radius: 6px; }
.sb-foot button:hover { background: rgba(255, 255, 255, 0.08); color: #fff; }
.sb-foot svg { width: 18px; height: 18px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  position: sticky; top: 0; z-index: 15; height: 60px; background: rgba(255, 255, 255, 0.92); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 14px; padding: 0 28px;
}
.topbar .menu-btn { display: none; }
.crumbs { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; min-width: 0; }
.crumbs b { color: var(--ink); font-weight: 600; }
.crumbs .sep { opacity: 0.5; }
.topbar .spacer { flex: 1; }
.content { padding: 26px 28px 60px; max-width: 1320px; width: 100%; }

/* ==========================================================================
   Page header
   ========================================================================== */
.page-head { display: flex; align-items: flex-end; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head .titles { flex: 1; min-width: 240px; }
.page-head .eyebrow { font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.page-head h1 { margin: 0; }
.page-head p { margin: 6px 0 0; color: var(--muted); max-width: 760px; }
.page-head .actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

/* ==========================================================================
   Cards, grids
   ========================================================================== */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 18px; }
.card-head { display: flex; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--line-2); }
.card-head h2 { margin: 0; flex: 1; }
.card-head .sub { color: var(--muted); font-size: 12.5px; font-weight: 400; display: block; margin-top: 2px; }
.card-body { padding: 18px 20px; }
.card-body.flush { padding: 0; }
.card-foot { padding: 12px 20px; border-top: 1px solid var(--line-2); background: #fafbfe; border-radius: 0 0 var(--radius) var(--radius); display: flex; gap: 8px; align-items: center; }
.grid { display: grid; gap: 18px; }
.grid.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.c-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.grid > .card { margin-bottom: 0; }
.stack > * + * { margin-top: 18px; }

/* ==========================================================================
   KPI tiles
   ========================================================================== */
.kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.kpi::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--accent); opacity: 0; }
.kpi.primary::after { opacity: 1; }
.kpi .k { color: var(--muted); font-size: 12.5px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.kpi .v { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.kpi .d { font-size: 12px; margin-top: 4px; color: var(--muted); display: flex; gap: 6px; align-items: center; }
.delta { font-weight: 600; border-radius: 6px; padding: 1px 6px; font-size: 11.5px; }
.delta.up { color: var(--ok); background: var(--ok-soft); }
.delta.down { color: var(--danger); background: var(--danger-soft); }
.delta.flat { color: var(--muted); background: var(--line-2); }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 36px; padding: 0 14px;
  border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 8px; font: inherit; font-weight: 550;
  cursor: pointer; white-space: nowrap; text-decoration: none !important; transition: background 0.12s, border-color 0.12s;
}
.btn:hover { background: #f6f8fc; border-color: #d3dbea; }
.btn svg { width: 16px; height: 16px; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 1px 2px rgba(47, 111, 237, 0.4); }
.btn.primary:hover { background: var(--accent-hover); }
.btn.danger { color: var(--danger); }
.btn.danger:hover { background: var(--danger-soft); border-color: #f3c6c6; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--line-2); }
.btn.small { height: 30px; padding: 0 10px; font-size: 13px; }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; }
.btn.brand-google { background: #fff; }
.btn.brand-ms { background: #fff; }

.seg { display: inline-flex; background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 3px; gap: 2px; }
.seg a, .seg button { border: 0; background: none; font: inherit; padding: 5px 12px; border-radius: 6px; color: var(--ink-2); font-size: 13px; font-weight: 550; cursor: pointer; text-decoration: none; }
.seg a:hover, .seg button:hover { background: var(--line-2); }
.seg .on { background: var(--accent); color: #fff !important; }

/* ==========================================================================
   Forms
   ========================================================================== */
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field > label, .field > .lbl { font-weight: 600; font-size: 13px; color: var(--ink); }
.help { font-size: 12.5px; color: var(--muted); }
.input {
  width: 100%; height: 38px; font: inherit; padding: 0 12px; border: 1px solid #cfd7e5; border-radius: 8px;
  background: #fff; color: var(--ink); transition: border-color 0.12s, box-shadow 0.12s;
}
textarea.input { height: auto; min-height: 84px; padding: 10px 12px; resize: vertical; }
select.input { padding-right: 32px; }
.input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.input[readonly] { background: #f7f9fc; }
.input.mono { font-family: var(--mono); font-size: 13px; }
.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.row-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

.choice { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; margin-bottom: 8px; transition: border-color 0.12s, background 0.12s; }
.choice:hover { border-color: #c7d3ea; }
.choice:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.choice input { margin-top: 3px; accent-color: var(--accent); }
.choice strong { display: block; font-weight: 600; }
.choice .help { display: block; }

/* toggle switch */
.switch-row { display: flex; gap: 14px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--line-2); }
.switch-row:last-child { border-bottom: 0; }
.switch-row .txt { flex: 1; }
.switch-row .txt strong { display: block; font-weight: 600; }
.switch { position: relative; width: 40px; height: 22px; flex: none; margin-top: 1px; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; background: #cbd5e5; border-radius: 22px; transition: background 0.15s; }
.switch span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); transition: transform 0.15s; }
.switch input:checked + span { background: var(--accent); }
.switch input:checked + span::after { transform: translateX(18px); }
.switch input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-ring); }

/* ==========================================================================
   Callouts, badges, alerts
   ========================================================================== */
.alert, .callout { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; font-size: 13.5px; margin-bottom: 16px; }
.alert svg, .callout svg { width: 18px; height: 18px; flex: none; margin-top: 1px; }
.alert.err, .callout.err { background: var(--danger-soft); color: #8e1f1f; }
.alert.ok, .callout.ok { background: var(--ok-soft); color: #0e5c33; }
.callout.info { background: var(--info-soft); color: #1d3f8f; }
.callout.warn { background: var(--warn-soft); color: #6b3f00; }
.callout b { font-weight: 650; }
.callout code { background: rgba(255, 255, 255, 0.6); padding: 1px 5px; border-radius: 4px; }

.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 2px 8px; border-radius: 20px; background: var(--line-2); color: var(--ink-2); white-space: nowrap; line-height: 18px; }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: 0.8; }
.badge.plain::before { display: none; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.err { background: var(--danger-soft); color: var(--danger); }
.badge.info { background: var(--accent-soft); color: var(--accent); }
.badge.neutral { background: var(--line-2); color: var(--muted); }
.tag { display: inline-block; font-family: var(--mono); font-size: 11.5px; background: var(--line-2); color: var(--ink-2); padding: 1px 6px; border-radius: 5px; margin: 0 4px 2px 0; }

/* ==========================================================================
   Tables
   ========================================================================== */
.table-wrap { overflow-x: auto; }
table.t { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.t th { text-align: left; font-size: 11.5px; font-weight: 650; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); padding: 10px 16px; background: #f8fafd; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.t td { padding: 11px 16px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr.click { cursor: pointer; }
table.t tbody tr.click:hover td { background: #f7faff; }
table.t .num, table.t th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.t td.barcell { width: 28%; min-width: 110px; }
.hbar { height: 8px; background: var(--accent); border-radius: 0 4px 4px 0; min-width: 2px; }
.cell-2 b { display: block; font-weight: 600; }
.cell-2 span { display: block; color: var(--muted); font-size: 12.5px; }
.empty { text-align: center; padding: 44px 20px; color: var(--muted); }
.empty svg { width: 36px; height: 36px; color: #b3c0d8; margin-bottom: 8px; }
.empty h3 { color: var(--ink); margin-bottom: 4px; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 14px 20px; border-bottom: 1px solid var(--line-2); }
.toolbar .input { height: 34px; width: auto; }
.toolbar .search { position: relative; flex: 1; min-width: 200px; max-width: 360px; }
.toolbar .search svg { position: absolute; left: 10px; top: 9px; width: 16px; height: 16px; color: var(--muted); }
.toolbar .search .input { width: 100%; padding-left: 34px; }
.pager { display: flex; gap: 8px; align-items: center; justify-content: flex-end; padding: 12px 20px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--line-2); }

/* platform dots in tables */
.pdots { display: inline-flex; gap: 4px; }
.pdot { width: 22px; height: 22px; border-radius: 6px; display: grid; place-items: center; font-size: 10px; font-weight: 800; color: #fff; }
.pdot.sent { background: var(--ok); }
.pdot.pending { background: #e2a23b; }
.pdot.failed { background: var(--danger); }
.pdot.skipped { background: #c3cbd9; }

/* ==========================================================================
   Charts (single series, one hue, recessive grid; hover tooltip per bar)
   ========================================================================== */
.chart { position: relative; padding-left: 40px; }
.chart .ymax, .chart .ymid { position: absolute; left: 0; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.chart .ymax { top: -7px; }
.chart .ymid { top: calc(50% - 7px); }
.bars { display: flex; align-items: flex-end; gap: 2px; height: 180px; border-bottom: 1px solid #d6deeb;
  background: linear-gradient(to bottom, var(--line-2) 1px, transparent 1px) 0 0 / 100% 50%; }
.bars.short { height: 110px; }
.bar-col { flex: 1; height: 100%; display: flex; align-items: flex-end; outline: none; cursor: default; }
.bar { width: 100%; max-width: 26px; margin: 0 auto; background: var(--accent); border-radius: 4px 4px 0 0; min-height: 2px; }
.bar.zero { background: #dbe3f1; }
.bar-col:hover .bar, .bar-col:focus .bar { background: var(--accent-hover); }
.x-axis { display: flex; justify-content: space-between; font-size: 11px; color: var(--muted); margin: 6px 0 0 40px; }
.viz-tip { position: absolute; top: -10px; width: 150px; background: var(--ink); color: #fff; font-size: 12.5px; padding: 8px 10px; border-radius: 8px; pointer-events: none; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2); z-index: 2; }
.viz-tip .tk { color: #aab6cc; font-size: 11.5px; }

/* ==========================================================================
   Platform cards, steps
   ========================================================================== */
.platform-card { display: flex; flex-direction: column; }
.platform-card .card-body { flex: 1; }
.p-logo { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; color: #fff; font-size: 15px; flex: none; }
.p-logo.google_ads { background: linear-gradient(135deg, #4285f4, #34a853); }
.p-logo.microsoft_ads { background: linear-gradient(135deg, #00a4ef, #7fba00); }
.p-logo.meta { background: linear-gradient(135deg, #0866ff, #7b5cff); }
.p-head { display: flex; gap: 12px; align-items: center; }
.p-head h2 { margin: 0; }
.p-stats { display: flex; gap: 18px; margin: 14px 0 4px; }
.p-stats div { font-size: 12px; color: var(--muted); }
.p-stats b { display: block; font-size: 20px; color: var(--ink); font-variant-numeric: tabular-nums; }

.steps-list { counter-reset: step; }
.step { display: grid; grid-template-columns: 34px 1fr; gap: 14px; padding: 18px 20px; border-bottom: 1px solid var(--line-2); }
.step:last-child { border-bottom: 0; }
.step .num { counter-increment: step; width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; font-weight: 700; color: var(--muted); font-size: 13px; }
.step .num::before { content: counter(step); }
.step.done .num { background: var(--ok); border-color: var(--ok); color: #fff; }
.step.done .num::before { content: "✓"; }
.step h3 { margin: 4px 0 4px; font-size: 15px; }
.step > div > p.help { margin-bottom: 14px; }

.code {
  position: relative; background: #0d1b36; color: #dbe6ff; border-radius: 10px; padding: 14px 16px; padding-right: 86px;
  font-family: var(--mono); font-size: 12.5px; white-space: pre-wrap; word-break: break-all; line-height: 1.6;
}
.code .copy { position: absolute; top: 9px; right: 9px; height: 28px; background: rgba(255, 255, 255, 0.12); border-color: transparent; color: #fff; }
.code .copy:hover { background: rgba(255, 255, 255, 0.2); }

.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; }
.checklist .ic { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; flex: none; font-size: 12px; font-weight: 800; }
.checklist .ic.ok { background: var(--ok-soft); color: var(--ok); }
.checklist .ic.no { background: var(--line-2); color: var(--muted); }

/* ==========================================================================
   Drawer + dialog + toast
   ========================================================================== */
.drawer-back { position: fixed; inset: 0; background: rgba(11, 31, 68, 0.35); z-index: 60; animation: fade 0.15s ease; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100vw); background: #fff; z-index: 61;
  box-shadow: var(--shadow-lg); display: flex; flex-direction: column; animation: slide 0.2s ease;
}
.drawer-head { display: flex; align-items: flex-start; gap: 12px; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { margin: 0; font-size: 18px; }
.drawer-head .sub { color: var(--muted); font-size: 13px; }
.drawer-head .x { margin-left: auto; }
.drawer-body { flex: 1; overflow-y: auto; padding: 18px 22px; }
.drawer-section { margin-bottom: 22px; }
.drawer-section > h3 { font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); margin-bottom: 10px; }
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 7px 14px; font-size: 13.5px; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; word-break: break-word; white-space: pre-wrap; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 16px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 12px 12px; font-size: 13px; }
.timeline li::before { content: ""; position: absolute; left: -22px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: #fff; border: 2px solid var(--accent); }
.timeline li.lead::before { background: var(--ok); border-color: var(--ok); }
.timeline time { color: var(--muted); font-size: 12px; margin-left: 6px; }
@keyframes fade { from { opacity: 0; } }
@keyframes slide { from { transform: translateX(30px); opacity: 0; } }

dialog.modal { border: 0; border-radius: 14px; padding: 0; width: min(520px, 94vw); box-shadow: var(--shadow-lg); }
dialog.modal::backdrop { background: rgba(11, 31, 68, 0.45); }
dialog.modal form { padding: 22px; }
dialog.modal h2 { font-size: 18px; margin-bottom: 14px; }

.toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 10px; box-shadow: var(--shadow-lg); z-index: 100; font-weight: 500; animation: fade 0.2s ease; }
.toast.err { background: var(--danger); }

.loading { padding: 60px; text-align: center; color: var(--muted); }
.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin 0.8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ==========================================================================
   Site list (account level)
   ========================================================================== */
.site-row .fav { width: 34px; height: 34px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 800; }
.site-name { display: flex; gap: 12px; align-items: center; }

/* ==========================================================================
   Public pages (landing, sign in)
   ========================================================================== */
.pub-top { background: #fff; border-bottom: 1px solid var(--line); }
.pub-top .inner { max-width: 1120px; margin: 0 auto; padding: 14px 24px; display: flex; align-items: center; gap: 12px; }
.pub-top .spacer { flex: 1; }
.brand { font-weight: 700; font-size: 17px; color: var(--ink); text-decoration: none !important; display: inline-flex; align-items: center; gap: 9px; }
.brand .logo { width: 30px; height: 30px; border-radius: 8px; background: var(--accent); color: #fff; display: grid; place-items: center; font-size: 14px; }
.hero { position: relative; background: linear-gradient(160deg, var(--navy) 0%, #143a8a 60%, var(--accent) 140%); color: #fff; padding: 90px 24px 110px; text-align: center; overflow: hidden; }
.hero h1 { font-size: 46px; line-height: 1.08; max-width: 820px; margin: 0 auto 16px; letter-spacing: -0.03em; }
.hero p { font-size: 18px; color: #c9d7f5; max-width: 660px; margin: 0 auto; }
.hero .actions { justify-content: center; margin-top: 30px; display: flex; gap: 10px; }
.hero .btn { height: 44px; padding: 0 22px; font-size: 15px; }
.hero .btn:not(.primary) { background: rgba(255, 255, 255, 0.1); color: #fff; border-color: rgba(255, 255, 255, 0.25); }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; max-width: 1120px; margin: -56px auto 60px; padding: 0 24px; position: relative; }
.features .card { padding: 22px; margin: 0; }
.features .n { width: 34px; height: 34px; border-radius: 9px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin-bottom: 12px; }
.features .n svg { width: 18px; height: 18px; }

.auth-wrap { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: linear-gradient(160deg, var(--navy) 0%, #143a8a 70%, var(--accent) 150%); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; }
.auth-side .brand { color: #fff; }
.auth-side h2 { font-size: 30px; line-height: 1.15; max-width: 440px; letter-spacing: -0.02em; }
.auth-side ul { list-style: none; padding: 0; margin: 20px 0 0; color: #c9d7f5; }
.auth-side li { padding: 6px 0 6px 26px; position: relative; }
.auth-side li::before { content: "✓"; position: absolute; left: 0; color: #8fb2ff; font-weight: 800; }
.auth-main { display: grid; place-items: center; padding: 32px; background: #fff; }
.auth-card { width: min(400px, 100%); }
.auth-card h1 { font-size: 26px; margin-bottom: 6px; }
.auth-card .lead { color: var(--muted); margin-bottom: 24px; }
.auth-card .btn.primary { width: 100%; height: 42px; }
.auth-card .switch-link { text-align: center; font-size: 13.5px; color: var(--muted); margin-top: 18px; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1100px) {
  .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grid.c3, .grid.c-2-1 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: var(--sidebar-w); transform: translateX(-100%); transition: transform 0.2s; }
  .app.nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
  .topbar { padding: 0 16px; }
  .topbar .menu-btn { display: inline-flex; }
  .content { padding: 20px 16px 50px; }
  .grid.c2, .row-2, .row-3, .features { grid-template-columns: 1fr; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .hero h1 { font-size: 32px; }
  .crumbs .hide-sm { display: none; }
}
.btn.disabled { opacity: 0.55; pointer-events: none; }
details > summary { list-style: none; }
details > summary::before { content: "▸ "; }
details[open] > summary::before { content: "▾ "; }
.site-switch > button > svg { width: 16px; height: 16px; flex: none; opacity: 0.7; }
.app { background: linear-gradient(90deg, #0d2552 0 var(--sidebar-w), var(--bg) var(--sidebar-w)); }
@media (max-width: 860px) { .app { background: var(--bg); } }
.field { align-content: start; }
#view:focus, #view:focus-visible { outline: none; }
.delta { white-space: nowrap; }
.sb-nav a > span:not(.pill) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumbs { overflow: hidden; white-space: nowrap; }
@media (max-width: 860px) { .crumbs { display: none; } }

/* ---------- account / billing ---------- */
.mono { font-family: var(--mono); font-size: 12.5px; }
.btn.danger-text { color: var(--danger); }
.btn.danger-text:hover:not([disabled]) { background: var(--danger-soft); }
.meter { height: 6px; background: var(--line-2); border-radius: 4px; overflow: hidden; margin-top: 10px; }
.meter .fill { height: 100%; background: var(--accent); border-radius: 4px; }
.meter .fill.hot { background: var(--warn); }
.plan-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.plan-card { border: 1px solid var(--line); border-radius: 12px; padding: 18px; display: flex; flex-direction: column; gap: 10px; }
.plan-card.current { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); background: #fafcff; }
.plan-card .pc-head { display: flex; justify-content: space-between; align-items: center; font-size: 15px; }
.plan-card .pc-price { color: var(--muted); font-size: 13.5px; }
.plan-card .pc-price span { font-size: 26px; font-weight: 700; color: var(--ink); letter-spacing: -0.02em; margin-right: 2px; }
.plan-card ul { list-style: none; padding: 0; margin: 0 0 4px; display: grid; gap: 6px; font-size: 13.5px; color: var(--ink-2); flex: 1; }
.plan-card li { padding-left: 20px; position: relative; }
.plan-card li::before { content: "✓"; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.plan-card .btn { width: 100%; justify-content: center; }
.pm-list { display: flex; flex-direction: column; }
.pm-row { display: grid; grid-template-columns: auto 1fr auto auto; gap: 16px; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line-2); }
.pm-row:last-child { border-bottom: 0; }
.pm-row.default { background: #fafcff; }
.pm-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pm-main b { font-weight: 600; }
.pm-main .muted { font-size: 13px; }
.pm-tags, .pm-actions { display: flex; gap: 6px; align-items: center; }
.pm-logo { width: 52px; height: 34px; border-radius: 6px; display: grid; place-items: center; font-size: 10.5px; font-weight: 800; letter-spacing: .04em; color: #fff; background: #44506a; }
.pm-logo.visa { background: #1a3e9a; } .pm-logo.mastercard { background: #2b2b2b; } .pm-logo.amex { background: #1f72cd; }
.pm-logo.discover { background: #e46b1f; } .pm-logo.diners { background: #0a5aa6; } .pm-logo.jcb { background: #0e7a4f; } .pm-logo.unionpay { background: #b51d2a; }
.pm-logo.bank { background: var(--accent-soft); color: var(--accent); }
.pm-logo svg { width: 20px; height: 20px; }
.accepted { display: flex; gap: 8px; flex-wrap: wrap; }
.accepted span { border: 1px solid var(--line); border-radius: 8px; padding: 4px 10px; font-size: 13px; color: var(--ink-2); background: #fff; }
.lock-banner { background: var(--warn-soft); color: #6b3f00; padding: 10px 24px; font-size: 13.5px; display: flex; gap: 10px; align-items: center; }
.lock-banner a { color: inherit; font-weight: 650; }
.trial-pill { display: block; margin: 0 12px 10px; padding: 10px 12px; border-radius: 10px; background: rgba(255, 255, 255, 0.07); color: var(--navy-text); font-size: 12.5px; text-decoration: none; }
.trial-pill b { color: #fff; display: block; font-size: 13px; }
@media (max-width: 900px) {
  .plan-grid { grid-template-columns: 1fr; }
  .pm-row { grid-template-columns: auto 1fr; }
  .pm-tags, .pm-actions { grid-column: 2; }
}
.empty .btn svg { width: 16px; height: 16px; margin: 0; color: currentColor; }
.sb-brand .logo.mark { padding: 0; overflow: hidden; }
.sb-brand .logo.mark svg { width: 100%; height: 100%; }

/* ---------- reporting scope + popovers ---------- */
.scope-btn { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; background: #fff; font: inherit; font-size: 13.5px; color: var(--ink); cursor: pointer; max-width: 320px; }
.scope-btn:hover { border-color: #c9d3e6; background: #fbfcfe; }
.scope-btn > span, .scope-btn > b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scope-btn small { color: var(--muted); font-size: 12px; white-space: nowrap; }
.scope-btn svg { width: 16px; height: 16px; flex: none; color: var(--muted); }
.popover { position: absolute; z-index: 80; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 6px; max-height: min(520px, 80vh); overflow: auto; }
.pop-head { padding: 10px 10px 8px; display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; }
.pop-head .muted { font-size: 12px; }
.pop-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 8px 6px 4px; border-top: 1px solid var(--line-2); margin-top: 6px; }
.pick-list { display: flex; flex-direction: column; max-height: 280px; overflow: auto; }
.pick-row { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; font-size: 13.5px; }
.pick-row:hover { background: var(--line-2); }
.pick-row input { width: 16px; height: 16px; accent-color: var(--accent); flex: none; }
.pick-row.all { border-bottom: 1px solid var(--line-2); border-radius: 8px 8px 0 0; margin-bottom: 4px; }
.presets { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 0 4px 8px; }
.preset { border: 1px solid var(--line); background: #fff; border-radius: 8px; padding: 8px 10px; font: inherit; font-size: 13px; text-align: left; cursor: pointer; color: var(--ink-2); }
.preset:hover { border-color: #c9d3e6; }
.preset.on { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.custom-range { padding: 8px 6px 2px; border-top: 1px solid var(--line-2); display: flex; flex-direction: column; gap: 8px; }
.range-inputs { display: flex; align-items: center; gap: 8px; }
.range-inputs .input { height: 36px; flex: 1; min-width: 0; }
.menu-list a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: 13.5px; }
.menu-list a:hover, .menu-list a.on { background: var(--accent-soft); }
.menu-list a svg { width: 16px; height: 16px; color: var(--accent); }
.site-chip { display: inline-block; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; font-size: 12px; font-weight: 600; color: var(--ink-2); background: var(--line-2); border-radius: 6px; padding: 2px 8px; }
.chips { display: inline-flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.ws-switch > button[disabled] { cursor: default; opacity: 1; }
.ws-switch > button[disabled]:hover { background: rgba(255, 255, 255, 0.06); }

/* ---------- team ---------- */
.role-legend { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.role-legend .kpi .d { display: block; line-height: 1.45; }
.role-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.role-card { position: relative; border: 1px solid var(--line); border-radius: 10px; padding: 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.role-card b { color: var(--ink); font-size: 14px; }
.role-card input { position: absolute; opacity: 0; }
.role-card.on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); background: #f8fbff; }
.role-card:has(input:focus-visible) { box-shadow: 0 0 0 3px var(--accent-ring); }
dialog .pick-list { border: 1px solid var(--line); border-radius: 10px; padding: 4px; max-height: 220px; }
dialog .pick-row.all { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 8px; }
.row-actions { display: flex; gap: 4px; justify-content: flex-end; }
.avatar.sm { width: 30px; height: 30px; font-size: 11.5px; flex: none; }
@media (max-width: 900px) {
  .role-legend, .role-cards { grid-template-columns: 1fr; }
  .scope-btn small { display: none; }
  .topbar { flex-wrap: wrap; height: auto; padding-top: 8px; padding-bottom: 8px; }
}
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-width: 120px; max-width: 200px; }

/* ---------------------------------------------------------------- Ads manager */
.switch.small { width: 34px; height: 19px; margin-top: 0; display: inline-block; vertical-align: middle; }
.switch.small span::after { width: 13px; height: 13px; }
.switch.small input:checked + span::after { transform: translateX(15px); }
.tree-cell { display: flex; align-items: center; gap: 8px; min-width: 240px; }
.tree-cell.d1 { padding-left: 30px; }
.tree-cell.d2 { padding-left: 58px; }
.tree-cell.d1 b, .tree-cell.d2 b { font-weight: 550; }
.caret, .caret-sp { width: 22px; height: 22px; flex: none; }
.caret { border: 0; background: none; padding: 0; border-radius: 6px; cursor: pointer; color: var(--muted); display: grid; place-items: center; }
.caret:hover { background: var(--line-2); color: var(--ink); }
.caret svg { width: 15px; height: 15px; transform: rotate(-90deg); transition: transform 0.12s; }
.caret[aria-expanded="true"] svg { transform: none; }
.link-btn { border: 0; background: none; font: inherit; color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; gap: 5px; padding: 2px 4px; border-radius: 5px; font-variant-numeric: tabular-nums; }
.link-btn svg { width: 13px; height: 13px; color: var(--muted); opacity: 0; transition: opacity 0.1s; }
.link-btn:hover { background: var(--accent-soft); color: var(--accent); }
.link-btn:hover svg, .link-btn:focus-visible svg { opacity: 1; color: var(--accent); }
.kv.compact { grid-template-columns: 110px 1fr; gap: 4px 12px; font-size: 13px; }
.chips-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.pick-chip { position: relative; cursor: pointer; }
.pick-chip input { position: absolute; opacity: 0; }
.pick-chip span { display: inline-block; border: 1px solid var(--line); border-radius: 20px; padding: 4px 12px; font-size: 13px; color: var(--ink-2); background: #fff; }
.pick-chip input:checked + span { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.pick-chip input:focus-visible + span { box-shadow: 0 0 0 3px var(--accent-ring); }
.prefix-input { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; background: #fff; }
.prefix-input > span { padding: 0 10px; display: flex; align-items: center; background: var(--line-2); color: var(--muted); font-size: 13px; white-space: nowrap; max-width: 55%; overflow: hidden; text-overflow: ellipsis; }
.prefix-input .input { border: 0; border-radius: 0; min-width: 0; flex: 1; }
.prefix-input:focus-within { box-shadow: 0 0 0 3px var(--accent-ring); border-color: var(--accent); }
.counter { display: block; text-align: right; }
.counter.over { color: var(--danger); font-weight: 600; }
.role-card.disabled { opacity: 0.55; cursor: not-allowed; }
.builder { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 18px; align-items: start; }
.builder-side { position: sticky; top: 76px; }
@media (max-width: 1100px) { .builder { grid-template-columns: 1fr; } .builder-side { position: static; } }
.ad-preview { display: flex; justify-content: center; }
.fb-ad { width: 100%; max-width: 330px; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; font-family: Helvetica, Arial, sans-serif; color: #050505; }
.fb-head { display: flex; gap: 8px; align-items: center; padding: 10px 12px 6px; }
.fb-head b { display: block; font-size: 13.5px; }
.fb-head span:not(.fb-avatar) { font-size: 12px; color: #65676b; }
.fb-avatar { width: 34px; height: 34px; border-radius: 50%; background: #1877f2; color: #fff; display: grid; place-items: center; font-weight: 700; flex: none; }
.fb-text { margin: 0; padding: 0 12px 8px; font-size: 13.5px; line-height: 1.38; white-space: pre-wrap; }
.fb-img { aspect-ratio: 1 / 1; background: linear-gradient(135deg, #e9eef7, #d8e2f3) center / cover no-repeat; display: grid; place-items: center; text-align: center; color: #6b7a93; font-size: 12.5px; padding: 20px; }
.fb-foot { display: flex; align-items: center; gap: 10px; background: #f0f2f5; padding: 10px 12px; }
.fb-foot > div { flex: 1; min-width: 0; }
.fb-foot small { display: block; font-size: 11px; color: #65676b; letter-spacing: 0.02em; }
.fb-foot b { display: block; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fb-foot span { display: block; font-size: 12.5px; color: #65676b; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fb-cta { flex: none; background: #e4e6eb; border-radius: 6px; padding: 7px 12px; font-size: 13px; font-weight: 600; }
.g-ad { width: 100%; max-width: 360px; font-family: Arial, sans-serif; color: #202124; padding: 4px 2px; }
.g-top { display: flex; gap: 10px; align-items: center; }
.g-top b { display: block; font-size: 14px; font-weight: 400; }
.g-top span:not(.g-fav) { display: block; font-size: 12px; color: #4d5156; }
.g-fav { width: 28px; height: 28px; border-radius: 50%; background: #f1f3f4; border: 1px solid #dadce0; display: grid; place-items: center; font-size: 13px; font-weight: 700; color: #1a73e8; flex: none; }
.g-sponsored { font-size: 12px; font-weight: 700; margin: 8px 0 2px; }
.g-title { display: block; font-size: 19px; line-height: 1.3; color: #1a0dab; cursor: default; }
.g-desc { margin: 4px 0 0; font-size: 14px; line-height: 1.55; color: #4d5156; }
table.t td.barcell.sm { width: 10%; min-width: 70px; }
.camp-cell { min-width: 230px; }

/* ---------------------------------------------------------------- Account security, activity log */
.sb-foot a.who { text-decoration: none; border-radius: 8px; padding: 4px 6px; margin: -4px -6px; }
.sb-foot a.who:hover, .sb-foot a.who.on { background: rgba(255, 255, 255, 0.08); }
.code-input { font-size: 20px; letter-spacing: 0.18em; text-align: center; font-variant-numeric: tabular-nums; max-width: 220px; }
.dlg-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }
.mt { margin-top: 18px; }
.static { min-height: 38px; display: flex; align-items: center; gap: 8px; font-size: 14px; }
.inline-form { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 14px; align-items: end; }
.inline-form .field { margin-bottom: 0; }
@media (max-width: 760px) { .inline-form { grid-template-columns: 1fr; } }
.verify-banner { align-items: center; }
.verify-banner > div { flex: 1; }
.mfa-on { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; font-size: 14px; }
.mfa-setup .steps { list-style: none; counter-reset: s; padding: 0; margin: 0 0 16px; display: grid; gap: 16px; }
.mfa-setup .steps > li { counter-increment: s; position: relative; padding-left: 38px; display: flex; flex-direction: column; gap: 8px; }
.mfa-setup .steps > li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 13px; display: grid; place-items: center; }
.mfa-setup .steps > li > span { color: var(--muted); font-size: 13px; }
.qr-row { display: flex; gap: 18px; align-items: center; flex-wrap: wrap; }
.qr { width: 168px; height: 168px; border: 1px solid var(--line); border-radius: 10px; padding: 6px; background: #fff; flex: none; }
.qr svg { width: 100%; height: 100%; display: block; }
.secret-key { display: block; margin-top: 6px; font-family: var(--mono); font-size: 13px; background: var(--line-2); padding: 8px 10px; border-radius: 8px; word-break: break-all; user-select: all; }
.backup-codes ol { columns: 2; list-style: none; padding: 14px 16px; margin: 0 0 12px; background: var(--line-2); border-radius: 10px; font-size: 15px; letter-spacing: 0.04em; }
.backup-codes li { padding: 3px 0; }
.gate { max-width: 640px; margin: 24px auto; }
.gate h1 { font-size: 22px; margin: 6px 0; }
.gate-icon { width: 46px; height: 46px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; }
.gate-icon svg { width: 24px; height: 24px; }
.filter-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) 150px 150px minmax(0, 1.2fr); gap: 10px; }
@media (max-width: 1100px) { .filter-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.activity { list-style: none; margin: 0; padding: 0; }
.activity .day { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.05em; padding: 14px 0 6px; border-bottom: 1px solid var(--line-2); }
.activity .day:first-child { padding-top: 0; }
.activity .ev { display: flex; gap: 12px; align-items: flex-start; padding: 11px 0; border-bottom: 1px solid var(--line-2); }
.ev-icon { width: 30px; height: 30px; border-radius: 8px; background: var(--line-2); color: var(--ink-2); display: grid; place-items: center; flex: none; }
.ev-icon svg { width: 15px; height: 15px; }
.cat-auth .ev-icon, .cat-security .ev-icon { background: #eef0ff; color: #4b4fd1; }
.cat-team .ev-icon { background: var(--ok-soft); color: var(--ok); }
.cat-billing .ev-icon { background: var(--warn-soft); color: var(--warn); }
.cat-content .ev-icon, .cat-sites .ev-icon { background: var(--accent-soft); color: var(--accent); }
.cat-data .ev-icon { background: var(--danger-soft); color: var(--danger); }
.ev-main { flex: 1; min-width: 0; }
.ev-sum { font-size: 14px; color: var(--ink); }
.ev-meta { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.ev-meta b { color: var(--ink-2); font-weight: 600; }
.review-form { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: end; margin-top: 16px; }
.review-form .field { margin-bottom: 0; }
