@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@500;600;700&family=Source+Sans+3:wght@400;500;600;700&display=swap');
:root {
  --bg: #eef1f6;
  --surface: #ffffff;
  --surface-2: #f8fafc;
  --ink: #0f172a;
  --ink-soft: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --brand: #0a1628;
  --brand-2: #152238;
  --gold: #c9a227;
  --gold-soft: #fef9e7;
  --accent: #1e40af;
  --accent-soft: #eff6ff;
  --ok: #047857;
  --ok-bg: #ecfdf5;
  --warn: #b45309;
  --warn-bg: #fffbeb;
  --danger: #b91c1c;
  --danger-bg: #fef2f2;
  --info: #1d4ed8;
  --info-bg: #eff6ff;
  --wa: #0f766e;
  --wa-bg: #f0fdfa;
  --sms: #4338ca;
  --sms-bg: #eef2ff;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --radius: 10px;
  --sidebar: 236px;
  --topbar: 60px;
  --ribbon-h: 34px;
  --font: 'Source Sans 3', 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;
  --display: 'Plus Jakarta Sans', 'Source Sans 3', sans-serif;
  --fs-xs: 14px;
  --fs-sm: 15px;
  --fs-base: 17px;
  --fs-md: 18px;
  --fs-lg: 20px;
  --fs-xl: 24px;
  --fs-2xl: 30px;
}
*, *::before, *::after { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  max-width: 100%;
  height: 100%;
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-base);
  line-height: 1.5;
  color: var(--ink);
  background: var(--bg);
  min-height: 100%;
  min-height: 100dvh;
  max-width: 100%;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
ul { margin: 0; padding: 0; list-style: none; }
table { border-collapse: collapse; }
.demo-ribbon {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--ribbon-h);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand-2) 100%);
  color: #cbd5e1;
  font-size: var(--fs-sm);
  padding: 0 12px;
  font-weight: 500;
  border-bottom: 2px solid var(--gold);
  flex-shrink: 0;
}
.demo-ribbon span { color: #fcd34d; font-weight: 600; }
.login-page {
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  max-width: 100%;
  overflow: hidden;
}
.login-visual {
  position: relative;
  overflow: hidden;
  background: var(--brand);
  color: #fff;
  padding: 40px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-width: 0;
}
.login-visual::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(29,78,216,.18), transparent 50%);
  pointer-events: none;
}
.login-visual > * { position: relative; z-index: 1; }
.login-brand img {
  height: 44px;
  width: auto;
  filter: brightness(0) invert(1);
}
.login-quote {
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.25;
  max-width: 16ch;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.login-quote em {
  font-style: normal;
  color: #93c5fd;
}
.login-meta { color: #94a3b8; font-size: var(--fs-sm); }
.login-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--bg);
  min-width: 0;
}
.login-card {
  width: min(400px, 100%);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 32px 28px;
  box-shadow: var(--shadow-md);
}
.login-card h1 {
  font-size: var(--fs-xl);
  font-weight: 650;
  margin: 0 0 4px;
  letter-spacing: -0.02em;
}
.login-card p.lead {
  margin: 0 0 24px;
  color: var(--muted);
  font-size: var(--fs-base);
}
.field { margin-bottom: 14px; min-width: 0; }
.field label {
  display: block;
  font-size: var(--fs-base);
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink-soft);
}
.field input, .field select, .field textarea,
.input, .select, .textarea {
  width: 100%;
  max-width: 100%;
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: 8px;
  padding: 11px 13px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus,
.input:focus, .select:focus, .textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.12);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 11px 14px;
  font-weight: 600;
  font-size: var(--fs-base);
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s, border-color .15s, color .15s;
}
.btn:active { transform: none; opacity: .92; }
.btn-primary {
  background: var(--brand);
  color: #fff;
}
.btn-primary:hover { background: var(--brand-2); }
.btn-accent {
  background: var(--accent);
  color: #fff;
}
.btn-ghost {
  background: #fff;
  border-color: var(--line-strong);
  color: var(--ink-soft);
}
.btn-ghost:hover { background: var(--surface-2); }
.btn-soft {
  background: var(--accent-soft);
  color: var(--accent);
}
.btn-danger {
  background: var(--danger);
  color: #fff;
  border-color: var(--danger);
}
.btn-danger:hover { background: #991b1b; }
.btn-danger-soft {
  background: var(--danger-bg);
  color: var(--danger);
}
.btn:disabled, .btn[disabled] {
  opacity: .45;
  cursor: not-allowed;
  pointer-events: none;
}
.btn-sm { padding: 8px 12px; font-size: var(--fs-sm); }
.login-hint {
  margin-top: 16px;
  padding: 11px 13px;
  background: var(--info-bg);
  border: 1px solid #dbeafe;
  border-radius: 8px;
  font-size: var(--fs-base);
  color: var(--info);
}
.login-foot {
  margin-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: var(--fs-sm);
  color: var(--muted);
}
.login-foot-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.login-foot-copy small {
  font-size: var(--fs-xs);
  color: var(--muted);
}
.login-foot img { height: 20px; width: auto; opacity: .9; }
.app-shell {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  max-width: 100%;
}
.app-body {
  display: flex;
  flex: 1 1 auto;
  min-width: 0;
  min-height: calc(100dvh - var(--ribbon-h));
  max-width: 100%;
  align-items: stretch;
  width: 100%;
}
.sidebar {
  width: var(--sidebar);
  flex: 0 0 var(--sidebar);
  background: linear-gradient(180deg, var(--brand) 0%, #0d1f35 100%);
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: sticky;
  top: var(--ribbon-h);
  align-self: stretch;
  min-height: calc(100dvh - var(--ribbon-h));
  height: auto;
  z-index: 40;
  overflow: hidden;
}
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  min-width: 0;
  flex-shrink: 0;
}
.sidebar-brand img {
  height: 28px;
  width: auto;
  flex-shrink: 0;
  filter: brightness(0) invert(1);
}
.sidebar-brand > div { min-width: 0; }
.sidebar-brand strong {
  display: block;
  font-size: var(--fs-base);
  font-weight: 700;
  font-family: var(--display);
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-brand small {
  color: #94a3b8;
  font-size: var(--fs-xs);
}
.nav {
  padding: 6px 6px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1 1 0;
  overflow-x: hidden;
  overflow-y: auto;
  min-height: 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.15) transparent;
}
.nav::-webkit-scrollbar { width: 4px; }
.nav::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,.12);
  border-radius: 4px;
}
.nav-label {
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  padding: 10px 10px 4px;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.nav a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px 7px 7px;
  border-left: 3px solid transparent;
  border-radius: 0 6px 6px 0;
  color: #94a3b8;
  font-weight: 500;
  font-size: var(--fs-sm);
  min-width: 0;
  line-height: 1.3;
}
.nav a:hover {
  background: rgba(255,255,255,.05);
  color: #e2e8f0;
}
.nav a.active {
  background: rgba(255,255,255,.1);
  color: #fff;
  border-left-color: var(--gold);
}
.nav a .ico {
  width: 18px;
  flex-shrink: 0;
  font-size: var(--fs-xs);
  font-weight: 700;
  opacity: .7;
  text-align: center;
}
.nav a.active .ico { opacity: 1; color: #fcd34d; }
.nav a span:nth-child(2) {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.nav a .badge {
  margin-left: auto;
  flex-shrink: 0;
  background: #1e293b;
  color: #e2e8f0;
  font-size: var(--fs-xs);
  font-weight: 650;
  border-radius: 999px;
  padding: 1px 7px;
  border: 1px solid rgba(255,255,255,.1);
}
.sidebar-user {
  padding: 10px 12px;
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex-shrink: 0;
}
.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #334155;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 650;
  font-size: var(--fs-sm);
  flex-shrink: 0;
}
.sidebar-user strong {
  display: block;
  color: #fff;
  font-size: var(--fs-sm);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.sidebar-user small { color: #94a3b8; font-size: var(--fs-xs); }
.sidebar-user > div:last-child { min-width: 0; }
.main {
  flex: 1 1 auto;
  min-width: 0;
  max-width: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  min-height: calc(100dvh - var(--ribbon-h));
  background: var(--bg);
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 24px;
  min-height: var(--topbar);
  background: #fff;
  border-bottom: 1px solid var(--line);
  border-top: 3px solid var(--gold);
  position: sticky;
  top: var(--ribbon-h);
  z-index: 30;
  min-width: 0;
  flex-shrink: 0;
  box-sizing: border-box;
}
.topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  flex: 1;
}
.menu-btn {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--line-strong);
  background: #fff;
  cursor: pointer;
  flex-shrink: 0;
}
.page-title {
  font-size: var(--fs-lg);
  font-weight: 700;
  font-family: var(--display);
  margin: 0;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.search {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 10px;
  width: 220px;
  max-width: 28vw;
}
.search input {
  border: 0;
  background: transparent;
  outline: none;
  width: 100%;
  min-width: 0;
  font-size: var(--fs-base);
}
.content {
  padding: 20px 24px 32px;
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  box-sizing: border-box;
}
@media (min-width: 1280px) {
  .content {
    padding-left: max(24px, calc((100% - 1120px) / 2));
    padding-right: max(24px, calc((100% - 1120px) / 2));
  }
}
.app-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: var(--fs-sm);
  color: var(--muted);
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
  flex-shrink: 0;
  margin-top: auto;
}
@media (min-width: 1280px) {
  .app-footer {
    padding-left: max(24px, calc((100% - 1120px) / 2));
    padding-right: max(24px, calc((100% - 1120px) / 2));
  }
}
.app-footer-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.app-footer-copy small {
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.35;
  max-width: 420px;
}
.app-footer img { height: 18px; width: auto; }
.app-footer a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--ink-soft);
  min-width: 0;
}
.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .4);
  z-index: 35;
}
.overlay.show { display: block; }
.grid { display: grid; gap: 12px; min-width: 0; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.span-2 { grid-column: span 2; }
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, .9fr);
  gap: 12px;
  min-width: 0;
  align-items: start;
}
.office-form .form-grid-office {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 4px;
}
.office-form .field {
  margin-bottom: 10px;
}
.office-dup-hint {
  margin: 0 0 10px;
}
.office-lead-check {
  margin: 4px 0 10px;
}
.office-form-actions {
  display: flex;
  margin-top: 4px;
}
.office-form-actions .btn {
  flex: 1;
}
@media (max-width: 560px) {
  .office-form .form-grid-office {
    grid-template-columns: minmax(0, 1fr);
  }
}
.split-dashboard {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, .9fr);
  gap: 12px;
  min-width: 0;
  align-items: start;
}
.panel-scroll {
  max-height: 420px;
  overflow-y: auto;
  overflow-x: hidden;
}
.agenda-page .panel-scroll {
  max-height: 480px;
}
.form-page-wrap {
  width: min(960px, 100%);
  margin: 0;
  flex: 0 0 auto;
  align-self: stretch;
}
.form-panel {
  width: 100%;
  max-width: 100%;
}
.form-page .content {
  padding: 16px 20px 28px;
  display: block;
  max-width: none;
}
.form-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.form-col-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.form-side-card {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
}
.form-side-title {
  margin: 0 0 10px;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--ink-soft);
}
.form-grid-core {
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}
.form-grid-extra {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.form-grid-followup {
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 8px;
}
.form-page .compact-form .input,
.form-page .compact-form .select {
  max-width: 100%;
}
.form-page .input-phone {
  max-width: 100%;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  padding: 10px 11px;
}
.form-grid-tight {
  gap: 10px;
}
@media (min-width: 900px) {
  .form-page-wrap {
    width: min(980px, 100%);
  }
  .form-layout {
    grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.9fr);
    gap: 22px;
  }
  .form-grid-core {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.95fr);
  }
  .form-page .form-grid-tight {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .form-page .form-grid-followup {
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  }
  .form-actions {
    display: grid;
    grid-template-columns: 1.2fr 1fr auto;
    gap: 8px;
  }
  .form-actions .btn {
    flex: none;
    width: 100%;
    padding: 11px 12px;
    font-size: var(--fs-sm);
  }
}
.field-hint {
  display: block;
  margin-top: 4px;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.3;
}
.dup-phone-warn {
  margin-top: 8px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  display: none;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}
