:root {
    --accent: #111111;
    --accent-soft: #E3EEF4;
    --accent-press: #000000;
    --on-accent: #ffffff;
    --lime: #DFFF00;
    --bg: #F5F5F2;
    --surface: #ffffff;
    --surface-2: #FAFAF7;
    --border: #E7E7E1;
    --border-strong: #D8D8D0;
    --text: #111111;
    --text-2: #737373;
    --text-3: #A3A3A3;
    --hot: #E5484D;
    --warm: #E08C1A;
    --cold: #3F72C4;
    --won: #2f9e44;
    --shadow: 0 1px 2px rgba(17,17,17,.03), 0 12px 40px -14px rgba(17,17,17,.07);
    --radius: 18px;
    --nav-w: 244px;
    --line: #E7E7E1;
    --bg-2: #FAFAF7;
    --accent-weak: #E3EEF4;
    --text-1: #111111;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
    font-family: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg); color: var(--text);
    font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased;
    font-feature-settings: 'ss01';
}
a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: #fff; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 8px; border: 2px solid var(--bg); }

/* ---------- Auth ---------- */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth__brand {
    background: linear-gradient(160deg, #12132a, #1f2350 60%, #2f5bea);
    color: #fff; padding: 64px; display: flex; flex-direction: column; justify-content: space-between;
}
.auth__brand h1 { font-size: 40px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.auth__brand p { color: #c7cdf0; margin-top: 16px; max-width: 360px; }
.auth__badges { display: flex; gap: 10px; flex-wrap: wrap; }
.auth__badge { font-size: 12px; background: rgba(255,255,255,.1); padding: 6px 12px; border-radius: 999px; }
.auth__form { display: flex; align-items: center; justify-content: center; padding: 40px; }
.auth__card { width: 100%; max-width: 360px; }
.auth__card h2 { font-size: 24px; letter-spacing: -.02em; }
.auth__card .sub { color: var(--text-2); margin: 6px 0 28px; }
.demo-hint { margin-top: 18px; font-size: 12px; color: var(--text-3); background: var(--surface-2); border: 1px solid var(--border); padding: 10px 12px; border-radius: 8px; }
/* Password field eye toggle */
.pw-wrap { position: relative; display: flex; align-items: center; }
.pw-wrap .input { width: 100%; padding-right: 40px; }
.pw-eye { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; border: 0; background: transparent; color: var(--text-3); cursor: pointer; border-radius: 6px; transition: color 140ms ease; }
.pw-eye:hover { color: var(--text); }
/* Forgot password — plain text link, right aligned */
.auth__forgot-row { display: flex; justify-content: flex-end; margin: 8px 0 2px; }
.auth__forgot { font-size: 13px; color: #3B5578; text-decoration: none; transition: color 140ms ease; }
.auth__forgot:hover { text-decoration: underline; color: #263A55; }
/* Inline form validation error banner */
.form-err { color: #B42318; background: #FEF3F2; border: 1px solid #FDA29B; padding: 9px 12px; border-radius: 8px; font-size: 13px; margin-bottom: 12px; }
@media (max-width: 860px) { .auth { grid-template-columns: 1fr; } .auth__brand { display: none; } }

/* ---------- Layout ---------- */
.shell { display: grid; grid-template-columns: var(--nav-w) 1fr; min-height: 100vh; }
.nav { border-right: 1px solid var(--border); background: var(--bg); display: flex; flex-direction: column; position: sticky; top: 0; height: 100vh; overflow-y: auto; }
.nav__brand { padding: 22px 20px 16px; display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -.01em; }
.nav__logo { width: 28px; height: 28px; border-radius: 8px; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; font-size: 13px; font-weight: 700; }
.nav__logo-img { height: 30px; width: auto; display: block; }
.nav__group { padding: 6px 12px; }
.nav__label { font-size: 10px; text-transform: uppercase; letter-spacing: .16em; color: var(--text-3); padding: 14px 12px 6px; font-weight: 600; }
.nav__item { display: flex; align-items: center; gap: 12px; padding: 9px 14px; border-radius: 999px; color: var(--text-2); cursor: pointer; font-weight: 500; font-size: 13.5px; transition: background-color .2s ease, color .2s ease; position: relative; }
.nav__item i { width: 16px; text-align: center; font-size: 14px; opacity: .8; }
.nav__item:hover { color: var(--text); }
.nav__item.active { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgba(17,17,17,.04), 0 8px 20px -10px rgba(17,17,17,.16); }
.nav__item.active i { opacity: 1; }
.nav__item.active::before { content: ''; position: absolute; left: 5px; top: 50%; transform: translateY(-50%); width: 3px; height: 15px; border-radius: 3px; background: var(--lime); }
.nav__foot { margin-top: auto; padding: 12px; border-top: 1px solid var(--border); position: sticky; bottom: 0; background: var(--bg); }
.nav__user { display: flex; align-items: center; gap: 10px; padding: 6px; border-radius: 8px; }
.avatar { width: 30px; height: 30px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 600; font-size: 12px; flex-shrink: 0; }
.nav__user .meta { overflow: hidden; }
.nav__user .meta b { display: block; font-size: 13px; }
.nav__user .meta span { font-size: 11px; color: var(--text-3); }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { height: 64px; border-bottom: 1px solid var(--border); background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(12px); position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 14px; padding: 0 32px; }
.topbar h1 { font-size: 17px; font-weight: 600; letter-spacing: -.02em; }
.topbar .spacer { flex: 1; }
.content { padding: 32px 32px 80px; max-width: 1500px; width: 100%; }

/* ---------- Buttons / inputs ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); font: inherit; font-weight: 600; font-size: 13.5px; cursor: pointer; transition: background-color .2s ease, border-color .2s ease, transform .15s ease; }
.btn:hover { background: var(--surface-2); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--accent-press); }
.btn--sm { height: 32px; padding: 0 14px; font-size: 12.5px; }
.btn--ghost { border-color: transparent; background: transparent; color: var(--text-2); }
.btn--ghost:hover { background: var(--surface-2); color: var(--text); }
.btn--danger { color: var(--hot); border-color: var(--border-strong); }
.icon-btn { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; border: 1px solid var(--border); background: var(--surface); cursor: pointer; color: var(--text-2); transition: background-color .2s ease, color .2s ease; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }

.input, .select, textarea.input { height: 40px; width: 100%; padding: 0 14px; border: 1px solid transparent; border-radius: 10px; background: var(--surface-2); color: var(--text); font: inherit; outline: none; transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease; }
textarea.input { height: auto; padding: 10px 12px; resize: vertical; }
.input:focus, .select:focus, textarea.input:focus { border-color: var(--accent); background: var(--surface); box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 8%, transparent); }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12px; font-weight: 500; color: var(--text-2); margin-bottom: 6px; }
.search { position: relative; }
.search i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-3); font-size: 13px; }
.search .input { padding-left: 34px; }

/* ---------- Cards / grid ---------- */
.grid { display: grid; gap: 16px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; box-shadow: none; }
.stat .k { font-size: 11px; color: var(--text-3); text-transform: uppercase; letter-spacing: .12em; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.stat .k i { opacity: .6; }
.stat .v { font-size: 40px; font-weight: 600; letter-spacing: -.03em; margin-top: 14px; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .d { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.section-title { font-size: 12px; font-weight: 600; color: var(--text-2); margin: 32px 0 14px; display: flex; align-items: center; gap: 8px; text-transform: uppercase; letter-spacing: .1em; }

/* ---------- Table ---------- */
.table-wrap { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: none; }
table { width: 100%; border-collapse: collapse; }
thead th { text-align: left; font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; padding: 16px 22px; border-bottom: 1px solid var(--border); background: transparent; white-space: nowrap; }
tbody td { padding: 18px 22px; border-bottom: 1px solid var(--border); font-size: 13.5px; }
tbody tr { cursor: pointer; transition: background-color .18s ease; }
tbody tr:hover { background: var(--surface-2); }
tbody tr:last-child td { border-bottom: none; }
.name-cell { display: flex; align-items: center; gap: 12px; font-weight: 600; }

/* ---------- Badges / chips ---------- */
.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); color: var(--text-2); }
.temp { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; }
.temp::before { content: ''; width: 8px; height: 8px; border-radius: 50%; }
.temp--hot::before { background: var(--hot); } .temp--hot { color: var(--hot); }
.temp--warm::before { background: var(--warm); } .temp--warm { color: var(--warm); }
.temp--cold::before { background: var(--cold); } .temp--cold { color: var(--cold); }
.stage-pill { font-size: 12px; font-weight: 500; padding: 4px 10px; border-radius: 6px; background: var(--accent-soft); color: var(--accent); display: inline-block; }
.score-bar { display: inline-flex; align-items: center; gap: 8px; }
.score-bar .track { width: 54px; height: 6px; background: var(--border); border-radius: 4px; overflow: hidden; }
.score-bar .fill { height: 100%; background: var(--accent); }

/* ---------- Drawer (record view) ---------- */
.drawer-overlay { position: fixed; inset: 0; background: rgba(10,12,20,.4); z-index: 60; opacity: 0; animation: fade .2s forwards; }
.drawer { position: fixed; top: 0; right: 0; height: 100vh; width: min(920px, 94vw); background: var(--bg); z-index: 61; box-shadow: -20px 0 60px rgba(0,0,0,.2); display: grid; grid-template-columns: 1fr 320px; transform: translateX(100%); animation: slidein .28s cubic-bezier(.2,.8,.2,1) forwards; }
@keyframes slidein { to { transform: translateX(0); } }
@keyframes fade { to { opacity: 1; } }
.drawer__main { overflow-y: auto; padding: 24px 28px; }
.drawer__side { border-left: 1px solid var(--border); background: var(--surface); overflow-y: auto; padding: 20px; }
.drawer__head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 20px; }
.drawer__head .avatar { width: 46px; height: 46px; font-size: 16px; border-radius: 10px; }
.drawer__head h2 { font-size: 22px; letter-spacing: -.02em; }
.drawer__head .sub { color: var(--text-2); font-size: 13px; margin-top: 3px; }
.detail-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 6px 16px; }
.detail-grid .row { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--border); gap: 12px; font-size: 13px; }
.detail-grid .row:nth-last-child(-n+2) { border-bottom: none; }
.detail-grid .row .l { color: var(--text-3); }
.detail-grid .row .r { color: var(--text); font-weight: 500; text-align: right; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin: 22px 0 16px; }
.tab { padding: 9px 12px; font-size: 13px; font-weight: 500; color: var(--text-2); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tab.active { color: var(--accent); border-color: var(--accent); }
.composer { display: flex; gap: 8px; margin-bottom: 16px; }
.timeline { position: relative; padding-left: 26px; }
.timeline::before { content: ''; position: absolute; left: 9px; top: 4px; bottom: 4px; width: 2px; background: var(--border); }
.tl-item { position: relative; padding: 0 0 18px; }
.tl-item .dot { position: absolute; left: -22px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: var(--surface); border: 2px solid var(--border-strong); display: grid; place-items: center; font-size: 8px; color: var(--text-2); }
.tl-item.t-status .dot { border-color: var(--accent); color: var(--accent); }
.tl-item.t-whatsapp .dot { border-color: var(--won); color: var(--won); }
.tl-item.t-email .dot { border-color: var(--cold); color: var(--cold); }
.tl-item.t-call .dot { border-color: var(--warm); color: var(--warm); }
.tl-item .t { font-size: 13px; font-weight: 500; }
.tl-item .b { font-size: 13px; color: var(--text-2); margin-top: 2px; white-space: pre-wrap; }
.tl-item .m { font-size: 11px; color: var(--text-3); margin-top: 3px; }

/* ---------- Kanban ---------- */
.kanban { display: flex; gap: 16px; overflow-x: auto; padding-bottom: 16px; }
.kcol { min-width: 288px; width: 288px; flex-shrink: 0; background: var(--surface-2); border: 1px solid var(--border); border-radius: 18px; padding: 8px; transition: background-color .2s ease, box-shadow .2s ease; }
.kcol.drop-target { background: var(--accent-weak); box-shadow: inset 0 0 0 2px var(--lime); }
.kcol__head { display: flex; align-items: center; justify-content: space-between; padding: 12px 12px 14px; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.kcol__head .count { color: var(--text-3); font-weight: 700; background: var(--surface); border: 1px solid var(--border); border-radius: 999px; padding: 1px 9px; font-size: 11px; letter-spacing: 0; }
.kcol__body { display: flex; flex-direction: column; gap: 10px; min-height: 60px; padding: 2px; }
.kcard { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 14px; cursor: grab; box-shadow: none; transition: border-color .2s ease, transform .15s ease, box-shadow .2s ease, opacity .2s ease; }
.kcard:hover { border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow); }
.kcard:active { cursor: grabbing; }
.kcard.dragging { opacity: .4; transform: rotate(1.5deg) scale(.98); }
.kcard .kn { font-weight: 600; font-size: 14px; display: flex; align-items: center; gap: 9px; }
.kcard .ks { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.kcard .kf { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; }
.kcard .kdot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* ---------- Modal ---------- */
.modal-overlay { position: fixed; inset: 0; background: rgba(10,12,20,.45); z-index: 80; display: grid; place-items: center; padding: 20px; opacity: 0; animation: fade .18s forwards; }
.modal { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; width: 100%; max-width: 520px; box-shadow: var(--shadow); max-height: 90vh; overflow-y: auto; }
.modal--wide { max-width: 820px; }
.modal__head { padding: 20px 22px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; }
.modal__head h3 { font-size: 17px; letter-spacing: -.01em; }
.modal__body { padding: 22px; }
.modal__foot { padding: 16px 22px; border-top: 1px solid var(--border); display: flex; justify-content: flex-end; gap: 10px; }
/* All form/modal containers stay solid white (no transparency) */
.modal, .modal__head, .modal__body, .modal__foot, form.card, .drawer, .gc-drawer__body { background: #FFFFFF; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

/* ---------- Toast ---------- */
.toast-wrap { position: fixed; bottom: 24px; right: 24px; z-index: 100; display: flex; flex-direction: column; gap: 10px; }
.toast { background: var(--text); color: var(--bg); padding: 12px 16px; border-radius: 9px; font-size: 13px; font-weight: 500; box-shadow: var(--shadow); display: flex; align-items: center; gap: 10px; animation: slidein .25s; min-width: 240px; }
.toast--error { background: var(--hot); color: #fff; }
.toast--success { background: var(--won); color: #fff; }

/* ---------- Misc ---------- */
.toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .spacer { flex: 1; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; }
.empty { text-align: center; padding: 60px 20px; color: var(--text-3); }
.empty i { font-size: 32px; margin-bottom: 12px; opacity: .5; }
.spinner { width: 22px; height: 22px; border: 2.5px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: spin .7s linear infinite; margin: 40px auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.dup-alert { background: color-mix(in srgb, var(--hot) 8%, var(--surface)); border: 1px solid color-mix(in srgb, var(--hot) 30%, var(--border)); border-radius: 8px; padding: 12px 14px; margin-bottom: 14px; font-size: 13px; }
.mono { font-variant-numeric: tabular-nums; }
.pill-row { display: flex; gap: 6px; flex-wrap: wrap; }
.help { font-size: 12px; color: var(--text-3); margin-top: 6px; }
.import-table td, .import-table th { font-size: 12.5px; padding: 8px 10px; }
.tag-ok { color: var(--won); } .tag-bad { color: var(--hot); }
@media (max-width: 980px) {
    .shell { grid-template-columns: 1fr; }
    .nav { position: fixed; z-index: 50; width: var(--nav-w); transform: translateX(-100%); transition: transform .25s; }
    .nav.open { transform: translateX(0); }
    .drawer { grid-template-columns: 1fr; } .drawer__side { display: none; }
    .content { padding: 18px; }
}
.nav-toggle { display: none; }
@media (max-width: 980px) { .nav-toggle { display: grid; } }

/* ---------- Chromeless (onboarding / full-screen) ---------- */
.chromeless { min-height: 100vh; background: var(--bg); }

/* ---------- Skeleton loaders ---------- */
.skeleton { background: linear-gradient(90deg, #F0F0EC 25%, #E5E5DF 50%, #F0F0EC 75%); background-size: 200% 100%; animation: shimmer 1.4s ease-in-out infinite; border-radius: 12px; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* ---------- Executive Dashboard (hero composition) ---------- */
.dash-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 20px; align-items: start; }
.dash-hero { grid-column: span 4; background: var(--accent-soft); border: 1px solid var(--border); border-radius: 24px; padding: 30px; display: flex; flex-direction: column; min-height: 520px; }
.dash-right { grid-column: span 8; display: flex; flex-direction: column; gap: 20px; }
.hero-greet { font-size: 30px; font-weight: 300; letter-spacing: -.02em; line-height: 1.12; color: var(--text); }
.hero-greet b { font-weight: 600; }
.hero-sub { color: var(--text-2); margin-top: 10px; font-size: 13.5px; line-height: 1.5; max-width: 300px; }
.ring-wrap { position: relative; width: 210px; height: 210px; margin: 26px auto 20px; }
.ring-center { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; }
.ring-center .pct { font-size: 34px; font-weight: 600; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.ring-center .cap { font-size: 12px; color: var(--text-2); margin-top: 2px; }
.breakdown { display: flex; justify-content: space-between; gap: 10px; padding-top: 6px; }
.breakdown .bd { flex: 1; }
.breakdown .bd .lbl { font-size: 11px; color: var(--text-2); display: flex; align-items: center; gap: 6px; }
.breakdown .bd .lbl::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--dot, var(--text-3)); }
.breakdown .bd .num { font-size: 22px; font-weight: 600; letter-spacing: -.02em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.hero-foot { margin-top: auto; padding-top: 24px; border-top: 1px solid color-mix(in srgb, var(--text) 8%, transparent); }
.hero-foot .lbl { font-size: 11px; text-transform: uppercase; letter-spacing: .14em; color: var(--text-2); font-weight: 600; }
.hero-num { font-size: 66px; font-weight: 600; letter-spacing: -.045em; line-height: 1; margin-top: 8px; font-variant-numeric: tabular-nums; }
.hero-num .unit { font-size: 22px; color: var(--text-2); font-weight: 500; letter-spacing: 0; margin-left: 6px; }

.kpi-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 20px; overflow: hidden; }
.kpi { background: var(--surface); padding: 22px 24px; transition: background-color .2s ease; }
.kpi:hover { background: var(--surface-2); }
.kpi__label { font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kpi__val { font-size: 42px; font-weight: 600; letter-spacing: -.035em; margin-top: 16px; line-height: 1; font-variant-numeric: tabular-nums; }
.kpi__val .unit { font-size: 18px; color: var(--text-3); font-weight: 500; margin-left: 3px; letter-spacing: 0; }
.kpi__sub { font-size: 12px; color: var(--text-3); margin-top: 8px; }
.delta { font-size: 10.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--text-2); font-variant-numeric: tabular-nums; }
.delta--lime { background: var(--lime); color: #111; }
.delta--up { color: var(--won); background: color-mix(in srgb, var(--won) 12%, transparent); }
.delta--down { color: var(--hot); background: color-mix(in srgb, var(--hot) 10%, transparent); }

.chart-card { background: var(--surface); border: 1px solid var(--border); border-radius: 24px; padding: 28px 28px 22px; }
.chart-card__head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 24px; }
.chart-card__head h3 { font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.chart-card__head .mut { font-size: 12px; color: var(--text-3); }
.bars { display: flex; align-items: flex-end; gap: 14px; height: 200px; }
.bars .barcol { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 10px; height: 100%; justify-content: flex-end; }
.bars .bar { width: 100%; max-width: 44px; border-radius: 8px 8px 3px 3px; background: #E7E7E1; transition: height .8s cubic-bezier(.22,1,.36,1), background-color .2s ease; position: relative; }
.bars .barcol:hover .bar { background: #D8D8D0; }
.bars .barcol.hot .bar { background: var(--lime); }
.bars .barcol .bx { font-size: 11px; color: var(--text-3); font-weight: 500; text-align: center; }
.bars .barcol .bv { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.bars .barcol .btag { position: absolute; top: -26px; left: 50%; transform: translateX(-50%); background: var(--lime); color: #111; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 6px; white-space: nowrap; }
.mini-bars { display: flex; flex-direction: column; gap: 14px; }
.mini-bars .mb { }
.mini-bars .mb__top { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 7px; }
.mini-bars .mb__top b { font-variant-numeric: tabular-nums; }
.mini-bars .mb__track { height: 6px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.mini-bars .mb__fill { height: 100%; background: var(--text); border-radius: 6px; transition: width .7s cubic-bezier(.22,1,.36,1); }

@media (max-width: 1100px) {
    .dash-hero, .dash-right { grid-column: span 12; }
    .dash-hero { min-height: 0; }
    .kpi-row { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) { .kpi-row { grid-template-columns: 1fr 1fr; } }

/* ---------- Sidebar user chip (now a link) ---------- */
.nav__user { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 12px; text-decoration: none; color: inherit; transition: background-color .2s ease; }
.nav__user:hover { background: var(--surface); }

/* ---------- Command palette trigger + overlay ---------- */
.cmdk-trigger { display: inline-flex; align-items: center; gap: 9px; height: 38px; padding: 0 12px 0 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-3); font: inherit; font-size: 13px; cursor: pointer; transition: border-color .2s ease, color .2s ease; }
.cmdk-trigger:hover { border-color: var(--border-strong); color: var(--text-2); }
.cmdk-trigger kbd { font-family: 'Manrope', sans-serif; font-size: 11px; font-weight: 600; background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 2px 6px; color: var(--text-3); }
@media (max-width: 720px) { .cmdk-trigger span, .cmdk-trigger kbd { display: none; } }
.cmdk-overlay { position: fixed; inset: 0; background: color-mix(in srgb, var(--bg) 70%, transparent); backdrop-filter: blur(6px); z-index: 90; display: flex; justify-content: center; align-items: flex-start; padding-top: 12vh; opacity: 0; animation: fade .16s forwards; }
.cmdk { width: min(620px, 92vw); background: var(--surface); border: 1px solid var(--border); border-radius: 18px; box-shadow: var(--shadow); overflow: hidden; }
.cmdk__bar { display: flex; align-items: center; gap: 12px; padding: 18px 20px; border-bottom: 1px solid var(--border); }
.cmdk__bar i { color: var(--text-3); font-size: 16px; }
.cmdk__input { flex: 1; border: none; outline: none; background: transparent; font: inherit; font-size: 18px; color: var(--text); }
.cmdk__list { max-height: 52vh; overflow-y: auto; padding: 8px; }
.cmdk__item { display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 12px; cursor: pointer; }
.cmdk__item i { width: 18px; text-align: center; color: var(--text-2); }
.cmdk__item.active { background: var(--surface-2); box-shadow: inset 2px 0 0 var(--lime); }
.cmdk__item .cmdk__t { font-size: 14px; font-weight: 500; }
.cmdk__item .cmdk__s { font-size: 12px; color: var(--text-3); }
.cmdk__item .cmdk__k { margin-left: auto; font-size: 10px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); }
.cmdk__empty { padding: 30px; text-align: center; color: var(--text-3); font-size: 13px; }

/* ---------- Profile / Account Settings ---------- */
.pf-head { display: flex; align-items: center; gap: 20px; margin-bottom: 28px; }
.pf-avatar { width: 78px; height: 78px; border-radius: 20px; display: grid; place-items: center; color: #fff; font-size: 28px; font-weight: 700; flex-shrink: 0; transition: background-color .25s ease; }
.pf-name { font-size: 26px; font-weight: 700; letter-spacing: -.02em; }
.pf-meta { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.settings-grid { display: grid; grid-template-columns: 220px 1fr; gap: 24px; align-items: start; }
.settings-nav { display: flex; flex-direction: column; gap: 4px; }
.settings-nav__item { display: flex; align-items: center; gap: 11px; padding: 11px 14px; border-radius: 12px; color: var(--text-2); cursor: pointer; font-weight: 500; font-size: 13.5px; transition: background-color .2s ease, color .2s ease; }
.settings-nav__item i { width: 16px; text-align: center; opacity: .8; }
.settings-nav__item:hover { background: var(--surface); color: var(--text); }
.settings-nav__item.active { background: var(--surface); color: var(--text); font-weight: 600; box-shadow: 0 1px 2px rgba(17,17,17,.04), 0 8px 20px -10px rgba(17,17,17,.16); }
.set-block { margin-bottom: 8px; }
.set-block__h { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; margin-bottom: 14px; }
.pf-swatches { display: flex; gap: 10px; margin-bottom: 22px; }
.pf-swatch { width: 34px; height: 34px; border-radius: 10px; border: 2px solid transparent; cursor: pointer; transition: transform .15s ease; }
.pf-swatch:hover { transform: scale(1.08); }
.pf-swatch.active { border-color: var(--text); box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--text); }
.set-rows { display: flex; flex-direction: column; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--border); }
.set-row:last-child { border-bottom: none; }
.set-row__t { font-size: 14px; font-weight: 500; }
.set-row__d { font-size: 12.5px; color: var(--text-3); margin-top: 2px; }
.sw { width: 44px; height: 26px; border-radius: 999px; border: none; background: var(--border-strong); cursor: pointer; position: relative; transition: background-color .2s ease; flex-shrink: 0; }
.sw.is-on { background: var(--text); }
.sw__knob { position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform .2s cubic-bezier(.4,0,.2,1); }
.sw.is-on .sw__knob { transform: translateX(18px); }
@media (max-width: 780px) { .settings-grid { grid-template-columns: 1fr; } .settings-nav { flex-direction: row; overflow-x: auto; } }

/* ---------- Inventory — Spatial Availability Map ---------- */
.inv-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 26px 28px; margin-top: 8px; }
.inv-hero__name { font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.inv-hero__loc { font-size: 13px; color: var(--text-3); margin-top: 4px; }
.inv-legend { display: flex; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.inv-legchip { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; color: var(--text-2); }
.inv-legchip i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.inv-legchip b { color: var(--text); font-variant-numeric: tabular-nums; }
.inv-legchip--available i { background: #fff; border: 1.5px solid var(--border-strong); }
.inv-legchip--held i { background: var(--warm); }
.inv-legchip--booked i { background: var(--lime); }
.inv-legchip--sold i { background: #111; }
.inv-legchip--unlisted i { background: #d5dae2; border: 1px dashed #7f8998; }
.inv-hero__metric { text-align: right; min-width: 170px; }
.inv-hero__num { font-size: 46px; font-weight: 600; letter-spacing: -.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.inv-hero__num .unit { font-size: 18px; color: var(--text-3); font-weight: 500; margin-left: 4px; }
.inv-hero__lbl { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; margin-top: 6px; }
.inv-absorb { height: 6px; border-radius: 6px; background: var(--surface-2); overflow: hidden; margin-top: 12px; }
.inv-absorb span { display: block; height: 100%; background: var(--text); border-radius: 6px; transition: width .8s cubic-bezier(.22,1,.36,1); }
.inv-map { display: flex; flex-wrap: wrap; gap: 10px; }
.inv-cell { width: 92px; height: 68px; border-radius: 12px; border: 1.5px solid var(--border-strong); background: var(--surface); cursor: pointer; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; padding: 0 12px; transition: transform .15s ease, box-shadow .15s ease, background-color .2s ease; }
.inv-cell:hover { transform: translateY(-2px); box-shadow: 0 10px 24px -10px rgba(17,17,17,.25); }
.inv-cell__no { font-weight: 700; font-size: 14px; font-variant-numeric: tabular-nums; }
.inv-cell__t { font-size: 11px; color: var(--text-3); margin-top: 2px; }
.inv-cell--available { background: var(--surface); border-color: var(--border-strong); }
.inv-cell--held { background: color-mix(in srgb, var(--warm) 14%, #fff); border-color: color-mix(in srgb, var(--warm) 40%, var(--border)); }
.inv-cell--held .inv-cell__t { color: var(--warm); }
.inv-cell--booked { background: var(--lime); border-color: #c9e600; }
.inv-cell--booked .inv-cell__t { color: #5a6b00; }
.inv-cell--sold { background: #111; border-color: #111; color: #fff; }
.inv-cell--sold .inv-cell__no { color: #fff; }
.inv-cell--sold .inv-cell__t { color: rgba(255,255,255,.6); }
.inv-cell--unlisted { background: repeating-linear-gradient(-45deg, #f4f6f8, #f4f6f8 6px, #eceff3 6px, #eceff3 12px); border-color: #b8c0ca; }
.inv-cell--unlisted .inv-cell__t { color: #697586; }

/* ---------- People Directory ---------- */
.avatar--lg { width: 46px; height: 46px; border-radius: 14px; font-size: 15px; }
.people-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.person-card { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 20px; transition: box-shadow .2s ease, transform .15s ease; }
.person-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.person-card__top { display: flex; align-items: flex-start; justify-content: space-between; }
.person-card__name { font-size: 15px; font-weight: 600; margin-top: 14px; }
.person-card__email { font-size: 12.5px; color: var(--text-3); margin-top: 2px; }
.person-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 16px; }
.person-card__active { display: flex; align-items: center; gap: 8px; }
.mut { font-size: 11.5px; color: var(--text-3); }

/* ---------- Roles & Access ---------- */
.access-intro { margin-bottom: 20px; }
.access-intro__h { font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.access-intro__p { color: var(--text-2); font-size: 13.5px; margin-top: 8px; max-width: 720px; line-height: 1.55; }
.access-grid { display: grid; grid-template-columns: 280px 1fr; gap: 20px; align-items: start; }
.access-roles { display: flex; flex-direction: column; gap: 4px; }
.access-roles__dept { font-size: 10px; text-transform: uppercase; letter-spacing: .14em; color: var(--text-3); font-weight: 600; padding: 16px 6px 6px; }
.access-role { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 13px 16px; border-radius: 14px; border: 1px solid transparent; background: transparent; cursor: pointer; text-align: left; transition: background-color .2s ease, border-color .2s ease; }
.access-role:hover { background: var(--surface); }
.access-role.active { background: var(--surface); border-color: var(--border); box-shadow: 0 1px 2px rgba(17,17,17,.04), 0 8px 20px -12px rgba(17,17,17,.18); }
.access-role.locked { opacity: .8; }
.access-role__name { font-size: 14px; font-weight: 600; }
.access-role__meta { font-size: 11.5px; color: var(--text-3); margin-top: 2px; }
.access-role i { color: var(--text-3); font-size: 12px; }
.access-role.active i { color: var(--text); }
.access-panel { padding: 26px; }
.access-panel__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.access-panel__role { font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
.access-panel__sub { font-size: 13px; color: var(--text-3); margin-top: 4px; }
.access-groups { display: flex; flex-direction: column; gap: 14px; }
.access-group { border: 1px solid var(--border); border-radius: 16px; overflow: hidden; }
.access-group__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; background: var(--surface-2); }
.access-group__title { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 13.5px; }
.access-group__title i { color: var(--text-2); width: 16px; text-align: center; }
.access-group__count { font-size: 11px; font-weight: 600; color: var(--text-3); background: var(--surface); border: 1px solid var(--border); border-radius: 999px; padding: 2px 9px; font-variant-numeric: tabular-nums; }
.access-group__all { display: flex; align-items: center; gap: 8px; }
.access-feature-rows { padding: 6px 18px; }
.access-feature { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.access-feature:last-child { border-bottom: none; }
.access-feature__t { font-size: 13.5px; font-weight: 500; }
.access-feature__k { font-family: ui-monospace, 'JetBrains Mono', monospace; font-size: 11px; color: var(--text-3); margin-top: 2px; }
@media (max-width: 900px) { .access-grid { grid-template-columns: 1fr; } .access-roles { flex-direction: row; overflow-x: auto; } }
.access-role__diff { font-size: 10px; font-weight: 700; color: #5a6b00; background: var(--lime); border-radius: 999px; padding: 1px 8px; margin-left: 8px; }
.access-panel__actions { display: flex; gap: 8px; align-items: center; }

/* ---------- Messaging split-view ---------- */
.wa-shell { display: grid; grid-template-columns: 320px 1fr 300px; gap: 16px; height: calc(100vh - 176px); }
.wa-shell.no-context { grid-template-columns: 320px 1fr; }
.wa-pane { background: var(--surface); border: 1px solid var(--border); border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; min-width: 0; }
.wa-list__filters { display: flex; gap: 6px; padding: 14px 14px 10px; border-bottom: 1px solid var(--border); }
.wa-list__body { overflow-y: auto; flex: 1; }
.wa-conv { padding: 14px 16px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background-color .18s ease; }
.wa-conv:hover { background: var(--surface-2); }
.wa-conv.active { background: var(--accent-weak); box-shadow: inset 3px 0 0 var(--lime); }
.wa-conv__top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.wa-conv__name { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wa-conv__badge { background: #25D366; color: #fff; border-radius: 999px; padding: 1px 8px; font-size: 11px; font-weight: 700; }
.wa-conv__preview { font-size: 12.5px; color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 4px; }
.wa-conv__meta { font-size: 11px; color: var(--text-3); margin-top: 5px; }
.wa-thread__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--border); }
.wa-msgs { flex: 1; overflow-y: auto; padding: 20px; background: var(--bg); display: flex; flex-direction: column; gap: 10px; }
.wa-composer { border-top: 1px solid var(--border); padding: 14px 16px; }
/* contextual lead panel */
.wa-lead { padding: 22px; overflow-y: auto; }
.wa-lead__avatar { width: 60px; height: 60px; border-radius: 18px; display: grid; place-items: center; font-size: 20px; font-weight: 700; background: var(--accent-weak); color: var(--text); }
.wa-lead__name { font-size: 17px; font-weight: 700; margin-top: 14px; letter-spacing: -.01em; }
.wa-lead__phone { font-size: 12.5px; color: var(--text-3); margin-top: 3px; }
.wa-lead__stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 14px; overflow: hidden; margin: 20px 0; }
.wa-lead__stat { background: var(--surface); padding: 14px; }
.wa-lead__stat .l { font-size: 10px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); font-weight: 600; }
.wa-lead__stat .v { font-size: 20px; font-weight: 700; margin-top: 6px; letter-spacing: -.02em; }
.wa-lead__row { display: flex; justify-content: space-between; padding: 11px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.wa-lead__row:last-child { border-bottom: none; }
.wa-lead__row .k { color: var(--text-3); }
@media (max-width: 1200px) { .wa-shell, .wa-shell.no-context { grid-template-columns: 300px 1fr; } .wa-lead { display: none; } }

/* ---------- Deals editorial ---------- */
.deal-hero { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 20px; overflow: hidden; margin-bottom: 24px; }
.deal-hero__cell { background: var(--surface); padding: 26px 28px; }
.deal-hero__l { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; }
.deal-hero__v { font-size: 38px; font-weight: 600; letter-spacing: -.035em; margin-top: 14px; line-height: 1; font-variant-numeric: tabular-nums; }
.aging-strip { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-bottom: 24px; }
.aging-cell { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px; }
.aging-cell .l { font-size: 11px; color: var(--text-3); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; }
.aging-cell .v { font-size: 20px; font-weight: 600; margin-top: 8px; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.aging-cell--hot { border-color: color-mix(in srgb, var(--hot) 35%, var(--border)); }
.aging-cell--hot .v { color: var(--hot); }

/* ---------- Integrations Hub ---------- */
.ig-intro { margin-bottom: 22px; }
.ig-intro__h { font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.ig-intro__p { color: var(--text-2); font-size: 13.5px; margin-top: 8px; max-width: 720px; line-height: 1.55; }
.ig-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.ig-card { background: var(--surface); border: 1px solid var(--border); border-radius: 20px; padding: 24px; cursor: pointer; transition: box-shadow .2s ease, transform .15s ease, border-color .2s ease; }
.ig-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--border-strong); }
.ig-card__top { display: flex; align-items: flex-start; justify-content: space-between; }
.ig-card__icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; color: #fff; font-size: 20px; }
.ig-card__name { font-size: 16px; font-weight: 700; margin-top: 16px; letter-spacing: -.01em; }
.ig-card__cat { font-size: 10px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3); font-weight: 600; margin-top: 3px; }
.ig-card__desc { font-size: 13px; color: var(--text-2); margin-top: 12px; line-height: 1.5; min-height: 58px; }
.ig-card__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
.ig-status { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; padding: 4px 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 6px; }
.ig-status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ig-status--idle { background: var(--surface-2); color: var(--text-3); }
.ig-status--ok { background: color-mix(in srgb, var(--won) 14%, transparent); color: var(--won); }
.ig-status--err { background: color-mix(in srgb, var(--hot) 12%, transparent); color: var(--hot); }
.ig-enable { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 16px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 14px; margin-bottom: 18px; }
.ig-result { font-size: 13px; margin-top: 12px; min-height: 18px; color: var(--text-3); }
.ig-result--ok { color: var(--won); font-weight: 600; }
.ig-result--err { color: var(--hot); font-weight: 600; }
.ig-docs { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; font-size: 13px; color: var(--text-2); text-decoration: none; }
.ig-docs:hover { color: var(--text); }

/* ===== Notifications bell ===== */
.notif__btn { position: relative; }
.notif__badge { position: absolute; top: -2px; right: -2px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 100px; background: #d64545; color: #fff; font-size: 10px; font-weight: 700; display: flex; align-items: center; justify-content: center; line-height: 1; }
.notif__panel { position: absolute; top: 46px; right: 0; width: 360px; max-width: 92vw; background: var(--surface, #fff); border: 1px solid var(--line, #e5e7d8); border-radius: 14px; box-shadow: 0 18px 50px rgba(20,22,15,.16); z-index: 1200; overflow: hidden; }
.notif__head { display: flex; align-items: center; justify-content: space-between; padding: 13px 16px; border-bottom: 1px solid var(--line, #eee); }
.notif__head b { font-size: 13px; }
.notif__all { background: none; border: 0; color: var(--olive, #4F5823); font-size: 12px; font-weight: 600; cursor: pointer; }
.notif__list { max-height: 62vh; overflow-y: auto; }
.notif__loading, .notif__empty { padding: 34px 16px; text-align: center; color: var(--text-3, #9a9d8c); font-size: 13px; }
.notif__empty i { font-size: 26px; display: block; margin-bottom: 8px; opacity: .5; }
.notif__item { display: flex; gap: 11px; padding: 12px 16px; border-bottom: 1px solid var(--line, #f1f1ea); text-decoration: none; color: inherit; transition: background-color .15s; }
.notif__item:hover { background: var(--cream, #f7f6f0); }
.notif__item--unread { background: #f4f6ea; }
.notif__ico { width: 32px; height: 32px; flex: none; border-radius: 9px; background: #EEF0E2; color: #4F5823; display: flex; align-items: center; justify-content: center; font-size: 13px; }
.notif__txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.notif__txt b { font-size: 12.5px; font-weight: 700; }
.notif__body { font-size: 12px; color: var(--text-2, #6b6f5f); }
.notif__time { font-size: 10.5px; color: var(--text-3, #9a9d8c); margin-top: 1px; }

/* ===== Reports & Analytics ===== */
.rep-wrap { display: flex; flex-direction: column; gap: 18px; }
.rep-tabs { display: flex; gap: 8px; flex-wrap: wrap; }
.rep-tab { padding: 9px 18px; border-radius: 100px; border: 1px solid var(--line, #e5e7d8); background: transparent; color: var(--text-2, #6b6f5f); font-size: 13px; font-weight: 600; cursor: pointer; transition: all .15s; }
.rep-tab:hover { border-color: #4F5823; color: #4F5823; }
.rep-tab--active { background: #4F5823; color: #fff; border-color: #4F5823; }
.rep-body { display: flex; flex-direction: column; gap: 18px; }
.rep-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.rep-kpi { background: var(--surface, #fff); border: 1px solid var(--line, #e5e7d8); border-radius: 16px; padding: 20px 22px; }
.rep-kpi--accent { background: #EEF0E2; border-color: #dfe1d2; }
.rep-kpi__v { font-size: 28px; font-weight: 800; color: #39401a; letter-spacing: -.01em; }
.rep-kpi__l { font-size: 11px; text-transform: uppercase; letter-spacing: .12em; color: var(--text-3, #8a8d7c); margin-top: 6px; }
.rep-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 18px; }
.rep-card { padding: 20px 22px; }
.rep-h { font-size: 14px; margin: 0 0 14px; color: #39401a; }
.rep-bars { display: flex; flex-direction: column; gap: 11px; }
.rep-bar { display: grid; grid-template-columns: 130px 1fr auto; align-items: center; gap: 12px; }
.rep-bar__lbl { font-size: 12px; color: var(--text-2, #6b6f5f); text-transform: capitalize; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rep-bar__track { height: 9px; background: #eef0e2; border-radius: 100px; overflow: hidden; }
.rep-bar__fill { height: 100%; background: linear-gradient(90deg, #6E7A3A, #4F5823); border-radius: 100px; transition: width .5s ease; }
.rep-bar__val { font-size: 12.5px; font-weight: 700; color: #39401a; min-width: 54px; text-align: right; }
@media print { .nav, .topbar, .rep-tabs { display: none !important; } .main, .content { margin: 0 !important; padding: 0 !important; } }

/* WhatsApp Template Builder */
.tpl-builder { display: grid; grid-template-columns: 1.3fr .9fr; gap: 24px; }
.tpl-form { display: flex; flex-direction: column; gap: 14px; }
.tpl-field label { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); font-weight: 700; margin-bottom: 6px; }
.tpl-btns { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.tpl-btn-row { display: grid; grid-template-columns: 1.1fr 1.2fr 1.4fr auto; gap: 8px; align-items: center; }
.tpl-preview-pane { background: #E5DDD5; border-radius: 16px; padding: 20px; position: sticky; top: 0; height: fit-content; }
.tpl-preview-label { font-size: 10px; text-transform: uppercase; letter-spacing: .12em; color: #667781; font-weight: 700; margin-bottom: 10px; }
.wa-preview { display: flex; flex-direction: column; gap: 4px; }
.wa-bubble { background: #fff; border-radius: 8px; border-top-left-radius: 0; padding: 8px 10px 6px; box-shadow: 0 1px 1px rgba(0,0,0,.12); max-width: 88%; position: relative; }
.wa-bubble .wa-h { font-weight: 700; font-size: 14px; color: #111; margin-bottom: 4px; }
.wa-bubble .wa-h.wa-media { background: #cfd8dc; border-radius: 6px; padding: 18px 10px; text-align: center; color: #445; font-size: 12px; }
.wa-bubble .wa-b { font-size: 13.5px; color: #111; white-space: pre-wrap; line-height: 1.4; }
.wa-bubble .wa-f { font-size: 11px; color: #8696a0; margin-top: 5px; }
.wa-bubble .wa-time { font-size: 10px; color: #8696a0; text-align: right; margin-top: 2px; }
.wa-btn { background: #fff; border-radius: 8px; padding: 9px; text-align: center; color: #027eb5; font-size: 13px; font-weight: 600; box-shadow: 0 1px 1px rgba(0,0,0,.1); max-width: 88%; }
@media (max-width: 820px) { .tpl-builder { grid-template-columns: 1fr; } }

/* WhatsApp Flow Builder */
.flow-cards { display: grid; grid-template-columns: repeat(auto-fill,minmax(280px,1fr)); gap: 16px; }
.flow-card { border: 1px solid var(--border); border-radius: 16px; padding: 18px; background: var(--surface); cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .15s; }
.flow-card:hover { border-color: var(--border-strong); box-shadow: 0 8px 30px rgba(17,17,17,.06); transform: translateY(-2px); }
.fc-top { display: flex; justify-content: space-between; align-items: center; }
.fc-name { font-weight: 700; display: flex; align-items: center; gap: 8px; }
.fc-meta { display: flex; justify-content: space-between; font-size: 11px; color: var(--text-3); margin-top: 10px; }
.fc-desc { font-size: 12.5px; color: var(--text-3); margin-top: 8px; }

.flow-builder { display: flex; flex-direction: column; height: calc(100vh - 120px); }
.flow-bar { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; flex-wrap: wrap; }
.flow-bar .flow-name { font-weight: 700; font-size: 15px; max-width: 240px; }
.flow-palette { display: flex; align-items: center; gap: 8px; padding: 10px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.fp-label { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); font-weight: 700; margin-right: 4px; }
.fp-btn { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); font-size: 12.5px; font-weight: 600; cursor: pointer; transition: background .15s, border-color .15s; }
.fp-btn:hover { background: var(--surface-2); border-color: var(--border-strong); }
.flow-canvas-wrap { flex: 1; overflow: auto; border: 1px solid var(--border); border-radius: 16px; margin-top: 12px; background: var(--surface-2); background-image: radial-gradient(rgba(17,17,17,.06) 1px, transparent 1px); background-size: 22px 22px; }
.flow-canvas { position: relative; width: 2600px; height: 1700px; }
.flow-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.flow-link { fill: none; stroke: var(--border-strong); stroke-width: 2; }
.flow-link-dot { fill: var(--cold); }
.flow-node { position: absolute; width: 264px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 6px 22px rgba(17,17,17,.08); overflow: hidden; }
.fn-head { display: flex; align-items: center; gap: 8px; padding: 9px 10px; background: color-mix(in srgb, var(--nc) 14%, var(--surface)); border-bottom: 1px solid var(--border); cursor: grab; border-left: 3px solid var(--nc); }
.fn-head > i:first-child { color: var(--nc); }
.fn-title { flex: 1; border: 0; background: transparent; font-weight: 700; font-size: 13px; color: var(--text); }
.fn-title:focus { outline: none; }
.fn-x { border: 0; background: transparent; color: var(--text-3); cursor: pointer; padding: 3px; border-radius: 6px; }
.fn-x:hover { color: var(--text); background: var(--surface-2); }
.fn-start { color: var(--lime); }
.fn-body { padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.fn-ta { font-size: 12.5px; resize: vertical; }
.fn-out { display: flex; align-items: center; gap: 6px; }
.fn-out-lbl { font-size: 11px; color: var(--text-3); font-weight: 700; white-space: nowrap; }
.flow-target { font-size: 12px; flex: 1; }
.flow-anchor { width: 10px; height: 10px; border-radius: 50%; background: var(--cold); flex: none; }
.fn-opts { display: flex; flex-direction: column; gap: 6px; }
.fn-opt { display: flex; align-items: center; gap: 5px; }
.fn-opt-ic { color: var(--text-3); font-size: 11px; }
.fn-opt .input { font-size: 12px; padding: 5px 7px; }
.fn-opt .flow-target { max-width: 84px; }
.fn-add { display: inline-flex; align-items: center; gap: 6px; border: 1px dashed var(--border-strong); background: transparent; border-radius: 8px; padding: 6px; font-size: 12px; font-weight: 600; color: var(--text-2); cursor: pointer; }
.fn-add:hover { background: var(--surface-2); }
.fn-terminal { display: flex; align-items: center; gap: 8px; font-size: 11.5px; color: var(--text-3); background: var(--surface-2); border-radius: 8px; padding: 7px 9px; }

/* Bot test simulator */
.sim-wrap { display: flex; justify-content: center; }
.sim-phone { width: 340px; background: #E5DDD5; border-radius: 18px; overflow: hidden; display: flex; flex-direction: column; height: 520px; }
.sim-topbar { background: #075E54; color: #fff; padding: 12px 16px; font-weight: 700; font-size: 14px; display: flex; align-items: center; gap: 8px; }
.sim-chat { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.sim-msg { max-width: 80%; padding: 8px 11px; border-radius: 8px; font-size: 13px; line-height: 1.4; white-space: pre-wrap; box-shadow: 0 1px 1px rgba(0,0,0,.1); }
.sim-msg.bot { background: #fff; align-self: flex-start; border-top-left-radius: 0; }
.sim-msg.user { background: #DCF8C6; align-self: flex-end; border-top-right-radius: 0; }
.sim-hint { align-self: flex-start; font-size: 11px; color: #667781; margin: -4px 0 2px; }
.sim-note { align-self: center; font-size: 11px; color: #667781; background: rgba(255,255,255,.6); padding: 3px 10px; border-radius: 10px; }
.sim-input { padding: 10px; background: #F0F0F0; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.sim-input .input { flex: 1; }
.sim-chip { background: #fff; border: 1px solid #ccd0d5; color: #075E54; border-radius: 16px; padding: 7px 14px; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.sim-chip:hover { background: #075E54; color: #fff; }

/* WhatsApp Inbound Rules */
.inbound-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(320px,1fr)); gap: 20px; align-items: start; }
.inbound-card { border: 1px solid var(--border); border-radius: 16px; padding: 20px; background: var(--surface); }
.ic-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.ic-head h3 { font-size: 15px; font-weight: 700; }
.ic-lbl { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); font-weight: 700; margin: 14px 0 6px; }
.switch-lbl { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.oh-days { display: flex; flex-direction: column; gap: 8px; }
.oh-row { display: flex; align-items: center; gap: 8px; }
.oh-day { display: inline-flex; align-items: center; gap: 6px; width: 66px; font-size: 12.5px; font-weight: 600; }
.oh-row .input { padding: 5px 8px; font-size: 12.5px; }
.oh-dash { color: var(--text-3); }
.agent-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.agent-chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border); border-radius: 999px; padding: 6px 12px; font-size: 12.5px; font-weight: 600; cursor: pointer; }
.test-out { margin-top: 14px; display: flex; flex-direction: column; gap: 6px; }
.test-step { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text-2); }
.test-step i { color: var(--cold); font-size: 10px; }
.test-reply { background: #DCF8C6; color: #111; border-radius: 8px; padding: 8px 11px; font-size: 12.5px; margin-top: 4px; }
.inbound-table { width: 100%; }
.kw-chip { display: inline-block; background: var(--surface-2); border-radius: 6px; padding: 2px 7px; font-size: 11px; margin: 2px; }

/* WhatsApp Campaign Manager */
.camp-card { border: 1px solid var(--border); border-radius: 16px; padding: 18px; background: var(--surface); cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .15s; }
.camp-card:hover { border-color: var(--border-strong); box-shadow: 0 8px 30px rgba(17,17,17,.06); transform: translateY(-2px); }
.camp-funnel { margin-top: 12px; display: flex; flex-direction: column; gap: 6px; }
.cf-row { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.cf-lbl { width: 68px; color: var(--text-3); font-weight: 600; }
.cf-track { flex: 1; height: 8px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.cf-fill { height: 100%; border-radius: 6px; transition: width .8s cubic-bezier(.22,1,.36,1); }
.cf-row b { width: 34px; text-align: right; font-variant-numeric: tabular-nums; }
.camp-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 14px; }
.btn--sm { padding: 6px 12px; font-size: 12.5px; }
.camp-stats { display: grid; grid-template-columns: repeat(6,1fr); gap: 10px; margin-bottom: 16px; }
.camp-stat { border: 1px solid var(--border); border-radius: 12px; padding: 12px; text-align: center; }
.cs-val { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.cs-lbl { font-size: 10px; text-transform: uppercase; letter-spacing: .08em; color: var(--text-3); font-weight: 700; margin-top: 2px; }
.camp-audience { border: 1px solid var(--border); border-radius: 14px; padding: 14px; background: var(--surface-2); margin-bottom: 14px; }
.ca-head { display: flex; justify-content: space-between; font-weight: 700; font-size: 13px; margin-bottom: 10px; }
.camp-tpl-preview { margin-top: 8px; background: #E5DDD5; color: #111; border-radius: 8px; padding: 10px 12px; font-size: 12.5px; white-space: pre-wrap; }
.sim-banner { background: color-mix(in srgb, var(--warm) 15%, var(--surface)); border: 1px solid color-mix(in srgb, var(--warm) 40%, var(--border)); color: var(--text); border-radius: 10px; padding: 10px 12px; font-size: 12.5px; margin-bottom: 14px; }

/* ---- WhatsApp bot analytics + connection check (2026-06) ---- */
.wa-astats{display:grid;grid-template-columns:repeat(4,1fr);gap:12px}
.wa-astat{background:var(--surface-2,#f6f6f2);border:1px solid var(--line,#e7e7e1);border-radius:14px;padding:14px;text-align:center}
.wa-astat-n{font-size:26px;font-weight:700;line-height:1}
.wa-astat-l{font-size:11px;text-transform:uppercase;letter-spacing:.04em;color:var(--text-3);margin-top:6px}
.wa-fn-node{border:1px solid var(--line,#e7e7e1);border-radius:12px;padding:10px 12px;margin-bottom:8px}
.wa-fn-head{display:flex;justify-content:space-between;align-items:center;font-size:13px;font-weight:600;margin-bottom:6px}
.wa-fn-cnt{font-size:11px;color:var(--text-3);font-weight:500}
.wa-fn-bar{height:8px;background:var(--surface-2,#eee);border-radius:6px;overflow:hidden}
.wa-fn-fill{height:100%;background:var(--accent,#DFFF00);border-radius:6px;transition:width .5s ease}
.wa-fn-opt{display:flex;justify-content:space-between;align-items:center;font-size:12px;margin-top:6px;padding-left:6px}
.wa-fn-tap{color:var(--text-3);font-variant-numeric:tabular-nums}
.wa-tpl-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:12px;border:1px solid var(--line,#e7e7e1);border-radius:12px;margin-bottom:8px}
.fn-opt-list{margin-bottom:8px}
.ig-check-overall{font-size:16px;font-weight:700;margin-bottom:14px;display:flex;align-items:center;gap:8px}
.ig-check-row{display:flex;gap:10px;align-items:flex-start;padding:10px 0;border-top:1px solid var(--line,#e7e7e1)}
