*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }

:root {
  /* White page; structure from hairlines, not tint.
     Every grey is a pure neutral (r==g==b) so nothing reads as beige. */
  --bg: #ffffff;
  --s1: #ffffff;
  --s2: #fafafa;
  --s3: #f4f4f4;
  --s4: #efefef;
  --border: #e9e9e9;
  --border2: #f1f1f1;
  --text: #131313;
  --muted: #9b9b9b;
  --mid: #6b6b6b;
  --dim: #c6c6c6;
  --white: #131313;
  --accent: #131313;
  --accent2: #131313;
  --red: #131313;
  --sidebar-w: 220px;
  --radius: 10px;
  --radius-sm: 7px;
  --ease: cubic-bezier(.16,.84,.44,1);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Outfit', sans-serif;
  min-height: 100vh;
  display: flex;
}

/* ————————————————————————————
   SIDEBAR
———————————————————————————— */
.sidebar {
  width: var(--sidebar-w);
  background: var(--s1);
  border-right: 1px solid var(--border);
  position: fixed;
  top: 0; left: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  z-index: 200;
  overflow: hidden;
}

.sb-logo {
  padding: 22px 20px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.sb-logo-label {
  font-size: 9px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 3px;
}
.sb-logo-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -.01em;
}

.sb-month {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.sb-month-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.sb-month-val {
  font-size: 16px;
  font-weight: 700;
  color: var(--white);
}
.sb-month-updated {
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

.sb-nav {
  flex: 1;
  overflow-y: auto;
  padding: 10px 0;
}

.sb-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--muted);
  cursor: pointer;
  transition: all .15s;
  text-decoration: none;
  border-radius: 0;
  width: 100%;
  background: none;
  border: none;
  text-align: left;
  font-family: 'Outfit', sans-serif;
}
.sb-item:hover { color: var(--text); background: var(--s2); }
.sb-item.active { color: #fff; background: #111; font-weight: 600; }

.sb-item-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--dim);
  flex-shrink: 0;
  transition: background .15s;
}
.sb-item.active .sb-item-dot { background: var(--white); }

.sb-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}
.sb-footer-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.sb-footer-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.sb-tool {
  font-size: 10px;
  padding: 3px 7px;
  background: var(--s3);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--mid);
}

/* ————————————————————————————
   LOGIN SCREEN
———————————————————————————— */
.login-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg);
}
.login-card {
  width: 420px;
  max-width: 92vw;
  background: var(--s1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
}
.login-logo {
  text-align: center;
  margin-bottom: 32px;
}
.login-logo-label {
  font-size: 9px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}
.login-logo-title {
  font-size: 20px;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -.02em;
}
.login-roles-label {
  font-size: 10px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  margin-bottom: 16px;
}
.login-roles {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}
/* Profiles: 3 × 2 grid (Nick · Kim · Claire / Bali · Shiv · Arianne). */
#loginRoles { display: grid; grid-template-columns: repeat(3, 88px); justify-content: center; gap: 18px 24px; }
.login-role-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  width: auto;
  padding: 0;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  text-align: center;
  transition: all .15s;
}
.login-role-btn:hover .login-role-icon { background: var(--s3); border-color: var(--s4); transform: translateY(-2px); }
.login-role-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: 12px;
  flex-shrink: 0;
  transition: all .15s;
}
.login-role-icon svg { width: 24px; height: 24px; stroke: var(--mid); }
.login-role-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

/* Password section */
.login-pw-section { }
.login-pw-back {
  font-size: 11px;
  color: var(--muted);
  cursor: pointer;
  margin-bottom: 16px;
  transition: color .15s;
}
.login-pw-back:hover { color: var(--text); }
.login-pw-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}
.login-pw-input {
  width: 100%;
  padding: 11px 14px;
  font-size: 13px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: var(--s2);
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}
.login-pw-input:focus { border-color: #111; background: #fff; }
.login-pw-error {
  font-size: 11px;
  color: #414141;
  min-height: 18px;
  margin-top: 6px;
}
.login-pw-btn {
  width: 100%;
  padding: 11px;
  margin-top: 8px;
  font-size: 12.5px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  color: #fff;
  background: #111;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background .15s;
}
.login-pw-btn:hover { background: #333; }

/* User bar in sidebar footer */
.sb-user-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.sb-user-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
}
.sb-logout-btn {
  font-size: 10px;
  font-weight: 500;
  color: var(--muted);
  background: none;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 3px 8px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: all .15s;
}
.sb-logout-btn:hover { color: #414141; border-color: #414141; }

/* Pulse stats */
.sb-pulse {
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}
.sb-pulse-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.sb-pulse-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 4px 0;
}
.sb-pulse-val {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}
.sb-pulse-key {
  font-size: 10px;
  color: var(--muted);
}

/* ————————————————————————————
   PAGE SWITCHER
———————————————————————————— */
.sb-pages {
  padding: 12px 12px 0;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.sb-pages-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
  padding: 0 8px;
}
/* A second group label (Events → Internal) gets breathing room above it. */
.sb-page-btn + .sb-pages-label { margin-top: 14px; }
.sb-page-btn {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  padding: 9px 12px;
  margin-bottom: 4px;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--mid);
  background: none;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all .15s;
  font-family: 'Outfit', sans-serif;
  text-align: left;
}
.sb-page-btn:last-child { margin-bottom: 12px; }
.sb-page-btn:hover { background: var(--s3); color: var(--text); }
.sb-page-btn.active {
  background: #111;
  color: #fff;
  font-weight: 600;
  border-color: #111;
}
.sb-page-icon {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sb-page-icon svg { width: 14px; height: 14px; }
.sb-page-btn.active .sb-page-icon svg { stroke: #fff; }

/* ————————————————————————————
   MAIN
———————————————————————————— */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* TOPBAR */
.topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 14px;
  height: 44px;
  display: flex;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
}

.tabs {
  display: flex;
  gap: 1px;
  align-items: center;
  width: 100%;
}

.tab {
  padding: 5px 7px;
  font-size: 10.5px;
  font-weight: 500;
  border-radius: 5px;
  cursor: not-allowed;
  color: var(--dim);
  transition: all .15s;
  white-space: nowrap;
  border: none;
  font-family: 'Outfit', sans-serif;
}
.tab.available {
  cursor: pointer;
  color: var(--mid);
}
.tab.available:hover { color: var(--text); background: var(--s3); }
/* Editors can click an empty month to fill it in */
.tabs-editable .tab { cursor: pointer; }
.tabs-editable .tab:not(.available):hover { color: var(--mid); background: var(--s3); }
.tab.active {
  background: #111;
  color: #fff;
  font-weight: 700;
}

/* CONTENT */
.content {
  padding: 24px 28px 48px;
  flex: 1;
  max-width: 880px;
  animation: contentFadeIn .3s ease;
}
@keyframes contentFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Staggered section reveal */
.section {
  animation: sectionReveal .4s ease both;
}
.section:nth-child(1) { animation-delay: 0s; }
.section:nth-child(2) { animation-delay: .06s; }
.section:nth-child(3) { animation-delay: .12s; }
.section:nth-child(4) { animation-delay: .18s; }
.section:nth-child(5) { animation-delay: .24s; }
.section:nth-child(6) { animation-delay: .3s; }
.section:nth-child(7) { animation-delay: .36s; }
@keyframes sectionReveal {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* SECTION HEADER */
.sec-head {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 20px;
}
.sec-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--white);
}
.sec-rule {
  flex: 1;
  height: 1px;
  background: var(--border);
}
.sec-tag {
  font-size: 10px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dim);
}

/* SECTION SPACING */
.section { margin-bottom: 32px; }

/* KPI GRID */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.kpi-card {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  position: relative;
  overflow: hidden;
  transition: border-color .15s;
}
.kpi-card:hover { border-color: var(--dim); }
.kpi-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: var(--border);
}
.kpi-card.accent::before { background: var(--white); }
.kpi-card.blue::before   { background: var(--mid); }
.kpi-card.red::before    { background: var(--dim); }

.kpi-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}
.kpi-val {
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
  color: var(--white);
  letter-spacing: -.02em;
}
.kpi-delta {
  font-size: 11px;
  color: var(--muted);
  margin-top: 6px;
}

/* GROWTH CHART */
.growth-chart {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.growth-chart-grid {
  display: flex;
  gap: 24px;
  align-items: flex-end;
  height: 120px;
  padding: 0 8px;
}
.growth-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  height: 100%;
  justify-content: flex-end;
}
.growth-bars {
  display: flex;
  gap: 3px;
  align-items: flex-end;
  flex: 1;
  width: 100%;
  justify-content: center;
}
.growth-bar {
  flex: 1;
  max-width: 18px;
  border-radius: 3px 3px 0 0;
  min-height: 4px;
  transition: height .6s cubic-bezier(.4,0,.2,1);
}
.growth-bar.b0 { background: var(--dim); }
.growth-bar.b1 { background: var(--mid); }
.growth-bar.b2 { background: var(--text); }
.growth-val {
  font-size: 10px;
  font-weight: 700;
  color: var(--text);
}
.growth-label {
  font-size: 8px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  line-height: 1.2;
}
.growth-legend {
  display: flex;
  gap: 14px;
  justify-content: center;
  margin-top: 12px;
}
.growth-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 9px;
  color: var(--muted);
}
.growth-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
}

/* TWO-COL GRID */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.three-col { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; }

/* CARD */
.card {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.card-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}

/* PLATFORM ROW */
.platform-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border2);
}
.platform-row:last-child { border-bottom: none; }
.platform-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--mid);
  width: 70px;
}
.platform-stat {
  text-align: right;
}
.platform-val {
  font-size: 18px;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
}
.platform-sub {
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

/* TOP POST */
.top-post {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.top-post-caption {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  margin-bottom: 18px;
  font-style: italic;
  border-left: 2px solid var(--accent);
  padding-left: 14px;
}
.post-stats {
  display: flex;
  gap: 24px;
}
.post-stat-val {
  font-size: 20px;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
}
.post-stat-label {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

/* OUTREACH */
.outreach-hero {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 12px;
}
.outreach-big-num {
  font-size: 56px;
  font-weight: 900;
  line-height: 1;
  color: var(--white);
  letter-spacing: -.04em;
  flex-shrink: 0;
}
.outreach-hero-right { flex: 1; }
.outreach-hero-label {
  font-size: 9px;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}
.outreach-hero-sub {
  font-size: 13px;
  color: var(--mid);
  line-height: 1.5;
}

.outreach-total-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.physician-list {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
}
.physician-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 0;
  border-bottom: 1px solid var(--border2);
}
.physician-item:last-child { border-bottom: none; }
.physician-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}
.physician-spec {
  font-size: 11px;
  color: var(--muted);
  background: var(--s3);
  padding: 3px 8px;
  border-radius: 4px;
}

/* LEAD BARS */
.lead-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.lead-row:last-child { margin-bottom: 0; }
.lead-label { font-size: 11px; color: var(--mid); width: 70px; flex-shrink: 0; }
.lead-bar-wrap {
  flex: 1;
  height: 5px;
  background: var(--s3);
  border-radius: 3px;
  overflow: hidden;
}
.lead-bar {
  height: 100%;
  background: var(--white);
  border-radius: 3px;
  transition: width 0.8s cubic-bezier(.4,0,.2,1);
}
.lead-pct { font-size: 11px; color: var(--muted); width: 28px; text-align: right; }

/* WEBSITE STATS */
.ws-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}
.ws-stat {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
}
.ws-label { font-size: 9px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.ws-val { font-size: 24px; font-weight: 800; color: var(--white); line-height: 1; }
.ws-sub { font-size: 10px; color: var(--muted); margin-top: 4px; }

/* BLOG CARDS */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.blog-card {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  border-top: 3px solid var(--border);
  transition: border-color .2s;
}
.blog-card:hover { border-top-color: var(--accent); }
.blog-title { font-size: 12px; font-weight: 600; color: var(--text); margin-bottom: 12px; line-height: 1.45; }
.blog-stats { display: flex; gap: 16px; }
.blog-stat-val { font-size: 18px; font-weight: 800; color: var(--white); line-height: 1; }
.blog-stat-label { font-size: 9px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }

/* ANALYSIS */
.analysis-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.analysis-list li {
  display: flex;
  gap: 12px;
  font-size: 13px;
  color: var(--mid);
  line-height: 1.6;
}
.al-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--white);
  flex-shrink: 0;
  margin-top: 7px;
}

/* ACTION STEPS */
.act-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.act-item {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  display: grid;
  grid-template-columns: 40px 80px 1fr;
  align-items: center;
  gap: 14px;
}
.act-n {
  font-size: 22px;
  font-weight: 800;
  color: var(--dim);
}
.act-tag {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--white);
  background: rgba(0,0,0,.06);
  padding: 4px 8px;
  border-radius: 4px;
  text-align: center;
}
.act-txt {
  font-size: 12.5px;
  color: var(--mid);
  line-height: 1.5;
}

/* YTD SECTION */
.ytd-toggle {
  display: flex;
  gap: 4px;
}
.ytd-toggle-btn {
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: var(--s2);
  color: var(--mid);
  cursor: pointer;
  transition: all .15s;
}
.ytd-toggle-btn:hover { color: var(--text); }
.ytd-toggle-btn.active { background: #111; color: #fff; border-color: #111; }

.ytd-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.ytd-summary-card {
  background: var(--s3);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.ytd-summary-val {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
}
.ytd-summary-label {
  font-size: 9px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}
.ytd-summary-delta {
  font-size: 10px;
  color: var(--muted);
  margin-top: 2px;
}

.ytd-chart-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 6px;
}
.ytd-chart-label {
  width: 32px;
  font-size: 10px;
  font-weight: 600;
  color: var(--mid);
  flex-shrink: 0;
}
.ytd-chart-bar-wrap {
  flex: 1;
  height: 14px;
  background: var(--s3);
  border-radius: 3px;
  overflow: hidden;
}
.ytd-chart-bar {
  height: 100%;
  border-radius: 3px;
  transition: width .6s cubic-bezier(.4,0,.2,1);
}
.ytd-chart-val {
  width: 50px;
  text-align: right;
  font-size: 10px;
  font-weight: 600;
  color: var(--text);
}

/* NOTES */
.notes-box {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 22px;
  font-size: 12.5px;
  color: var(--mid);
  line-height: 1.65;
}

/* TOOLS MARQUEE */
.marquee-wrap {
  overflow: hidden;
  width: 100%;
  padding: 10px 0;
}
.marquee-track {
  display: flex;
  gap: 8px;
  animation: marquee 20s linear infinite;
  width: max-content;
}
@keyframes marquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.tool-chip {
  background: var(--s3);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 500;
  color: var(--mid);
  white-space: nowrap;
}

/* COUNT UP */
.count-num { display: inline-block; }

/* EMPTY STATE */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 60vh;
  color: var(--muted);
  text-align: center;
}
.empty-state-label {
  font-size: 11px;
  letter-spacing: .15em;
  text-transform: uppercase;
  margin-bottom: 10px;
}
.empty-state-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--dim);
}