.dup-phone-warn:not([hidden]) {
  display: flex;
}
.dup-phone-warn strong {
  color: #b45309;
  font-size: var(--fs-sm);
}
.dup-phone-warn > span {
  font-size: var(--fs-xs);
  color: var(--ink-soft);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.field.has-dup .input-phone {
  border-color: #f59e0b;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.15);
}
.field-error {
  display: block;
  margin-top: 4px;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--danger);
  line-height: 1.3;
}
.field.has-error .input,
.field.has-error .select,
.field.has-error .chip-pick {
  border-color: var(--danger);
  box-shadow: 0 0 0 2px rgba(185, 28, 28, 0.12);
}
.reason-box.has-error,
.field.has-error .chip-pick {
  outline: 2px solid rgba(185, 28, 28, 0.25);
  border-radius: 8px;
}
.reason-title {
  font-size: 13px;
  display: block;
  margin-bottom: 4px;
}
.details-followup > summary {
  font-weight: 600;
  color: var(--ink-soft);
}
.quick-row-compact {
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}
.save-success-modal {
  text-align: center;
  max-width: 360px;
}
.save-success-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: var(--ok-bg);
  color: var(--ok);
  font-size: 28px;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid #a7f3d0;
}
.save-success-icon--warn {
  background: #fffbeb;
  color: #b45309;
  border-color: #fde68a;
}
.save-success-summary {
  display: grid;
  gap: 8px;
  text-align: left;
  margin: 14px 0 4px;
  padding: 12px;
  background: var(--surface-2);
  border-radius: 8px;
  font-size: var(--fs-sm);
}
.save-success-summary .lbl {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.save-success-actions {
  flex-direction: column;
  width: 100%;
}
.save-success-actions .btn {
  width: 100%;
}
.form-page .fab { display: none; }
.form-grid-tight {
  gap: 10px;
}
.form-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
  margin-top: 14px;
}
.form-actions .btn {
  flex: 1 1 0;
  min-width: 0;
  padding: 10px 6px;
  font-size: var(--fs-xs);
  white-space: nowrap;
}
.form-actions .btn-wa {
  flex: 1.1 1 0;
}
.form-kvkk {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-top: 10px;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.4;
}
.field-followup { margin-top: 4px; }
input[type="datetime-local"],
input[type="date"],
input[type="time"] {
  min-width: 0;
  max-width: 100%;
}
.seg-compact label {
  padding: 7px 4px;
  font-size: var(--fs-xs);
}
.chip-pick--projects button {
  flex: 0 1 auto;
  max-width: 100%;
}
.dash-stats {
  margin-bottom: 14px;
}
.dash-hot {
  margin-top: 14px;
}
.panel-b-compact {
  padding: 8px 14px 12px;
}
.dash-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  border-radius: 6px;
  transition: background .1s;
}
.dash-row:last-child { border-bottom: 0; }
.dash-row:hover { background: var(--surface-2); }
.dash-row.done { opacity: .55; }
.dash-row-time {
  min-width: 44px;
  font-weight: 700;
  font-size: var(--fs-sm);
  color: var(--accent);
  flex-shrink: 0;
}
.dash-row-body {
  flex: 1;
  min-width: 0;
}
.dash-row-body strong {
  display: block;
  font-size: var(--fs-sm);
  font-weight: 650;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-row-body small {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.dash-empty {
  margin: 8px 0;
  font-size: var(--fs-sm);
  color: var(--muted);
  text-align: center;
}
.remind-compact {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
  margin-bottom: 14px;
  font-size: var(--fs-sm);
  position: relative;
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.remind-compact--alert {
  background: #fffbeb;
  border-color: #fde68a;
  border-left: 4px solid #f59e0b;
  padding-left: 12px;
  animation: remindGlow 2.2s ease-in-out infinite;
}
.remind-compact--alert::before {
  content: '';
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #f59e0b;
  flex-shrink: 0;
  animation: remindBeacon 1.15s ease-in-out infinite;
}
.remind-compact--alert strong {
  animation: remindLabel 2.2s ease-in-out infinite;
}
.remind-compact--alert .remind-compact-count {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  background: #fef3c7;
  border: 1px solid #fcd34d;
  color: #b45309;
  animation: remindLabel 2.2s ease-in-out infinite;
}
.remind-compact--idle {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: var(--ink-soft);
}
.remind-compact strong {
  color: #b45309;
  flex-shrink: 0;
}
.remind-compact--idle strong { color: var(--ok); }
.remind-compact-text {
  font-weight: 600;
  color: var(--ink-soft);
  flex: 1;
  min-width: 120px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.remind-compact-count {
  font-weight: 700;
  color: var(--accent);
  flex-shrink: 0;
}
.remind-compact .spacer { flex: 1; min-width: 8px; }
@media (prefers-reduced-motion: reduce) {
  .remind-compact--alert,
  .remind-compact--alert::before,
  .remind-compact--alert strong,
  .remind-compact--alert .remind-compact-count,
  .remind-hero--alert,
  .remind-hero--alert .remind-hero-pulse,
  .remind-hero--alert .remind-hero-countdown {
    animation: none !important;
  }
  .remind-compact--alert::before { opacity: 1; }
}
.stat {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 18px;
  min-width: 0;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transition: border-color .15s, box-shadow .15s;
}
.stat:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}
.stat-accent {
  border-left: 4px solid var(--gold);
}
.stat::after { display: none; }
.stat .label {
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 600;
}
.stat .value {
  font-size: var(--fs-2xl);
  font-weight: 700;
  margin: 4px 0 2px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.stat .delta {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--muted);
}
.stat .delta.up { color: var(--ok); }
.stat .delta.down { color: var(--danger); }
.panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  min-width: 0;
  max-width: 100%;
  box-shadow: var(--shadow);
}
.panel-h {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
  background: #fff;
  min-width: 0;
}
.panel-h h2, .panel-h h3 {
  margin: 0;
  font-size: var(--fs-sm);
  font-weight: 700;
  font-family: var(--display);
  letter-spacing: -0.01em;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.panel-b { padding: 14px; min-width: 0; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  border-radius: 4px;
  font-size: var(--fs-sm);
  font-weight: 600;
  background: var(--surface-2);
  color: var(--ink-soft);
  border: 1px solid var(--line);
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}
.chip-accent { background: var(--accent-soft); color: var(--accent); border-color: #dbeafe; }
.chip-ok { background: var(--ok-bg); color: var(--ok); border-color: #a7f3d0; }
.chip-warn { background: var(--warn-bg); color: var(--warn); border-color: #fde68a; }
.chip-danger { background: var(--danger-bg); color: var(--danger); border-color: #fecaca; }
.chip-info { background: var(--info-bg); color: var(--info); border-color: #bfdbfe; }
.chip-brand { background: #f1f5f9; color: #334155; border-color: #e2e8f0; }
.table-wrap {
  overflow-x: auto;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}
table.data {
  width: 100%;
  min-width: 520px;
  font-size: var(--fs-base);
}
table.data th {
  text-align: left;
  font-size: var(--fs-sm);
  font-weight: 650;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--muted);
  padding: 11px 13px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  white-space: nowrap;
}
table.data td {
  padding: 11px 13px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
table.data tr:last-child td { border-bottom: 0; }
table.data tr:hover td { background: #fafafa; }
table.data tr { cursor: pointer; }
.person {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}
.person .avatar { width: 34px; height: 34px; font-size: var(--fs-xs); }
.person > div { min-width: 0; }
.person strong {
  display: block;
  font-size: var(--fs-base);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 220px;
}
.person small {
  color: var(--muted);
  font-size: var(--fs-sm);
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.panel-count {
  color: var(--muted);
  font-weight: 500;
  font-size: var(--fs-sm);
}
.person-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
}
.person-link:hover strong { color: var(--accent); }
.customer-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: flex-end;
}
.customer-cards {
  display: none;
  flex-direction: column;
  gap: 10px;
  padding: 10px 14px 0;
}
.customer-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  background: #fff;
}
.customer-card-head {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: inherit;
  text-decoration: none;
  margin-bottom: 8px;
}
.customer-card-body {
  flex: 1;
  min-width: 0;
}
.customer-card-body strong {
  display: block;
  font-size: var(--fs-base);
}
.customer-card-body > span {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  margin-top: 2px;
}
.customer-card-meta {
  margin-top: 4px !important;
  line-height: 1.35;
}
.customer-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
}
.customer-profile-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}
.customer-profile-avatar {
  width: 52px;
  height: 52px;
  font-size: var(--fs-base);
}
.customer-profile-info {
  flex: 1;
  min-width: 0;
}
.customer-profile-name {
  margin: 0 0 4px;
  font-size: var(--fs-xl);
  font-weight: 700;
}
.customer-profile-info p {
  margin: 0;
  font-size: var(--fs-sm);
  color: var(--muted);
}
.customer-profile-note {
  margin-top: 6px !important;
  color: var(--ink-soft) !important;
  line-height: 1.4;
}
.customer-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}
.customer-kpi {
  padding: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-width: 0;
}
.customer-kpi .lbl {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}
.customer-kpi strong {
  display: block;
  font-size: var(--fs-sm);
  line-height: 1.3;
}
.customer-kpi .sub {
  display: block;
  margin-top: 4px;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.35;
}
.pane-title {
  margin: 0 0 10px;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--ink-soft);
}
.pane-hint {
  margin: 0 0 12px;
  font-size: var(--fs-sm);
  color: var(--muted);
}
.tl-head {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 2px;
}
.tl-body p {
  margin: 2px 0 0;
}
.tl-item[data-agenda] {
  cursor: pointer;
  border-radius: 8px;
  padding: 4px;
  margin: -4px;
}
.tl-item[data-agenda]:hover {
  background: var(--surface-2);
}
.list-row[role="button"] {
  cursor: pointer;
}
.list-row[role="button"]:hover {
  background: var(--surface-2);
}
@media (max-width: 900px) {
  .customer-summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  .customer-table-wrap { display: none; }
  .customer-cards { display: flex; }
}
@media (max-width: 480px) {
  .customer-summary-grid {
    grid-template-columns: 1fr;
  }
  .customer-actions .btn {
    flex: 1 1 auto;
    min-width: 0;
  }
}
.list-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
  min-width: 0;
  border-radius: 6px;
  transition: background .12s;
}
.list-row:hover { background: var(--surface-2); }
.list-row:last-child { border-bottom: 0; }
.list-row .time {
  min-width: 48px;
  font-size: var(--fs-sm);
  font-weight: 700;
  color: var(--accent);
  padding-top: 2px;
  flex-shrink: 0;
}
.list-row .body { flex: 1; min-width: 0; }
.list-row .body strong {
  display: block;
  font-size: var(--fs-base);
  overflow: hidden;
  text-overflow: ellipsis;
}
.list-row .body span {
  color: var(--muted);
  font-size: var(--fs-sm);
}
.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  max-width: 100%;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.filters .input, .filters .select {
  width: auto;
  min-width: 120px;
  max-width: 100%;
  background: #fff;
}
.tabs {
  display: flex;
  gap: 0;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
  padding: 0 8px;
  background: #fff;
  max-width: 100%;
  overflow-x: auto;
}
.tab {
  border: 0;
  background: transparent;
  padding: 11px 13px;
  font-weight: 600;
  font-size: var(--fs-base);
  color: var(--muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  white-space: nowrap;
}
.tab.active {
  color: var(--brand);
  border-bottom-color: var(--accent);
}
.timeline { display: flex; flex-direction: column; }
.tl-item {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr);
  gap: 10px;
  padding: 0 0 14px;
  position: relative;
}
.tl-item::before {
  content: '';
  position: absolute;
  left: 5px;
  top: 14px;
  bottom: 0;
  width: 1px;
  background: var(--line);
}
.tl-item:last-child::before { display: none; }
.tl-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--line);
  margin-top: 3px;
}
.tl-item strong { display: block; font-size: var(--fs-base); }
.tl-item p { margin: 3px 0 0; color: var(--muted); font-size: var(--fs-sm); }
.tl-item small { color: var(--muted); font-size: var(--fs-sm); }
.project-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  min-width: 0;
  transition: border-color .15s, box-shadow .15s, transform .15s;
  box-shadow: var(--shadow);
}
.project-card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.project-card .cover {
  min-height: 108px;
  color: #fff;
  padding: 16px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 6px;
  position: relative;
}
.project-card .cover::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,.35), transparent 55%);
  pointer-events: none;
}
.project-card .cover > * { position: relative; z-index: 1; }
.project-city {
  align-self: flex-start;
  font-size: var(--fs-xs);
  font-weight: 650;
  background: rgba(255,255,255,.18);
  padding: 3px 10px;
  border-radius: 999px;
  backdrop-filter: blur(4px);
}
.project-card .cover strong {
  font-size: var(--fs-base);
  font-weight: 650;
  line-height: 1.3;
}
.project-card .body { padding: 14px; flex: 1; display: flex; flex-direction: column; gap: 10px; }
.project-card-top {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.project-card-top small { color: var(--muted); font-size: var(--fs-sm); }
.project-kpi {
  font-size: var(--fs-sm);
  color: var(--ink-soft);
}
.project-card .meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: auto;
  padding-top: 4px;
}
.cal-day {
  text-align: center;
  padding: 10px 6px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid var(--line);
  min-width: 0;
}
.cal-day .d {
  font-size: var(--fs-lg);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.cal-day .m {
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
}
.cal-day.active {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.cal-day.active .m { color: #94a3b8; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.form-grid .full { grid-column: 1 / -1; }
.reason-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: var(--surface-2);
  min-width: 0;
}
.reason-box.ok { border-color: #a7f3d0; background: var(--ok-bg); }
.reason-box.bad { border-color: #fecaca; background: var(--danger-bg); }
.chip-pick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.chip-pick button {
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: 6px;
  padding: 5px 10px;
  font-size: var(--fs-sm);
  font-weight: 600;
  cursor: pointer;
  color: var(--ink-soft);
}
.chip-pick button.on {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.kpi-bar {
  height: 6px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
  margin-top: 6px;
}
.kpi-bar > i {
  display: block;
  height: 100%;
  background: var(--accent);
  border-radius: inherit;
}
.empty {
  text-align: center;
  padding: 32px 16px;
  color: var(--muted);
}
.fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 50;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  border: 0;
  box-shadow: 0 6px 20px rgba(29, 78, 216, .35);
  font-size: var(--fs-xl);
  font-weight: 500;
  cursor: pointer;
  display: none;
  transition: transform .15s, box-shadow .15s;
}
.fab:hover { transform: scale(1.05); box-shadow: 0 8px 28px rgba(29, 78, 216, .4); }
.fab-menu {
  position: fixed;
  right: 20px;
  bottom: 84px;
  z-index: 49;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  padding: 6px;
  min-width: 200px;
  display: none;
  flex-direction: column;
  gap: 2px;
}
.fab-menu.open { display: flex; }
.fab-menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-weight: 600;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  transition: background .12s;
}
.fab-menu a:hover { background: var(--surface-2); color: var(--ink); }
.fab-ico { font-size: 18px; width: 24px; text-align: center; }
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%) translateY(12px);
  background: var(--brand);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: var(--fs-base);
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: .2s;
  z-index: 80;
  max-width: calc(100vw - 32px);
  text-align: center;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.hero-banner {
  border-radius: var(--radius);
  padding: 16px 18px;
  background: var(--brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  max-width: 100%;
}
.hero-banner h2 {
  margin: 0 0 4px;
  font-size: var(--fs-lg);
  font-weight: 650;
  letter-spacing: -0.02em;
}
.hero-banner p {
  margin: 0;
  color: #94a3b8;
  font-size: var(--fs-base);
}
.action-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  margin-bottom: 16px;
  max-width: 100%;
  box-shadow: var(--shadow);
}
.btn-wa { background: var(--wa-bg); color: var(--wa); border: 1px solid #99f6e4; }
.btn-sms { background: var(--sms-bg); color: var(--sms); border: 1px solid #c7d2fe; }
.btn-call { background: var(--info-bg); color: var(--info); border: 1px solid #bfdbfe; }
.btn-remind { background: var(--warn-bg); color: var(--warn); border: 1px solid #fde68a; }
.remind-strip {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: #fffbeb;
  border: 1px solid #fde68a;
  margin-bottom: 12px;
  font-size: var(--fs-base);
  max-width: 100%;
  position: relative;
  transition: background .2s, border-color .2s, box-shadow .2s;
}
.remind-strip strong { color: var(--warn); flex-shrink: 0; }
.remind-strip .spacer { flex: 1 1 8px; min-width: 0; }
.remind-strip .remind-text { font-weight: 600; color: var(--ink-soft); }
@keyframes remindGlow {
  0%, 100% {
    background: #fffbeb;
    border-color: #fde68a;
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0);
  }
  50% {
    background: #fef3c7;
    border-color: #f59e0b;
    box-shadow: 0 0 0 5px rgba(245, 158, 11, 0.14);
  }
}
@keyframes remindBeacon {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.55);
  }
  50% {
    opacity: 0.45;
    transform: scale(0.82);
    box-shadow: 0 0 0 8px rgba(245, 158, 11, 0);
  }
}
@keyframes remindLabel {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.72; }
}
.remind-strip--alert {
  animation: remindGlow 2.2s ease-in-out infinite;
  border-left: 4px solid #f59e0b;
  padding-left: 12px;
}
.remind-strip--alert::before {
  content: '';
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #f59e0b;
  flex-shrink: 0;
  animation: remindBeacon 1.15s ease-in-out infinite;
}
.remind-strip--alert strong {
  animation: remindLabel 2.2s ease-in-out infinite;
}
.remind-strip--alert .remind-countdown {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  border-radius: 999px;
  background: #fef3c7;
  border: 1px solid #fcd34d;
  color: #b45309;
  font-size: var(--fs-sm);
  font-weight: 700;
  animation: remindGlow 2.2s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .remind-strip--alert,
  .remind-strip--alert::before,
  .remind-strip--alert strong,
  .remind-strip--alert .remind-countdown {
    animation: none;
  }
  .remind-strip--alert::before { opacity: 1; }
}
.seg {
  display: flex;
  flex-wrap: wrap;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  max-width: 100%;
}
.seg label {
  flex: 1 1 0;
  min-width: 0;
  text-align: center;
  padding: 8px 6px;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
  border-right: 1px solid var(--line);
  margin: 0 !important;
}
.seg label:last-child { border-right: 0; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label:has(input:checked) {
  background: var(--brand);
  color: #fff;
}
.compact-form .field { margin-bottom: 10px; }
.compact-form .field label { font-size: var(--fs-sm); margin-bottom: 5px; }
.compact-form .input,
.compact-form .select,
.compact-form .textarea { padding: 9px 11px; font-size: var(--fs-sm); }
.compact-form .chip-pick { margin-top: 6px; gap: 5px; }
.compact-form .chip-pick button {
  padding: 5px 9px;
  font-size: var(--fs-xs);
}
.compact-form .reason-box { padding: 10px; }
.compact-form .details-more > summary { font-size: var(--fs-sm); padding: 10px 12px; }
.quick-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
  gap: 8px;
  align-items: end;
}
.quick-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}
.quick-presets button {
  border: 1px solid var(--line-strong);
  background: #fff;
  border-radius: 6px;
  padding: 5px 9px;
  font-size: var(--fs-sm);
  font-weight: 600;
  cursor: pointer;
  color: var(--ink-soft);
}
.quick-presets button:hover,
.quick-presets button.on {
  border-color: #93c5fd;
  background: var(--accent-soft);
  color: var(--accent);
}
.agenda-card {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  margin-bottom: 8px;
  max-width: 100%;
  transition: border-color .15s, box-shadow .15s;
}
.agenda-card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow);
}
.agenda-card.done { opacity: .55; }
.agenda-card .time {
  font-weight: 700;
  font-size: var(--fs-base);
  color: var(--accent);
  padding-top: 2px;
}
.agenda-card .title {
  font-weight: 650;
  font-size: var(--fs-base);
  line-height: 1.35;
  word-break: break-word;
}
.agenda-card .meta {
  font-size: var(--fs-sm);
  color: var(--muted);
  margin-top: 2px;
}
.agenda-card .acts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.details-more {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
  padding: 0;
  margin-top: 4px;
  max-width: 100%;
}
.details-more > summary {
  cursor: pointer;
  padding: 11px 13px;
  font-size: var(--fs-base);
  font-weight: 600;
  color: var(--ink-soft);
  list-style: none;
}
.details-more > summary::-webkit-details-marker { display: none; }
.details-more[open] > summary { border-bottom: 1px solid var(--line); }
.details-more .inner { padding: 12px; }
.integ-card {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  min-width: 0;
  max-width: 100%;
}
.integ-card .ico {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: var(--fs-xs);
  flex-shrink: 0;
}
.integ-card.wa .ico { background: var(--wa-bg); color: var(--wa); }
.integ-card.sms .ico { background: var(--sms-bg); color: var(--sms); }
.integ-card strong { display: block; font-size: var(--fs-base); }
.integ-card p { margin: 4px 0 0; font-size: var(--fs-sm); color: var(--muted); }
.modal-back {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .45);
  z-index: 90;
  display: none;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
}
.modal-back.show { display: flex; }
.modal {
  width: min(440px, 100%);
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: var(--shadow-md);
  max-width: 100%;
}
.modal-sm { width: min(380px, 100%); }
.modal-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  margin-top: 16px;
  flex-wrap: wrap;
}
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 16px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.page-header h2 {
  margin: 0 0 6px;
  font-size: var(--fs-xl);
  font-weight: 650;
  letter-spacing: -0.02em;
}
.page-header p {
  margin: 0;
  color: var(--muted);
  font-size: var(--fs-sm);
  max-width: 56ch;
  line-height: 1.5;
}
.page-header-actions {
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}
.empty-state {
  text-align: center;
  padding: 48px 24px;
  background: #fff;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  color: var(--muted);
}
.empty-state .empty-icon {
  font-size: 40px;
  margin-bottom: 12px;
  opacity: .85;
}
.empty-state strong {
  display: block;
  color: var(--ink);
  font-size: var(--fs-lg);
  margin-bottom: 6px;
}
.empty-state p { margin: 0 0 16px; font-size: var(--fs-sm); }
.modal h3 {
  margin: 0 0 4px;
  font-size: var(--fs-lg);
  font-weight: 650;
}
.modal p.hint {
  margin: 0 0 12px;
  font-size: var(--fs-base);
  color: var(--muted);
}
.mobile-only { display: none; }
@media (max-width: 1100px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: minmax(0, 1fr); }
  .split-dashboard { grid-template-columns: minmax(0, 1fr); }
  .quick-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}
