@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  font-family: 'DM Sans', sans-serif;
  color: #20243a;
  background: #f6f7fb;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --ink: #20243a;
  --muted: #85899d;
  --line: #eceef4;
  --purple: #6857df;
  --purple-dark: #5545c8;
  --panel: #fff;
  --green: #24966a;
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 360px; background: #f6f7fb; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.shell { min-height: 100vh; }

.sidebar {
  position: fixed; inset: 0 auto 0 0; width: 242px; z-index: 3;
  display: flex; flex-direction: column; padding: 27px 17px;
  background: #fff; border-right: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 6px; color: var(--ink); text-decoration: none; font: 800 21px Manrope, sans-serif; letter-spacing: -.7px; }
.brand-mark { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; color: white; background: linear-gradient(145deg,#8578f4,#5c4bd2); box-shadow: 0 7px 16px #6857df33; font: 800 24px Manrope,sans-serif; }
.brand-mark.small { width: 36px; height: 36px; border-radius: 11px; font-size: 19px; }
.brand-sub { display: block; margin-top: 3px; color: #9da0b1; font: 600 9px 'DM Sans',sans-serif; letter-spacing: 1.6px; }
.side-label { margin: 54px 10px 12px; color: #a6a8b8; font-size: 10px; font-weight: 700; letter-spacing: 1.15px; }
.sidebar nav { display: grid; gap: 6px; }
.nav-link { display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 11px; border-radius: 9px; color: #777b90; text-decoration: none; font-size: 13px; font-weight: 600; }
.nav-link:hover { color: var(--purple); background: #f8f7ff; }
.nav-link.active { color: var(--purple); background: #f0efff; }
.nav-icon { width: 20px; text-align: center; font-size: 19px; }
.nav-count { margin-left: auto; color: #8f8ca4; font-size: 11px; }
.sidebar-bottom { display: flex; align-items: center; gap: 9px; margin-top: auto; padding: 14px 5px; border-top: 1px solid var(--line); color: #9296a7; font-size: 11px; }
.online-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #32b77d; box-shadow: 0 0 0 3px #32b77d1d; }

.main-area { min-height: 100vh; max-width: 1800px; margin-left: 242px; padding: 0 42px; }
.topbar { display: flex; align-items: center; justify-content: space-between; height: 72px; margin: 0 -42px 32px; padding: 0 42px; border-bottom: 1px solid var(--line); background: #fff; }
.breadcrumb { color: #9699aa; font-size: 12px; }
.breadcrumb span { margin: 0 9px; color: #cacbd4; }
.breadcrumb strong { color: #45495e; font-weight: 600; }
.user-menu { display: flex; align-items: center; gap: 9px; color: #55596c; font-size: 12px; font-weight: 600; }
.avatar { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #6253d1; background: #e9e6ff; font-weight: 700; }
.icon-button { padding: 5px 8px; border: 0; border-radius: 7px; color: #9295a6; background: transparent; font-size: 18px; }
.icon-button:hover { color: var(--purple); background: #f0efff; }
.page-section { animation: appear .18s ease-out; }
@keyframes appear { from { opacity: .5; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 25px; }
.eyebrow { margin: 0 0 7px; color: #989bad; font-size: 9px; font-weight: 700; letter-spacing: 1.45px; }
.page-heading h1 { margin: 0 0 6px; color: #282c42; font: 700 26px Manrope,sans-serif; letter-spacing: -.8px; }
.muted { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.button { padding: 9px 13px; border: 1px solid #e6e8f0; border-radius: 8px; color: #5e6277; background: #fff; font-size: 11px; font-weight: 600; white-space: nowrap; transition: .15s; }
.button:hover { border-color: #c8c3f6; color: var(--purple); background: #fbfaff; }
.button.primary { border-color: var(--purple); color: #fff; background: var(--purple); box-shadow: 0 3px 8px #6857df2b; }
.button.primary:hover { background: var(--purple-dark); }
.button.full { width: 100%; margin-top: 8px; padding: 12px; }
.button.full span { float: right; }

.metric-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 15px; margin-bottom: 20px; }
.metric-card { min-width: 0; padding: 18px 18px 16px; border: 1px solid var(--line); border-radius: 11px; background: #fff; box-shadow: 0 2px 6px #282c4205; }
.metric-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.metric-label { color: #888ca0; font-size: 11px; font-weight: 600; }
.metric-icon { display: grid; place-items: center; flex: 0 0 34px; width: 34px; height: 34px; border-radius: 10px; font-size: 16px; }
.metric-value { margin: 13px 0 4px; color: #292d42; font: 700 26px Manrope,sans-serif; letter-spacing: -.8px; }
.metric-note { color: #a0a3b2; font-size: 10px; }
.metric-icon.purple { color: #6555d8; background: #f0efff; }
.metric-icon.blue { color: #4f8be3; background: #eaf3ff; }
.metric-icon.orange { color: #e29256; background: #fff2e8; }
.metric-icon.green { color: #36a477; background: #e8f8f0; }
.overview-grid { display: grid; grid-template-columns: minmax(0,1.45fr) minmax(270px,.8fr); gap: 17px; }
.panel { min-width: 0; padding: 19px; border: 1px solid var(--line); border-radius: 11px; background: #fff; box-shadow: 0 2px 6px #282c4204; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 16px; }
.panel h2 { margin: 1px 0 5px; color: #303449; font: 700 14px Manrope,sans-serif; }
.panel-heading .muted { font-size: 10px; }
.quick-links { display: grid; }
.quick-links>a { display: flex; align-items: center; gap: 11px; padding: 13px 0; border-top: 1px solid #f1f2f6; color: var(--ink); text-decoration: none; }
.quick-links>a:first-child { border-top: 0; }
.quick-icon { display: grid; place-items: center; flex: 0 0 34px; width: 34px; height: 34px; border-radius: 9px; font-size: 17px; }
.quick-icon.lilac { color: #6b5bdb; background: #f1efff; }
.quick-icon.mint { color: #35a678; background: #e9f8f1; }
.quick-icon.peach { color: #d98e5a; background: #fff1e8; }
.quick-links b { display: block; margin-bottom: 3px; font-size: 11px; }
.quick-links small { display: block; color: #9699a9; font-size: 9px; }
.quick-links i { margin-left: auto; color: #a4a6b4; font-style: normal; }
.quick-links>a:hover b,.quick-links>a:hover i { color: var(--purple); }
.status-pill { padding: 6px 8px; border-radius: 20px; font-size: 9px; font-weight: 700; }
.status-pill.healthy { color: #24966a; background: #eaf8f1; }
.sync-time { margin: 19px 0 5px; color: #35394e; font: 700 17px Manrope,sans-serif; }
.small-text { font-size: 10px; }
.health-foot { display: flex; align-items: center; gap: 8px; margin-top: 24px; padding-top: 13px; border-top: 1px solid #f0f1f5; color: #717589; font-size: 10px; }
.footer { padding: 27px 0; color: #a1a3b0; font-size: 10px; }
.footer span { padding: 0 5px; }

.data-panel { overflow: hidden; padding: 0; }
.toolbar { display: flex; align-items: center; gap: 10px; padding: 15px 17px; border-bottom: 1px solid var(--line); }
.search-box { display: flex; align-items: center; flex: 1; gap: 8px; max-width: 320px; height: 34px; padding: 0 9px; border: 1px solid #e9eaf1; border-radius: 7px; color: #a0a2b0; }
.search-box span { font-size: 19px; }
.search-box input { width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 11px; }
.search-box input::placeholder { color: #a7a9b6; }
.toolbar select,.bulk-bar select,.dialog select { height: 34px; padding: 0 9px; border: 1px solid #e9eaf1; border-radius: 7px; outline: 0; color: #64687a; background: #fff; font-size: 10px; }
.result-count { margin-left: auto; color: #999cad; font-size: 10px; white-space: nowrap; }
.table-wrap { overflow: auto; }
table { width: 100%; border-collapse: collapse; white-space: nowrap; }
thead { background: #fbfbfd; }
th { height: 39px; padding: 0 13px; border-bottom: 1px solid #eff0f4; color: #999cad; text-align: left; font-size: 9px; font-weight: 700; letter-spacing: .55px; }
td { padding: 11px 13px; border-bottom: 1px solid #f0f1f5; color: #676b7f; font-size: 10px; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fcfcff; }
th:first-child,td:first-child { padding-left: 17px; }
.check-cell { width: 32px; }
input[type=checkbox] { width: 13px; height: 13px; accent-color: var(--purple); }
.contact-name { color: #34384d; font-size: 10px; font-weight: 600; }
.contact-email { margin-top: 3px; color: #9a9dad; font-size: 9px; }
.company-name { color: #5d6175; font-weight: 500; }
.status-badge { display: inline-flex; align-items: center; gap: 5px; padding: 5px 7px; border-radius: 20px; font-size: 9px; font-weight: 600; }
.status-badge:before { width: 5px; height: 5px; border-radius: 50%; background: currentColor; content: ''; }
.status-badge.unclassified { color: #86899a; background: #f1f2f5; }
.status-badge.lead,.status-badge.prospect { color: #d2873e; background: #fff4e7; }
.status-badge.developer { color: #3976b8; background: #eaf3ff; }
.status-badge.customer { color: #278b65; background: #eaf7f0; }
.status-badge.partner { color: #6355cb; background: #f0efff; }
.status-badge.inactive { color: #9a7481; background: #f8eef1; }
.bulk-bar { display: flex; align-items: center; gap: 9px; padding: 10px 16px; border-bottom: 1px solid #e8e5ff; color: #55516e; background: #f5f4ff; font-size: 10px; }
.bulk-bar select { background: #fff; }
.small-button { padding: 8px 11px; }
.text-button { padding: 5px; border: 0; color: #77798a; background: transparent; font-size: 10px; }
.table-footer { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; border-top: 1px solid var(--line); color: #999cad; font-size: 10px; }
.page-button { margin-left: 4px; padding: 6px 10px; }
.empty-state { padding: 34px 12px; color: #999cad; text-align: center; font-size: 11px; }
.edit-button { padding: 7px 10px; border: 0; border-radius: 6px; color: var(--purple); background: #f3f2ff; font-size: 10px; font-weight: 600; }
.edit-button:hover { background: #e9e6ff; }

.date-filter { display: flex; align-items: end; gap: 8px; }
.date-filter label { display: grid; gap: 5px; color: #8c8fa1; font-size: 9px; font-weight: 600; }
.date-filter input { height: 34px; padding: 0 8px; border: 1px solid #e7e8ef; border-radius: 7px; color: #55596d; background: #fff; font-size: 10px; }
.report-metrics { grid-template-columns: repeat(3,minmax(0,1fr)); }
.report-grid { grid-template-columns: minmax(0,1.2fr) minmax(290px,.8fr); }
.chart { display: flex; align-items: end; gap: 4px; height: 210px; overflow-x: auto; padding: 10px 0 0; border-bottom: 1px solid #eceef3; }
.chart-column { position: relative; display: flex; align-items: end; justify-content: center; flex: 1; gap: 2px; min-width: 16px; height: 100%; }
.chart-bar { width: 28%; min-width: 3px; min-height: 2px; border-radius: 3px 3px 0 0; }
.chart-bar.sent { background: #7062df; }
.chart-bar.received { background: #62b7a0; }
.chart-bar.meetings { background: #f2b66e; }
.chart-label { position: absolute; bottom: -17px; color: #a2a4b1; font-size: 8px; white-space: nowrap; }
.chart-legend { display: flex; gap: 15px; margin-top: 22px; color: #898c9d; font-size: 9px; }
.chart-legend span { display: flex; align-items: center; gap: 5px; }
.legend-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; }
.legend-dot.sent { background: #7062df; }
.legend-dot.received { background: #62b7a0; }
.legend-dot.meetings { background: #f2b66e; }
.top-company-list { display: grid; }
.top-company { padding: 10px 0; border-top: 1px solid #f0f1f5; }
.top-company:first-child { border-top: 0; }
.top-company-top { display: flex; justify-content: space-between; gap: 8px; color: #55596c; font-size: 10px; }
.top-company b { font-weight: 600; }
.top-company span { color: #9699a9; }
.top-company-track { height: 4px; overflow: hidden; margin-top: 7px; border-radius: 5px; background: #f0eff7; }
.top-company-track i { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg,#897cf1,#6152d6); }

.notice { position: fixed; top: 82px; right: 25px; z-index: 8; max-width: 340px; padding: 11px 15px; border-radius: 8px; color: #fff; background: #2c3044; box-shadow: 0 8px 22px #20243a22; font-size: 11px; }
.notice.error { background: #a03d4b; }
.dialog-backdrop { position: fixed; inset: 0; z-index: 10; display: grid; place-items: center; padding: 20px; background: #191a2d77; }
.dialog { width: min(440px,100%); padding: 23px; border-radius: 13px; background: #fff; box-shadow: 0 18px 60px #17172a33; }
.dialog-title { display: flex; align-items: start; justify-content: space-between; margin-bottom: 22px; }
.dialog-title h2 { margin: 0; color: #303449; font: 700 16px Manrope,sans-serif; }
.dialog label,.login-card label { display: block; margin: 15px 0 7px; color: #74788c; font-size: 10px; font-weight: 600; }
.dialog input,.dialog select,.login-card input { width: 100%; height: 39px; padding: 0 10px; border: 1px solid #e7e8ef; border-radius: 7px; outline: 0; color: #44485e; background: #fff; font-size: 11px; }
.dialog input:focus,.dialog select:focus,.login-card input:focus { border-color: #988ef0; box-shadow: 0 0 0 3px #7162df14; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 23px; }

.login-screen { display: grid; place-items: center; min-height: 100vh; padding: 20px; background: radial-gradient(ellipse at 30% 20%,#f0eeff,transparent 38%),#f6f7fb; }
.login-card { width: min(390px,100%); padding: 34px; border: 1px solid var(--line); border-radius: 15px; background: #fff; box-shadow: 0 16px 55px #33325e0c; }
.login-card .brand-mark { margin-bottom: 26px; }
.login-card h1 { margin: 0 0 7px; color: #2c3044; font: 700 21px Manrope,sans-serif; letter-spacing: -.55px; }
.login-card>.muted { margin-bottom: 25px; }
.login-card input { height: 42px; }
.form-error { min-height: 16px; margin: 8px 0; color: #b84350; font-size: 10px; }
.login-foot { margin: 20px 0 0; color: #a1a3b1; text-align: center; font-size: 9px; }

@media (min-width: 1800px) { .main-area { margin-right: auto; } }
@media (max-width: 1050px) {
  .main-area { margin-left: 218px; padding: 0 25px; }
  .topbar { margin: 0 -25px 27px; padding: 0 25px; }
  .sidebar { width: 218px; }
  .metric-grid { gap: 10px; }
  .metric-card { padding: 15px; }
  .overview-grid,.report-grid { grid-template-columns: 1fr; }
  .health-panel { min-height: 160px; }
}
@media (max-width: 760px) {
  .sidebar { width: 62px; align-items: center; padding: 18px 8px; }
  .brand { padding: 0; }
  .brand>span:nth-child(2),.side-label { display: none; }
  .sidebar nav { width: 100%; margin-top: 32px; }
  .nav-link { justify-content: center; padding: 0; font-size: 0; }
  .nav-link .nav-icon { font-size: 18px; }
  .nav-count,.sidebar-bottom { display: none; }
  .main-area { margin-left: 62px; padding: 0 15px; }
  .topbar { height: 60px; margin: 0 -15px 23px; padding: 0 15px; }
  .page-heading { align-items: flex-start; flex-direction: column; }
  .page-heading h1 { font-size: 23px; }
  .metric-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .metric-value { font-size: 23px; }
  .toolbar { flex-wrap: wrap; }
  .search-box { min-width: 100%; max-width: none; }
  .toolbar select { flex: 1; }
  .result-count { margin-left: 0; }
  .bulk-bar { flex-wrap: wrap; }
  .date-filter { width: 100%; flex-wrap: wrap; }
  .date-filter label { flex: 1; }
  .date-filter input { width: 100%; }
  .report-metrics { grid-template-columns: 1fr; }
  .panel { padding: 14px; }
  .data-panel { padding: 0; }
  .table-footer { padding: 10px; }
  .user-menu { gap: 6px; }
  .user-menu>span { max-width: 85px; overflow: hidden; text-overflow: ellipsis; }
  .chart-column:nth-child(odd) .chart-label { display: none; }
}

.eyebrow { font-size: 11px; }
.muted { font-size: 14px; }
.nav-link { font-size: 14px; }
.page-heading h1 { font-size: 30px; }
.button { font-size: 13px; }
.metric-label { font-size: 13px; }
.metric-value { font-size: 30px; }
.metric-note { font-size: 12px; }
.panel h2 { font-size: 16px; }
.panel-heading .muted { font-size: 12px; }
.quick-links b { font-size: 13px; }
.quick-links small { font-size: 11px; }
.status-pill { font-size: 11px; }
.small-text { font-size: 12px; }
.health-foot { font-size: 12px; }
.footer { font-size: 12px; }
.search-box input,.toolbar select,.bulk-bar select,.dialog select { font-size: 12px; }
.result-count { font-size: 12px; }
th { font-size: 11px; }
td { font-size: 12px; }
.contact-name { font-size: 12px; }
.contact-email { font-size: 11px; }
.status-badge { font-size: 11px; }
.bulk-bar,.text-button,.table-footer,.edit-button { font-size: 12px; }
.empty-state { font-size: 13px; }
.date-filter label { font-size: 11px; }
.date-filter input { font-size: 12px; }
.chart-label { font-size: 10px; }
.chart-legend { font-size: 11px; }
.top-company-top { font-size: 12px; }
.notice { font-size: 13px; }
.dialog label,.login-card label { font-size: 12px; }
.dialog input,.dialog select,.login-card input { font-size: 13px; }
.form-error { font-size: 12px; }
.login-foot { font-size: 11px; }
.login-card h1 { font-size: 23px; }

@media (max-width: 760px) {
  .nav-link { font-size: 0; }
  .page-heading h1 { font-size: 27px; }
  .metric-value { font-size: 26px; }
}

