:root {
  --croma-50: #FEF4EF; --croma-100: #FDE6DA; --croma-200: #FACBB2; --croma-400: #F48B58;
  --croma-500: #F16B2B; --croma-600: #D9551A; --croma-700: #B34313;
  --ink-0: #FFFFFF; --ink-25: #FCFCFD; --ink-50: #F5F5F7; --ink-100: #EFEFF2; --ink-200: #E4E4E8; --ink-300: #D3D3D9;
  --ink-400: #A8A8B3; --ink-500: #6F707E; --ink-600: #55566A; --ink-700: #3D3E4A; --ink-800: #2B2B2B; --ink-900: #18181C;
  --bg: #F7F6F4; --surface: #FFFFFF; --text: var(--ink-900); --muted: var(--ink-500); --line: var(--ink-200);
  --success: #12946A; --success-50: #E9F7F0; --danger: #D93F2C; --danger-50: #FDEEEC; --info: #3465D1; --info-50: #EDF2FD;
  --warning: #B7791F; --warning-50: #FDF6E7;
  --radius: 14px; --shadow: 0 1px 2px rgba(24,24,28,.04), 0 4px 16px rgba(24,24,28,.05);
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111114; --surface: #1B1B20; --text: #F2F2F4; --muted: #A1A2AE; --line: #2E2E36;
    --ink-25: #1F1F25; --ink-50: #23232A; --ink-100: #2A2A31; --croma-50: #2C1A11; --croma-100: #3A2216;
    --success-50: #10291F; --danger-50: #33160F; --info-50: #151E33; --warning-50: #2E2410;
  }
}
:root[data-theme="dark"] {
  --bg: #111114; --surface: #1B1B20; --text: #F2F2F4; --muted: #A1A2AE; --line: #2E2E36;
  --ink-25: #1F1F25; --ink-50: #23232A; --ink-100: #2A2A31; --croma-50: #2C1A11; --croma-100: #3A2216;
  --success-50: #10291F; --danger-50: #33160F; --info-50: #151E33; --warning-50: #2E2410;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
svg[aria-hidden="true"] { width: 16px; height: 16px; flex: none; vertical-align: -3px; }
.grid + .card, .card + .grid, .grid + .grid { margin-top: 16px; }
html, body { margin: 0; }
body { font-family: var(--font); background: var(--bg); color: var(--text); font-size: 15px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--croma-600); }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: 30px; font-weight: 800; }
h2 { font-size: 19px; font-weight: 700; }
h3 { font-size: 15px; font-weight: 700; }
p { margin: 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.eyebrow { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.num { font-variant-numeric: tabular-nums; }

/* Layout */
.shell { display: grid; grid-template-columns: 252px 1fr; min-height: 100vh; }
.sidebar { background: var(--ink-900); color: #E9E9EE; padding: 22px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; color: #fff; text-decoration: none; }
.brand-mark { width: 34px; height: 34px; border-radius: 10px; background: var(--croma-500); display: grid; place-items: center; }
.brand-name { font-weight: 800; font-size: 19px; letter-spacing: -0.03em; }
.brand-sub { font-size: 10px; letter-spacing: .14em; color: #9C9CA8; font-weight: 600; }
.nav-group { font-size: 10.5px; font-weight: 700; letter-spacing: .12em; color: #8A8A96; padding: 16px 12px 6px; text-transform: uppercase; }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; color: #D6D6DD; text-decoration: none; font-size: 14px; font-weight: 500; border: 0; background: none; width: 100%; text-align: left; cursor: pointer; }
.nav-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.nav-item.active { background: var(--croma-500); color: #fff; font-weight: 600; }
.nav-item svg { width: 18px; height: 18px; flex: none; opacity: .9; }
.nav-badge { margin-left: auto; background: var(--croma-500); color: #fff; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; }
.nav-item.active .nav-badge { background: #fff; color: var(--croma-600); }
.sidebar-foot { margin-top: auto; padding: 14px 8px 0; border-top: 1px solid rgba(255,255,255,.08); display: flex; align-items: center; gap: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--croma-500); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.foot-name { font-size: 13px; font-weight: 600; color: #fff; }
.foot-role { font-size: 11.5px; color: #9C9CA8; }
.icon-btn { margin-left: auto; background: rgba(255,255,255,.08); border: 0; color: #fff; width: 34px; height: 34px; border-radius: 9px; cursor: pointer; display: grid; place-items: center; }
.icon-btn:hover { background: rgba(255,255,255,.16); }

.main { min-width: 0; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 14px 32px; border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 5; }
.btn.menu-toggle { display: none; }
.crumb { font-size: 14px; color: var(--muted); }
.crumb b { color: var(--text); }
.topbar-right { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.preview-bar { background: var(--croma-500); color: #fff; padding: 10px 32px; font-size: 14px; }
.content { padding: 28px 32px 64px; max-width: 1240px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head p { margin-top: 6px; color: var(--muted); }

/* Componentes */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card + .card, .stack > * + * { margin-top: 16px; }
.grid > .card, .grid > .stat { margin-top: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.stat.accent { background: var(--croma-500); border-color: var(--croma-500); color: #fff; }
.stat.accent .stat-label, .stat.accent .stat-sub { color: rgba(255,255,255,.85); }
.stat-label { font-size: 13px; color: var(--muted); font-weight: 500; }
.stat-value { font-size: 28px; font-weight: 800; letter-spacing: -0.03em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat-sub { font-size: 12px; color: var(--muted); margin-top: 4px; }
.up { color: var(--success); } .down { color: var(--danger); }
.stat.accent .up, .stat.accent .down { color: #fff; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 10px; padding: 9px 16px; font-weight: 600; font-size: 14px; cursor: pointer; background: var(--croma-500); color: #fff; text-decoration: none; white-space: nowrap; }
.btn:hover { background: var(--croma-600); }
.btn.secondary { background: var(--ink-50); color: var(--text); border-color: var(--line); }
.btn.secondary:hover { background: var(--ink-100); }
.btn.ghost { background: transparent; color: var(--text); }
.btn.ghost:hover { background: var(--ink-50); }
.btn.danger { background: var(--danger-50); color: var(--danger); }
.btn.sm { padding: 6px 11px; font-size: 13px; border-radius: 8px; }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn svg { width: 16px; height: 16px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }

.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 99px; background: var(--ink-50); color: var(--ink-600); white-space: nowrap; }
.badge.orange { background: var(--croma-50); color: var(--croma-700); }
.badge.green { background: var(--success-50); color: var(--success); }
.badge.red { background: var(--danger-50); color: var(--danger); }
.badge.blue { background: var(--info-50); color: var(--info); }
.badge.yellow { background: var(--warning-50); color: var(--warning); }

.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; font-weight: 600; }
.field .hint { font-size: 12px; color: var(--muted); }
input[type=text], input[type=password], input[type=number], input[type=date], input[type=email], input[type=month], input[type=time], input[type=search], select, textarea {
  width: 100%; border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 10px 12px; font-size: 14px; outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--croma-400); box-shadow: 0 0 0 3px var(--croma-100); }
textarea { resize: vertical; min-height: 110px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }
.checks { display: flex; gap: 14px; flex-wrap: wrap; }
.checks label { display: flex; gap: 6px; align-items: center; font-weight: 500; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 11.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 700; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--ink-25); white-space: nowrap; }
td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
td.r, th.r { text-align: right; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.table-wrap table th:first-child, .table-wrap table td:first-child { padding-left: 18px; }

.list-item { display: flex; gap: 12px; align-items: flex-start; padding: 13px 0; border-bottom: 1px solid var(--line); }
.list-item:last-child { border-bottom: 0; }
.dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 7px; flex: none; background: var(--info); }
.dot.danger { background: var(--danger); } .dot.warning { background: var(--warning); } .dot.info { background: var(--info); }
.empty { text-align: center; padding: 36px 16px; color: var(--muted); }
.empty h3 { color: var(--text); margin-bottom: 6px; }

.tabs { display: inline-flex; background: var(--ink-50); border: 1px solid var(--line); border-radius: 11px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.tab { border: 0; background: none; padding: 7px 14px; border-radius: 8px; font-weight: 600; font-size: 13.5px; cursor: pointer; color: var(--muted); }
.tab.active { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.08); }

.bar { height: 8px; background: var(--ink-100); border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--croma-500); border-radius: 99px; }
.funnel { display: flex; flex-direction: column; gap: 10px; }
.funnel-step { display: grid; grid-template-columns: 160px 1fr 120px; gap: 14px; align-items: center; }
.funnel-step .bar { height: 26px; border-radius: 8px; }
.funnel-step .bar > i { border-radius: 8px; }
.chart { width: 100%; height: 180px; }
.chart rect { fill: var(--croma-400); }
.chart rect:hover { fill: var(--croma-600); }
.chart text { fill: var(--muted); font-size: 10px; }

.notice { border-radius: 12px; padding: 14px 16px; background: var(--croma-50); border: 1px solid var(--croma-200); font-size: 14px; }
.notice.info { background: var(--info-50); border-color: transparent; }
.notice.danger { background: var(--danger-50); border-color: transparent; color: var(--danger); }

.ad-card { border: 1px solid var(--line); border-radius: 12px; padding: 16px; background: var(--surface); display: flex; flex-direction: column; gap: 8px; }
.ad-card img { width: 100%; border-radius: 8px; aspect-ratio: 1.6; object-fit: cover; background: var(--ink-50); }
.ad-headline { color: var(--info); font-weight: 600; }

.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-h { text-align: center; font-size: 12px; color: var(--muted); padding: 4px 0; }
.cal-d { aspect-ratio: 1; border-radius: 10px; border: 1px solid transparent; background: var(--ink-50); display: flex; flex-direction: column; align-items: center; justify-content: center; font-weight: 600; cursor: pointer; font-size: 14px; position: relative; }
.cal-d.out { opacity: .3; cursor: default; }
.cal-d.has::after { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--croma-500); margin-top: 3px; }
.cal-d.sel { border-color: var(--croma-500); background: var(--croma-50); }
.slot { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; }
.slot + .slot { margin-top: 8px; }

.form-section { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--croma-600); margin: 18px 0 10px; padding-top: 14px; border-top: 1px solid var(--line); }
.form-section:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
@media (max-width: 1100px) { .theme-label { display: none; } }

/* Visão geral */
.hero { background: var(--ink-900); color: #fff; border-radius: 18px; padding: 28px 30px; display: flex; gap: 20px; align-items: center; justify-content: space-between; margin-bottom: 16px; position: relative; overflow: hidden; }
.hero::after { content: ''; position: absolute; width: 360px; height: 360px; right: -120px; top: -160px; border-radius: 50%; background: radial-gradient(circle, rgba(241,107,43,.45), rgba(241,107,43,0) 70%); }
.hero p { color: #C9C9D2; margin-top: 8px; max-width: 640px; position: relative; z-index: 1; }
.hero-title { font-size: 34px; font-weight: 800; margin-top: 6px; position: relative; z-index: 1; }
.eyebrow.light { color: #A8A8B3; }
.hero-icon { width: 72px; height: 72px; border-radius: 18px; background: rgba(255,255,255,.08); display: grid; place-items: center; color: var(--croma-400); flex: none; position: relative; z-index: 1; }
.hero-icon svg { width: 34px; height: 34px; }
.shortcut { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: inherit; transition: border-color .15s, transform .15s; }
.shortcut:hover { border-color: var(--croma-400); transform: translateY(-2px); }
.shortcut-icon { width: 46px; height: 46px; border-radius: 12px; background: var(--croma-50); color: var(--croma-600); display: grid; place-items: center; }
.shortcut-icon svg { width: 22px; height: 22px; }
.shortcut-cta { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); font-weight: 700; font-size: 14px; color: var(--croma-600); }
.plat-mark { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; font-size: 17px; flex: none; }
.plat-mark.google_ads { background: #E8F5EE; color: #188038; }
.plat-mark.meta_ads { background: #E8EFFD; color: #1A5CD8; }

/* Relatórios */
.section-title { font-size: 24px; font-weight: 800; margin: 4px 0 8px; }
.rtabs { display: flex; gap: 6px; flex-wrap: wrap; border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 16px; }
.rtab { border: 0; background: none; padding: 10px 16px; border-radius: 10px; font-weight: 600; font-size: 14.5px; cursor: pointer; color: var(--muted); }
.rtab span { font-size: 11px; margin-right: 6px; opacity: .7; }
.rtab.active { background: var(--ink-900); color: #fff; }
.rtab.active span { color: var(--croma-400); opacity: 1; }
:root[data-theme="dark"] .rtab.active { background: var(--croma-500); }
.acc-chips { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 10px; margin-bottom: 18px; }
.acc-chip { display: flex; gap: 10px; align-items: center; border: 1px dashed var(--line); border-radius: 12px; padding: 10px 12px; }
.acc-chip .plat-mark { width: 30px; height: 30px; font-size: 14px; }
.metric-panel { background: var(--croma-50); border: 1px solid var(--croma-200); border-radius: 18px; padding: 20px 22px; }
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); margin: 16px 0; }
.metric-cell { padding: 6px 18px; border-left: 1px solid var(--croma-200); display: flex; flex-direction: column; gap: 6px; }
.metric-cell:first-child { border-left: 0; padding-left: 0; }
.metric-cell svg { width: 16px; height: 16px; }
.metric-value { font-size: 32px; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.metric-cell:first-child .metric-value { color: var(--croma-600); }
.metric-bars { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px 24px; border-top: 1px solid var(--croma-200); padding-top: 16px; }
.funnel-wrap { display: grid; grid-template-columns: 1.1fr 1fr; gap: 32px; align-items: center; }
.funnel-viz { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.fstage { border: 0; cursor: pointer; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 22px 10px; color: var(--ink-900); font-family: inherit; transition: filter .15s, transform .15s; }
.fstage:hover { filter: brightness(1.05); transform: scale(1.01); }
.fstage.f0 { width: 100%; background: var(--ink-900); color: #fff; clip-path: polygon(0 0, 100% 0, 88% 100%, 12% 100%); }
.fstage.f1 { width: 76%; background: var(--croma-200); clip-path: polygon(0 0, 100% 0, 85% 100%, 15% 100%); }
.fstage.f2 { width: 52%; background: var(--croma-500); color: #fff; clip-path: polygon(0 0, 100% 0, 80% 100%, 20% 100%); padding-bottom: 28px; }
.fstage.on { outline: 3px solid var(--croma-400); outline-offset: -3px; }
.fstage.f0 .tiny { color: var(--croma-300, var(--croma-200)); }
.fval { font-size: 32px; font-weight: 800; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.funnel-explain { border-left: 1px solid var(--line); padding-left: 28px; }
.acc-title { margin: 18px 0 10px; font-size: 17px; }
.camp-card { background: var(--ink-50); border: 1px solid var(--line); border-radius: 14px; padding: 18px; }
.camp-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px 16px; margin-top: 12px; }
.camp-grid b { font-size: 18px; font-variant-numeric: tabular-nums; }
.camp-more { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.camp-more summary, details > summary { cursor: pointer; }
.camp-more summary { color: var(--croma-600); font-weight: 600; font-size: 14px; }
.eng-tile { background: var(--ink-50); border-radius: 12px; padding: 14px 16px; }
.sale-row { display: flex; gap: 22px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }

/* Biblioteca de anúncios */
.ad-group { margin-bottom: 26px; }
.ad-group-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.ad-group-n { font-weight: 800; color: var(--croma-600); font-size: 13px; border-right: 2px solid var(--croma-200); padding-right: 10px; }
.ad-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; align-items: start; }
.feed, .serp { border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.feed-head { display: flex; gap: 10px; align-items: center; padding: 10px 12px; }
.feed-text { margin: 0 12px 10px; white-space: pre-line; }
.feed-text.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.ad-media { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: var(--ink-100); border: 0; }
video.ad-media { aspect-ratio: 4 / 5; background: #000; }
.ad-media-wrap { position: relative; }
.ad-play { position: absolute; inset: 0; margin: auto; width: 54px; height: 54px; border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; display: grid; place-items: center; font-size: 20px; z-index: 1; }
.ad-noimg { display: grid; place-items: center; color: var(--muted); font-size: 13px; text-align: center; padding: 16px; aspect-ratio: 1.6; }
.ad-carousel { display: flex; gap: 6px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0 12px; }
.ad-carousel img { flex: 0 0 78%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; scroll-snap-align: start; }
.feed-foot { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 10px 12px; background: var(--ink-50); }
.feed-title { display: block; overflow: hidden; text-overflow: ellipsis; }
.feed-cta { flex: none; background: var(--ink-100); border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; font-size: 12.5px; font-weight: 600; }
.serp { padding: 14px; }
.serp-top { font-size: 12px; margin-bottom: 8px; }
.serp-site { display: flex; gap: 8px; align-items: center; margin-bottom: 6px; }
.serp-fav { width: 28px; height: 28px; border-radius: 50%; background: var(--croma-50); color: var(--croma-700); display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.serp-title { color: #1a0dab; font-size: 18px; line-height: 1.3; margin-bottom: 4px; }
:root[data-theme="dark"] .serp-title { color: #8ab4f8; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .serp-title { color: #8ab4f8; } }

/* Histórico em linha do tempo */
.tl-body { padding: 0 0 6px; }
.ad-banner { background: var(--ink-900); color: #fff; border-radius: 16px; padding: 20px 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.ad-banner h2 { color: #fff; }
.timeline { position: relative; padding-left: 8px; }
.tl-day + .tl-day { margin-top: 22px; }
.tl-date { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--croma-600); margin: 0 0 10px 26px; }
.tl-item { position: relative; padding-left: 26px; padding-bottom: 12px; }
.tl-item::before { content: ''; position: absolute; left: 6px; top: 14px; bottom: -2px; width: 2px; background: var(--line); }
.tl-day .tl-item:last-child::before { display: none; }
.tl-dot { position: absolute; left: 0; top: 8px; width: 14px; height: 14px; border-radius: 50%; background: var(--croma-500); box-shadow: 0 0 0 4px var(--croma-50); }
.tl-dot.api { background: var(--info); box-shadow: 0 0 0 4px var(--info-50); }
.tl-card { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; background: var(--surface); }

/* Kanban de prospectos */
.kanban { display: grid; grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 12px; overflow-x: auto; padding-bottom: 6px; align-items: start; }
.kcol { background: var(--ink-50); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; min-height: 320px; transition: background .15s, border-color .15s; }
.kcol.over { border-color: var(--croma-500); background: var(--croma-50); }
.kcol-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.kcard { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px; margin-bottom: 10px; cursor: grab; box-shadow: var(--shadow); }
.kcard:hover { border-color: var(--croma-300, var(--croma-200)); }
.kcard.dragging { opacity: .45; }
.kcard-notes { margin-top: 6px; }
.kmove { width: auto; flex: 1; padding: 5px 8px; font-size: 12.5px; border-radius: 8px; }
.kempty { border: 1.5px dashed var(--line); border-radius: 10px; padding: 18px 10px; text-align: center; font-size: 12.5px; color: var(--muted); }

/* Modal e toast */
.modal-bg { position: fixed; inset: 0; background: rgba(15,15,18,.5); display: grid; place-items: center; padding: 16px; z-index: 50; }
.modal { background: var(--surface); border-radius: 18px; width: min(640px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; padding: 24px; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
#toast-root { position: fixed; top: 16px; right: 16px; z-index: 60; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--ink-900); color: #fff; padding: 12px 16px; border-radius: 12px; font-size: 14px; box-shadow: 0 8px 24px rgba(0,0,0,.2); max-width: 360px; animation: in .2s ease; }
.toast.error { background: var(--danger); }
@keyframes in { from { transform: translateY(-6px); opacity: 0; } }
.secret { font-family: ui-monospace, Menlo, monospace; background: var(--ink-50); border: 1px dashed var(--line); border-radius: 10px; padding: 12px; font-size: 14px; }

/* Login */
.login-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-art { background: var(--ink-900); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.login-art::after { content: ''; position: absolute; width: 520px; height: 520px; border-radius: 50%; background: radial-gradient(circle, rgba(241,107,43,.55), rgba(241,107,43,0) 70%); right: -160px; bottom: -160px; }
.login-art h1 { font-size: 44px; max-width: 520px; position: relative; z-index: 1; }
.login-art h1 em { font-style: normal; color: var(--croma-400); }
.login-form { display: grid; place-items: center; padding: 32px 16px; }
.login-card { width: min(380px, 100%); display: flex; flex-direction: column; gap: 16px; }

.loading { padding: 60px; text-align: center; color: var(--muted); }

@media (max-width: 1000px) {
  .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .g3 { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  .sidebar { position: fixed; left: 0; top: 0; z-index: 40; width: 270px; transform: translateX(-100%); transition: transform .2s; }
  .sidebar.open { transform: none; box-shadow: 0 0 40px rgba(0,0,0,.4); }
  .btn.menu-toggle { display: inline-flex; }
  .preview-bar { background: var(--croma-500); color: #fff; padding: 10px 32px; font-size: 14px; }
.content { padding: 20px 16px 48px; }
  .topbar { padding: 12px 16px; flex-wrap: wrap; }
  .stat-value { font-size: 21px; }
  .metric-value { font-size: 26px; }
  .topbar-right { margin-left: 0; width: 100%; flex-wrap: wrap; }
  .topbar-right select { min-width: 0 !important; flex: 1; }
  .shell, .main, .content { max-width: 100vw; overflow-x: hidden; }
  .preview-bar { padding: 10px 16px; }
  .g2, .form-grid { grid-template-columns: 1fr; }
  .login-wrap { grid-template-columns: 1fr; }
  .login-art { padding: 32px 20px; min-height: 220px; }
  .login-art h1 { font-size: 30px; }
  .funnel-step { grid-template-columns: 100px 1fr 80px; }
  .funnel-wrap { grid-template-columns: 1fr; }
  .funnel-explain { border-left: 0; padding-left: 0; }
  .metric-cell { border-left: 0; padding-left: 0; }
  .hero { padding: 22px; }
  .hero-title { font-size: 26px; }
  .kanban { grid-template-columns: repeat(5, 78vw); scroll-snap-type: x mandatory; }
  .kcol { scroll-snap-align: start; }
  h1 { font-size: 25px; }
}