@media (min-width: 901px) {
  .split-dashboard { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); }
}
@media (max-width: 900px) {
  .login-page { grid-template-columns: minmax(0, 1fr); }
  .login-visual { min-height: 200px; padding: 24px; }
  .login-quote { max-width: none; font-size: var(--fs-xl); }
  .sidebar {
    position: fixed;
    left: 0;
    top: var(--ribbon-h);
    bottom: 0;
    transform: translateX(-105%);
    transition: transform .2s ease;
    height: calc(100dvh - var(--ribbon-h));
    min-height: calc(100dvh - var(--ribbon-h));
    max-height: none;
    z-index: 45;
  }
  .sidebar.open { transform: translateX(0); }
  .main {
    width: 100%;
    min-height: calc(100dvh - var(--ribbon-h));
  }
  .menu-btn { display: grid; place-items: center; }
  .search { display: none; }
  .grid-3, .grid-2, .form-grid { grid-template-columns: minmax(0, 1fr); }
  .span-2 { grid-column: auto; }
  .fab { display: grid; place-items: center; }
  .mobile-only { display: initial; }
  .content { padding: 16px; padding-bottom: 72px; }
  .topbar { padding: 12px 16px; }
  table.data .hide-sm { display: none; }
  table.data { min-width: 0; }
}
@media (min-width: 640px) and (max-width: 899px) {
  .form-page-wrap { width: min(720px, 100%); }
  .form-page .form-grid-core,
  .form-page .form-grid-tight,
  .form-page .form-grid-extra {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .form-page .form-grid-followup {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  }
}
@media (min-width: 481px) {
  .form-page .form-grid-followup {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  }
}
@media (max-width: 720px) {
  .split-dashboard { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat .value { font-size: var(--fs-xl); }
  .topbar-actions .hide-xs { display: none; }
  .quick-row { grid-template-columns: minmax(0, 1fr); }
  .action-bar .btn span.label { display: none; }
  .form-page .content { padding: 12px 12px 72px; }
  .form-page-wrap { width: 100%; max-width: 100%; }
  .form-layout,
  .form-grid-core,
  .form-grid-followup,
  .form-grid-extra,
  .form-page .form-grid-tight {
    grid-template-columns: minmax(0, 1fr);
  }
  .form-page .panel-b { padding: 12px; }
  .form-page .panel-h { padding: 10px 12px; }
  .form-page .compact-form .field { margin-bottom: 8px; }
  .form-page .compact-form .input,
  .form-page .compact-form .select,
  .form-page .compact-form .textarea {
    padding: 10px 11px;
    font-size: 16px;
  }
  .form-page .chip-pick button {
    padding: 7px 10px;
    font-size: 13px;
  }
  .form-page .seg label {
    flex: 1 1 100%;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 10px 8px;
    font-size: 14px;
  }
  .form-page .seg label:last-child { border-bottom: 0; }
  .form-page .form-grid-tight { gap: 8px; }
  .form-actions .btn {
    padding: 9px 4px;
    font-size: 12px;
  }
  .form-page .quick-presets button {
    flex: 1 1 calc(33% - 4px);
    text-align: center;
    padding: 8px 4px;
  }
  .compact-form .seg-compact label {
    flex: 1 1 33%;
    border-bottom: 0;
    border-right: 1px solid var(--line);
  }
  .compact-form .seg-compact label:nth-child(3n) { border-right: 0; }
}
@media (max-width: 400px) {
  .compact-form .seg-compact label {
    flex: 1 1 100%;
    border-right: 0 !important;
    border-bottom: 1px solid var(--line);
  }
  .compact-form .seg-compact label:last-child { border-bottom: 0; }
}
.guide-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, .5);
  z-index: 9500;
}
.guide-highlight {
  position: relative;
  z-index: 9501 !important;
  box-shadow: 0 0 0 3px #1d4ed8, 0 0 0 9999px rgba(15, 23, 42, .52) !important;
  border-radius: 8px;
}
.guide-popover {
  position: absolute;
  z-index: 9502;
  width: min(360px, calc(100vw - 24px));
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  box-shadow: var(--shadow-md);
}
.guide-popover--center {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
}
.guide-popover-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.guide-step-count {
  font-size: var(--fs-sm);
  font-weight: 650;
  color: var(--accent);
}
.guide-close {
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  color: var(--muted);
  padding: 0 4px;
}
.guide-title {
  margin: 0 0 8px;
  font-size: var(--fs-lg);
  font-weight: 650;
}
.guide-body {
  font-size: var(--fs-base);
  color: var(--ink-soft);
  line-height: 1.55;
}
.guide-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}
.guide-menu {
  position: fixed;
  top: calc(var(--topbar) + 48px);
  right: 16px;
  z-index: 9503;
  width: min(320px, calc(100vw - 32px));
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  box-shadow: var(--shadow-md);
}
.guide-menu-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.guide-menu-lead {
  margin: 0 0 12px;
  font-size: var(--fs-sm);
  color: var(--muted);
}
.guide-menu-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}
.guide-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  text-align: left;
  border: 1px solid var(--line);
  background: var(--surface-2);
  border-radius: 8px;
  padding: 10px 12px;
  cursor: pointer;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--ink-soft);
}
.guide-menu-item:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}
.guide-menu-item span:first-child {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 11px;
  flex-shrink: 0;
}
.guide-menu-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: var(--fs-sm);
  color: var(--muted);
  cursor: pointer;
}
.btn-guide {
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid #bfdbfe;
}
.btn-module-help {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 50%;
  background: var(--gold-soft);
  color: #92400e;
  border: 1px solid #fde68a;
  font-weight: 700;
  font-size: var(--fs-base);
}
.btn-module-help:hover { background: #fef3c7; }
.modal-lg { width: min(560px, 100%); }
.module-modal .module-modal-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.module-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(145deg, var(--brand), var(--accent));
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: var(--fs-sm);
  flex-shrink: 0;
}
.module-modal-head h3 {
  margin: 0 0 4px;
  font-family: var(--display);
  font-size: var(--fs-xl);
  font-weight: 700;
}
.module-tagline {
  margin: 0;
  color: var(--gold);
  font-weight: 600;
  font-size: var(--fs-sm);
}
.module-desc {
  margin: 0 0 14px;
  color: var(--ink-soft);
  line-height: 1.6;
}
.module-bullets {
  margin: 0 0 14px;
  padding-left: 20px;
  color: var(--ink-soft);
  line-height: 1.7;
}
.module-bullets li { margin-bottom: 4px; }
.module-tip {
  padding: 12px 14px;
  background: var(--gold-soft);
  border: 1px solid #fde68a;
  border-radius: 8px;
  font-size: var(--fs-sm);
  color: #78350f;
}
.module-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 360px;
  overflow-y: auto;
}
.module-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-2);
  cursor: pointer;
  text-align: left;
  transition: border-color .12s, box-shadow .12s;
}
.module-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow);
}
.module-card-ico {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 700;
}
.module-card strong { font-size: var(--fs-sm); color: var(--ink); }
.module-card span:last-child { font-size: var(--fs-xs); color: var(--muted); }
.remind-hero {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 20px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fff 0%, var(--surface-2) 100%);
  border: 1px solid var(--line);
  margin-bottom: 16px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}
