/* Antenity CRM visual polish — intentionally additive for safe rollback. */
:root{
  --polish-radius:10px;
  --polish-radius-sm:7px;
  --polish-shadow:0 1px 2px rgba(15,35,55,.07),0 8px 24px rgba(15,35,55,.055);
  --polish-shadow-hover:0 2px 4px rgba(15,35,55,.08),0 12px 28px rgba(15,35,55,.09);
  --polish-focus:0 0 0 3px rgba(1,118,211,.22);
}

body.crm-app{background:linear-gradient(180deg,#f5f8fb 0,#eef3f7 42%,#edf2f6 100%);font-feature-settings:"kern" 1,"liga" 1;text-rendering:optimizeLegibility}
body.crm-app::before{background-size:360px auto;opacity:.018}

.app-rail{background:linear-gradient(180deg,#06233a 0,#071b2d 48%,#061827 100%);border-right-color:#173c58;box-shadow:4px 0 18px rgba(2,21,37,.08)}
.rail-brand{height:62px;background:rgba(255,255,255,.025)}
.rail-brand img{width:40px;height:40px;filter:drop-shadow(0 3px 7px rgba(0,0,0,.2))}
.rail-nav{padding:10px 6px;gap:3px}
.rail-nav a{min-height:55px;border:1px solid transparent;border-radius:8px;color:#c9dae7;font-weight:650;letter-spacing:.01em;transition:background .16s ease,color .16s ease,transform .16s ease}
.rail-nav a:hover{background:rgba(255,255,255,.09);transform:translateY(-1px)}
.rail-nav a.active{background:linear-gradient(135deg,#0c4e7c,#123b5c);border-color:rgba(129,211,229,.22);box-shadow:inset 0 1px rgba(255,255,255,.08),0 4px 10px rgba(0,0,0,.14)}
.rail-nav a.active::before{inset:7px auto 7px -6px;width:4px;background:#2de0e5}

.sf-shell{padding-top:112px}
.global-bar{height:62px;padding:0 22px;border-bottom-color:#d8e2ea;box-shadow:0 2px 10px rgba(15,35,55,.07)}
.global-brand{font-size:19px;letter-spacing:-.01em}
.global-search{height:40px;border-color:#a8b7c4;border-radius:9px;box-shadow:inset 0 1px 2px rgba(15,35,55,.04);transition:border-color .16s ease,box-shadow .16s ease}
.global-search:focus-within{border-color:var(--brand);box-shadow:var(--polish-focus)}
.global-search input{font-size:14px}
.icon-action{width:36px;height:36px;transition:background .16s ease,transform .16s ease}
.icon-action:hover{background:#eaf4fd;transform:translateY(-1px)}

.workspace-nav{top:62px;height:50px;padding:0 20px;border-bottom-color:#d8e2ea;box-shadow:0 2px 7px rgba(15,35,55,.045)}
.workspace-name{font-weight:750;letter-spacing:-.01em}
.app-grid{border-radius:8px;background:linear-gradient(135deg,#0b8f87,#087a9e);box-shadow:0 4px 10px rgba(11,143,135,.18)}
.workspace-tabs>a,.more-menu>summary{padding:0 14px;font-weight:540;transition:background .14s ease,color .14s ease}
.workspace-tabs>a.active{color:var(--brand-dark);font-weight:750}
.workspace-tabs>a.active::after{height:4px;border-radius:4px 4px 0 0}

.shell-main{padding:20px 24px 34px}
.page-titlebar,.record-hero,.calendar-head,.sf-list-view,.record-card,.home-card,.metric-tile,.dashboard-widget,.panel,.card{border-color:#d7e0e7;border-radius:var(--polish-radius);box-shadow:var(--polish-shadow)}
.record-card,.home-card,.metric-tile,.mini-report{transition:border-color .16s ease,box-shadow .16s ease,transform .16s ease}
.metric-tile:hover,.mini-report:hover{border-color:#a9c8df;box-shadow:var(--polish-shadow-hover);transform:translateY(-1px)}
.record-hero{min-height:104px;padding:20px 22px;background:linear-gradient(110deg,#fff 0,#fff 70%,#f3f9fd 100%)}
.record-hero-icon,.list-object-icon,.page-titlebar .object-icon{box-shadow:inset 0 1px rgba(255,255,255,.24),0 5px 13px rgba(11,143,135,.18)}
.record-hero h1,.calendar-head h1,.list-title-row h1{letter-spacing:-.025em}
.record-hero h1{font-size:26px}
.record-hero p{margin-top:4px}

.btn{border-radius:var(--polish-radius-sm);font-weight:650;transition:background .15s ease,border-color .15s ease,box-shadow .15s ease,transform .15s ease}
.btn:hover{box-shadow:0 3px 9px rgba(15,35,55,.12);transform:translateY(-1px)}
.btn:focus-visible,.icon-action:focus-visible,.tool-button:focus-visible,.workspace-tabs>a:focus-visible,.rail-nav a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,summary:focus-visible{outline:0;box-shadow:var(--polish-focus)}
.record-actions{gap:7px}

.sf-list-view{overflow:clip}
.list-header{padding:19px 20px 14px}
.list-meta-toolbar{padding:2px 20px 12px}
.list-actions .btn:first-child{border-radius:7px 0 0 7px}.list-actions .btn:last-child{border-radius:0 7px 7px 0}
.list-search{height:34px;border-color:#a8b7c4;border-radius:7px;transition:border-color .16s ease,box-shadow .16s ease}
.list-search:focus-within{border-color:var(--brand);box-shadow:var(--polish-focus)}
.tool-button{width:34px;height:34px;border-color:#c6d2db;border-radius:7px}
.bulk-strip{padding:9px 20px;background:#f8fafc}
.list-table-wrap{scrollbar-color:#a9b8c4 transparent;scrollbar-width:thin}
.list-table-wrap::-webkit-scrollbar{height:9px}.list-table-wrap::-webkit-scrollbar-thumb{background:#a9b8c4;border:2px solid transparent;border-radius:9px;background-clip:padding-box}
.sf-table th{height:40px;background:#f6f8fa;color:#31475a;font-size:12px;letter-spacing:.01em}
.sf-table td{height:48px;border-right-color:#edf1f4}
.sf-table tbody tr{transition:background .12s ease}
.sf-table tbody tr:nth-child(even){background:#fbfcfd}
.sf-table tbody tr:hover{background:#eef7fd}
.sf-table a.record-link{color:#076ba9;font-weight:750}
.sf-table .row-action{border-color:#cbd6de;border-radius:7px;background:#fff}
.status-pill{border:1px solid rgba(1,118,211,.1);padding:3px 9px;font-weight:650}

.record-layout{gap:18px}.record-primary,.record-side{gap:18px}
.record-card-head{min-height:52px;padding:14px 18px;background:linear-gradient(180deg,#fff,#fbfcfd)}
.record-card-head h2{color:#17324d;font-size:16px;letter-spacing:-.01em}
.publisher-grid summary{min-height:47px}
.timeline{padding:5px 20px 18px}.timeline article{padding:16px 0}
.detail-grid{padding:5px 18px 18px}.detail-grid>div{padding:12px 0}
.detail-grid dt{letter-spacing:.045em}.detail-grid dd{color:#253b4f}

.home-hero{min-height:118px;border-color:#b8d8ee;border-radius:var(--polish-radius);box-shadow:var(--polish-shadow);background:linear-gradient(112deg,#fff 0,#f7fbfe 62%,#e8f6ff 100%)}
.home-hero h1{font-size:28px;letter-spacing:-.025em}
.metric-tile{min-height:118px;padding:19px;border-radius:var(--polish-radius)}
.metric-tile::before{width:5px;background:linear-gradient(180deg,#0b8f87,#0176d3)}
.metric-tile strong{font-size:29px;letter-spacing:-.025em}
.mini-report{border-radius:8px;background:linear-gradient(180deg,#fff,#f8fbfd)}
.home-titlebar{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 18px;background:#fff;border:1px solid #c9c9c9;border-radius:var(--polish-radius);box-shadow:var(--polish-shadow)}
.home-titlebar h1{margin:0;color:#181818;font-size:24px}.home-titlebar .home-actions{margin:0}
.welcome-panel{overflow:hidden;background:#fff;border:1px solid #c9c9c9;border-radius:var(--polish-radius);box-shadow:var(--polish-shadow)}
.welcome-panel-head{display:flex;align-items:flex-start;justify-content:space-between;padding:18px 20px 12px;background:linear-gradient(105deg,#fff 0,#f5faff 75%,#eaf5fd 100%)}
.welcome-panel-head h2{margin:0 0 3px;color:#181818;font-size:20px}.welcome-panel-head p{margin:0;color:#5c5c5c}
.suggestion-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1px;background:#e5e5e5;border-top:1px solid #e5e5e5}
.suggestion-grid>a{display:grid;grid-template-columns:42px 1fr;align-items:center;column-gap:12px;min-height:102px;padding:16px 18px;color:#181818;background:#fff;text-decoration:none}
.suggestion-grid>a:hover{background:#f7fbff}.suggestion-grid>a>span{grid-row:1/3;display:grid;place-items:center;width:40px;height:40px;border-radius:7px;color:#fff;background:#706e6b}.suggestion-grid>a:nth-child(2)>span{background:#9050e9}.suggestion-grid>a:nth-child(3)>span{background:#1b96ff}.suggestion-grid svg{width:20px;height:20px}.suggestion-grid strong{align-self:end;font-size:14px}.suggestion-grid small{align-self:start;color:#5c5c5c;line-height:1.35}
.report-card-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.report-card{overflow:hidden;background:#fff;border:1px solid #c9c9c9;border-radius:var(--polish-radius);box-shadow:var(--polish-shadow)}
.report-card-head{display:flex;align-items:center;justify-content:space-between;padding:12px 14px;border-bottom:1px solid #e5e5e5}.report-card-head>div{display:flex;align-items:center;gap:9px}.report-card-head span{display:grid;place-items:center;width:32px;height:32px;border-radius:6px;color:#fff;background:#1b96ff}.report-card-head svg{width:17px}.report-card-head h2{margin:0;font-size:16px}.report-card-chart{position:relative;display:grid;grid-template-columns:1fr auto;grid-template-rows:1fr auto;min-height:132px;padding:20px;color:#181818;text-decoration:none;background:linear-gradient(180deg,#fff,#fbfcfd)}
.report-card-chart i{align-self:end;width:92%;height:56px;border-radius:5px 5px 0 0;background:linear-gradient(90deg,#1b96ff var(--report-level),#d8edff var(--report-level));box-shadow:inset 0 -1px #9ecce9}.report-card-chart strong{align-self:center;color:#032d60;font-size:31px}.report-card-chart small{grid-column:1/3;margin-top:10px;color:#0176d3;font-weight:700}.report-card footer{display:flex;justify-content:space-between;padding:9px 14px;border-top:1px solid #e5e5e5;color:#706e6b;font-size:11px}.report-card footer a{display:flex;align-items:center;gap:4px}.report-card footer svg{width:13px;height:13px}
.home-side-stack{display:grid;align-content:start;gap:16px}.recent-record-list{display:grid}.recent-record-list>a{display:flex;gap:11px;align-items:center;padding:11px 15px;border-bottom:1px solid #eee;color:#181818;text-decoration:none}.recent-record-list>a:hover{background:#f7fbff}.recent-record-list>a>span:first-child{display:grid;place-items:center;width:30px;height:30px;border-radius:5px;color:#fff;background:#706e6b}.recent-record-list svg{width:15px;height:15px}.recent-record-list strong,.recent-record-list small{display:block}.recent-record-list small{margin-top:2px;color:#706e6b}

.record-page .record-card .list-table-wrap:first-child,.sf-list-view>.record-layout .list-table-wrap{border-top:0}
.sf-list-view>.record-layout{padding:0 18px 18px}
.sf-list-view>.record-layout .record-card{min-height:0}
.sf-list-view>.record-layout .sf-table{min-width:680px}
.sf-list-view>.record-layout .record-card .empty{display:grid;place-items:center;min-height:92px;margin:0;padding:20px;color:var(--muted);background:#fbfcfd;text-align:center}

.user-menu>div,.more-menu>div,.action-menu>div,.toolbar-menu>div,.row-menu>div,.filter-menu>form{border-color:#cbd6df;border-radius:9px;box-shadow:0 10px 30px rgba(15,35,55,.18)}
.settings-tabs{border-radius:9px}
.utility-bar{height:36px;border-top-color:#d6e0e8;box-shadow:0 -2px 8px rgba(15,35,55,.055)}

[data-theme="dark"] body.crm-app{background:linear-gradient(180deg,#0b1220,#0c1624)}
[data-theme="dark"] .record-hero{background:linear-gradient(110deg,#111c2e 0,#111c2e 70%,#142741 100%)}
[data-theme="dark"] .record-card-head{background:linear-gradient(180deg,#111c2e,#101a2a)}
[data-theme="dark"] .record-card-head h2,[data-theme="dark"] .detail-grid dd{color:#e7edf6}
[data-theme="dark"] .sf-table tbody tr:nth-child(even),[data-theme="dark"] .sf-list-view>.record-layout .record-card .empty{background:#101a2a}
[data-theme="dark"] .sf-table tbody tr:hover{background:#172a43}
[data-theme="dark"] .sf-table .row-action{background:#111c2e;border-color:#304158}
[data-theme="dark"] .home-titlebar,[data-theme="dark"] .welcome-panel,[data-theme="dark"] .suggestion-grid>a,[data-theme="dark"] .report-card,[data-theme="dark"] .report-card-chart{background:#111c2e;border-color:#304158;color:#e7edf6}[data-theme="dark"] .welcome-panel-head{background:linear-gradient(105deg,#111c2e,#142741)}[data-theme="dark"] .home-titlebar h1,[data-theme="dark"] .welcome-panel h2,[data-theme="dark"] .suggestion-grid>a,[data-theme="dark"] .report-card-chart{color:#e7edf6}
.lead-intake-note{display:flex;gap:12px;align-items:flex-start;padding:13px 15px;border:1px solid #b8d7f3;border-left:4px solid var(--sf-blue,#0176d3);border-radius:10px;background:#f3f9ff;color:#16325c}
.lead-intake-note strong{white-space:nowrap}.lead-intake-note span{color:#3e526b;line-height:1.45}
[data-theme="dark"] .lead-intake-note{background:#11243a;border-color:#245786;color:#e7edf6}[data-theme="dark"] .lead-intake-note span{color:#bac8d8}

@media(max-width:1050px){.shell-main{padding:16px}.record-layout{gap:14px}.sf-list-view>.record-layout{padding:0 14px 14px}.suggestion-grid{grid-template-columns:1fr}.report-card-grid{grid-template-columns:1fr 1fr}}
@media(max-width:760px){.global-bar{padding:0 12px}.workspace-nav{padding:0 10px}.shell-main{padding:10px}.record-hero{padding:16px}.record-hero h1{font-size:23px}.sf-list-view>.record-layout{padding:0 10px 10px}.list-header{padding:15px}.list-meta-toolbar{padding:0 15px 12px}}
@media(max-width:640px){.lead-intake-note{display:block}.lead-intake-note strong{display:block;margin-bottom:4px}.home-titlebar{align-items:flex-start;flex-direction:column}.report-card-grid{grid-template-columns:1fr}.suggestion-grid>a{min-height:88px}.report-card-chart{min-height:112px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{scroll-behavior:auto!important;transition-duration:.01ms!important;animation-duration:.01ms!important;animation-iteration-count:1!important}}

/* Lightning-density pass: Salesforce-like geometry with Antenity identity. */
:root{
  --polish-radius:4px;
  --polish-radius-sm:4px;
  --polish-shadow:0 2px 2px rgba(0,0,0,.05);
  --polish-shadow-hover:0 2px 4px rgba(0,0,0,.12);
}
html{font-size:16px}
body.crm-app{background:#f3f3f3;color:#181818;font-family:Arial,"Helvetica Neue",sans-serif}
.app-rail{width:72px;background:#032d60;border-right:0;box-shadow:none}
.rail-brand{height:56px;background:#fff;border-right:1px solid #c9c9c9}
.rail-brand img{width:36px;height:36px;filter:none}
.rail-nav{padding:8px 5px;gap:2px}
.rail-nav a{min-height:58px;border-radius:4px;color:#fff;font-size:10px;font-weight:400;letter-spacing:0}
.rail-nav a:hover{background:#0b5cab;transform:none}
.rail-nav a.active{background:#0b5cab;border-color:transparent;box-shadow:none}
.rail-nav a.active::before{inset:0 auto 0 -5px;width:4px;background:#1b96ff;border-radius:0}
.rail-nav svg{width:23px;height:23px}
.sf-shell{margin-left:72px;padding-top:106px}
.global-bar{height:56px;padding:0 20px;background:#fff;border-bottom:1px solid #c9c9c9;box-shadow:none}
.global-brand{font-size:18px;font-weight:700;color:#032d60}
.global-search{width:min(515px,44vw);height:36px;border:1px solid #939393;border-radius:4px;box-shadow:none}
.global-search:focus-within{border-color:#1b96ff;box-shadow:0 0 3px #0176d3}
.icon-action{width:32px;height:32px;border-radius:50%;color:#706e6b}
.icon-action:hover{background:#f3f3f3;transform:none}
.workspace-nav{top:56px;height:50px;padding:0 20px;background:#fff;border-bottom:1px solid #c9c9c9;box-shadow:0 2px 3px rgba(0,0,0,.08)}
.app-grid{width:32px;height:32px;border-radius:4px;background:#0b8f87;box-shadow:none}
.workspace-name{font-size:16px;font-weight:700;color:#181818}
.workspace-tabs>a,.more-menu>summary{height:50px;padding:0 13px;color:#181818;font-size:13px;font-weight:400}
.workspace-tabs>a:hover,.more-menu>summary:hover{background:#f3f3f3;color:#0176d3}
.workspace-tabs>a.active{color:#032d60;font-weight:700}
.workspace-tabs>a.active::after{height:3px;background:#1b96ff;border-radius:0}
.shell-main{max-width:none;padding:16px 20px 40px}
.page-titlebar,.record-hero,.calendar-head,.sf-list-view,.record-card,.home-card,.metric-tile,.dashboard-widget,.panel,.card,.home-titlebar,.welcome-panel,.report-card{border:1px solid #c9c9c9;border-radius:4px;box-shadow:0 2px 2px rgba(0,0,0,.05)}
.home-titlebar{min-height:64px;padding:12px 16px}
.home-titlebar h1{font-size:24px;font-weight:700;line-height:1.25}
.btn{min-height:32px;padding:0 16px;border-radius:4px;font-size:13px;font-weight:700;box-shadow:none}
.btn:hover{box-shadow:none;transform:none}
.btn:not(.secondary):not(.danger){background:#0176d3;border-color:#0176d3}
.btn:not(.secondary):not(.danger):hover{background:#014486;border-color:#014486}
.welcome-panel-head{padding:20px 20px 16px;background:linear-gradient(100deg,#fff 0,#fff 64%,#eef7fd 100%)}
.welcome-panel-head h2{font-size:20px;line-height:1.25}
.suggestion-grid>a{min-height:98px;padding:16px 18px}
.suggestion-grid>a>span{width:40px;height:40px;border-radius:4px}
.metric-grid{gap:12px}
.metric-tile{min-height:122px;padding:18px;background:#fff}
.metric-tile::before{width:4px;background:#1b96ff}
.metric-tile strong{font-size:28px;color:#032d60}
.report-card-grid{gap:12px}
.report-card-head{min-height:52px;padding:10px 14px}
.report-card-head span{border-radius:4px}
.report-card-chart{min-height:138px;padding:18px 20px;background:#fff}
.report-card-chart i{height:52px;border-radius:2px 2px 0 0}
.report-card footer{min-height:34px;padding:8px 14px;background:#fff}
.record-layout{gap:12px}.record-primary,.record-side,.home-side-stack{gap:12px}
.record-hero{min-height:96px;padding:16px 20px;background:#fff}
.record-hero h1{font-size:24px}
.record-card-head{min-height:50px;padding:12px 16px;background:#fff}
.sf-list-view{background:#fff}
.list-header{padding:16px 16px 10px}
.list-meta-toolbar{padding:0 16px 10px}
.sf-table th{height:32px;background:#fafaf9;color:#444;font-size:12px;font-weight:700}
.sf-table td{height:44px;background:#fff}
.sf-table tbody tr:nth-child(even){background:#fff}
.sf-table tbody tr:hover{background:#f3f8fc}
.status-pill{border-radius:12px}
.utility-bar{height:36px;background:#fff;border-top:1px solid #c9c9c9;box-shadow:0 -1px 3px rgba(0,0,0,.08)}
.path-guidance{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:14px 18px;background:#fff;border:1px solid #c9c9c9;border-top:0;border-radius:0 0 4px 4px}.path-guidance div{display:grid;gap:3px}.path-guidance small{color:#5c5c5c;font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.04em}.path-guidance strong{color:#032d60;font-size:14px}.path-guidance p{margin:0;color:#444;font-size:13px}.record-tabs{display:flex;align-items:center;gap:24px;min-height:44px;padding:0 18px;background:#fff;border:1px solid #c9c9c9;border-radius:4px}.record-tabs a{display:flex;align-items:center;min-height:44px;color:#444;font-size:13px;font-weight:700;border-bottom:3px solid transparent}.record-tabs a:hover,.record-tabs a:focus,.record-tabs a.active{color:#0176d3;border-bottom-color:#0176d3;text-decoration:none}.record-page [id]{scroll-margin-top:130px}
@media(max-width:760px){.sf-shell{margin-left:0;padding-top:106px}.app-rail{width:0}.shell-main{padding:12px}.global-search{width:min(360px,52vw)}}
@media(max-width:760px){.path-guidance{align-items:flex-start;flex-direction:column}.record-tabs{gap:16px;overflow:auto}}