/* PONY LIST */
.pony-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.pony-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--white);
}
.pony-add-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  font-size: 11.5px;
  font-weight: 600;
  color: #fff;
  background: #111;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: background .15s;
}
.pony-add-btn:hover { background: #333; }
.pony-add-btn svg { width: 13px; height: 13px; }

.pony-filters {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.pony-filter {
  padding: 5px 12px;
  font-size: 11px;
  font-weight: 500;
  color: var(--mid);
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: all .15s;
}
.pony-filter:hover { color: var(--text); border-color: var(--s4); }
.pony-filter.active { background: #111; color: #fff; border-color: #111; font-weight: 600; }

.pony-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.pony-table thead th {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
  text-align: left;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: var(--s3);
}
.pony-table tbody td {
  font-size: 12.5px;
  color: var(--text);
  padding: 13px 18px;
  border-bottom: 1px solid var(--border2);
}
.pony-table tbody tr:last-child td { border-bottom: none; }
.pony-table tbody tr { transition: background .1s; }
.pony-table tbody tr:hover { background: var(--s3); }

.pony-name { font-weight: 600; }
.pony-tag {
  display: inline-block;
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 4px;
  font-weight: 500;
  letter-spacing: .02em;
}
.pony-tag {
  cursor: pointer;
  transition: all .15s;
  user-select: none;
}
.pony-tag:hover { transform: scale(1.05); filter: brightness(0.95); }
.pony-tag.hot       { background: #f1f1f1; color: #414141; }
.pony-tag.warm      { background: #f4f4f4; color: #6b6b6b; }
.pony-tag.cold      { background: #f1f1f1; color: #414141; }
.pony-tag.converted { background: #f1f1f1; color: #414141; }
.pony-tag.lost      { background: var(--s3); color: var(--muted); }

.pony-empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--muted);
}
.pony-empty-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--dim);
  margin-bottom: 6px;
}
.pony-empty-sub {
  font-size: 12px;
}

.pony-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

/* Pony inline edit */
.pony-input {
  width: 100%;
  padding: 5px 8px;
  font-size: 12.5px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s1);
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}
.pony-input:focus { border-color: #111; background: #fff; }
.pony-select {
  padding: 5px 8px;
  font-size: 11px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s1);
  color: var(--text);
  outline: none;
  cursor: pointer;
}
.pony-select:focus { border-color: #111; }

.pony-del-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--dim);
  font-size: 14px;
  padding: 4px 8px;
  border-radius: 4px;
  transition: all .15s;
  line-height: 1;
}
.pony-del-btn:hover { color: #414141; background: #f1f1f1; }

/* Pony modal overlay */
.pony-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.25);
  backdrop-filter: blur(4px);
}
.pony-modal {
  background: var(--s1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  width: 440px;
  max-width: 92vw;
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.28);
}
.pony-modal-title {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 20px;
}
.pony-modal-fields {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.pony-modal-field {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 12.5px;
  font-family: 'Outfit', sans-serif;
  background: var(--s2);
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}
.pony-modal-field:focus { border-color: #111; background: #fff; }
.pony-modal-field.error { border-color: #414141; }
textarea.pony-modal-field { resize: vertical; min-height: 48px; }
.pony-modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 18px;
}
.pony-btn-cancel {
  padding: 8px 16px;
  font-size: 11.5px;
  font-weight: 500;
  color: var(--mid);
  background: var(--s3);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: all .15s;
}
.pony-btn-cancel:hover { background: var(--s4); }
.pony-btn-save {
  padding: 8px 16px;
  font-size: 11.5px;
  font-weight: 600;
  color: #fff;
  background: #111;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: background .15s;
}
.pony-btn-save:hover { background: #333; }

/* Pony row actions cell */
.pony-actions-cell { text-align: right; white-space: nowrap; }

/* ————————————————————————————
   INVOICE SYSTEM
———————————————————————————— */

/* Sidebar invoice month nav */
.inv-month-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 8px 20px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  font-size: 12.5px;
  font-weight: 400;
  color: var(--muted);
  text-align: left;
  transition: all .15s;
}
.inv-month-btn:hover { color: var(--text); background: var(--s2); }
.inv-month-btn.active { color: #fff; background: #111; font-weight: 600; }
.inv-month-badge {
  font-size: 10px;
  font-weight: 500;
  padding: 2px 7px;
  border-radius: 99px;
  background: var(--s3);
  color: var(--mid);
}
.inv-month-btn.active .inv-month-badge { background: rgba(255,255,255,.2); color: #fff; }
.inv-month-badge.inv-paid { background: transparent; color: var(--text); font-weight: 700; }
.inv-month-btn.active .inv-month-badge.inv-paid { background: rgba(255,255,255,.18); color: #fff; }

/* YTD stats bar */
.inv-ytd {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}
.inv-ytd-stat { text-align: center; }
.inv-ytd-num {
  font-size: 28px;
  font-weight: 800;
  color: var(--white);
  line-height: 1;
}
.inv-ytd-label {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}
.inv-ytd-divider {
  width: 1px;
  height: 36px;
  background: var(--border);
}

/* Invoice header */
.inv-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}
.inv-title {
  font-size: 28px;
  font-weight: 800;
  color: var(--white);
  letter-spacing: -.02em;
  line-height: 1.1;
}
.inv-meta {
  font-size: 10px;
  letter-spacing: .08em;
  color: var(--muted);
  margin-top: 4px;
  text-transform: uppercase;
}

/* Status badge */
.inv-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all .15s;
  font-family: 'Outfit', sans-serif;
}
.inv-status:hover { transform: scale(1.03); }
.inv-status.unpaid { background: var(--s1); color: var(--mid); border-color: var(--dim); }
.inv-status.paid { background: var(--text); color: #fff; border-color: var(--text); }
.inv-status-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

/* Invoice grid */
.inv-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 12px; max-width: 100%; }
.inv-full { grid-column: 1 / -1; }

/* Override content max-width for invoice & masterlist pages */
.content:has(.inv-ytd) { max-width: 100%; }
.content:has(.ml-toolbar) { max-width: 100%; }

/* Card hover lift */
.card:hover, .top-post:hover, .ws-stat:hover, .blog-card:hover {
  transform: translateY(-1px);
}
.card, .top-post, .ws-stat {
  transition: border-color .2s;
}

/* Invoice table */
.inv-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
.inv-table thead th {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
  text-align: left;
  padding: 10px 14px;
  border-bottom: 2px solid var(--border);
}
.inv-table thead th:last-child,
.inv-table tbody td:last-child { text-align: right; }
.inv-table tbody td {
  font-size: 12.5px;
  color: var(--text);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border2);
}
.inv-table tbody tr:last-child td { border-bottom: none; }
.inv-table tbody tr:hover td { background: var(--s3); }
.inv-table .inv-total-row td {
  font-weight: 700;
  border-top: 2px solid var(--border);
  border-bottom: none;
  background: var(--s3);
  font-size: 12px;
}
.inv-amount {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -.01em;
}
.inv-rate {
  font-size: 11px;
  color: var(--muted);
}

/* Share of the grand total, under each split figure in the summary card */
.inv-split-pct {
  margin-top: 2px;
  font-size: 11px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

/* Hours input */
.inv-hours {
  width: 68px;
  padding: 5px 8px;
  font-size: 12.5px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s1);
  color: var(--text);
  text-align: right;
  outline: none;
  transition: border-color .15s;
}
.inv-hours:focus { border-color: #111; background: #fff; }

/* Editable rate — a $ sign pinned to a narrow numeric input */
.inv-rate-edit {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.inv-rate-sym {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.inv-rate-input {
  width: 62px;
  padding: 5px 8px;
  font-size: 12.5px;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s1);
  color: var(--text);
  text-align: right;
  outline: none;
  transition: border-color .15s;
  font-variant-numeric: tabular-nums;
}
.inv-rate-input:focus { border-color: #111; background: #fff; }

/* Summary lines */
.inv-summary-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: 12.5px;
  border-bottom: 1px solid var(--border2);
}
.inv-summary-line:last-child { border-bottom: none; }
.inv-sum-label { color: var(--muted); font-size: 12px; }
.inv-sum-val { font-weight: 700; font-variant-numeric: tabular-nums; }
.inv-summary-grand {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0 0;
  margin-top: 8px;
  border-top: 2px solid var(--border);
  font-size: 20px;
  font-weight: 800;
  color: var(--white);
}

/* Payment info box */
.inv-paybox {
  background: #111;
  color: #fff;
  border-radius: var(--radius);
  padding: 18px 22px;
  margin-top: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.inv-pay-label {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  opacity: .5;
  margin-bottom: 3px;
}
.inv-pay-val {
  font-size: 12.5px;
  font-weight: 600;
}
.inv-pay-amount {
  font-size: 16px;
  font-weight: 800;
  color: var(--dim);
}

/* Print button */
.inv-print-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 14px;
  font-size: 11px;
  font-weight: 600;
  color: var(--mid);
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: all .15s;
}
.inv-print-btn:hover { background: var(--s3); color: var(--text); }

@media (max-width: 900px) {
  .inv-grid { grid-template-columns: 1fr; }
  .inv-ytd-divider { display: none; }
  .inv-ytd { gap: 12px; padding: 14px 16px; }
  .inv-ytd-num { font-size: 22px; }
  .inv-paybox { gap: 12px; }
}
@media (max-width: 560px) {
  .inv-topbar { flex-direction: column; }
  .inv-title { font-size: 22px; }
  .inv-hours { width: 56px; font-size: 11px; }
  .inv-rate-input { width: 54px; font-size: 11px; }
  .inv-table thead th { padding: 8px 10px; }
  .inv-table tbody td { padding: 8px 10px; font-size: 11.5px; }
}
/* ————————————————————————————
   MASTERLIST
———————————————————————————— */
.ml-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.ml-search {
  flex: 1;
  min-width: 180px;
  max-width: 320px;
  padding: 8px 12px;
  font-size: 12px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: var(--s1);
  color: var(--text);
  outline: none;
}
.ml-search:focus { border-color: #111; }
.ml-search::placeholder { color: var(--dim); }
.ml-select {
  padding: 7px 10px;
  font-size: 11px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: var(--s1);
  color: var(--text);
  cursor: pointer;
  outline: none;
}
.ml-select:focus { border-color: #111; }
.ml-btn-clear {
  padding: 7px 12px;
  font-size: 11px;
  font-weight: 500;
  color: var(--mid);
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
}
.ml-btn-clear:hover { color: var(--text); }
.ml-btn-addcol {
  padding: 7px 12px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text);
  background: var(--s1);
  border: 1px dashed var(--mid);
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
}
.ml-btn-addcol:hover { background: var(--s3); border-style: solid; }

/* Custom column header (with × delete for admin) */
.ml-table th.ml-custom-col { position: relative; padding-right: 26px; }
.ml-table th.ml-custom-col .ml-col-del {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--dim);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 3px;
  opacity: 0;
  transition: opacity .15s, color .15s, background .15s;
}
.ml-table th.ml-custom-col:hover .ml-col-del { opacity: 1; }
.ml-table th.ml-custom-col .ml-col-del:hover { color: #414141; background: var(--s4); }
.ml-table td.ml-custom-col {
  font-size: 11.5px;
  color: var(--mid);
  max-width: 160px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ml-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

/* ML Masterlist Sections (Priority / Active / General) */
.ml-section {
  background: var(--s1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}
.ml-section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 18px;
  background: var(--s2);
  border: none;
  border-bottom: 1px solid transparent;
  font-family: 'Outfit', sans-serif;
  cursor: pointer;
  text-align: left;
  transition: background .15s;
}
.ml-section-header:hover { background: var(--s3); }
.ml-section.open .ml-section-header { border-bottom-color: var(--border); }
.ml-section-caret {
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--mid);
  border-bottom: 1.5px solid var(--mid);
  transform: rotate(-45deg);
  transition: transform .2s ease;
  flex-shrink: 0;
  margin-left: 2px;
}
.ml-section.open .ml-section-caret { transform: rotate(45deg); margin-top: -3px; }
.ml-section-title {
  flex: 1;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text);
}
.ml-section-count {
  font-size: 11px;
  font-weight: 600;
  color: var(--mid);
  background: var(--s4);
  padding: 2px 10px;
  border-radius: 10px;
  min-width: 28px;
  text-align: center;
}
.ml-section-body { display: none; }
.ml-section.open .ml-section-body { display: block; }
.ml-section-empty {
  padding: 26px 18px;
  text-align: center;
  font-size: 11.5px;
  color: var(--muted);
  font-style: italic;
}
.ml-section .ml-table-wrap { border-radius: 0; }
.ml-section .ml-table {
  border-radius: 0;
  border: none;
  background: var(--s1);
}
.ml-section .ml-table thead th {
  background: var(--s2);
  border-bottom: 1px solid var(--border);
}

/* ML Table */
.ml-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}
.ml-table thead th {
  font-size: 9px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
  text-align: left;
  padding: 12px 14px;
  border-bottom: 2px solid var(--border);
  background: var(--s3);
  cursor: default;
  user-select: none;
  white-space: nowrap;
  position: sticky;
  top: 0;
  z-index: 2;
}
.ml-table thead th.ml-th-sortable { cursor: pointer; }
.ml-table thead th:hover { color: var(--text); }
.ml-table thead th.sorted { color: var(--text); font-weight: 700; }
.ml-table thead th.ml-th-sortable:hover { color: var(--text); }
.ml-table thead th.ml-th-sortable .ml-sort-caret {
  display: inline-block;
  margin-left: 5px;
  font-size: 9px;
  color: var(--text);
  vertical-align: middle;
}
.ml-table tbody td {
  font-size: 12px;
  color: var(--text);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border2);
  max-width: 180px;
}
.ml-table tbody tr { cursor: pointer; transition: background .1s; }
.ml-table tbody tr:last-child td { border-bottom: none; }
.ml-table tbody tr:hover td { background: var(--s3); }
.ml-name { font-weight: 600; font-size: 12.5px; }
.ml-mono { font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ml-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ml-ig-link {
  color: #414141;
  text-decoration: underline;
  text-decoration-color: rgba(107,107,107,.4);
  text-underline-offset: 2px;
  font-size: 11px;
  font-weight: 500;
}
.ml-ig-link:hover { color: #131313; text-decoration-color: #131313; }

/* ML Badges */
.ml-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 600;
  white-space: nowrap;
}
/* Greyscale stages — heaviest fill = furthest along. No hue anywhere. */
.ml-badge { border: 1px solid transparent; }
.ml-badge-green  { background: var(--text); color: #fff; }
.ml-badge-blue   { background: var(--s1); border-color: var(--text); color: var(--text); }
.ml-badge-purple { background: #e5e5e5; color: #414141; }
.ml-badge-yellow { background: var(--s3); border-color: var(--border); color: #414141; }
.ml-badge-orange { background: var(--s3); color: var(--mid); }
.ml-badge-gray   { background: var(--s3); color: var(--muted); }
.ml-badge-red    { background: transparent; border-color: var(--dim); color: var(--muted);
                   text-decoration: line-through; text-decoration-thickness: 1px; }

/* OT Archive cards */
.ml-ot-card {
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: background .1s;
}
.ml-ot-card:hover { background: var(--s3); }
.ml-ot-name { font-weight: 700; font-size: 12.5px; margin-bottom: 3px; }
.ml-ot-meta { font-size: 11px; color: var(--muted); }
.ml-ot-notes {
  font-size: 11px;
  color: var(--muted);
  background: var(--s3);
  padding: 6px 10px;
  border-radius: 5px;
  margin-top: 8px;
  font-style: italic;
}

/* ML Empty */
.ml-empty {
  text-align: center;
  padding: 48px 20px;
  color: var(--muted);
  font-size: 12px;
}

/* ML Modal */
.ml-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.3);
  backdrop-filter: blur(4px);
}
.ml-modal {
  background: var(--s1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 520px;
  max-width: 94vw;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.28);
}
.ml-modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.ml-modal-title { font-size: 16px; font-weight: 700; color: var(--text); }
.ml-modal-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }
.ml-modal-close {
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  color: var(--muted);
  line-height: 1;
}
.ml-modal-close:hover { color: var(--text); }
.ml-modal-body { padding: 20px 24px; }
.ml-field-row { display: flex; gap: 10px; margin-bottom: 10px; }
.ml-field { flex: 1; }
.ml-field-label {
  font-size: 9px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}
.ml-field input, .ml-field select, .ml-field textarea {
  width: 100%;
  padding: 8px 10px;
  font-size: 12px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 6px;
  background: var(--s2);
  color: var(--text);
  outline: none;
}
.ml-field input:focus, .ml-field select:focus, .ml-field textarea:focus {
  border-color: #111; background: #fff;
}
.ml-field textarea { resize: vertical; min-height: 60px; }
.ml-modal-footer {
  padding: 14px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.ml-btn-delete {
  padding: 7px 14px;
  font-size: 11px;
  font-weight: 600;
  color: #414141;
  background: #f1f1f1;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
}
.ml-btn-delete:hover { background: #414141; color: #fff; }

/* ML Priority — chip + row stripe */
.ml-pri-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 9px 2px 7px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
  cursor: pointer;
  user-select: none;
  border: 1px solid transparent;
  transition: filter .12s, border-color .12s;
  white-space: nowrap;
}
.ml-pri-chip:hover { filter: brightness(.96); border-color: var(--border); }
.ml-pri-dot { width: 6px; height: 6px; border-radius: 50%; flex-shrink: 0; }
.ml-pri-high { background: var(--text); color: #fff; }
.ml-pri-high .ml-pri-dot { background: #fff; }
.ml-pri-med  { background: #e5e5e5; color: #414141; }
.ml-pri-med .ml-pri-dot { background: #414141; }
.ml-pri-low  { background: var(--s1); border-color: var(--border); color: var(--mid); }
.ml-pri-low .ml-pri-dot { background: #414141; }
.ml-pri-none { background: var(--s3); color: var(--muted); border: 1px dashed var(--border); }
.ml-pri-none .ml-pri-dot { background: var(--dim); }
.ml-pri-empty {
  display: inline-block;
  color: var(--dim);
  cursor: pointer;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 500;
  user-select: none;
}
.ml-pri-empty:hover { color: var(--mid); }
.ml-empty-dash { color: var(--dim); font-size: 11px; }

/* left priority stripe removed — the PRIORITY column already carries this */
.ml-table tbody tr.ml-row-pri-high td:first-child,
.ml-table tbody tr.ml-row-pri-med  td:first-child,
.ml-table tbody tr.ml-row-pri-low  td:first-child { box-shadow: none; }

/* ML Notes column cell */
.ml-notes-cell {
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 320px;
  min-width: 200px;
}
.ml-start-flair {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  background: #f1f1f1;
  color: #414141;
  padding: 2px 7px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
}
.ml-note-preview {
  color: var(--mid);
  font-style: italic;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  font-size: 11px;
}
.ml-note-empty { color: var(--dim); font-size: 11px; }
.ml-note-count {
  background: var(--s3);
  color: var(--mid);
  border: 1px solid var(--border);
  font-size: 9px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 99px;
  flex-shrink: 0;
}

/* ML Modal — section labels for grouping */
.ml-section-label {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 18px 0 10px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border2);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}
.ml-lock-icon {
  font-size: 9px;
  color: var(--muted);
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: none;
}
/* Follow-up date picker + quick buttons */
.ml-followup-date-wrap {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}
.ml-followup-date-wrap input[type="date"] {
  width: auto;
  min-width: 140px;
  flex: 0 0 auto;
}
.ml-fu-quick {
  padding: 6px 10px;
  font-size: 10.5px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  color: var(--mid);
  background: var(--s2);
  border: 1px solid var(--border);
  border-radius: 5px;
  cursor: pointer;
  white-space: nowrap;
}
.ml-fu-quick:hover { color: var(--text); background: var(--s3); border-color: var(--mid); }
.ml-fu-quick:disabled { opacity: .5; cursor: not-allowed; }
.ml-fu-quick.ml-fu-clear { color: var(--muted); border-style: dashed; }
.ml-fu-quick.ml-fu-clear:hover { color: #414141; border-color: #414141; border-style: solid; background: var(--s2); }

.ml-perm-banner {
  background: #f1f1f1;
  border: 1px solid #d8d8d8;
  color: #414141;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 11px;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Linked-list pills (in Master List row name cell) */
.ml-pony-pill, .ml-wait-pill {
  display: inline-block;
  padding: 1px 7px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .04em;
  border-radius: 4px;
  margin-left: 6px;
  vertical-align: middle;
}
.ml-pony-pill { background: #f4f4f4; color: #6b6b6b; }
.ml-wait-pill { background: #f1f1f1; color: #414141; }

/* Linked-list buttons in modal */
.ml-links-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.ml-link-btn {
  padding: 7px 12px;
  font-size: 11px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid var(--border);
  background: var(--s2);
  color: var(--text);
  flex: 1;
  min-width: 140px;
  transition: background .12s, border-color .12s;
}
.ml-link-btn:hover { background: var(--s3); border-color: var(--mid); }
.ml-link-btn-on { background: #f4f4f4; border-color: #d8d8d8; color: #6b6b6b; }
.ml-link-btn-on:hover { background: #efefef; border-color: #c6c6c6; }
.ml-link-btn-add { border-style: dashed; color: var(--mid); }

/* "Linked to Master List" badge in pony/waiting modals */
.ml-link-badge {
  background: var(--s2);
  border: 1px solid var(--border);
  padding: 7px 12px;
  border-radius: 6px;
  font-size: 11px;
  color: var(--mid);
  margin-bottom: 14px;
}
.ml-link-badge a { color: var(--text); font-weight: 600; text-decoration: underline; }
.ml-link-badge a:hover { color: #000; }

/* ML Notes timeline (inside modal) */
.ml-note-input-wrap {
  background: var(--s2);
  border: 1.5px solid var(--border);
  border-radius: 6px;
  padding: 10px;
  margin-bottom: 14px;
}
.ml-note-input-wrap textarea {
  width: 100%;
  background: transparent;
  border: none;
  outline: none;
  resize: vertical;
  min-height: 50px;
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  color: var(--text);
}
.ml-note-input-wrap textarea::placeholder { color: var(--dim); }
.ml-note-input-actions { display: flex; justify-content: flex-end; margin-top: 6px; }
.ml-btn-add-note {
  padding: 6px 12px;
  font-size: 11px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  color: #fff;
  background: var(--text);
  border: none;
  border-radius: 5px;
  cursor: pointer;
}
.ml-btn-add-note:hover { background: #000; }
.ml-btn-add-note:disabled { background: var(--dim); cursor: not-allowed; }

.ml-timeline { display: flex; flex-direction: column; gap: 10px; margin-bottom: 6px; }
.ml-timeline-empty { color: var(--dim); font-size: 11px; padding: 6px 2px; font-style: italic; }
.ml-note-entry {
  border-left: 2px solid var(--border);
  padding: 0 22px 0 12px;
  margin-left: 4px;
  position: relative;
}
.ml-note-del {
  position: absolute;
  right: 0;
  top: 0;
  background: none;
  border: none;
  color: var(--dim);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 3px;
  opacity: 0;
  transition: opacity .15s, color .15s, background .15s;
}
.ml-note-entry:hover .ml-note-del { opacity: 1; }
.ml-note-del:hover { color: #414141; background: var(--s4); }
.ml-note-entry::before {
  content: '';
  position: absolute;
  left: -5px;
  top: 5px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text);
  border: 2px solid var(--s1);
}
.ml-note-meta {
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 2px;
  font-weight: 500;
}
.ml-note-author { color: var(--text); font-weight: 600; }
.ml-note-text {
  font-size: 12px;
  color: var(--text);
  white-space: pre-wrap;
  line-height: 1.45;
}

@media (max-width: 900px) {
  .ml-stats { grid-template-columns: 1fr 1fr; }
  .ml-hide-mobile { display: none; }
}
@media (max-width: 560px) {
  .ml-toolbar { gap: 6px; }
  .ml-search { max-width: 100%; }
  .ml-field-row { flex-direction: column; gap: 8px; }
}

/* ————————————————————————————
   REPORT ADD MONTH
———————————————————————————— */
.tab-add {
  padding: 4px 7px;
  font-size: 11px;
  color: var(--dim);
  background: none;
  border: 1px dashed var(--border);
  border-radius: 5px;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  transition: all .15s;
  line-height: 1;
  display: none;
  margin-left: 2px;
  flex-shrink: 0;
}
.tab-add:hover { color: var(--mid); border-color: var(--mid); }

/* All-months picker */
.rpt-month-list { display: flex; flex-direction: column; gap: 6px; }
.rpt-month-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 11px 14px;
  text-align: left;
  font-family: 'Outfit', sans-serif;
  background: var(--s2);
  border: 1.5px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  transition: all .15s;
}
.rpt-month-row:hover { border-color: #111; background: #fff; }
.rpt-month-row.empty { border-style: dashed; }
.rpt-month-name {
  flex: 0 0 130px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
}
.rpt-month-row.empty .rpt-month-name { color: var(--mid); font-weight: 600; }
.rpt-month-status { flex: 1; font-size: 10.5px; color: var(--muted); }
.rpt-month-action {
  flex: 0 0 auto;
  padding: 3px 10px;
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #fff;
  background: #111;
  border-radius: 4px;
}
.rpt-month-row.empty .rpt-month-action { color: var(--mid); background: var(--s3); }

/* Month with no report yet */
.empty-month {
  padding: 64px 32px;
  text-align: center;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: var(--s1);
}
.empty-month-title {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -.02em;
  color: var(--text);
}
.empty-month-txt { font-size: 12px; color: var(--muted); margin-top: 6px; }
.empty-month-btn {
  margin-top: 20px;
  padding: 9px 18px;
  font-size: 11px;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  color: #fff;
  background: #111;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: opacity .15s;
}
.empty-month-btn:hover { opacity: .85; }

.rpt-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 40px;
  background: rgba(0,0,0,.25);
  backdrop-filter: blur(4px);
  overflow-y: auto;
}
.rpt-modal {
  background: var(--s1);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  width: 640px;
  max-width: 94vw;
  margin-bottom: 40px;
  box-shadow: 0 24px 60px -20px rgba(0,0,0,.28);
}
.rpt-modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.rpt-modal-title { font-size: 15px; font-weight: 700; color: var(--text); }
.rpt-modal-sub { font-size: 10px; color: var(--muted); margin-top: 2px; }

/* Localhost warning + dry-run toggle */
.rpt-local-note {
  padding: 12px 14px;
  margin-bottom: 18px;
  border: 1px solid #d8d8d8;
  border-radius: 6px;
  background: #fafafa;
}
.rpt-local-title { font-size: 11px; font-weight: 700; color: #6b6b6b; }
.rpt-local-txt { font-size: 11px; color: #6b6b6b; line-height: 1.5; margin-top: 3px; }
.rpt-dry-label {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 9px;
  font-size: 11px;
  font-weight: 600;
  color: #6b6b6b;
  cursor: pointer;
}
.rpt-dry-label input { cursor: pointer; }

/* Repeatable list editors — lead sources, physicians, blog posts */
.rpt-list-block { margin: 14px 0 4px; }
.rpt-list-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 5px;
}
.rpt-list-head label { font-size: 10px; color: var(--muted); }
.rpt-hint { font-size: 10px; color: var(--dim); }
.rpt-hint.warn { color: #414141; font-weight: 600; }
.rpt-list-row { display: flex; gap: 8px; margin-bottom: 6px; align-items: center; }
.rpt-list-row input {
  flex: 1;
  min-width: 0;
  padding: 6px 9px;
  font-size: 12px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s2);
  color: var(--text);
  outline: none;
}
.rpt-list-row input:focus { border-color: #111; background: #fff; }
.rpt-row-del {
  flex: 0 0 auto;
  padding: 0 7px;
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
  background: none;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
.rpt-row-del:hover { color: #414141; }
.rpt-row-add {
  padding: 5px 11px;
  font-size: 10px;
  font-weight: 600;
  font-family: 'Outfit', sans-serif;
  color: var(--mid);
  background: none;
  border: 1px dashed var(--border);
  border-radius: 5px;
  cursor: pointer;
  transition: all .15s;
}
.rpt-row-add:hover { color: var(--text); border-color: var(--mid); }
.rpt-note-line { font-size: 10px; color: var(--dim); line-height: 1.5; margin: 2px 0 6px; }
.rpt-modal-body { padding: 20px 24px; }
.rpt-section-label {
  font-size: 9px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 18px 0 10px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border2);
}
.rpt-section-label:first-child { margin-top: 0; }
.rpt-row { display: flex; gap: 10px; margin-bottom: 8px; }
.rpt-field { flex: 1; }
.rpt-field label {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 3px;
}
.rpt-field input, .rpt-field textarea {
  width: 100%;
  padding: 7px 10px;
  font-size: 12px;
  font-family: 'Outfit', sans-serif;
  border: 1.5px solid var(--border);
  border-radius: 5px;
  background: var(--s2);
  color: var(--text);
  outline: none;
}
.rpt-field input:focus, .rpt-field textarea:focus { border-color: #111; background: #fff; }
.rpt-field textarea { resize: vertical; min-height: 50px; }
.rpt-field input[type="number"] { -moz-appearance: textfield; }
.rpt-field input[type="number"]::-webkit-inner-spin-button { opacity: 1; }
.rpt-modal-footer {
  padding: 14px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

@media print {
  .sidebar, .topbar, .pony-add-btn, .inv-print-btn { display: none !important; }
  .main { margin-left: 0 !important; }
  .content { padding: 16px !important; }
  body { background: #fff; }
}

/* SCROLLBAR */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--dim); border-radius: 3px; }

/* ————————————————————————————
   RESPONSIVE
———————————————————————————— */
@media (max-width: 900px) {
  :root { --sidebar-w: 0px; }
  .main { margin-left: 0; min-width: 0; }

  .topbar { padding: 0 14px; height: auto; min-height: 48px; flex-wrap: wrap; gap: 6px; padding-top: 8px; padding-bottom: 8px; }
  .tabs { flex-wrap: wrap; gap: 4px; }
  .tab { padding: 5px 10px; font-size: 11px; }

  .content { padding: 20px 14px 48px; }

  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .kpi-val { font-size: 28px; }

  .two-col { grid-template-columns: 1fr; }
  .three-col { grid-template-columns: 1fr 1fr; }

  .outreach-hero { flex-direction: column; gap: 14px; }
  .outreach-big-num { font-size: 60px; }
  .outreach-total-row { grid-template-columns: 1fr; }

  .ws-grid { grid-template-columns: 1fr 1fr; }
  .blog-grid { grid-template-columns: 1fr; }

  .act-item { grid-template-columns: 36px 70px 1fr; gap: 10px; }
  .act-n { font-size: 18px; }
  .pony-stats { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .kpi-card { padding: 14px 14px; }
  .kpi-val { font-size: 24px; }
  .kpi-label { font-size: 8px; }

  .three-col { grid-template-columns: 1fr; }
  .ws-grid { grid-template-columns: 1fr; }

  .outreach-big-num { font-size: 48px; }

  .act-item { grid-template-columns: 1fr; gap: 6px; }
  .act-n { display: none; }

  .platform-val { font-size: 18px; }
  .post-stat-val { font-size: 22px; }
  .blog-stat-val { font-size: 18px; }

  .sec-head { gap: 8px; }
  .sec-rule { display: none; }

  .content { padding: 16px 12px 48px; }
  .section { margin-bottom: 32px; }
  .card { padding: 16px; }
  .top-post { padding: 16px; }
  .physician-list { padding: 14px 16px; }
  .pony-stats { grid-template-columns: 1fr 1fr; gap: 8px; }
  .pony-table thead th { padding: 10px 12px; font-size: 8px; }
  .pony-table tbody td { padding: 10px 12px; font-size: 11.5px; }
}


/* ————————————————————————————
   CLEAN REFIT — ledger tables, aligned section heads, motion
   Appended last so these win over the base rules above.
———————————————————————————— */

/* a table that starts a card has no card header above it, so its
   header row needs its own breathing room */
.card > .ml-table-wrap:first-child .ml-table th,
.ml-section-body > .ml-table-wrap:first-child .ml-table th,
#mkt-table-area > .ml-table:first-child th { padding-top: 15px; }

/* numeric columns: right-align the header with its figures */
.ml-table th.num, .ml-table td.num, .inv-table th.num, .inv-table td.num {
  text-align: right; font-variant-numeric: tabular-nums;
}

/* Master List ledger — deterministic widths, one line per row, ellipsis
   instead of ragged wrapping. Skipped when admin custom columns exist.
   Notes gets real room (17%) — at 8% it was clipped to nothing. */
.ml-table-masterlist:not(.has-custom) { table-layout: fixed; }
.ml-table-masterlist:not(.has-custom) th,
.ml-table-masterlist:not(.has-custom) td {
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.ml-table-masterlist:not(.has-custom) th:nth-child(1) { width: 14%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(2) { width: 10%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(3) { width: 7%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(4) { width: 13%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(5) { width: 11%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(6) { width: 8%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(7) { width: 10%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(8) { width: 10%; }
.ml-table-masterlist:not(.has-custom) th:nth-child(9) { width: 17%; }
/* the notes cell had min-width:200px, which a fixed column clipped away */
.ml-table-masterlist .ml-notes-cell { min-width: 0; max-width: none; }
.ml-table-masterlist .ml-note-preview { font-size: 11.5px; }

/* the section header pads 18px; make the ledger's outer columns match so the
   title lines up with NAME and the caret lines up with the last column */
.ml-section-body .ml-table th:first-child,
.ml-section-body .ml-table td:first-child { padding-left: 18px; }
.ml-section-body .ml-table th:last-child,
.ml-section-body .ml-table td:last-child { padding-right: 18px; }

/* section head: caret to the right of the count so the title lines up
   with the first table column */
.ml-section-title { order: 1; }
.ml-section-count { order: 2; }
.ml-section-caret { order: 3; margin-left: 4px; }

/* ——— MOTION ———
   Entrance only, and only on page / month / list changes — never on
   filter typing or invoice keystrokes, so nothing flickers.
   transform + opacity only, so it stays on the compositor. */
@keyframes lt-rise { from { opacity: 0; transform: translate3d(0,12px,0); } to { opacity: 1; transform: none; } }
.lt-anim > * { animation: lt-rise .52s var(--ease) both; }
.lt-anim > *:nth-child(1) { animation-delay: 0s; }
.lt-anim > *:nth-child(2) { animation-delay: .055s; }
.lt-anim > *:nth-child(3) { animation-delay: .11s; }
.lt-anim > *:nth-child(4) { animation-delay: .165s; }
.lt-anim > *:nth-child(5) { animation-delay: .22s; }
.lt-anim > *:nth-child(6) { animation-delay: .275s; }
.lt-anim > *:nth-child(7) { animation-delay: .33s; }
.lt-anim > *:nth-child(8) { animation-delay: .385s; }
.lt-anim > *:nth-child(n+9) { animation-delay: .44s; }

/* graph bars grow from the left, staggered down the column */
@keyframes lt-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.lt-anim .ytd-chart-bar, .lt-anim .lead-bar, .lt-anim .growth-bar {
  transform-origin: left; animation: lt-grow .8s var(--ease) both;
}
.lt-anim .ytd-chart-row:nth-child(2) .ytd-chart-bar { animation-delay: .04s; }
.lt-anim .ytd-chart-row:nth-child(3) .ytd-chart-bar { animation-delay: .08s; }
.lt-anim .ytd-chart-row:nth-child(4) .ytd-chart-bar { animation-delay: .12s; }
.lt-anim .ytd-chart-row:nth-child(5) .ytd-chart-bar { animation-delay: .16s; }
.lt-anim .ytd-chart-row:nth-child(6) .ytd-chart-bar { animation-delay: .20s; }
.lt-anim .ytd-chart-row:nth-child(7) .ytd-chart-bar { animation-delay: .24s; }
.lt-anim .ytd-chart-row:nth-child(n+8) .ytd-chart-bar { animation-delay: .28s; }

/* month tabs + sidebar settle on their own easing */
.tab, .sb-item, .sb-page-btn, .inv-month-btn { transition: background .16s var(--ease), color .16s var(--ease); }

@media (prefers-reduced-motion: reduce) {
  .lt-anim > *, .lt-anim .ytd-chart-bar, .lt-anim .lead-bar, .lt-anim .growth-bar {
    animation: none !important;
  }
}

/* ————————————————————————————
   REPORT PAGE — clean layout (ported from the sandbox design)
———————————————————————————— */
.lt-dash { color: var(--dim); }
.lt-g2  { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lt-g3  { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-top: 10px; }
.lt-g12 { display: grid; grid-template-columns: 1fr 1.9fr; gap: 10px; }
@media (max-width: 1150px) { .lt-g2, .lt-g3, .lt-g12 { grid-template-columns: 1fr; } }

.card.lt-card { padding: 0; overflow: hidden; }
.lt-card-h { display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 18px 0; margin-bottom: 13px; }
.lt-card-t { font-size: 13px; font-weight: 600; letter-spacing: -.005em; color: var(--text); }
.lt-card-t span { font-size: 11.5px; font-weight: 400; color: var(--muted); margin-left: 5px; }
.lt-pad { padding: 0 18px 16px; }
.lt-pad-all { padding: 16px 18px; }
.lt-sub { margin-top: 15px; padding-top: 15px; border-top: 1px solid var(--border2); }

/* KPI sub-line + lead card rule */
.lt-kpi-sub { font-size: 11px; color: var(--muted); margin-top: 6px; }
.kpi-card.lead::before { background: var(--text); }
.kpi-card .kpi-val { margin-top: 0; }

/* pills */
.lt-legend { display: flex; gap: 5px; flex-wrap: wrap; }
.lt-pill { display: inline-flex; align-items: center; gap: 5px; padding: 2.5px 9px;
  font-size: 10.5px; font-weight: 500; border-radius: 99px; background: var(--s3);
  color: var(--mid); white-space: nowrap; }
.lt-pill b { color: var(--text); font-weight: 700; }
.lt-dot-ink::before, .lt-dot-mid::before, .lt-dot-lite::before {
  content: ''; width: 5px; height: 5px; border-radius: 50%; flex-shrink: 0; }
.lt-dot-ink::before  { background: var(--text); }
.lt-dot-mid::before  { background: #909090; }
.lt-dot-lite::before { background: var(--dim); }

/* charts */
.lt-chart { width: 100%; display: block; overflow: visible; }
.lt-ax { font-size: 9px; fill: var(--muted); font-family: 'Outfit', sans-serif; }
.lt-gl { stroke: var(--border); stroke-width: 1; }
.lt-slice { font-size: 10px; font-weight: 600; fill: #fff; }
.lt-slice-dark { fill: var(--text); }

/* bar list */
.lt-bl { display: flex; flex-direction: column; gap: 7px; }
.lt-bl-r { display: flex; align-items: center; gap: 12px; }
.lt-bl-k { width: 98px; font-size: 11px; font-weight: 500; flex-shrink: 0; color: var(--mid);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lt-bl-t { flex: 1; height: 15px; background: var(--s4); border-radius: 4px; overflow: hidden;
  min-width: 40px; }
.lt-bl-f { height: 100%; border-radius: 4px; background: var(--text); transform-origin: left; }
.lt-bl-v { width: 64px; text-align: right; font-size: 11.5px; font-weight: 700; flex-shrink: 0;
  font-variant-numeric: tabular-nums; color: var(--text); }

/* prose */
.lt-quote { font-size: 13px; line-height: 1.65; color: var(--mid); }
.lt-big { font-size: 46px; font-weight: 700; letter-spacing: -.04em; line-height: 1;
  color: var(--text); font-variant-numeric: tabular-nums; margin-top: 4px; }

/* outreach hero */
.lt-hero { background: var(--text); color: #fff; border-radius: var(--radius); padding: 22px 24px;
  display: flex; align-items: center; gap: 26px; flex-wrap: wrap; margin-bottom: 10px; }
.lt-hero-n { font-size: 58px; font-weight: 700; letter-spacing: -.045em; line-height: .9;
  font-variant-numeric: tabular-nums; }
.lt-hero-r { flex: 1; min-width: 230px; }
.lt-hero-k { font-size: 9px; letter-spacing: .16em; text-transform: uppercase;
  color: rgba(255,255,255,.45); margin-bottom: 7px; }
.lt-hero-x { font-size: 12.5px; line-height: 1.7; color: rgba(255,255,255,.72); }

/* physicians introduced */
.lt-plist { display: grid; grid-template-columns: repeat(auto-fill,minmax(186px,1fr)); gap: 8px; }
.lt-pitem { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--s2);
  border: 1px solid var(--border); border-radius: var(--radius-sm); }
.lt-pitem-n { font-size: 9.5px; font-weight: 700; color: var(--dim); flex-shrink: 0;
  font-variant-numeric: tabular-nums; }
.lt-pitem-nm { font-size: 12.5px; font-weight: 600; letter-spacing: -.005em; color: var(--text); }
.lt-pitem-s { font-size: 10.5px; color: var(--muted); margin-left: auto; }

/* analysis */
.lt-alist { display: flex; flex-direction: column; gap: 13px; }
.lt-alist li { display: flex; gap: 13px; list-style: none; font-size: 13px; line-height: 1.65;
  color: var(--mid); }
.lt-alist-n { font-size: 10px; font-weight: 700; color: var(--dim); flex-shrink: 0; margin-top: 3px;
  font-variant-numeric: tabular-nums; letter-spacing: .04em; }

/* action steps */
.lt-acts { display: grid; grid-template-columns: repeat(auto-fit,minmax(248px,1fr)); gap: 10px; }
.lt-act { background: var(--s2); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 15px 17px; }
.lt-act-n { font-size: 9.5px; font-weight: 700; color: var(--dim); letter-spacing: .1em; }
.lt-act-t { font-size: 10px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--text); margin: 9px 0 8px; }
.lt-act-x { font-size: 12.5px; line-height: 1.65; color: var(--mid); }

/* motion for the new chart + bars */
@keyframes lt-draw { from { stroke-dashoffset: var(--len); } to { stroke-dashoffset: 0; } }
@keyframes lt-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes lt-area { from { opacity: 0; transform: scaleY(.9); } to { opacity: 1; transform: none; } }
@keyframes lt-dot  { from { opacity: 0; transform: scale(.2); } to { opacity: 1; transform: scale(1); } }
@keyframes lt-pie  { from { opacity: 0; transform: scale(.92) rotate(-7deg); } to { opacity: 1; transform: none; } }
.lt-anim .lt-ln { stroke-dasharray: var(--len); animation: lt-draw 1.15s var(--ease) .12s both; }
.lt-anim .lt-ln-dash { animation: lt-fade .95s var(--ease) .45s both; }
.lt-anim .lt-area { transform-origin: bottom; animation: lt-area .8s var(--ease) .3s both; }
.lt-anim .lt-dot { transform-box: fill-box; transform-origin: center;
  animation: lt-dot .42s cubic-bezier(.34,1.5,.64,1) both; }
.lt-anim .lt-pie { transform-box: fill-box; transform-origin: center;
  animation: lt-pie .7s var(--ease) .18s both; }
.lt-anim .lt-bl-f { animation: lt-grow .8s var(--ease) both; }
@media (prefers-reduced-motion: reduce) {
  .lt-anim .lt-ln, .lt-anim .lt-ln-dash, .lt-anim .lt-area, .lt-anim .lt-dot,
  .lt-anim .lt-pie, .lt-anim .lt-bl-f { animation: none !important; }
}

/* ————————————————————————————
   WIDTH — cap and centre the content so wide screens don't stretch.
   Was: 880px on the report but max-width:100% on Master List / Invoices,
   which let those two run edge-to-edge.
———————————————————————————— */
.content,
.content:has(.inv-ytd),
.content:has(.ml-toolbar) {
  max-width: 1300px;
  width: 100%;
  margin: 0 auto;
}
/* month strip lines up with the content below it */
.topbar { padding: 0; }
.topbar .tabs { max-width: 1300px; width: 100%; margin: 0 auto; padding: 0 28px; }

/* keep the filter toolbar on one line at this width */
.ml-toolbar .ml-search { max-width: 260px; min-width: 160px; }
.ml-toolbar .ml-select { max-width: 150px; }

/* ————————————————————————————
   EVENT WORKSPACE (ACEP 2026)
   The one page allowed colour: deep teal, scoped to .ev so the rest of LT stays monochrome.
———————————————————————————— */
.content:has(.ev) { max-width: 100%; min-width: 0; }
/* Flex items default to min-width:auto; without this a wide board (or table) widens the whole page instead of scrolling in place. */
body[data-page="event"] .main { min-width: 0; }
body[data-page="event"] .main { background: #f6f5f1; }
.ev {
  --ev-bg: #f6f5f1;          /* warm white page; working surfaces are white */
  --ev-card: #ffffff;
  --ev-sunken: #f1f0eb;
  --ev-hover: #fbfaf7;
  --ev-line: #e6e4dd;
  --ev-line-strong: #d6d3ca;
  --ev-ink: #16252a;
  --ev-mid: #44545a;
  --ev-muted: #5f6d72;       /* the lightest text allowed: 4.9:1 on the page background, 5.4:1 on white */
  --ev-green: #2e7d4f;
  --ev-teal: #1a6965;        /* primary; also Pulse "Form Leads" */
  --ev-teal-dk: #125350;
  --ev-teal-lt: #7cc4bd;     /* Pulse "Qualified" (validated ordinal pair with --ev-teal) */
  --ev-teal-soft: #e4f1ef;
  --ev-blue-soft: #e6eef8;   --ev-blue-ink: #2d5b8f;
  --ev-lav-soft: #eeebf8;    --ev-lav-ink: #5a4ba0;
  --ev-yellow-soft: #f8f1dd; --ev-yellow-ink: #85650f;
  --ev-coral-soft: #f8e6e1;  --ev-coral-ink: #a1442e;
  /* Gauge ramp, light (1) → dark (7), validated ordinal */
  --ev-g1: #7cc4bd; --ev-g2: #5aaea7; --ev-g3: #3d9791; --ev-g4: #27807b;
  --ev-g5: #1a6965; --ev-g6: #125350; --ev-g7: #0b3d3b; --ev-g-off: #e6eeec;
  --ev-radius: 14px;
  color: var(--ev-ink);
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  accent-color: var(--ev-teal);
  caret-color: var(--ev-teal);
}
.ev ::selection { background: #cfe5e1; }
.ev kbd { font: 500 11px 'Outfit', sans-serif; padding: 0 5px; border: 1px solid currentColor; border-radius: 4px; opacity: .6; line-height: 16px; }
.ev-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ev svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ev .ev-pulse-chart, .ev .ev-gauge svg { width: 100%; height: auto; stroke: none; }
.ev-empty { padding: 32px; text-align: center; color: var(--ev-muted); }
.ev-muted { color: var(--ev-muted); font-size: 12.5px; }
.ev-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ev-foot { margin-top: 10px; }

/* Header */
.ev-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; padding: 18px 2px 16px; flex-wrap: wrap; }
.ev-eyebrow { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--ev-teal); font-weight: 700; }
.ev-title { font-size: 28px; font-weight: 600; letter-spacing: -.025em; line-height: 1.15; margin: 0 0 4px; }
.ev-sub { color: var(--ev-mid); font-size: 13.5px; }
.ev-sub b { color: var(--ev-teal); font-weight: 600; }
.ev-sub span[title] { text-decoration: underline dotted var(--ev-line-strong); text-underline-offset: 3px; cursor: help; }
.ev-head-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ev-live { font: inherit; font-size: 12.5px; font-weight: 500; display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  color: var(--ev-mid); background: var(--ev-card); border: 1px solid var(--ev-line); padding: 0 12px; min-height: 32px; border-radius: 999px; }
.ev-live:hover { border-color: var(--ev-line-strong); color: var(--ev-ink); }
.ev-live i, .ev-status i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; display: inline-block; }
.ev-live-on i { background: var(--ev-green); }
.ev-live-stale { color: var(--ev-yellow-ink); background: var(--ev-yellow-soft); border-color: #eadbb0; }
.ev-live-off { color: var(--ev-coral-ink); background: var(--ev-coral-soft); border-color: #ebc9bf; }
/* Phone: the sidebar's ACEP views move to a row under the header. */
.ev-viewnav { display: none; }

/* Buttons & inputs */
.ev-btn { font: inherit; font-weight: 500; font-size: 13.5px; padding: 0 13px; border-radius: 8px; border: 1px solid var(--ev-line-strong);
  background: var(--ev-card); color: var(--ev-ink); cursor: pointer; min-height: 36px; display: inline-flex; align-items: center; gap: 7px; }
.ev-btn:hover { border-color: var(--ev-mid); }
.ev-btn.on { border-color: var(--ev-teal); }
.ev-btn:disabled { opacity: .5; cursor: default; }
.ev-btn, .ev-chip-btn, .ev-kpi { transition: transform .18s cubic-bezier(.22,1,.36,1), border-color .15s, background-color .15s, box-shadow .2s; }
.ev-btn:active:not(:disabled), .ev-chip-btn:active { transform: scale(.96); }
.ev-kpi:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(22,37,42,.07); }
.ev-kpi:active { transform: translateY(0) scale(.985); }
@media (prefers-reduced-motion: reduce) { .ev-btn, .ev-chip-btn, .ev-kpi { transition: none; } .ev-kpi:hover { transform: none; } }
.ev-btn-primary { background: var(--ev-teal); border-color: var(--ev-teal); color: #fff; }
.ev-btn-primary:hover { background: var(--ev-teal-dk); }
.ev-link { font: inherit; font-size: 13px; font-weight: 600; background: none; border: 0; color: var(--ev-teal); cursor: pointer; padding: 4px; }
.ev-link:hover { text-decoration: underline; }
.ev-page-title { font-size: 20px; font-weight: 600; margin: 2px 0 14px; }
.ev-page-sub { margin: -8px 0 14px; }
.ev button:focus-visible, .ev .ev-input:focus-visible, .ev [data-ev-lead]:focus-visible {
  outline: 2px solid var(--ev-teal); outline-offset: 2px; }
.ev-input { font: inherit; font-size: 13.5px; border: 1px solid var(--ev-line-strong); border-radius: 8px; padding: 7px 11px;
  background: #fff; color: var(--ev-ink); min-height: 36px; width: 100%; }
.ev-input::placeholder { color: var(--ev-muted); }
.ev-input:focus { outline: none; border-color: var(--ev-teal); box-shadow: 0 0 0 3px var(--ev-teal-soft); }
.ev-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.ev-filters .ev-input { width: auto; }
/* Segmented control: Mine / Team, Work view / Form fields */
.ev-seg { display: inline-flex; border: 1px solid var(--ev-line); border-radius: 10px; background: var(--ev-sunken); padding: 3px; flex: 0 0 auto; }
.ev-seg button { font: inherit; font-size: 13px; border: 0; background: none; color: var(--ev-mid); padding: 0 11px; min-height: 30px; border-radius: 6px; cursor: pointer; white-space: nowrap; }
.ev-seg button:hover { color: var(--ev-ink); }
.ev-seg button.on { background: var(--ev-card); color: var(--ev-teal-dk); font-weight: 600; box-shadow: 0 1px 3px rgba(22,37,42,.10); }
/* Work queues: the first row of the list card; one scope (Mine / Team) for every count */
.ev-queues { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--ev-line); }
.ev-queues-list { display: flex; gap: 6px; flex: 1; min-width: 0; flex-wrap: wrap; }
.ev-q { font: inherit; display: inline-flex; align-items: center; gap: 7px; min-height: 34px; padding: 0 11px; border: 1px solid var(--ev-line);
  border-radius: 8px; background: var(--ev-card); color: var(--ev-mid); font-size: 13.5px; cursor: pointer; white-space: nowrap; flex-shrink: 0; }
.ev-q b { font-weight: 600; color: var(--ev-ink); }
.ev-q:hover { border-color: var(--ev-line-strong); color: var(--ev-ink); }
.ev-q.zero b { color: var(--ev-muted); font-weight: 500; }
.ev-q.alert { background: #fbeeea; border-color: #efcfc5; color: var(--ev-coral-ink); }
.ev-q.alert b { color: var(--ev-coral-ink); }
.ev-q.on { border-color: var(--ev-teal); color: var(--ev-teal-dk); background: var(--ev-teal-soft); }
.ev-q.on b { color: var(--ev-teal-dk); }
.ev-q-more .ev-chev { margin-right: -4px; }
.ev-menu-n { margin-left: auto; padding-left: 16px; color: var(--ev-muted); }
.ev-menu-pop [aria-current] { color: var(--ev-teal-dk); font-weight: 600; }
.ev-queues .ev-menu-pop { left: 0; right: auto; }

/* Lead Hub toolbar: one line — search grows, selects stay compact. */
.ev-toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 12px; border-bottom: 1px solid var(--ev-line); }
.ev-toolbar .ev-input { width: auto; }
.ev-toolbar select.ev-input { flex: 0 0 auto; max-width: 170px; }
/* Own chevron so it sits further in from the edge than the browser's. */
select.ev-input { -webkit-appearance: none; appearance: none; padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none' stroke='%23525252' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 4.5l3 3 3-3'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; background-size: 12px; }
.ev-toolbar .ev-search-wrap { flex: 1 1 220px; max-width: 360px; min-width: 200px; }
.ev-toolbar .ev-search { width: 100%; }
.ev-toolbar-sp { flex: 1; }
.ev-count { font-size: 13px; color: var(--ev-muted); white-space: nowrap; }
.ev-dash { color: var(--ev-line-strong); }
.ev-more { margin: 0; padding: 10px 12px; background: var(--ev-hover); border-bottom: 1px solid var(--ev-line); }
/* Page header for the workspace's other views (Follow-ups, Marlab handoff) */
.ev-page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 12px; }
.ev-page-head .ev-page-title { margin-bottom: 2px; }
.ev-card.ev-flush { padding: 0; }
/* Count chips above a table */
.ev-board-sum { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.ev-bsum { font: inherit; display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; border: 1px solid var(--ev-line);
  border-radius: 8px; background: var(--ev-card); color: var(--ev-mid); font-size: 13.5px; }
.ev-bsum b { color: var(--ev-ink); font-weight: 600; }
.ev-bsum.alert { background: #fbeeea; border-color: #efcfc5; color: var(--ev-coral-ink); }
.ev-bsum.alert b { color: var(--ev-coral-ink); }
.ev-kcount { font-size: 12px; font-weight: 600; color: var(--ev-mid); background: #e6e4dd; border-radius: 999px; padding: 1px 8px; }
/* Follow-ups: one table, section rows */
.ev-fu-table td { white-space: normal; }
.ev-fu-table .ev-over { color: var(--ev-coral-ink); font-weight: 500; }
.ev-fu-table .ev-due { color: var(--ev-yellow-ink); font-weight: 500; }
.ev-qsec th { background: var(--ev-sunken); color: var(--ev-ink); font-size: 13px; font-weight: 600; padding: 8px 12px; }
.ev-qsec th span { margin-left: 8px; color: var(--ev-muted); font-weight: 500; }
.ev-qsec.over th { color: var(--ev-coral-ink); }
.ev-fu-lead { display: block; font-size: 12px; color: var(--ev-muted); margin-top: 2px; }
/* Marlab handoff */
.ev-ho-sec { margin-bottom: 14px; }
.ev-ho-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 14px 16px; border-bottom: 1px solid var(--ev-line); }
.ev-ho-head h2 { font-size: 15px; font-weight: 600; }
.ev-ho-miss { white-space: normal !important; }
.ev-ho-miss .ev-chip-miss { margin: 2px 6px 2px 0; }
.ev-ho-actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 12px 16px; border-top: 1px solid var(--ev-line); }
.ev-ho-preview { padding: 0 16px 16px; }
.ev-ho-preview > .ev-muted { margin: 4px 0 8px; }
.ev-ho-preview .ev-table-wrap { border: 1px solid var(--ev-line); border-radius: 8px; }
.ev-ho-preview .ev-table.ev-sheet { min-width: 1200px; }
.ev-ho-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* Filters in effect beyond the queue */
.ev-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--ev-line); }
.ev-chips[hidden] { display: none; }
.ev-fchip { font: inherit; font-size: 13px; display: inline-flex; align-items: center; gap: 6px; border: 0; cursor: pointer;
  background: var(--ev-teal-soft); color: var(--ev-teal-dk); border-radius: 999px; padding: 3px 9px 3px 11px; }
.ev-fchip span { font-size: 15px; line-height: 1; opacity: .7; }
.ev-fchip:hover span { opacity: 1; }
.ev-more[hidden] { display: none; }
.ev-search-wrap { position: relative; display: flex; align-items: center; flex: 1 1 190px; }
.ev-search-wrap svg { position: absolute; left: 12px; color: var(--ev-muted); }
.ev-search { padding-left: 36px; }

/* Menus */
.ev-menu { position: relative; }
.ev-menu-pop { position: absolute; right: 0; top: calc(100% + 6px); z-index: 50; background: var(--ev-card); border: 1px solid var(--ev-line);
  border-radius: 12px; box-shadow: 0 10px 30px rgba(22,37,42,.12); padding: 6px; min-width: 220px; display: flex; flex-direction: column; }
.ev-menu-pop[hidden] { display: none; }
.ev-menu-pop button, .ev-menu-pop a { font: inherit; text-align: left; background: none; border: 0; padding: 9px 10px; border-radius: 8px;
  cursor: pointer; color: var(--ev-ink); text-decoration: none; }
.ev-menu-pop button:hover, .ev-menu-pop a:hover { background: var(--ev-teal-soft); }
.ev-menu-pop button, .ev-menu-pop a { display: flex; align-items: center; gap: 8px; }
.ev-menu-h { font-size: 12px; color: var(--ev-muted); padding: 6px 10px 2px; }
.ev-menu-pop hr { border: 0; border-top: 1px solid var(--ev-line); margin: 6px 0; }

/* Cards & grid */
.ev-card { background: var(--ev-card); border: 1px solid var(--ev-line); border-radius: var(--ev-radius); padding: 20px; }
.ev-main > .ev-card { margin-bottom: 14px; }
.ev-card h2 { font-size: 17px; font-weight: 600; letter-spacing: -.015em; line-height: 1.35; }
.ev-card h3 { font-size: 14.5px; font-weight: 600; margin: 18px 0 10px; }
.ev-hub { padding: 0; }
.ev-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.ev-row1 { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.2fr) minmax(0, .85fr); gap: 16px; margin-bottom: 16px; }

/* KPI cards */
.ev-kpis { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.ev-kpi { font: inherit; text-align: left; background: var(--ev-card); border: 1px solid var(--ev-line); border-radius: var(--ev-radius);
  padding: 18px 20px; display: flex; flex-direction: column; gap: 8px; color: var(--ev-ink); cursor: pointer; min-height: 150px; }
.ev-kpi:hover { border-color: var(--ev-teal); }
.ev-kpi-top { display: flex; justify-content: space-between; align-items: center; font-size: 14px; color: var(--ev-mid); }
.ev-kpi-icon { width: 34px; height: 34px; border-radius: 10px; background: var(--ev-teal-soft); color: var(--ev-teal);
  display: inline-flex; align-items: center; justify-content: center; }
.ev-kpi-icon svg { width: 18px; height: 18px; }
.ev-kpi > b { font-size: 40px; line-height: 1.1; font-weight: 600; letter-spacing: -.03em; margin-top: auto; font-variant-numeric: tabular-nums; }
/* Brand emphasis stays on the headline metric; all data and grid positions are unchanged. */
/* Odometer tick for each new value while a counter rolls. */
.ev-kpi > b { display: inline-block; } /* so the odometer spring can move it */
.ev-trend { font-size: 12px; color: var(--ev-mid); line-height: 1.4; }
.ev-trend b { color: var(--ev-teal); font-weight: 700; }
.ev-trend span { color: var(--ev-teal); margin-right: 2px; }
.ev-trend.down b, .ev-trend.down span { color: var(--ev-mid); }
.ev-trend.bad b, .ev-trend.bad span { color: var(--ev-coral-ink); }

/* Event Pulse */
.ev-legend-inline { list-style: none; display: flex; gap: 14px; font-size: 12px; color: var(--ev-mid); }
.ev-legend-inline li { display: flex; align-items: center; gap: 6px; }
.ev-legend-inline i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
i.ev-s1 { background: var(--ev-teal); } i.ev-s2 { background: var(--ev-teal-lt); }
path.ev-s1 { fill: var(--ev-teal); } path.ev-s2 { fill: var(--ev-teal-lt); }
.ev-grid-line { stroke: var(--ev-line); stroke-dasharray: 3 3; stroke-width: 1; }
.ev-axis { font-size: 10.5px; fill: var(--ev-muted); font-family: 'Outfit', sans-serif; }
.ev-axis-sub { font-size: 9.5px; }
.ev-hit { fill: transparent; }
.ev-pulse-g { cursor: pointer; }
.ev-pulse-g:hover .ev-hit { fill: var(--ev-teal-soft); opacity: .5; }

/* Pipeline gauge */
.ev-gauge { display: block; width: 100%; max-width: 280px; margin: 0 auto; background: none; border: 0; padding: 8px 6px 0; cursor: pointer; }
/* Motion scales gauge segments from their centre and Pulse bars up from the baseline. */
.ev-seg-on { transform-box: fill-box; transform-origin: center; }
.ev-pulse-chart path.ev-s1, .ev-pulse-chart path.ev-s2 { transform-box: fill-box; transform-origin: bottom; }
.ev-gauge-n { font-size: 26px; font-weight: 700; fill: var(--ev-ink); font-family: 'Outfit', sans-serif; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
/* Outreach funnel (under the gauge): one teal, bars grow in when the counts change. */
.ev-funnel { list-style: none; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--ev-line); display: flex; flex-direction: column; gap: 2px; }
.ev-funnel button { font: inherit; width: 100%; display: grid; grid-template-columns: 76px 1fr 26px 38px; gap: 10px; align-items: center;
  background: none; border: 0; padding: 6px 6px; border-radius: 8px; cursor: pointer; color: var(--ev-mid); font-size: 12px; text-align: left; }
.ev-funnel button:hover { background: var(--ev-teal-soft); }
.ev-funnel b { color: var(--ev-ink); font-size: 13px; text-align: right; font-variant-numeric: tabular-nums; }
.ev-funnel-pct { text-align: right; color: var(--ev-muted); font-variant-numeric: tabular-nums; }
.ev-funnel-track { height: 8px; background: var(--ev-g-off); border-radius: 4px; overflow: hidden; }
.ev-funnel-bar { display: block; height: 100%; background: var(--ev-teal); border-radius: 4px; min-width: 2px; }

/* Lead Hub */
.ev-bulk { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; background: var(--ev-teal-soft); border-radius: 10px; padding: 8px 10px; margin-bottom: 10px; }
.ev-bulk[hidden] { display: none; }
.ev-bulk .ev-input { width: auto; }
.ev-bulk .ev-dd-btn { min-width: 150px; }
.ev-table-wrap { overflow-x: auto; border-radius: 0 0 var(--ev-radius) var(--ev-radius); }
.ev-card > .ev-table, .ev-card .ev-table { font-size: 13.5px; }
.ev-table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.ev-table td { white-space: nowrap; }
.ev-table th { text-align: left; font-size: 12px; font-weight: 600; color: var(--ev-muted); padding: 9px 12px; white-space: nowrap;
  background: var(--ev-hover); border-bottom: 1px solid var(--ev-line); }
.ev-table td { padding: 14px 12px; border-bottom: 1px solid var(--ev-line); vertical-align: middle; }
.ev-table tr:last-child td { border-bottom: 0; }
.ev-table tr[data-ev-lead] { cursor: pointer; }
.ev-table tr[data-ev-lead]:hover td { background: var(--ev-hover); }
.ev-table tr.active td, .ev-table tr.active:hover td { background: var(--ev-teal-soft); }
.ev-table .ev-cb { width: 40px; padding-right: 0; }
/* Work view: wraps instead of truncating; the drawer has everything else */
.ev-list-work td { white-space: normal; }
.ev-list-work .ev-stat, .ev-list-work .ev-own, .ev-list-work .ev-pri-c, .ev-list-work .ev-acts { white-space: nowrap; }
.ev-phys { min-width: 200px; }
.ev-phys b { font-weight: 600; font-size: 14px; letter-spacing: -.01em; }
.ev-phys > span:last-child, .ev-nxt span, .ev-lst span { display: block; font-size: 12.5px; color: var(--ev-muted); margin-top: 1px; }
.ev-nxt { min-width: 170px; }
.ev-nxt b { display: block; font-weight: 500; }
.ev-nxt .ev-over { color: var(--ev-coral-ink); font-weight: 500; }
.ev-nxt .ev-due { color: var(--ev-yellow-ink); font-weight: 500; }
.ev-none { color: var(--ev-muted); }
.ev-lst { color: var(--ev-mid); font-size: 13px; }
.ev-person { display: inline-flex; align-items: center; gap: 8px; }
.ev-person .ev-av { width: 24px; height: 24px; font-size: 11px; background: var(--ev-sunken); color: var(--ev-mid); border: 1px solid var(--ev-line); }
.ev-unas { color: var(--ev-yellow-ink); font-size: 13px; }
.ev-bars { display: inline-flex; gap: 2px; vertical-align: middle; }
.ev-bars i { width: 4px; height: 12px; border-radius: 1px; background: var(--ev-line-strong); }
.ev-bars i.on { background: var(--ev-mid); }
.ev-acts { text-align: right; width: 84px; }
.ev-ib { font: inherit; width: 32px; height: 32px; border-radius: 8px; border: 0; background: none; color: var(--ev-muted); cursor: pointer;
  display: inline-grid; place-items: center; vertical-align: middle; }
.ev-ib:hover { background: var(--ev-sunken); color: var(--ev-ink); }
.ev-num { text-align: right; }
/* Sheet-shaped table: fixed columns that always fit; long values end in "…" (full text on hover / in the drawer). */
.ev-table.ev-sheet { table-layout: fixed; }
.ev-table.ev-sheet { min-width: 1080px; }
.ev-sheet th, .ev-sheet td { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ev-note-cell { width: 100%; max-width: 0; color: var(--ev-mid); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ev-who { display: flex; align-items: center; gap: 10px; }
.ev-av { width: 30px; height: 30px; border-radius: 50%; background: var(--ev-teal-soft); color: var(--ev-teal); font-size: 10px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; letter-spacing: .02em; }
.ev-dots { font: inherit; font-size: 18px; line-height: 1; background: none; border: 0; cursor: pointer; color: var(--ev-mid);
  width: 32px; height: 32px; border-radius: 8px; vertical-align: middle; }
.ev-dots:hover { background: var(--ev-teal-soft); color: var(--ev-ink); }

/* Pills */
.ev-pill { display: inline-block; font-size: 12px; line-height: 1.5; font-weight: 500; padding: 3px 10px; border-radius: 6px; background: #efeee9; color: var(--ev-mid); white-space: nowrap; }
.ev-pipe-new { background: var(--ev-teal-soft); color: var(--ev-teal-dk); }
.ev-pipe-message-sent { background: var(--ev-yellow-soft); color: var(--ev-yellow-ink); }
.ev-pipe-replied { background: var(--ev-coral-soft); color: var(--ev-coral-ink); }
.ev-pipe-interested { background: var(--ev-lav-soft); color: var(--ev-lav-ink); }
.ev-pipe-no-response, .ev-pipe-not-interested { background: #f4f6f5; color: var(--ev-muted); }
.ev-pipe-qualified { background: var(--ev-blue-soft); color: var(--ev-blue-ink); }
.ev-pipe-marlab-ready { background: var(--ev-teal); color: #fff; }
.ev-pipe-exported { background: #efeee9; color: var(--ev-mid); }
.ev-pipe-imported { background: var(--ev-g7); color: #fff; }
.ev-pri-high { background: var(--ev-teal-soft); color: var(--ev-teal-dk); }
.ev-pri-medium { background: #eef2f1; color: var(--ev-mid); }
.ev-pri-low { background: #f4f6f5; color: var(--ev-muted); }
.ev-flag { background: var(--ev-coral-soft); color: var(--ev-coral-ink); margin-left: 6px; }

/* Sync & Exports, queue, shared bits */
.ev-kpis-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 14px; }
.ev-status { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 12px; margin: 8px 0; }
.ev-status-on { color: var(--ev-teal); }
.ev-status-stale { color: var(--ev-yellow-ink); }
.ev-status-off { color: var(--ev-coral-ink); }
.ev-dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 13.5px; margin: 10px 0; }
.ev-dl dt { color: var(--ev-muted); }
.ev-dl dd { font-weight: 500; }
.ev-steps { padding-left: 18px; font-size: 12px; line-height: 1.8; margin: 8px 0 14px; }
.ev-timeline { list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; }

.ev-timeline li { display: flex; flex-direction: column; gap: 1px; border-left: 2px solid var(--ev-line); padding-left: 10px; }
.ev-timeline li[data-ev-lead] { cursor: pointer; }
.ev-kpi.static { cursor: default; min-height: 0; }

/* Live: presence, new-row flash, toast */
.ev-presence { display: flex; align-items: center; gap: 4px; }
.ev-presence .ev-av { width: 30px; height: 30px; border: 2px solid #fff; margin-left: -8px; background: var(--ev-teal); color: #fff; }
.ev-presence .ev-av:first-child { margin-left: 0; }
.ev-presence .ev-muted { margin-left: 6px; }
.ev-viewing { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12px; font-weight: 600;
  color: var(--ev-yellow-ink); background: var(--ev-yellow-soft); padding: 4px 10px; border-radius: 8px; }
.ev-viewing i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ev-toast { position: fixed; left: 0; right: 0; margin: 0 auto; width: fit-content; bottom: 24px; z-index: 600; background: var(--ev-ink); color: #fff;
  padding: 10px 16px; border-radius: 12px; font-size: 13px; font-weight: 600; box-shadow: 0 10px 30px rgba(22,37,42,.25);
}

/* Drawer: outreach bar */
.ev-contact-sum { font-size: 12px; color: var(--ev-mid); margin-top: 6px; }
.ev-contact-sum b { color: var(--ev-ink); font-weight: 600; }
.ev-contact { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0 0 14px; }
.ev-contact .ev-btn { justify-content: center; text-decoration: none; }
a.ev-btn { text-decoration: none; }
.ev-btn-off { opacity: .45; cursor: not-allowed; }
/* Follow-up: reach out → "What happened?" → next follow-up */
.ev-sub-h { font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; font-weight: 700; color: var(--ev-muted); margin: 16px 0 8px; }
.ev-outcome { margin: 2px 0 4px; background: var(--ev-teal-soft); border-radius: 14px; padding: 4px 14px 14px; display: flex; flex-direction: column; gap: 10px; }
.ev-outcome .ev-sub-h { color: var(--ev-teal-dk); margin: 10px 0 0; }
.ev-outcome textarea { background: #fff; }
.ev-seg-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ev-seg-row .ev-muted { margin-right: 4px; }
.ev-seg-row .ev-btn { min-height: 32px; padding: 5px 12px; font-size: 12px; }
.ev-btn.on { background: var(--ev-teal); border-color: var(--ev-teal); color: #fff; }
.ev-next { display: flex; align-items: center; gap: 10px; background: #f6f9f8; border: 1px solid var(--ev-line); border-radius: 14px; padding: 10px 12px; font-size: 13px; }
.ev-next > span:nth-child(2) { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.ev-next-when { font-size: 12px; color: var(--ev-mid); }
.ev-next.overdue { border-color: var(--ev-coral-soft); background: #fdf6f4; }
.ev-next-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--ev-teal-soft); color: var(--ev-teal); display: grid; place-items: center; flex-shrink: 0; }
.ev-next .ev-btn { min-height: 32px; padding: 5px 12px; }
.ev-overdue { color: var(--ev-coral-ink); font-weight: 700; }
.ev-next-none { flex-wrap: wrap; color: var(--ev-mid); }
.ev-next-none > span { flex: 1 1 100%; font-weight: 600; color: var(--ev-ink); }
.ev-next-none .ev-btn { min-height: 32px; padding: 5px 12px; font-size: 12px; }
.ev-next-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; font-size: 12px; }

/* Dropdowns (evDD): one look for Status, Priority, Assigned To, Source, Candidate Status, modals and bulk actions */
.ev-field { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 500; color: var(--ev-mid); min-width: 0; }
.ev-dd { position: relative; min-width: 0; }
.ev-dd-btn { display: flex; align-items: center; justify-content: space-between; gap: 8px; text-align: left; cursor: pointer; font-weight: 500; }
.ev-dd-btn:hover { border-color: #c9d6d3; }
.ev-dd-btn[aria-expanded="true"] { border-color: var(--ev-teal); box-shadow: 0 0 0 3px var(--ev-teal-soft); }
.ev-dd-val { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ev-ink); }
.ev-dd-ph { color: var(--ev-muted); }
.ev .ev-chev { width: 16px; height: 16px; color: var(--ev-muted); transition: transform .2s; }
.ev-dd-btn[aria-expanded="true"] .ev-chev { transform: rotate(180deg); color: var(--ev-teal); }
.ev-dd-pop { position: absolute; top: calc(100% + 6px); left: 0; min-width: 100%; z-index: 60; background: var(--ev-card);
  border: 1px solid var(--ev-line); border-radius: 12px; box-shadow: 0 12px 32px rgba(22,37,42,.14); padding: 6px; transform-origin: top left; }
.ev-dd-q { margin-bottom: 6px; min-height: 34px; }
.ev-dd-list { display: flex; flex-direction: column; max-height: 240px; overflow-y: auto; }
.ev-dd-opt { font: inherit; font-size: 13px; font-weight: 500; text-align: left; background: none; border: 0; border-radius: 8px;
  padding: 8px 10px 8px 28px; cursor: pointer; color: var(--ev-ink); position: relative; white-space: nowrap; }
.ev-dd-opt:hover, .ev-dd-opt:focus-visible { background: var(--ev-teal-soft); outline: none; }
.ev-dd-opt[aria-selected="true"] { font-weight: 700; color: var(--ev-teal-dk); }
.ev-dd-opt[aria-selected="true"]::before { content: '✓'; position: absolute; left: 10px; color: var(--ev-teal); }
.ev-dd-add { color: var(--ev-teal); font-weight: 600; }
.ev-dd-none { padding: 8px 10px; color: var(--ev-muted); font-size: 12px; }
.ev-dd-sm .ev-dd-btn { min-height: 32px; padding: 5px 10px; font-size: 12px; font-weight: 600; }
.ev-dd-sm .ev-dd-pop { min-width: 150px; }
.ev-next .ev-dd-pop, .ev-bulk .ev-dd-pop { left: auto; right: 0; transform-origin: top right; }

/* Marlab handoff: a completeness bar, only what's missing, and a clear state */
.ev-handoff-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
.ev-handoff-head h3 { margin: 0; }
.ev-hs { font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: #eef2f1; color: var(--ev-mid); }
.ev-hs-ready { background: var(--ev-teal); color: #fff; }
.ev-hs-exported { background: var(--ev-teal-soft); color: var(--ev-teal-dk); }
.ev-hs-imported { background: var(--ev-g7); color: #fff; }
.ev-meter { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; }
.ev-meter i { height: 6px; border-radius: 3px; background: var(--ev-g-off); }
.ev-meter i.on { background: var(--ev-teal); }
.ev-missing { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 12px; }
.ev-chip-miss { font: inherit; font-size: 12px; font-weight: 600; border: 1px dashed #e0b8ad; background: var(--ev-coral-soft); color: var(--ev-coral-ink);
  border-radius: 999px; padding: 4px 11px; cursor: pointer; transition: transform .18s cubic-bezier(.22,1,.36,1); }
.ev-chip-miss:hover { border-style: solid; }
.ev-chip-miss:active { transform: scale(.96); }
.ev-hint { font-size: 12px; color: var(--ev-mid); margin-top: 12px; }
.ev-handoff-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; align-items: end; margin-top: 14px; }
.ev-handoff-foot { margin-top: 12px; }
.ev-switch { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; color: var(--ev-ink); cursor: pointer; min-height: 38px; }
.ev-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ev-switch span { width: 36px; height: 20px; border-radius: 999px; background: #d6dfdd; position: relative; transition: background .2s; flex-shrink: 0; }
.ev-switch span::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .25s cubic-bezier(.22,1,.36,1); }
.ev-switch input:checked + span { background: var(--ev-teal); }
.ev-switch input:checked + span::after { transform: translateX(16px); }
.ev-switch input:focus-visible + span { outline: 2px solid var(--ev-teal); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { .ev-switch span, .ev-switch span::after, .ev .ev-chev { transition: none; } }

/* Drawer: form answers first; the rest of the form behind "More form answers" */
.ev-sec.ev-first { border-top: 0; margin-top: 16px; padding-top: 0; }
.ev-more-answers { margin-top: 10px; }
.ev-more-answers summary { cursor: pointer; font-size: 12px; font-weight: 600; color: var(--ev-teal); list-style: none; }
.ev-more-answers summary::-webkit-details-marker { display: none; }
.ev-more-answers summary::before { content: '▸ '; }
.ev-more-answers[open] summary::before { content: '▾ '; }
.ev-more-answers .ev-drawer-grid { margin-top: 10px; }
.ev-sec .ev-contact { margin-bottom: 10px; }

/* Drawer */
.ev-drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(480px, 100vw); background: var(--ev-card); z-index: 400;
  box-shadow: -1px 0 0 var(--ev-line), -24px 0 48px -20px rgba(22,37,42,.22); overflow-y: auto; padding: 18px 20px 40px; }
.ev-drawer-head { position: sticky; top: -18px; z-index: 5; background: var(--ev-card); margin: -18px -20px 14px; padding: 18px 20px 12px;
  border-bottom: 1px solid var(--ev-line); }
.ev-drawer-head h2 .ev-pill { vertical-align: 3px; margin-left: 4px; }
.ev-drawer-top { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ev-drawer-bar { display: none; }
.ev-drawer-next { margin-top: 10px; }
/* Note box: the first thing to type into */
.ev-composer { border: 1px solid var(--ev-line-strong); border-radius: var(--ev-radius); background: #fff; }
.ev-composer:focus-within { border-color: var(--ev-teal); box-shadow: 0 0 0 3px var(--ev-teal-soft); }
.ev-composer textarea { border: 0; min-height: 72px; resize: vertical; font-size: 14px; padding: 10px 12px 4px; }
.ev-composer textarea:focus { box-shadow: none; }
.ev-composer-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 8px 8px 12px; }
.ev-composer-foot kbd { border-color: #fff; opacity: .7; }
.ev-note-state { font-size: 12.5px; color: var(--ev-muted); }
.ev-note-state.draft { color: var(--ev-yellow-ink); }
.ev-note-state.saved { color: var(--ev-green); font-weight: 500; }
.ev-note-state.failed { color: var(--ev-coral-ink); font-weight: 500; }
/* Collapsible drawer sections */
.ev-folds { margin-top: 18px; }
.ev-fold { border: 1px solid var(--ev-line); border-radius: var(--ev-radius); margin-top: 8px; }
.ev-fold > summary { list-style: none; display: flex; align-items: center; gap: 8px; padding: 10px 12px; min-height: 44px; font-weight: 600; font-size: 13.5px; cursor: pointer; border-radius: var(--ev-radius); }
.ev-fold > summary::-webkit-details-marker { display: none; }
.ev-fold > summary:hover { background: var(--ev-hover); }
.ev-fold > summary:focus-visible { outline: 2px solid var(--ev-teal); outline-offset: 2px; }
.ev-fold-r { margin-left: auto; font-size: 12.5px; font-weight: 400; color: var(--ev-muted); }
.ev-fold[open] > summary .ev-chev { transform: rotate(180deg); }
.ev-fold-b { padding: 2px 12px 14px; }
.ev-sec .ev-fold { border: 0; margin-top: 4px; }
.ev-sec .ev-fold > summary { padding: 6px 0; min-height: 36px; font-size: 13px; color: var(--ev-teal); }
.ev-sec .ev-fold > summary:hover { background: none; text-decoration: underline; }
.ev-sec .ev-fold > summary .ev-fold-r { margin-left: 0; }
.ev-sec .ev-fold-b { padding: 0; }
.ev-warn { color: var(--ev-yellow-ink); }
.ev-hs-todo { background: #efeee9; color: var(--ev-mid); }
/* Quick note picker */
.ev-qn-list { display: flex; flex-direction: column; gap: 2px; margin: 8px 0 12px; max-height: 260px; overflow-y: auto; }
.ev-qn-opt { font: inherit; text-align: left; display: flex; justify-content: space-between; gap: 12px; align-items: baseline; background: none;
  border: 1px solid transparent; border-radius: 8px; padding: 8px 10px; cursor: pointer; color: var(--ev-ink); }
.ev-qn-opt span { font-size: 12.5px; color: var(--ev-muted); }
.ev-qn-opt:hover { background: var(--ev-hover); }
.ev-qn-opt[aria-selected="true"] { background: var(--ev-teal-soft); border-color: var(--ev-teal); }
.ev-drawer-head { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.ev-drawer-head h2 { font-size: 20px; font-weight: 600; line-height: 1.2; }
.ev-x { font-size: 24px; line-height: 1; background: none; border: 0; cursor: pointer; color: var(--ev-muted); width: 34px; height: 34px; border-radius: 8px; }
.ev-x:hover { background: var(--ev-teal-soft); color: var(--ev-ink); }
.ev-drawer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ev-drawer-grid label, .ev-wide { display: flex; flex-direction: column; gap: 4px; font-size: 12px; font-weight: 500; color: var(--ev-mid); }
.ev-wide { grid-column: 1 / -1; }
.ev-inline { display: inline-flex; gap: 6px; align-items: center; font-size: 12px; font-weight: 600; margin-top: 8px; }
.ev-sec { border-top: 1px solid var(--ev-line); margin-top: 18px; padding-top: 14px; }
.ev-sec h3 { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ev-muted); margin-bottom: 8px;
  display: flex; justify-content: space-between; align-items: center; }
.ev-dup { background: var(--ev-coral-soft); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 6px; margin: 10px 0; font-size: 12px; }
.ev-notes { list-style: none; display: flex; flex-direction: column; gap: 8px; margin-top: 10px; font-size: 13.5px; }
.ev-notes li { background: var(--ev-hover); border: 1px solid var(--ev-line); border-radius: 8px; padding: 8px 10px; white-space: pre-wrap; }

/* Modals */
.ev-modal-overlay { position: fixed; inset: 0; background: rgba(22,37,42,.35); z-index: 500; display: flex; align-items: center; justify-content: center; padding: 16px; }
.ev-modal { background: var(--ev-card); border-radius: 12px; width: min(640px, 100%); max-height: 90vh; overflow-y: auto; box-shadow: 0 20px 60px rgba(22,37,42,.25); }
.ev-modal-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--ev-line); }
.ev-modal-head h2 { font-size: 17px; font-weight: 600; }
.ev-modal-body { padding: 16px 20px; }
.ev-modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 20px; border-top: 1px solid var(--ev-line); }

/* ACEP surface polish: existing brand palette and Outfit remain authoritative. */
.ev { scrollbar-color: var(--ev-line-strong) var(--ev-bg); scrollbar-width: thin; }
.ev-card-head .ev-muted { margin-top: 3px; line-height: 1.45; }
.ev-btn-primary { box-shadow: 0 2px 4px rgba(18,83,80,.16); }
.ev-btn-primary:hover { border-color: var(--ev-teal-dk); }
.ev-btn:disabled { box-shadow: none; }
.ev-queues { border-radius: var(--ev-radius) var(--ev-radius) 0 0; padding: 12px; }
.ev-toolbar { padding: 12px; }
.ev-person .ev-av { background: var(--ev-teal-soft); color: var(--ev-teal-dk); border-color: transparent; }
.ev-table tr[data-ev-lead] td { transition: background-color .15s; }
.ev-grid-line { stroke-dasharray: 2 5; }
@media (prefers-reduced-motion: reduce) { .ev-table tr[data-ev-lead] td { transition: none; } }

@media (max-width: 1280px) {
  .ev-row1 { grid-template-columns: 1fr 1fr; }
  .ev-row1 > .ev-kpis { grid-column: 1 / -1; grid-template-columns: repeat(4, 1fr); }
  .ev-kpi { min-height: 130px; }
  .ev-lst { display: none; }
}
@media (max-width: 900px) {
  .ev-viewnav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 0 12px; }
  .ev-viewnav button { font: inherit; font-size: 13.5px; white-space: nowrap; border: 1px solid var(--ev-line); background: var(--ev-card);
    color: var(--ev-mid); border-radius: 999px; padding: 0 14px; min-height: 36px; cursor: pointer; }
  .ev-viewnav button.on { background: var(--ev-teal-soft); border-color: var(--ev-teal); color: var(--ev-teal-dk); font-weight: 600; }
  .ev-head kbd { display: none; }
  .ev-queues { flex-wrap: wrap; }
  .ev-queues-list { order: 2; flex: 1 1 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
    mask-image: linear-gradient(to right, #000 88%, transparent); }
  .ev-queues .ev-seg { margin-left: auto; }
  .ev-queues .ev-menu { position: static; }
  .ev-toolbar { flex-wrap: wrap; }
  .ev-toolbar .ev-search-wrap { flex: 1 1 100%; }
  .ev-toolbar select.ev-input { flex: 1 1 120px; max-width: none; }
  .ev-toolbar-sp { display: none; }
}
@media (max-width: 760px) {
  .ev-row1 { grid-template-columns: 1fr; }
  .ev-row1 > .ev-kpis { grid-template-columns: 1fr 1fr; }
}
/* Phone: the work view becomes one card per physician (name + status, next action, owner + note). */
@media (max-width: 700px) {
  /* Phone: the same Lead Hub table as desktop — checkbox + physician stay pinned, the rest swipes sideways. */
  .ev-list-work { min-width: 1060px; }
  .ev-table-wrap { position: relative; } /* keeps the absolutely-positioned .ev-sr label inside the scroller */
  .ev-list-work .ev-lst { display: table-cell; }
  .ev-list-work td { padding: 12px 10px; }
  .ev-list-work tr > :nth-child(1) { position: sticky; left: 0; z-index: 2; width: 36px; min-width: 36px; padding-left: 12px; }
  .ev-list-work tr > :nth-child(2) { position: sticky; left: 36px; z-index: 2; min-width: 150px; width: 150px; max-width: 150px;
    box-shadow: inset -1px 0 0 var(--ev-line); }
  .ev-list-work td:nth-child(-n+2) { background: var(--ev-card); }
  .ev-list-work tr[data-ev-lead]:hover td:nth-child(-n+2) { background: var(--ev-hover); }
  .ev-list-work tr.active td:nth-child(-n+2) { background: var(--ev-teal-soft); }
  .ev-list-work .ev-phys b, .ev-list-work .ev-phys > span:last-child { overflow-wrap: anywhere; }
  .ev-drawer-top .ev-dd-btn { padding: 6px 8px; font-size: 13px; }
  /* The drawer's own Reach out buttons move to a bar pinned at the bottom, within thumb reach. */
  .ev-sec-reach .ev-contact { display: none; }
  .ev-sec-reach:not(:has(.ev-outcome)) { display: none; }
  .ev-drawer-bar { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 8px; position: sticky; bottom: -40px; z-index: 5;
    margin: 20px -16px -40px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: var(--ev-card); border-top: 1px solid var(--ev-line); }
  .ev-drawer-bar .ev-btn { min-height: 44px; justify-content: center; padding: 0 10px; }
}
@media (max-width: 560px) {
  .ev-drawer-grid, .ev-handoff-grid { grid-template-columns: 1fr; }
  .ev-head { padding-top: 12px; }
  .ev-title { font-size: 22px; }
  .ev-drawer { padding: 16px 16px 40px; }
  .ev-drawer-head { top: -16px; margin: -16px -16px 14px; padding: 16px 16px 12px; }
  .ev-contact .ev-btn { min-height: 44px; }
}
/* On the ACEP page the sidebar follows the page's teal instead of LT's black. */
body[data-page="event"] .sb-page-btn.active { background: #e4f1ef; color: #125350; border-color: #e4f1ef; }
body[data-page="event"] .sb-page-btn.active .sb-page-icon svg { stroke: #125350; }
#sb-nav-event { flex: 0 0 auto; padding: 0 0 6px; }
#sb-nav-event .sb-item { padding: 7px 12px 7px 20px; border-radius: 6px; font-size: 13px; color: #44545a; }
#sb-nav-event .sb-item:hover { background: #f1f0eb; color: #16252a; }
#sb-nav-event .sb-item.active { background: none; color: #125350; font-weight: 600; }
#sb-nav-event .sb-item.active .sb-item-dot { background: #1a6965; }
#sb-nav-event .sb-item:focus { outline: none; }
#sb-nav-event .sb-item:focus-visible, body[data-page="event"] .sb-page-btn:focus-visible { outline: 2px solid #1a6965; outline-offset: -2px; }
body[data-page="event"] .sb-page-btn:focus:not(:focus-visible) { outline: none; }
.sb-page-btn .sb-item-n { font-weight: 500; }
.sb-item-n { margin-left: auto; font-size: 11.5px; color: #5f6d72; font-variant-numeric: tabular-nums; }
.sb-item-n.alert { color: #a1442e; font-weight: 600; }
.sb-nav + .sb-pages-label { margin-top: 14px; }

/* Export PDF = the browser's print → Save as PDF: a clean one-page report. */
@media print {
  body[data-page="event"] .sidebar, .ev-head-actions, .ev-filters, .ev-toolbar, .ev-queues, .ev-chips, .ev-viewnav, .ev-drawer-bar, .ev-acts, .ev-bulk, .ev-drawer, .ev-modal-overlay,
  .ev-dots, .ev-more-link, .ev-back, .ev-table th:first-child, .ev-table td:first-child, .ev-table th:last-child, .ev-table td:last-child { display: none !important; }
  body[data-page="event"] .main { margin: 0 !important; background: #fff !important; }
  .ev-card, .ev-kpi { box-shadow: none; break-inside: avoid; }
  .ev-row1 { grid-template-columns: 1fr 1fr 1fr; }
  .ev-kpi { min-height: 0; }
  .ev * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* Secondary workspaces: accessible native disclosure, closed on sign-in. */
.sb-internal { margin-top: 16px; }
.sb-internal[hidden] { display: none; }
.sb-group-toggle {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 36px; padding: 6px 8px; margin-bottom: 6px;
  color: var(--mid); font: 500 12px 'Outfit', sans-serif; cursor: pointer;
  list-style: none; border-radius: 8px;
}
.sb-group-toggle::-webkit-details-marker { display: none; }
.sb-group-toggle:hover { background: var(--s3); color: var(--text); }
.sb-group-toggle:focus-visible { outline: 2px solid #7cc4bd; outline-offset: 2px; }
.sb-group-toggle svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .15s; }
.sb-internal[open] > .sb-group-toggle svg { transform: rotate(90deg); }
@media (prefers-reduced-motion: reduce) { .sb-group-toggle svg { transition: none; } }

/* Navigation swaps the complete surface, rather than animating its parts twice. */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 180ms; animation-timing-function: ease-out; }
#page-navigation-status { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 10000; padding: 10px 16px; border-radius: 10px; background: #171717; color: #fff; font: 400 13px 'Outfit', sans-serif; box-shadow: 0 4px 16px #0002; }
#page-navigation-status[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { ::view-transition-old(root), ::view-transition-new(root) { animation: none; } }

/* ————————————————————————————
   MOBILE (≤900px) — the desktop sidebar becomes a slide-in drawer behind a
   sticky menu bar, so every nav item, sub-tab and Sign Out stays reachable.
   Desktop is untouched: .m-bar and .m-scrim only render below 900px.
———————————————————————————— */
.m-bar, .m-scrim { display: none; }
@media (max-width: 900px) {
  html { scroll-padding-top: 64px; }
  .m-bar {
    display: flex; align-items: center; gap: 6px;
    position: sticky; top: 0; z-index: 150;
    height: calc(52px + env(safe-area-inset-top)); padding: env(safe-area-inset-top) 12px 0 4px;
    background: rgba(255,255,255,.94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
  }
  .m-menu-btn {
    width: 44px; height: 44px; display: grid; place-items: center;
    border: 0; background: none; color: var(--text); border-radius: 10px; cursor: pointer;
  }
  .m-menu-btn:active { background: var(--s3); }
  .m-menu-btn:focus-visible { outline: 2px solid var(--text); outline-offset: -2px; }
  .m-menu-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
  .m-bar-title { font-size: 15px; font-weight: 700; letter-spacing: -.01em; color: var(--text); }

  /* month tabs sit under the bar and scroll sideways instead of wrapping to 2 rows */
  .topbar { top: calc(52px + env(safe-area-inset-top)); z-index: 140; flex-wrap: nowrap; padding: 6px 12px; min-height: 0; }
  .tabs { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab, .tab-add { flex-shrink: 0; min-height: 36px; display: inline-flex; align-items: center; }

  .sidebar {
    width: min(300px, 86vw); height: 100dvh; z-index: 300;
    padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom);
    overflow-y: auto; overscroll-behavior: contain;
    transform: translateX(-100%); visibility: hidden;
    transition: transform .28s var(--ease), visibility 0s linear .28s;
  }
  body.nav-open .sidebar {
    transform: none; visibility: visible;
    transition: transform .28s var(--ease), visibility 0s;
    box-shadow: 8px 0 32px rgba(0,0,0,.14);
  }
  .m-scrim { display: block; position: fixed; inset: 0; z-index: 290; background: rgba(0,0,0,.32); }
  .m-scrim[hidden] { display: none; }
  body.nav-open { overflow: hidden; }

  /* thumb-sized targets inside the drawer */
  .sb-page-btn, .sb-item, .sb-group-toggle { min-height: 44px; }
  .sb-item { display: flex; align-items: center; }
  .sb-logout-btn { min-height: 40px; padding-left: 14px; padding-right: 14px; }

  /* wide ledgers swipe sideways instead of crushing columns to "Chris J…" */
  .ml-table-wrap, #mkt-demand-table, #mkt-table-area { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .ml-table-wrap > .ml-table, #mkt-demand-table > .ml-table, #mkt-table-area > .ml-table { min-width: 640px; }
  .ml-table-wrap > .ml-table-masterlist { min-width: 900px; }
}
@media (max-width: 900px) and (prefers-reduced-motion: reduce) {
  .sidebar, body.nav-open .sidebar { transition: none; }
}

/* Phone: the Lead Hub controls in 4 tight rows instead of 8 —
   [queues ⟷ | Mine/Team] · [search | More] · [who | status | specialty] · [view | count | Export]. */
@media (max-width: 700px) {
  .ev-hub .ev-queues { flex-wrap: nowrap; gap: 8px; padding: 8px 10px; }
  .ev-hub .ev-queues-list { order: 0; flex: 1 1 auto; min-width: 0; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none;
    mask-image: linear-gradient(to right, #000 calc(100% - 24px), transparent); padding-right: 16px; }
  .ev-hub .ev-queues-list::-webkit-scrollbar { display: none; }
  .ev-hub .ev-queues .ev-seg { order: 1; margin-left: 0; }
  .ev-hub .ev-q { min-height: 34px; padding: 0 10px; gap: 5px; font-size: 13px; flex-shrink: 0; }
  .ev-hub .ev-seg { padding: 2px; }
  .ev-hub .ev-seg button { min-height: 32px; padding: 0 10px; font-size: 13px; }

  .ev-hub .ev-toolbar { gap: 6px; padding: 8px 10px; }
  .ev-hub .ev-toolbar .ev-search-wrap { order: 1; flex: 1 1 calc(100% - 96px); min-width: 0; max-width: none; }
  .ev-hub .ev-toolbar .ev-input { min-height: 36px; padding-top: 6px; padding-bottom: 6px; font-size: 14px; }
  .ev-hub .ev-toolbar > .ev-btn { order: 2; flex: 0 0 auto; min-height: 36px; padding: 0 11px; }
  .ev-hub .ev-toolbar select.ev-input { order: 3; flex: 1 1 calc((100% - 12px) / 3); min-width: 0; max-width: none; padding-left: 8px; padding-right: 28px; background-position: right 10px center; font-size: 13px;
    text-overflow: ellipsis; }
  .ev-hub .ev-toolbar .ev-seg { order: 4; }
  .ev-hub .ev-toolbar .ev-count { order: 5; flex: 1 1 auto; text-align: right; font-size: 12.5px; white-space: nowrap; }
  .ev-hub .ev-toolbar .ev-menu { order: 6; }
  .ev-hub .ev-toolbar .ev-menu > .ev-btn { min-height: 36px; padding: 0 10px; }
  .ev-hub .ev-chips { padding-top: 6px; padding-bottom: 6px; }
}

/* Sign-in: the username iPhone Passwords needs is present but not shown. */
.login-user { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; border: 0; padding: 0; }

/* ————————————————————————————
   BOOTH (Oct 2 meeting plan) — newest-first booth list on phones, one-tap notes,
   Form / Manual tags, who noted first, photos, Faces, Debrief, quick Add lead.
———————————————————————————— */
.ev-ava { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; object-fit: cover;
  background: var(--ev-teal-soft); color: var(--ev-teal-dk); font-size: 13px; font-weight: 600; letter-spacing: .02em; }
.ev-ava-md { width: 48px; height: 48px; font-size: 15px; }
.ev-ava-lg { width: 52px; height: 52px; font-size: 16px; }
.ev-ava-xl { width: 96px; height: 96px; font-size: 26px; }
.ev-via { display: inline-block; font-size: 11px; font-weight: 600; line-height: 1; padding: 3px 6px; border-radius: 5px; vertical-align: 1px;
  background: var(--ev-sunken); color: var(--ev-mid); border: 1px solid var(--ev-line); white-space: nowrap; }
.ev-via-form { background: var(--ev-teal-soft); color: var(--ev-teal-dk); border-color: transparent; }
.ev-via-manual { background: var(--ev-yellow-soft); color: var(--ev-yellow-ink); border-color: transparent; }
.ev-via-blinq { background: var(--ev-blue-soft); color: var(--ev-blue-ink); border-color: transparent; }
.ev-firstnote { display: block; margin-top: 3px; font-size: 12px; color: var(--ev-muted); white-space: nowrap; }
.ev-firstnote b, .ev-brow-tags b, .ev-head-tags b, .ev-face small b { color: var(--ev-mid); font-weight: 600; }

/* Booth list: phones only (the table stays on computers). */
.ev-booth-bar, .ev-booth { display: none; }
.ev-booth-live { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ev-muted); margin-right: auto; min-width: 0; }
.ev-booth-live i { width: 8px; height: 8px; border-radius: 50%; background: var(--ev-line-strong); flex: none; }
.ev-booth-live.on i { background: var(--ev-green); box-shadow: 0 0 0 3px rgba(46,125,79,.15); }
.ev-brow { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px;
  border-top: 1px solid var(--ev-line); cursor: pointer; -webkit-tap-highlight-color: transparent; }
.ev-brow:first-child { border-top: 0; }
.ev-brow:active, .ev-brow.active { background: var(--ev-teal-soft); }
.ev-brow.is-new { background: #fbfaf2; }
.ev-brow:focus-visible { outline: 2px solid var(--ev-teal); outline-offset: -2px; }
.ev-brow-main { min-width: 0; display: grid; gap: 1px; }
.ev-brow-main > b { font-size: 16.5px; font-weight: 600; letter-spacing: -.01em; color: var(--ev-ink); overflow-wrap: anywhere; }
.ev-brow-main > span { font-size: 13px; color: var(--ev-mid); }
.ev-brow-main .ev-brow-tags { font-size: 12px; color: var(--ev-muted); margin-top: 3px; line-height: 1.5; }
.ev-brow-note { font: inherit; font-weight: 600; font-size: 14px; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px;
  border: 0; border-radius: 12px; background: var(--ev-teal); color: #fff; cursor: pointer; }
.ev-brow-note svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.ev-brow-note:active { background: var(--ev-teal-dk); }
.ev-brow-note:focus-visible { outline: 2px solid var(--ev-teal-dk); outline-offset: 2px; }

/* Lead panel: photo + tags in the head, notes right under the name, then the details. */
.ev-drawer-head > div { flex: 1; min-width: 0; }
.ev-drawer-head .ev-ava { align-self: flex-start; }
.ev-head-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin-top: 6px; font-size: 12.5px; color: var(--ev-muted); }
.ev-head-tags a { color: var(--ev-teal-dk); font-weight: 500; }
.ev-note-top { margin-top: 0; }
.ev-note-top h3 .ev-muted { font-weight: 500; margin-left: 4px; }
.ev-note-by { font-size: 12px; color: var(--ev-muted); margin-bottom: 2px; }
.ev-note-by b { color: var(--ev-ink); font-weight: 600; }
.ev-note-for { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ev-muted); }
.ev-note-for select { width: auto; min-height: 32px; padding: 4px 32px 4px 10px; background-position: right 12px center; font-size: 12.5px; max-width: 170px; }
.ev-composer-foot { flex-wrap: wrap; }
.ev-composer-foot .ev-note-state { margin-right: auto; }
.ev-details-h { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ev-muted); margin: 22px 0 10px;
  padding-top: 14px; border-top: 1px solid var(--ev-line); }
.ev-photo-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ev-photo-btn { cursor: pointer; }
.ev-formlink { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; padding: 10px 12px; border-radius: 10px;
  background: var(--ev-yellow-soft); color: var(--ev-yellow-ink); font-size: 13px; font-weight: 500; }
.ev-formlink span { margin-right: auto; }

/* Quick Add lead: tap choices for degree, specialty and training level. */
.ev-chipset { display: flex; flex-wrap: wrap; gap: 6px; }
.ev-chip { position: relative; }
.ev-chip input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.ev-chip span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--ev-line-strong); border-radius: 10px;
  font-size: 14px; color: var(--ev-mid); background: var(--ev-card); }
.ev-chip input:checked + span { border-color: var(--ev-teal); background: var(--ev-teal-soft); color: var(--ev-teal-dk); font-weight: 600; }
.ev-chip input:focus-visible + span { outline: 2px solid var(--ev-teal); outline-offset: 2px; }
.ev-add-more { border-top: 1px solid var(--ev-line); padding-top: 10px; }
.ev-add-more summary { cursor: pointer; font-size: 13.5px; font-weight: 600; color: var(--ev-mid); padding: 4px 0; }
.ev-add-more > .ev-drawer-grid { margin-top: 10px; }

/* Faces + Debrief */
.ev-daychips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 0 14px; padding-bottom: 2px; }
.ev-daychips .ev-q { flex-shrink: 0; }
.ev-faces { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; }
.ev-face { display: grid; justify-items: center; align-content: start; gap: 4px; text-align: center; padding: 18px 14px 16px;
  background: var(--ev-card); border: 1px solid var(--ev-line); border-radius: var(--ev-radius); cursor: pointer; }
.ev-face:hover { border-color: var(--ev-line-strong); }
.ev-face:focus-visible { outline: 2px solid var(--ev-teal); outline-offset: 2px; }
.ev-face .ev-ava { margin-bottom: 8px; }
.ev-face b { font-size: 16px; font-weight: 600; color: var(--ev-ink); overflow-wrap: anywhere; }
.ev-face > span { font-size: 13px; color: var(--ev-mid); }
.ev-face q { font-size: 12.5px; color: var(--ev-muted); margin-top: 6px; line-height: 1.45; }
.ev-face small { font-size: 12px; color: var(--ev-muted); margin-top: 4px; }
.ev-page-h2 { font-size: 16px; font-weight: 600; margin: 22px 0 2px; }

@media (max-width: 700px) {
  /* The list comes first on a phone; the overview cards and charts follow it. */
  #ev-main:has(> .ev-hub) { display: flex; flex-direction: column; }
  #ev-main > .ev-hub { order: -1; }
  #ev-main > .ev-row1 { margin-top: 14px; }
  .ev-jump-leads { display: none !important; }
  .ev-booth-bar { display: flex; align-items: center; gap: 8px; padding: 10px 10px 8px; border-bottom: 1px solid var(--ev-line); }
  .ev-booth-bar .ev-btn { min-height: 40px; padding: 0 12px; flex: none; }
  /* Filters folded away until asked for: search stays, everything else behind the Filters button. */
  .ev-hub:not(.filters-open) .ev-queues,
  .ev-hub:not(.filters-open) .ev-toolbar > :not(.ev-search-wrap),
  .ev-hub:not(.filters-open) .ev-filters { display: none !important; }
  .ev-hub:not(.filters-open) .ev-toolbar .ev-search-wrap { flex: 1 1 100%; }
  .ev-hub.filters-open [data-ev-act="phone-filters"] { background: var(--ev-teal-soft); border-color: var(--ev-teal); color: var(--ev-teal-dk); }
  /* "Our tracking" on a phone = the booth list; "Form answers" keeps the swipeable table. */
  .ev-hub.is-work .ev-table-wrap { display: none; }
  .ev-hub.is-work .ev-booth { display: block; }
  .ev-hub.is-work .ev-bulk { display: none !important; }
  /* Each row has its own Note button, and Add lead (with its ⋯ options) sits right above the list. */
  .ev-head-actions [data-ev-act="quick-note"], .ev-head-actions > .ev-menu { display: none; }
  .ev-booth-bar .ev-btn-icon { width: 40px; padding: 0; justify-content: center; font-size: 18px; letter-spacing: 1px; }
  .ev-booth-bar .ev-menu-pop { right: 0; left: auto; }
  .ev-drawer-head .ev-ava-lg { width: 44px; height: 44px; font-size: 14px; }
  .ev-note-top .ev-composer textarea { min-height: 96px; font-size: 16px; }
  .ev-note-top [data-ev-dact="add-note"] { min-height: 44px; padding: 0 18px; }
  .ev-faces { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .ev-ava-xl { width: 76px; height: 76px; font-size: 22px; }
  .ev-add-quick .ev-input { font-size: 16px; } /* no iOS zoom on focus */
}
@media (prefers-reduced-motion: reduce) { .ev-brow { transition: none; } }