.remind-hero--alert {
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  border-color: #f59e0b;
  animation: remindGlow 2.5s ease-in-out infinite;
}
.remind-hero--alert .remind-hero-countdown {
  animation: remindLabel 2.2s ease-in-out infinite;
}
.remind-hero--alert .remind-hero-label {
  animation: remindLabel 2.2s ease-in-out infinite;
}
.remind-hero--idle {
  background: linear-gradient(135deg, #ecfdf5 0%, #fff 100%);
  border-color: #a7f3d0;
}
.remind-hero-pulse {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--gold);
}
.remind-hero--alert .remind-hero-pulse {
  background: #f59e0b;
  animation: remindBeacon 1.5s ease-in-out infinite;
}
.remind-hero--alert .remind-hero-icon {
  animation: remindBeacon 1.5s ease-in-out infinite;
}
.remind-hero-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 22px;
  flex-shrink: 0;
}
.remind-hero--alert .remind-hero-icon { background: #d97706; }
.remind-hero--idle .remind-hero-icon { background: var(--ok); }
.remind-hero-body { flex: 1; min-width: 180px; }
.remind-hero-label {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  margin-bottom: 4px;
}
.remind-hero-body strong {
  display: block;
  font-family: var(--display);
  font-size: var(--fs-md);
  font-weight: 700;
  margin-bottom: 4px;
}
.remind-hero-countdown {
  display: inline-block;
  font-weight: 700;
  color: var(--accent);
  font-size: var(--fs-sm);
}
.remind-hero--alert .remind-hero-countdown { color: #b45309; }
.remind-hero-meta {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  margin-top: 4px;
}
.remind-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.week-strip {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  margin-bottom: 16px;
}
.week-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.week-nav-center {
  flex: 1;
  min-width: 140px;
  text-align: center;
}
.week-nav-center strong {
  display: block;
  font-family: var(--display);
  font-size: var(--fs-md);
}
.week-nav-sub {
  font-size: var(--fs-xs);
  color: var(--muted);
}
.week-day {
  text-align: center;
  padding: 10px 6px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
  position: relative;
  transition: border-color .12s, box-shadow .12s;
  cursor: pointer;
  font: inherit;
  color: inherit;
  width: 100%;
}
.week-day:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow);
}
.week-day.active {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  box-shadow: var(--shadow-md);
}
.week-day.has-event .wd-num { font-weight: 700; }
.wd-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--gold);
  color: #1e293b;
  font-size: 10px;
  font-weight: 700;
  line-height: 18px;
}
.week-day.active .wd-badge {
  background: #fff;
  color: var(--brand);
}
.wd-label {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.week-day.active .wd-label { color: #94a3b8; }
.wd-num {
  display: block;
  font-size: var(--fs-lg);
  font-weight: 650;
  font-family: var(--display);
  margin-top: 2px;
}
.wd-dot {
  position: absolute;
  bottom: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--gold);
}
.agenda-layout { align-items: start; }
.agenda-timeline { position: relative; }
.agenda-timeline-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr);
  gap: 12px;
  margin-bottom: 4px;
}
.agenda-timeline-item .tl-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 18px;
}
.agenda-timeline-item .tl-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--line);
}
.agenda-timeline-item.late .tl-dot { background: var(--danger); }
.agenda-timeline-item.soon .tl-dot { background: var(--warn); animation: remindBeacon 1.5s infinite; }
.agenda-timeline-item.done { opacity: .55; }
.agenda-card-pro {
  display: block;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  transition: border-color .12s, box-shadow .12s;
  cursor: pointer;
}
.agenda-card-pro:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow);
}
.agenda-card-head {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.agenda-card-head .time {
  font-weight: 700;
  font-size: var(--fs-lg);
  font-family: var(--display);
  color: var(--accent);
  margin-right: auto;
}
.agenda-remind-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 8px;
  padding: 4px 10px;
  background: var(--warn-bg);
  border: 1px solid #fde68a;
  border-radius: 999px;
  font-size: var(--fs-xs);
  font-weight: 600;
  color: #92400e;
}
.agenda-note-preview {
  margin-top: 6px;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.4;
}
.process-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 12px 0 4px;
}
.process-step {
  padding: 4px 10px;
  border-radius: 999px;
  font-size: var(--fs-xs);
  font-weight: 600;
  background: var(--surface-2);
  border: 1px solid var(--line);
  color: var(--muted);
}
.process-step.done {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #047857;
}
.process-step.active {
  background: #eff6ff;
  border-color: #93c5fd;
  color: var(--accent);
  box-shadow: 0 0 0 1px #bfdbfe;
}
.export-textarea {
  width: 100%;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: var(--fs-sm);
  line-height: 1.5;
  resize: vertical;
  min-height: 240px;
}
.remind-panel-head {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  padding: 0 8px 8px;
}
.lbl-opt {
  font-weight: 400;
  color: var(--muted);
  font-size: var(--fs-xs);
}
.remind-panel .remind-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 8px;
  border-bottom: 1px solid var(--line);
  border-radius: 6px;
  transition: background .12s;
}
.remind-panel .remind-item:last-child { border-bottom: 0; }
.remind-panel .remind-item:hover { background: var(--surface-2); }
.remind-panel .remind-item--urgent {
  background: #fffbeb;
  border: 1px solid #fde68a;
  margin-bottom: 6px;
}
.remind-item-time {
  min-width: 44px;
  font-weight: 700;
  font-size: var(--fs-sm);
  color: var(--accent);
}
.remind-item-body { flex: 1; min-width: 0; }
.remind-item-body strong {
  display: block;
  font-size: var(--fs-sm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.remind-item-body span {
  font-size: var(--fs-xs);
  color: var(--muted);
}
.agenda-detail-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
}
.agenda-detail-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 16px 0;
  padding: 14px;
  background: var(--surface-2);
  border-radius: 8px;
}
.agenda-detail-grid .lbl {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 2px;
}
.agenda-detail-customer {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.seg-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.seg-card {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  cursor: pointer;
  font-weight: 600;
  font-size: var(--fs-sm);
  text-align: center;
}
.seg-card:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--accent);
}
.seg-card input { display: none; }
.textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  padding: 11px 13px;
  resize: vertical;
  min-height: 72px;
}
.textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(29, 78, 216, 0.12);
  outline: none;
}
@media (max-width: 720px) {
  .module-grid { grid-template-columns: 1fr; }
  .week-strip { grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; }
  .week-day { padding: 8px 4px; }
  .remind-hero { padding: 14px; }
  .seg-cards { grid-template-columns: 1fr; }
}

