/* MoveDatabase v2: readable, minimal CRM cards (home + customer demo) */
:root { --move-status-column:84px; --move-status-gap:12px; }
.crm-feed {
  --crm-line:#e7ecf2;
  --crm-ink:#1e3047;
  --crm-muted:#697a90;
  border:1px solid #e1e8f0;
  border-radius:14px;
  background:#fff;
  overflow:hidden;
}
.crm-entry {
  display:grid;
  grid-template-columns:var(--move-status-column) 112px minmax(0,1fr) 30px;
  align-items:start;
  gap:12px;
  min-width:0;
  padding:15px 16px;
  border-bottom:1px solid var(--crm-line);
  color:var(--crm-ink);
  text-decoration:none;
}
.crm-entry:last-of-type {border-bottom:0;}
/* The record body is plain text: drag-to-select and copy without navigation. */
.crm-entry-main {user-select:text;-webkit-user-select:text;}
.crm-customer-link {display:inline;text-decoration:none;color:inherit;}
.crm-customer-link:hover {text-decoration:underline;text-underline-offset:3px;color:#285db5;}
.crm-customer-link:focus-visible {outline:3px solid #9abaf2;outline-offset:2px;border-radius:3px;}
/* Calm visual priority: today gets a thin accent, earlier records recede. */
.crm-entry--today {background:#f3f8ff;}
.crm-entry--today .crm-when time {color:#285b9f;}
.crm-entry--past {background:#fafbfc;}
.crm-entry--past .crm-entry-title {color:#607083;}
.crm-entry--past .crm-entry-summary,
.crm-entry--past .crm-entry-result,
.crm-entry--past .crm-entry-meta {color:#778598;}
.crm-when {
  display:flex;
  flex-direction:column;
  gap:3px;
  padding-top:1px;
  color:var(--crm-muted);
  font-size:12px;
  line-height:1.5;
  font-variant-numeric:tabular-nums;
}
.crm-when time {color:#2c4b73;font-size:12.5px;font-weight:750;white-space:nowrap;}
.crm-time {font-size:12px;}
.crm-type-empty{grid-column:1;}
.crm-type {
  justify-self:start;
  grid-column:1;
  max-width:100%;
  box-sizing:border-box;
  white-space:normal;
  overflow-wrap:anywhere;
  text-align:center;
  border-radius:7px;
  padding:4px 9px;
  background:#f0f4f8;
  color:#52647b;
  font-size:12px;
  font-weight:700;
}
/* Category color is stable across today and past rows. */
.crm-type--inquiry {color:#245ba6;background:#eaf2ff;}
.crm-type--visit {color:#6a4ca0;background:#f0ebfa;}
.crm-type--delivery {color:#236f55;background:#e9f6ee;}
.crm-type--supplies {color:#876023;background:#fff3da;}
.crm-type--call,.crm-type--other {color:#596b83;background:#edf2f7;}
.crm-entry-main {min-width:0;}
.crm-entry-title {
  color:#172b46;
  font-size:15px;
  font-weight:800;
  line-height:1.45;
  overflow-wrap:anywhere;
}
.crm-entry-meta {
  display:flex;
  flex-wrap:wrap;
  gap:3px 0;
  margin:3px 0 6px;
  color:#66788d;
  font-size:12.5px;
  line-height:1.6;
}
.crm-meta-item {min-width:0;overflow-wrap:anywhere;}
.crm-meta-item + .crm-meta-item::before {
  content:"·";
  margin:0 10px;
  color:#b5c0cd;
}
.crm-meta-item--staff {color:#405875;white-space:pre;}
.crm-entry-summary {
  margin-top:6px;
  color:#354860;
  font-size:13.5px;
  line-height:1.65;
  overflow-wrap:anywhere;
}
.crm-entry-summary--live {
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:2;
  overflow:hidden;
}
.crm-result-row {
  display:flex;
  align-items:flex-start;
  gap:16px;
  margin-top:6px;
  min-width:0;
}
.crm-entry-result {
  flex:1;
  min-width:0;
  color:#5c7086;
  font-size:12.5px;
  line-height:1.55;
  overflow-wrap:anywhere;
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:1;
  overflow:hidden;
}
.crm-result-duration {
  flex:none;
  margin-left:auto;
  color:#48627c;
  font-size:12px;
  font-weight:700;
  line-height:1.6;
  white-space:nowrap;
}
.crm-entry--expanded .crm-entry-summary--live,
.crm-entry--expanded .crm-entry-result {
  display:block;
  overflow:visible;
  -webkit-line-clamp:unset;
  white-space:pre-wrap;
}
.crm-entry-agent {color:#8b97a5;font-size:12px;margin-top:6px;}
.crm-disclosure {
  display:none;
  align-items:center;
  justify-content:center;
  justify-self:end;
  align-self:start;
  border:0;
  border-radius:6px;
  padding:0 3px;
  background:transparent;
  color:#476b9c;
  font-family:inherit;
  font-size:20px;
  line-height:1.3;
  cursor:pointer;
}
.crm-entry--overflowing .crm-disclosure:not([hidden]) {display:inline-flex;}
.crm-disclosure[hidden] {display:none !important;}
.crm-disclosure:hover {background:#edf4ff;}
.crm-disclosure:focus-visible {outline:3px solid #9abaf2;outline-offset:2px;}
.crm-arrow {font-size:18px;line-height:1;color:#a9b4c2;text-align:right;}
.crm-feed-actions {padding:11px 16px;display:flex;justify-content:center;background:#fff;border-top:1px solid var(--crm-line);}
.crm-more {padding:9px 17px;border:1px solid #dae4f1;border-radius:9px;background:#fff;color:#265cbb;font-size:13px;font-weight:750;cursor:pointer;}
.crm-more:hover {background:#f3f7fd;}
.crm-more:focus-visible {outline:3px solid #9abaf2;outline-offset:2px;}
.crm-feed-empty {padding:30px 15px;color:#78869a;font-size:13px;text-align:center;}

@media(max-width:760px) {
  .crm-entry {grid-template-columns:var(--move-status-column) minmax(0,1fr) 28px;gap:8px 10px;padding:14px 12px;}
  .crm-type {grid-column:1;grid-row:1 / span 2;justify-self:start;}
  .crm-when {grid-column:2;grid-row:1;flex-direction:row;align-items:baseline;gap:8px;flex-wrap:wrap;}
  .crm-entry-main {grid-column:2;grid-row:2;}
  .crm-disclosure,.crm-arrow {grid-column:3;grid-row:1;}
  .crm-entry-meta {font-size:12px;gap:2px 0;}
  .crm-meta-item + .crm-meta-item::before {margin:0 6px;}
  .crm-entry-title {font-size:14.5px;}
  .crm-entry-summary {font-size:13px;}
}
@media(max-width:540px) {
  :root {--move-status-column:76px;--move-status-gap:10px;}
  .crm-entry {grid-template-columns:var(--move-status-column) minmax(0,1fr) 24px;gap:7px var(--move-status-gap);padding:15px 12px;}
  .crm-when {grid-column:2;grid-row:1;gap:6px;}
  .crm-when time {font-size:12.5px;}
  .crm-time {font-size:12px;}
  .crm-type {grid-column:1;grid-row:1 / span 2;}
  .crm-disclosure,.crm-arrow {grid-column:3;grid-row:1;}
  .crm-entry-main {grid-column:2;grid-row:2;}
  .crm-entry-title {font-size:15px;}
  .crm-entry-meta {font-size:12px;margin:4px 0 6px;}
  .crm-entry-summary {font-size:13.5px;}
  .crm-entry-result {font-size:12.5px;}
}