.campaign-page .content {
  padding-bottom: 24px;
}
.campaign-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 14px 18px;
  margin-bottom: 14px;
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fffbeb 0%, #fef3c7 100%);
  border: 1px solid #fde68a;
  animation: remindGlow 2.8s ease-in-out infinite;
}
.campaign-hero-kicker {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #b45309;
  margin-bottom: 2px;
}
.campaign-hero-main strong {
  display: block;
  font-size: var(--fs-lg);
  font-family: var(--display);
  color: var(--ink);
}
.campaign-hero-main > span:last-child {
  font-size: var(--fs-sm);
  color: var(--muted);
}
.campaign-hero-stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.campaign-hero-stats > div {
  min-width: 72px;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255,255,255,.75);
  border: 1px solid #fde68a;
  text-align: center;
}
.campaign-hero-stats b {
  display: block;
  font-size: var(--fs-lg);
  font-family: var(--display);
  color: #b45309;
  line-height: 1.1;
}
.campaign-hero-stats span {
  font-size: var(--fs-xs);
  color: var(--muted);
}
.campaign-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.85fr);
  gap: 14px;
  align-items: start;
}
.panel-sub {
  margin: 2px 0 0;
  font-size: var(--fs-xs);
  color: var(--muted);
  font-weight: 500;
}
.campaign-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 14px 0;
  align-items: center;
}
.campaign-toolbar .input {
  flex: 1 1 180px;
  min-width: 0;
}
.campaign-select-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}
.campaign-check-all {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  margin-right: auto;
}
.campaign-rows {
  max-height: min(560px, 62vh);
  overflow-y: auto;
  padding: 6px 8px 12px;
}
.campaign-row {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto auto;
  gap: 10px;
  align-items: center;
  padding: 10px 8px;
  border-radius: 8px;
  border-bottom: 1px solid var(--line);
}
.campaign-row:last-child { border-bottom: 0; }
.campaign-row:hover { background: var(--surface-2); }
.campaign-row.is-sent { opacity: .78; }
.campaign-row-person {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  color: inherit;
}
.campaign-row-person strong {
  display: block;
  font-size: var(--fs-sm);
}
.campaign-row-person span {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.campaign-compose {
  position: sticky;
  top: calc(var(--ribbon-h) + var(--topbar) + 12px);
}
.campaign-msg-label {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}
.campaign-msg-label label { margin: 0; }
.campaign-vars { margin-top: 6px; }
.campaign-preview {
  margin: 4px 0 12px;
  padding: 12px;
  border-radius: 10px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
}
.campaign-preview.is-sms {
  background: #eef2ff;
  border-color: #c7d2fe;
}
.campaign-preview-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
  margin-bottom: 8px;
}
.campaign-bubble {
  background: #fff;
  border-radius: 12px 12px 12px 4px;
  padding: 10px 12px;
  font-size: var(--fs-sm);
  line-height: 1.45;
  color: var(--ink-soft);
  box-shadow: var(--shadow);
  white-space: pre-wrap;
}
.campaign-actions {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 8px;
  margin-top: 4px;
}
.campaign-actions .btn { width: 100%; }
.campaign-note {
  margin: 10px 0 0;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.4;
}
@media (max-width: 1100px) {
  .campaign-layout { grid-template-columns: minmax(0, 1fr); }
  .campaign-compose { position: static; }
  .campaign-rows { max-height: none; }
}
@media (max-width: 560px) {
  .campaign-row { grid-template-columns: 28px minmax(0, 1fr); }
  .campaign-row .chip,
  .campaign-row .btn {
    grid-column: 2;
    justify-self: start;
  }
  .campaign-actions { grid-template-columns: 1fr; }
}

.messages-page .content { padding-bottom: 24px; }
.msg-status-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.msg-status-item {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1 1 220px;
  min-width: 0;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.msg-status-item strong {
  display: block;
  font-size: var(--fs-sm);
}
.msg-status-item span:last-child {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
}
.msg-status-ico {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
}
.msg-status-item.is-wa .msg-status-ico {
  background: var(--wa-bg);
  color: var(--wa);
}
.msg-status-item.is-sms .msg-status-ico {
  background: var(--sms-bg);
  color: var(--sms);
}
.msg-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.9fr);
  gap: 14px;
  align-items: start;
}
.msg-tpl-list {
  display: grid;
  gap: 8px;
  padding: 12px 14px 14px;
  max-height: min(620px, 68vh);
  overflow-y: auto;
}
.msg-tpl-card {
  text-align: left;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  padding: 12px;
  cursor: pointer;
  transition: border-color .12s, box-shadow .12s, background .12s;
  font: inherit;
  color: inherit;
  width: 100%;
}
.msg-tpl-card:hover {
  border-color: #cbd5e1;
  box-shadow: var(--shadow);
}
.msg-tpl-card.is-active {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 1px #bfdbfe;
}
.msg-tpl-card.is-wa.is-active {
  border-color: #5eead4;
  background: #f0fdfa;
  box-shadow: 0 0 0 1px #99f6e4;
}
.msg-tpl-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}
.msg-tpl-top strong {
  font-size: var(--fs-sm);
}
.msg-tpl-card p {
  margin: 0;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.msg-tpl-use {
  display: inline-block;
  margin-top: 8px;
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--accent);
}
.msg-tpl-card.is-wa .msg-tpl-use { color: var(--wa); }
.msg-compose {
  position: sticky;
  top: calc(var(--ribbon-h) + var(--topbar) + 12px);
}
.msg-cust-card {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 8px;
  padding: 10px;
  border-radius: 8px;
  background: var(--surface-2);
  border: 1px solid var(--line);
}
.msg-cust-card strong {
  display: block;
  font-size: var(--fs-sm);
}
.msg-cust-card span {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
}
.msg-cust-card > div:nth-child(2) {
  flex: 1;
  min-width: 0;
}
.msg-actions {
  display: grid;
  grid-template-columns: 1.4fr auto;
  gap: 8px;
  margin-top: 4px;
}
.msg-actions .btn { width: 100%; }
@media (max-width: 1100px) {
  .msg-layout { grid-template-columns: minmax(0, 1fr); }
  .msg-compose { position: static; }
  .msg-tpl-list { max-height: none; }
}
@media (max-width: 560px) {
  .msg-actions { grid-template-columns: 1fr; }
}

.btn-block { width: 100%; justify-content: center; }
.customer-page .content { padding-bottom: 28px; }
.cd-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: var(--fs-sm);
  color: var(--muted);
  flex-wrap: wrap;
}
.cd-nav-sep { opacity: .5; }
.cd-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 18px 20px;
  margin-bottom: 12px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border-top: 3px solid var(--gold);
}
.cd-hero-main {
  display: flex;
  gap: 14px;
  min-width: 0;
  flex: 1 1 320px;
}
.cd-avatar {
  width: 56px;
  height: 56px;
  font-size: var(--fs-md);
  background: var(--brand);
  color: #fff;
  flex-shrink: 0;
}
.cd-hero-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.cd-hero-title-row h1 {
  margin: 0;
  font-size: var(--fs-xl);
  font-family: var(--display);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.cd-hero-meta {
  margin: 0;
  font-size: var(--fs-sm);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}
.cd-hero-meta a {
  color: var(--accent);
  font-weight: 600;
}
.cd-hero-note {
  margin: 8px 0 10px;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  line-height: 1.45;
  max-width: 56ch;
}
.cd-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.cd-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
}
.cd-kpi-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.cd-kpi {
  padding: 12px 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-width: 0;
}
.cd-kpi .lbl {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
  margin-bottom: 4px;
}
.cd-kpi strong {
  display: block;
  font-size: var(--fs-sm);
  line-height: 1.3;
}
.cd-kpi .sub {
  display: block;
  margin-top: 4px;
  font-size: var(--fs-xs);
  color: var(--muted);
  line-height: 1.35;
}
.cd-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(260px, 0.7fr);
  gap: 14px;
  align-items: start;
}
.cd-tabs em {
  font-style: normal;
  font-weight: 700;
  color: var(--muted);
  margin-left: 2px;
}
.cd-ozet-grid,
.cd-interest-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.cd-ozet-block {
  min-width: 0;
}
.cd-dl {
  margin: 0;
  display: grid;
  gap: 10px;
}
.cd-dl > div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.cd-dl dt {
  font-size: var(--fs-xs);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.cd-dl dd {
  margin: 0;
  font-size: var(--fs-sm);
  font-weight: 600;
}
.cd-budget-line {
  margin: 12px 0 0;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
}
.cd-timeline {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.cd-tl-item {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 10px;
  padding: 8px 4px;
  border-radius: 8px;
}
.cd-tl-item[role="button"] { cursor: pointer; }
.cd-tl-item[role="button"]:hover { background: var(--surface-2); }
.cd-tl-rail {
  display: flex;
  justify-content: center;
  padding-top: 2px;
}
.cd-tl-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--surface-2);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  font-size: 11px;
}
.cd-tl-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 2px;
}
.cd-tl-body p {
  margin: 0;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  line-height: 1.4;
}
.cd-tl-body small {
  color: var(--muted);
  font-size: var(--fs-xs);
}
.cd-list-row {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 12px 4px;
  border-bottom: 1px solid var(--line);
}
.cd-list-row:last-child { border-bottom: 0; }
.cd-list-row[role="button"] {
  cursor: pointer;
  border-radius: 8px;
  padding-left: 8px;
  padding-right: 8px;
}
.cd-list-row[role="button"]:hover { background: var(--surface-2); }
.cd-list-time strong {
  display: block;
  font-size: var(--fs-sm);
  color: var(--accent);
}
.cd-list-time span {
  font-size: var(--fs-xs);
  color: var(--muted);
}
.cd-list-body strong {
  display: block;
  font-size: var(--fs-sm);
}
.cd-list-body span {
  display: block;
  font-size: var(--fs-xs);
  color: var(--muted);
  margin-top: 2px;
}
.cd-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: sticky;
  top: calc(var(--ribbon-h) + var(--topbar) + 12px);
}
.cd-next-card,
.cd-side-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  box-shadow: var(--shadow);
}
.cd-next-card {
  background: linear-gradient(160deg, #fffbeb 0%, #fff 70%);
  border-color: #fde68a;
}
.cd-next-card.is-empty {
  background: #fff;
  border-color: var(--line);
}
.cd-next-label {
  font-size: var(--fs-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #b45309;
  margin-bottom: 6px;
}
.cd-next-card.is-empty .cd-next-label { color: var(--muted); }
.cd-next-card > strong {
  display: block;
  font-size: var(--fs-md);
  margin-bottom: 4px;
}
.cd-next-card > p {
  margin: 0 0 10px;
  font-size: var(--fs-sm);
  color: var(--ink-soft);
  line-height: 1.4;
}
.cd-next-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}
.cd-side-card h3 {
  margin: 0 0 10px;
  font-size: var(--fs-sm);
  font-weight: 700;
}
.cd-side-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}
.cd-side-actions .btn {
  width: 100%;
}
.cd-side-facts {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}
.cd-side-facts li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: var(--fs-sm);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.cd-side-facts li:last-child { border-bottom: 0; padding-bottom: 0; }
.cd-side-facts span { color: var(--muted); }
@media (max-width: 1100px) {
  .cd-layout { grid-template-columns: minmax(0, 1fr); }
  .cd-side { position: static; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .cd-kpi-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cd-ozet-grid,
  .cd-interest-grid { grid-template-columns: minmax(0, 1fr); }
  .cd-side { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .cd-hero-actions { width: 100%; }
  .cd-hero-actions .btn { flex: 1 1 calc(50% - 8px); }
  .cd-list-row { grid-template-columns: 72px minmax(0, 1fr); }
  .cd-list-row .chip { grid-column: 2; justify-self: start; }
  .cd-kpi-row { grid-template-columns: minmax(0, 1fr); }
}
