/* SalesData 本番UI準拠のお試しデモ */
.try-demo {
  padding: 56px 0 72px;
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
}
.try-demo .section-lead { margin-bottom: 8px; }

.sd-demo {
  position: relative;
  max-width: 1240px;
  margin: 28px auto 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.1);
  font-family: "Noto Sans JP", "Hiragino Sans", sans-serif;
  color: #0f172a;
}
.sd-demo::after {
  content: "DEMO · 架空企業データ";
  position: absolute;
  right: 12px;
  bottom: 10px;
  z-index: 4;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: rgba(15, 23, 42, 0.35);
  background: rgba(255,255,255,0.75);
  border: 1px solid rgba(15,23,42,0.08);
  padding: 4px 8px;
  border-radius: 6px;
  pointer-events: none;
}

.sd-demo-tip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #0f172a;
  color: #e2e8f0;
  font-size: 12.5px;
}
.sd-demo-tip strong { color: #a5b4fc; font-weight: 700; }
.sd-demo-tip .sd-prog {
  display: flex; align-items: center; gap: 8px; white-space: nowrap;
}
.sd-demo-tip .sd-prog-bar {
  width: 88px; height: 6px; border-radius: 999px; background: #334155; overflow: hidden;
}
.sd-demo-tip .sd-prog-bar > i {
  display: block; height: 100%; width: 0; background: #818cf8;
  transition: width 0.4s ease;
}

/* Top nav — Header.tsx 準拠 */
.sd-top {
  height: 56px;
  background: #fff;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  padding: 0 12px;
  gap: 2px;
  overflow-x: auto;
}
.sd-brand {
  display: flex; align-items: center;
  margin-right: 8px; flex-shrink: 0;
}
.sd-brand img { height: 26px; width: auto; display: block; }
.sd-nav-btn {
  border: 0; background: transparent; color: #374151;
  padding: 8px 10px; border-radius: 6px; font-size: 13px;
  cursor: pointer; white-space: nowrap; font-weight: 500;
}
.sd-nav-btn:hover { background: #f3f4f6; color: #111827; }
.sd-nav-btn.is-active { background: #374151; color: #fff; }
.sd-top-grow { flex: 1; min-width: 8px; }
.sd-user {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: #374151; flex-shrink: 0; padding-left: 8px;
  font-weight: 500;
}
.sd-avatar {
  width: 32px; height: 32px; border-radius: 999px; background: #374151;
  color: #fff; display: grid; place-items: center; font-size: 12px; font-weight: 600;
}

.sd-body { display: flex; min-height: 620px; background: #f8fafc; }

/* Sidebar — FilterPage w-[300px] */
.sd-side {
  width: 300px;
  flex-shrink: 0;
  background: #fff;
  border-right: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
}
.sd-side-head {
  padding: 14px 16px;
  border-bottom: 1px solid #e2e8f0;
  display: flex; align-items: center; justify-content: space-between;
}
.sd-side-head-l { display: flex; align-items: center; gap: 8px; }
.sd-side-ico {
  width: 28px; height: 28px; border-radius: 8px; background: #eef2ff;
  color: #4f46e5; display: grid; place-items: center;
}
.sd-side-head strong { font-size: 13px; color: #1e293b; }
.sd-side-clear {
  border: 0; background: transparent; color: #94a3b8; font-size: 11px; cursor: pointer;
}
.sd-side-clear:hover { color: #4f46e5; }
.sd-side-scroll {
  flex: 1; overflow: auto; padding: 4px 0 12px;
}
.sd-sec { border-bottom: 1px solid #f1f5f9; padding-top: 4px; }
.sd-sec-title {
  padding: 12px 16px 4px;
  font-size: 11px; font-weight: 600; color: #64748b;
  letter-spacing: 0.06em; text-transform: uppercase;
}
.sd-sec-body { padding: 4px 16px 14px; }
.sd-label { display: block; font-size: 11px; font-weight: 600; color: #64748b; margin-bottom: 6px; }
.sd-input, .sd-select {
  width: 100%; height: 36px; border: 1px solid #e2e8f0; border-radius: 8px;
  padding: 0 10px; font-size: 13px; background: #fff; color: #0f172a;
}
.sd-input:focus, .sd-select:focus {
  outline: none; border-color: #818cf8; box-shadow: 0 0 0 3px rgba(99,102,241,0.12);
}
.sd-check-list { display: grid; gap: 4px; max-height: 180px; overflow: auto; }
.sd-check {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 8px; border-radius: 6px; font-size: 12.5px; color: #475569; cursor: pointer;
}
.sd-check:hover { background: #f8fafc; }
.sd-check.is-on { background: #eef2ff; color: #4338ca; font-weight: 600; }
.sd-check input { accent-color: #4f46e5; width: 14px; height: 14px; }
.sd-side-foot {
  padding: 12px 16px; border-top: 1px solid #e2e8f0; background: #fff;
  display: grid; gap: 8px;
}
.sd-search-btn {
  width: 100%; height: 40px; border: 0; border-radius: 8px;
  background: #4f46e5; color: #fff; font-size: 14px; font-weight: 700;
  cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 8px;
}
.sd-search-btn:hover { background: #4338ca; }
.sd-search-btn.is-loading { opacity: 0.65; pointer-events: none; }
.sd-side-subacts { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.sd-ghost-btn {
  height: 32px; border: 1px solid #e2e8f0; border-radius: 8px;
  background: #fff; color: #475569; font-size: 11.5px; font-weight: 600; cursor: pointer;
}
.sd-ghost-btn:hover { background: #f8fafc; color: #4f46e5; border-color: #c7d2fe; }

/* Main */
.sd-main { flex: 1; min-width: 0; display: flex; flex-direction: column; background: #f8fafc; }
.sd-main-head {
  background: #fff; border-bottom: 1px solid #e2e8f0;
  padding: 12px 18px; display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.sd-main-title h1 { font-size: 16px; font-weight: 800; margin: 0; line-height: 1.2; color: #0f172a; }
.sd-main-title p { margin: 2px 0 0; font-size: 11px; color: #94a3b8; }
.sd-main-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.sd-btn {
  height: 34px; padding: 0 12px; border-radius: 8px; font-size: 12.5px; font-weight: 700;
  border: 1px solid #e2e8f0; background: #fff; color: #0f172a; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
}
.sd-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.sd-btn.crm {
  border-color: #CBD6E2; color: #2D3E50; background: #fff;
}
.sd-btn.crm svg { color: #FF7A59; }
.sd-btn.crm:hover:not(:disabled) { border-color: #FF7A59; background: #FFF8F6; }
.sd-btn.add { background: #4f46e5; border-color: #4f46e5; color: #fff; }
.sd-btn.add:hover:not(:disabled) { background: #4338ca; }
.sd-btn.hub { background: #FF7A59; border-color: #FF7A59; color: #fff; }
.sd-btn.hub:hover:not(:disabled) { background: #EA6A4A; }
.sd-btn.csv { background: #0f172a; border-color: #0f172a; color: #fff; }

.sd-stats {
  background: #fff; border-bottom: 1px solid #e2e8f0;
  padding: 10px 18px; display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.sd-stats .num { font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums; color: #0f172a; }
.sd-stats .unit { font-size: 13px; color: #94a3b8; }
.sd-sel-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px; background: #eef2ff;
  color: #4f46e5; font-size: 12px; font-weight: 700;
}
.sd-sel-badge button { border: 0; background: transparent; color: #818cf8; cursor: pointer; font-size: 14px; line-height: 1; }
.sd-link {
  border: 0; background: transparent; color: #4f46e5; font-size: 12px;
  font-weight: 600; text-decoration: underline; cursor: pointer;
}
.sd-chips {
  background: #fff; border-bottom: 1px solid #e2e8f0;
  padding: 0 18px 10px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
}
.sd-chips[hidden] { display: none !important; }
.sd-chips-label { font-size: 11px; color: #94a3b8; margin-right: 2px; }
.sd-chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 10px; border-radius: 999px; background: #f1f5f9;
  color: #334155; font-size: 11px; font-weight: 600;
}

.sd-results {
  flex: 1; overflow: auto; padding: 12px 16px; display: grid; gap: 8px;
  align-content: start; max-height: 460px;
}
.sd-select-all-row {
  display: flex; align-items: center; gap: 8px;
  padding: 0 2px 4px; font-size: 11px; color: #94a3b8;
}

/* CompanyTable 準拠カード */
.sd-card {
  display: block;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.sd-card:hover { border-color: #cbd5e1; box-shadow: 0 1px 3px rgba(15,23,42,0.06); }
.sd-card.is-on {
  border-color: #c7d2fe;
  box-shadow: 0 0 0 1px rgba(99,102,241,0.12), 0 1px 2px rgba(15,23,42,0.04);
}
.sd-card-top { padding: 12px 16px 8px; display: flex; align-items: flex-start; gap: 12px; }
.sd-card-top > input { margin-top: 3px; accent-color: #4f46e5; width: 16px; height: 16px; flex-shrink: 0; }
.sd-card-main { flex: 1; min-width: 0; }
.sd-card-title-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.sd-card-name {
  font-size: 13.5px; font-weight: 700; color: #0f172a;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.sd-card-ind {
  flex-shrink: 0; font-size: 10px; font-weight: 600;
  padding: 2px 6px; border-radius: 4px; background: #eef2ff; color: #4f46e5;
}
.sd-card-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
  margin-top: 4px; font-size: 11px; color: #94a3b8;
}
.sd-card-meta span, .sd-card-meta a { display: inline-flex; align-items: center; gap: 3px; }
.sd-card-meta .web { color: #6366f1; font-weight: 600; }
.sd-card-contacts { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.sd-contact-ico {
  width: 24px; height: 24px; border-radius: 999px;
  background: #ecfdf5; color: #059669;
  display: grid; place-items: center;
}
.sd-contact-ico svg { width: 12px; height: 12px; }
.sd-card-bottom { padding: 0 16px 12px; }
.sd-metrics { display: flex; gap: 8px; overflow-x: auto; align-items: flex-start; }
.sd-metric {
  background: #f8fafc; border-radius: 6px; padding: 6px 10px; flex-shrink: 0;
}
.sd-metric .l { font-size: 9px; color: #94a3b8; line-height: 1; }
.sd-metric .v { font-size: 11px; font-weight: 700; color: #334155; margin-top: 2px; white-space: nowrap; }
.sd-card-desc {
  flex: 1; min-width: 120px; margin-left: 4px;
  font-size: 11px; color: #94a3b8; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.sd-empty, .sd-loading {
  grid-column: 1 / -1;
  text-align: center; padding: 56px 16px; color: #64748b; font-size: 14px;
}
.sd-spinner {
  width: 40px; height: 40px; margin: 0 auto 12px; position: relative;
}
.sd-spinner::before, .sd-spinner::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  border: 3px solid #e2e8f0;
}
.sd-spinner::after {
  border-color: #4f46e5 transparent transparent transparent;
  animation: sd-spin 0.8s linear infinite;
}
@keyframes sd-spin { to { transform: rotate(360deg); } }

.sd-placeholder {
  margin: 40px auto; max-width: 420px; text-align: center; padding: 32px 20px;
  background: #fff; border: 1px solid #e2e8f0; border-radius: 16px;
}
.sd-placeholder h3 { margin: 0 0 8px; font-size: 18px; color: #0f172a; }
.sd-placeholder p { margin: 0 0 16px; font-size: 13.5px; color: #64748b; line-height: 1.7; }

.sd-panel { display: none; flex: 1; min-width: 0; flex-direction: column; background: #f8fafc; }
.sd-panel.is-show { display: flex; }
.sd-list-layout { display: flex; flex: 1; min-height: 0; }
.sd-mylist {
  width: 240px; background: #fff; border-right: 1px solid #e2e8f0;
  padding: 14px; display: flex; flex-direction: column; gap: 10px;
}
.sd-mylist-create {
  width: 100%; height: 38px; border-radius: 10px; border: 0;
  background: #0f172a; color: #fff; font-weight: 700; font-size: 12.5px; cursor: pointer;
}
.sd-mylist-item {
  border: 1px solid #e2e8f0; border-radius: 10px; padding: 12px; background: #fff; cursor: pointer;
}
.sd-mylist-item.is-on { border-color: #818cf8; background: #eef2ff; }
.sd-mylist-item strong { display: block; font-size: 13px; margin-bottom: 4px; }
.sd-mylist-item span { font-size: 11px; color: #64748b; line-height: 1.5; }
.sd-list-main { flex: 1; padding: 14px 16px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.sd-table-wrap {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; overflow: auto; flex: 1;
}
.sd-table-wrap table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.sd-table-wrap th {
  text-align: left; background: #f8fafc; padding: 11px 12px; color: #64748b;
  font-weight: 700; border-bottom: 1px solid #e2e8f0; font-size: 11px;
}
.sd-table-wrap td { padding: 12px; border-bottom: 1px solid #f1f5f9; }
.sd-table-wrap td.m { color: #64748b; }

.sd-toast {
  position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%) translateY(10px);
  background: #0f172a; color: #fff; padding: 10px 16px; border-radius: 999px;
  font-size: 13px; font-weight: 700; opacity: 0; pointer-events: none;
  transition: 0.25s ease; z-index: 8; box-shadow: 0 12px 28px rgba(0,0,0,0.2);
}
.sd-toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

.sd-modal {
  position: absolute; inset: 0; background: rgba(15,23,42,0.5);
  display: grid; place-items: center; z-index: 10; padding: 20px;
  backdrop-filter: blur(3px);
}
.sd-modal[hidden] { display: none !important; }
.sd-modal-card {
  background: #fff; border-radius: 16px; padding: 24px; max-width: 380px; width: 100%;
  text-align: center; box-shadow: 0 24px 60px rgba(0,0,0,0.25);
}
.sd-modal-mark {
  width: 48px; height: 48px; margin: 0 auto 12px; border-radius: 50%;
  background: #eef2ff; color: #4f46e5; display: grid; place-items: center;
  font-size: 22px; font-weight: 900;
}
.sd-modal-card h3 { margin: 0 0 8px; font-size: 20px; }
.sd-modal-card p { margin: 0 0 16px; font-size: 13.5px; line-height: 1.7; color: #64748b; }
.sd-modal-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

.crm-add-card { text-align: left; max-width: 440px; }
.crm-add-title { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.crm-add-title h3 { margin: 0; font-size: 18px; color: #0f172a; }
.crm-add-ico {
  width: 28px; height: 28px; border-radius: 8px; background: #FFEDE7; color: #FF7A59;
  display: grid; place-items: center;
}
.crm-add-lead { margin: 0 0 14px !important; font-size: 13px !important; color: #64748b !important; line-height: 1.6 !important; }
.crm-add-summary {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 14px;
}
.crm-add-summary > div {
  background: #EAF0F6; border-radius: 10px; padding: 10px 12px;
}
.crm-add-summary .k { font-size: 11px; color: #7C98B6; font-weight: 700; }
.crm-add-summary .v { font-size: 18px; font-weight: 800; color: #2D3E50; margin-top: 2px; }
.crm-add-skip { background: #f8fafc; }

@media (max-width: 900px) {
  .sd-body { flex-direction: column; }
  .sd-side { width: 100%; border-right: 0; border-bottom: 1px solid #e2e8f0; max-height: 280px; }
  .sd-list-layout { flex-direction: column; }
  .sd-mylist { width: 100%; border-right: 0; border-bottom: 1px solid #e2e8f0; }
  .sd-nav-btn { font-size: 12px; padding: 6px 8px; }
}


/* ===== CRM shell (production-like rebuild) ===== */
.crm-shell {
  display: flex;
  min-height: 640px;
  height: 640px;
  background: #F5F8FA;
  position: relative;
}
.crm-nav {
  width: 240px;
  flex-shrink: 0;
  background: #1B2A3A;
  color: rgba(255,255,255,0.75);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-right: 1px solid rgba(255,255,255,0.06);
}
.crm-nav-brand {
  display: flex; align-items: center; gap: 10px;
  color: #fff; font-weight: 800; font-size: 14px;
  height: 56px; padding: 0 16px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}
.crm-nav-brand-sq {
  width: 32px; height: 32px; border-radius: 8px;
  background: #FF7A59; color: #fff;
  display: grid; place-items: center; flex-shrink: 0;
}
.crm-nav-list {
  flex: 1; overflow: auto; padding: 8px;
  display: flex; flex-direction: column; gap: 2px;
}
.crm-nav-item {
  border: 0; background: transparent; color: rgba(255,255,255,0.75);
  text-align: left; padding: 10px 12px; border-radius: 8px;
  font-size: 13px; font-weight: 600; cursor: pointer;
  display: flex; align-items: center; gap: 12px;
  transition: background .15s, color .15s;
}
.crm-nav-item svg { flex-shrink: 0; opacity: 0.55; }
.crm-nav-item:hover { background: rgba(255,255,255,0.1); color: #fff; }
.crm-nav-item:hover svg { opacity: 1; }
.crm-nav-item.is-on {
  background: #FF7A59; color: #fff;
  box-shadow: 0 6px 16px rgba(255,122,89,0.28);
}
.crm-nav-item.is-on svg { opacity: 1; color: #fff; }
.crm-nav-foot {
  display: grid; gap: 8px; margin-top: auto;
  padding: 12px 16px; border-top: 1px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}
.crm-nav-foot-btn {
  width: 100%; text-align: center; border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.8);
  border-radius: 8px; padding: 9px 10px; font-size: 11.5px; font-weight: 600; cursor: pointer; line-height: 1.4;
}
.crm-nav-foot-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }

.crm-content { flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; background: #F5F8FA; }
.crm-page { display: none; flex: 1; flex-direction: column; padding: 0; overflow: auto; }
.crm-page.is-show { display: flex; }
.crm-page[hidden] { display: none !important; }
.crm-page-body { padding: 16px 20px 24px; }
.crm-page-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 12px; margin-bottom: 14px; padding: 16px 20px 0;
  flex-wrap: wrap;
}
.crm-page[data-crm-view="pipeline"] .crm-page-head { padding-top: 16px; }
.crm-page-head h2, .crm-white-head h2 { margin: 0; font-size: 22px; font-weight: 800; color: #2D3E50; letter-spacing: -0.02em; }
.crm-page-head p, .crm-white-head p { margin: 4px 0 0; font-size: 12.5px; color: #7C98B6; }
.crm-white-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 12px; flex-wrap: wrap;
  background: #fff; border-bottom: 1px solid #CBD6E2;
  padding: 18px 20px; flex-shrink: 0;
}
.crm-h-ico { display: flex; align-items: center; gap: 8px; }
.crm-head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.crm-card-block {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px;
  padding: 0; margin-bottom: 14px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-card-block > h3, .crm-card-block-h {
  padding: 12px 16px; border-bottom: 1px solid #EAF0F6;
  margin: 0; font-size: 13px; font-weight: 800; color: #2D3E50;
}
.crm-card-block-h {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.crm-card-block-h h3 { margin: 0; font-size: 13px; font-weight: 800; display: flex; align-items: center; gap: 6px; }
.crm-card-block > .crm-exec-grid,
.crm-card-block > .crm-funnel-in,
.crm-card-block > .sd-table-wrap,
.crm-card-block > .crm-outcome-tabs { }
.crm-card-block .crm-exec-grid { padding: 16px; }
.crm-card-block .crm-upload,
.crm-card-block .crm-textarea,
.crm-card-block .sd-select,
.crm-card-block .sd-label,
.crm-card-block .crm-hint,
.crm-card-block .crm-history { margin-left: 16px; margin-right: 16px; }
.crm-card-block .crm-upload { margin-top: 12px; }
.crm-card-block .sd-label:first-of-type { margin-top: 12px; }
.crm-card-block .crm-hint { margin-bottom: 14px; }
.crm-card-block .crm-history { margin-bottom: 14px; }
.crm-ico-orange { color: #FF7A59; }
.crm-text-link {
  border: 0; background: transparent; color: #FF7A59;
  font-size: 11.5px; font-weight: 800; cursor: pointer;
}
.crm-text-link:hover { text-decoration: underline; }
.crm-mini { font-size: 11px; color: #7C98B6; margin: 2px 0 0; font-weight: 500; }
.crm-count-pill {
  font-size: 10px; font-weight: 800; background: #EAF0F6; color: #7C98B6;
  padding: 2px 8px; border-radius: 999px;
}

.crm-exec-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px;
}
.crm-exec-kpi {
  background: rgba(234,240,246,0.45); border: 1px solid #CBD6E2;
  border-radius: 10px; padding: 14px;
}
.crm-exec-kpi .k { font-size: 10px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; color: #7C98B6; }
.crm-exec-kpi .v { font-size: 20px; font-weight: 800; color: #2D3E50; margin-top: 4px; }
.crm-exec-kpi .t { font-size: 11px; color: #7C98B6; margin-top: 2px; }
.crm-exec-kpi .a { font-size: 12px; font-weight: 800; margin-top: 8px; }
.crm-exec-kpi .a.ok { color: #00BDA5; }
.crm-exec-kpi .a.mid { color: #FF7A59; }
.crm-exec-kpi .a.bad { color: #dc2626; }

.crm-funnel {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px;
  padding: 14px; margin-bottom: 14px;
}
.crm-funnel-in {
  border: 0; border-top: 1px solid #EAF0F6; border-radius: 0; margin: 0;
  background: transparent;
}
.crm-funnel-title { font-size: 11px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #7C98B6; margin-bottom: 10px; }
.crm-funnel-row { display: flex; flex-wrap: wrap; gap: 6px; }
.crm-funnel-chip {
  font-size: 11.5px; font-weight: 700; padding: 6px 10px; border-radius: 8px;
  background: #EAF0F6; color: #33475B; border: 1px solid #CBD6E2;
}
.crm-funnel-steps {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px;
}
.crm-funnel-step {
  background: #EAF0F6; border-radius: 10px; padding: 12px; text-align: center;
}
.crm-funnel-step span { display: block; font-size: 11px; font-weight: 700; color: #7C98B6; }
.crm-funnel-step strong { display: block; font-size: 20px; font-weight: 800; color: #2D3E50; margin-top: 4px; }

.crm-action-queue {
  border: 1px solid rgba(0,189,165,0.35); background: rgba(228,245,241,0.35);
  border-radius: 12px; padding: 14px 16px; margin-bottom: 14px;
}
.crm-action-queue.empty {
  border-color: rgba(0,189,165,0.3); color: #516F90; font-size: 13px;
}
.crm-action-queue .aq-h { font-size: 12.5px; font-weight: 800; color: #2D3E50; margin-bottom: 8px; }
.crm-action-item {
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
  padding: 8px 0; border-top: 1px solid rgba(203,214,226,0.6); cursor: pointer;
}
.crm-action-item:first-of-type { border-top: 0; }
.crm-action-item .name { font-size: 13px; font-weight: 800; color: #2D3E50; }
.crm-action-item .sub { font-size: 11px; color: #7C98B6; }
.crm-action-item .tag { font-size: 10px; font-weight: 800; padding: 3px 7px; border-radius: 6px; background: #FFEDE7; color: #EA6A4A; }

.crm-quick-links {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 14px;
}
.crm-ql {
  border: 1px solid #CBD6E2; background: #fff; border-radius: 10px;
  padding: 12px; text-align: left; cursor: pointer;
  font-size: 12px; font-weight: 800; color: #2D3E50;
  display: flex; align-items: center; gap: 8px;
}
.crm-ql:hover { border-color: #FF7A59; background: #FFF8F6; }
.crm-ql span { font-size: 16px; }

.crm-stat-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px;
}
.crm-stat {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 14px;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-stat .k { display: block; font-size: 11px; color: #7C98B6; font-weight: 700; }
.crm-stat strong { font-size: 20px; color: #2D3E50; }
.crm-stat .sub { display: block; font-size: 11px; color: #7C98B6; margin-top: 4px; }
.crm-stat.bad strong { color: #dc2626; }

.crm-dash-2col {
  display: grid; grid-template-columns: 1fr 1fr; gap: 14px;
}
.crm-stage-list { list-style: none; margin: 0; padding: 8px 0 12px; }
.crm-stage-list li {
  display: flex; justify-content: space-between; padding: 8px 16px;
  font-size: 13px; font-weight: 700; color: #33475B; cursor: pointer;
}
.crm-stage-list li:hover { background: #F5F8FA; }
.crm-stage-list .n { font-weight: 800; color: #2D3E50; }

.crm-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(140px, 1fr));
  gap: 8px;
  overflow-x: auto;
  padding: 0 16px 16px;
  flex: 1;
  align-content: start;
}
.crm-col {
  background: rgba(234,240,246,0.6);
  border-radius: 12px;
  padding: 8px;
  min-height: 320px;
  border: 1px solid #CBD6E2;
  transition: border-color 0.15s, background 0.15s;
}
.crm-col.is-over { border-color: #FF7A59; background: rgba(255,237,231,0.4); }
.crm-col-h {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 6px; padding: 4px 2px 10px;
}
.crm-col-h .dot {
  width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px;
}
.crm-col-h strong { font-size: 12px; color: #2D3E50; display: block; }
.crm-col-h .amt { font-size: 10.5px; color: #7C98B6; font-weight: 600; margin-top: 3px; }
.crm-col-h .cnt {
  font-size: 11px; font-weight: 800; background: #fff; color: #516F90;
  padding: 2px 7px; border-radius: 999px; border: 1px solid #CBD6E2;
}
.crm-deal {
  background: #fff;
  border: 1px solid #CBD6E2;
  border-radius: 12px;
  padding: 11px;
  margin-bottom: 8px;
  cursor: grab;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-deal:active { cursor: grabbing; }
.crm-deal:hover { box-shadow: 0 8px 18px rgba(45,62,80,0.1); }
.crm-deal.is-dragging { opacity: 0.45; }
.crm-deal .dn { font-size: 13px; font-weight: 800; color: #2D3E50; margin-bottom: 6px; }
.crm-deal .meta { font-size: 11.5px; color: #7C98B6; margin-top: 3px; }
.crm-deal .yen { font-size: 12px; font-weight: 800; color: #2D3E50; margin-top: 6px; }
.crm-deal .badge {
  display: inline-block; margin-top: 8px; font-size: 10.5px; font-weight: 800;
  padding: 3px 7px; border-radius: 6px; background: #E4F5F1; color: #008F7A;
}
.crm-deal .hot {
  display: inline-block; margin-left: 6px; font-size: 9px; font-weight: 900;
  padding: 2px 5px; border-radius: 4px; background: #E4F5F1; color: #008F7A; vertical-align: middle;
}
.crm-deal.is-overdue { border-color: #fecaca; box-shadow: 0 0 0 1px rgba(239,68,68,0.12); }
.crm-deal .due.bad { color: #dc2626; font-weight: 700; }
.crm-col-empty {
  border: 1px dashed #CBD6E2; border-radius: 10px; padding: 18px 8px;
  text-align: center; color: #7C98B6; font-size: 11.5px; margin-top: 4px;
}

.crm-kpi-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px;
}
.crm-kpi-5 { grid-template-columns: repeat(5, 1fr); }
.crm-kpi {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 14px;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-kpi .k { font-size: 11.5px; color: #7C98B6; font-weight: 700; }
.crm-kpi .v { font-size: 22px; font-weight: 800; color: #2D3E50; margin-top: 4px; }
.crm-kpi .goal { font-size: 11px; color: #7C98B6; margin-top: 6px; font-weight: 600; }
.crm-kpi.accent-blue { border-top: 3px solid #2563eb; }
.crm-kpi.accent-teal { border-top: 3px solid #00BDA5; }
.crm-kpi.accent-orange { border-top: 3px solid #FF7A59; }

.crm-sec { margin-bottom: 14px; overflow: hidden; border-radius: 12px; border: 1px solid #CBD6E2; background: #fff; box-shadow: 0 1px 2px rgba(45,62,80,0.04); }
.crm-sec-h {
  font-size: 13px; font-weight: 800; padding: 12px 16px;
  border-bottom: 1px solid #EAF0F6;
  display: flex; align-items: center; gap: 8px;
}
.crm-sec-h.over { color: #dc2626; background: #fef2f2; }
.crm-sec-h.today { color: #FF7A59; background: #FFF8F6; }
.crm-sec-h.hot { color: #008F7A; background: #E4F5F1; }
.crm-sec-h.soon { color: #2D3E50; }
.crm-sec-desc { font-size: 11px; font-weight: 500; color: #7C98B6; margin-left: auto; }
.crm-row {
  background: #fff; border: 0; border-bottom: 1px solid #EAF0F6;
  padding: 12px 16px; cursor: pointer;
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
}
.crm-row:last-child { border-bottom: 0; }
.crm-row:hover { background: #F5F8FA; }
.crm-row .name { font-size: 13.5px; font-weight: 800; color: #2D3E50; }
.crm-row .sub { font-size: 11.5px; color: #7C98B6; margin-top: 3px; }
.crm-stage-pill {
  font-size: 11px; font-weight: 800; padding: 4px 8px; border-radius: 999px;
  background: #EAF0F6; color: #33475B; white-space: nowrap;
}

.crm-owner-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-left: auto; }
.crm-owner-chips button {
  border: 1px solid #CBD6E2; background: #fff; color: #33475B;
  border-radius: 999px; padding: 6px 10px; font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.crm-owner-chips button.is-on { background: #FF7A59; border-color: #FF7A59; color: #fff; }

.crm-nba {
  background: linear-gradient(135deg, #FFF8F6, #fff);
  border: 1px solid #FFD5C8; border-radius: 12px; padding: 14px 16px; margin-bottom: 16px;
}
.crm-nba strong { display: block; color: #FF7A59; font-size: 12.5px; margin-bottom: 6px; }
.crm-nba p { margin: 0; font-size: 13px; color: #33475B; line-height: 1.6; }
.crm-nba-list { display: grid; gap: 8px; margin-top: 8px; }
.crm-nba-item {
  display: flex; justify-content: space-between; gap: 8px; align-items: center;
  background: #fff; border: 1px solid #FFD5C8; border-radius: 8px; padding: 10px 12px;
  cursor: pointer; text-align: left; width: 100%;
}
.crm-nba-item:hover { border-color: #FF7A59; }
.crm-nba-item strong { color: #2D3E50; font-size: 13px; margin: 0; }
.crm-nba-item span { font-size: 11px; color: #7C98B6; }

.crm-today-body { max-width: 720px; margin: 0 auto; width: 100%; }

/* Companies split */
.crm-co-layout { display: flex; flex: 1; min-height: 0; overflow: hidden; }
.crm-co-main { flex: 1; min-width: 0; overflow: auto; display: flex; flex-direction: column; }
.crm-co-detail {
  width: 0; overflow: hidden; background: #fff; display: flex; flex-direction: column;
  border-left: 0 solid #CBD6E2; flex-shrink: 0; transition: width .2s ease;
}
.crm-co-detail[hidden] { display: none !important; }
.crm-co-layout.is-detail .crm-co-detail {
  display: flex; width: min(380px, 42%); border-left-width: 1px;
}
.crm-co-head { align-items: flex-end; }
.crm-co-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.crm-search-wrap {
  position: relative; min-width: 180px;
}
.crm-search-wrap svg {
  position: absolute; left: 10px; top: 50%; transform: translateY(-50%); color: #7C98B6;
}
.crm-search-wrap .sd-input { padding-left: 32px; height: 36px; }
.crm-box-bar {
  background: linear-gradient(90deg, #EAF0F6, #fff 40%, rgba(255,237,231,0.35));
  border-bottom: 1px solid #CBD6E2; padding: 12px 16px;
}
.crm-box-kinds { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; }
.crm-box-label { font-size: 10px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #7C98B6; }
.crm-box-kinds button {
  border: 1px solid #CBD6E2; background: #fff; color: #516F90;
  border-radius: 8px; padding: 6px 12px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.crm-box-kinds button.is-on { background: #2D3E50; border-color: #2D3E50; color: #fff; }
.crm-box-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.crm-box-chips button {
  border: 1px solid #CBD6E2; background: #fff; color: #33475B;
  border-radius: 999px; padding: 5px 12px; font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.crm-box-chips button em { font-style: normal; opacity: 0.75; margin-left: 2px; }
.crm-box-chips button.is-on { background: #FF7A59; border-color: #FF7A59; color: #fff; }
.crm-box-kpis {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px;
  padding: 12px 16px; background: #fff; border-bottom: 1px solid #EAF0F6;
}
.crm-box-kpi {
  background: #EAF0F6; border-radius: 10px; padding: 10px 12px;
}
.crm-box-kpi .k { display: block; font-size: 10.5px; color: #7C98B6; font-weight: 700; }
.crm-box-kpi strong { font-size: 18px; color: #2D3E50; }
.crm-co-table-wrap { flex: 1; margin: 0; border-radius: 0; border: 0; }
.crm-co-table-wrap table { min-width: 640px; }
.crm-co-table-wrap tbody tr { cursor: pointer; }
.crm-co-table-wrap tbody tr:hover td { background: #FFF8F6; }
.crm-co-detail-h {
  background: #fff; border-bottom: 1px solid #CBD6E2; padding: 14px 16px;
}
.crm-co-detail-h h3 { margin: 8px 0 4px; font-size: 18px; color: #2D3E50; }
.crm-co-detail-h p { margin: 0; font-size: 12px; color: #7C98B6; }
.crm-co-detail-tabs {
  display: flex; gap: 4px; padding: 8px 12px; background: #fff; border-bottom: 1px solid #EAF0F6;
}
.crm-co-detail-tabs button {
  border: 0; background: transparent; color: #7C98B6;
  border-radius: 8px; padding: 7px 12px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.crm-co-detail-tabs button.is-on { background: #EAF0F6; color: #2D3E50; }
.crm-co-detail-body { padding: 16px; }
.crm-co-kv { display: grid; grid-template-columns: 100px 1fr; gap: 8px 12px; font-size: 13px; }
.crm-co-kv .k { color: #7C98B6; font-weight: 700; }
.crm-co-kv .v { color: #2D3E50; font-weight: 700; }

/* Prep */
.crm-prep-page { display: flex; flex-direction: column; min-height: 100%; background: rgba(234,240,246,0.35); }
.crm-prep-sticky {
  position: sticky; top: 0; z-index: 3;
  background: rgba(255,255,255,0.95); backdrop-filter: blur(8px);
  border-bottom: 1px solid #CBD6E2; padding: 12px 16px;
}
.crm-prep-sticky-top {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px;
}
.crm-prep-title { display: flex; align-items: center; gap: 10px; }
.crm-prep-title h2 { margin: 0; font-size: 16px; font-weight: 800; color: #2D3E50; }
.crm-prep-title p { margin: 2px 0 0; font-size: 11.5px; color: #7C98B6; }
.crm-prep-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.crm-pill-tabs {
  display: flex; gap: 4px; margin-top: 12px;
  background: #EAF0F6; border-radius: 12px; padding: 4px;
}
.crm-pill-tabs button {
  flex: 1; border: 0; background: transparent; color: #7C98B6;
  border-radius: 8px; padding: 8px 6px; font-size: 11.5px; font-weight: 800; cursor: pointer;
  min-width: 0;
}
.crm-pill-tabs button.is-on { background: #fff; color: #2D3E50; box-shadow: 0 1px 3px rgba(45,62,80,0.08); }
.crm-prep-body { display: flex; flex: 1; min-height: 0; }
.crm-prep-side {
  width: 240px; flex-shrink: 0; background: #fff;
  border-right: 1px solid #CBD6E2; padding: 14px; overflow: auto;
}
.crm-prep-group {
  display: flex; gap: 4px; background: #EAF0F6; border-radius: 8px; padding: 3px; margin-bottom: 12px;
}
.crm-prep-group button {
  flex: 1; border: 0; background: transparent; color: #7C98B6;
  border-radius: 6px; padding: 6px; font-size: 10px; font-weight: 800; cursor: pointer;
}
.crm-prep-group button.is-on { background: #2D3E50; color: #fff; }
.crm-prep-group-label {
  font-size: 10px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase;
  color: #7C98B6; margin: 10px 0 4px;
}
.crm-prep-list .crm-side-item {
  width: 100%; text-align: left; margin-bottom: 6px;
  background: #EAF0F6; border: 0; border-radius: 8px; padding: 10px 12px; cursor: pointer;
}
.crm-prep-list .crm-side-item.is-on { background: #FF7A59; color: #fff; }
.crm-prep-list .crm-side-item.is-on strong,
.crm-prep-list .crm-side-item.is-on span { color: #fff; }
.crm-side-item strong { display: block; font-size: 12.5px; color: #2D3E50; margin-bottom: 2px; }
.crm-side-item span { font-size: 10.5px; color: #7C98B6; }
.crm-prep-main { flex: 1; min-width: 0; padding: 16px; overflow: auto; }
.crm-prep-panel[hidden] { display: none !important; }
.crm-prep-panel.is-show { display: block; }
.crm-editor { background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 16px; }
.crm-textarea {
  width: 100%; min-height: 140px; border: 1px solid #CBD6E2; border-radius: 8px;
  padding: 10px; font-size: 13px; line-height: 1.6; resize: vertical; color: #33475B; background: #F5F8FA;
  box-sizing: border-box;
}
.crm-hint { font-size: 12px; color: #7C98B6; margin-top: 8px; line-height: 1.5; }
.crm-field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.crm-chip-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.crm-chip-row span {
  font-size: 12px; font-weight: 700; padding: 6px 12px; border-radius: 999px;
  background: #EAF0F6; color: #516F90; border: 1px solid #CBD6E2;
}
.crm-chip-row span.is-on { background: #FF7A59; border-color: #FF7A59; color: #fff; }
.crm-plot-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.crm-plot-tabs button {
  border: 1px solid #CBD6E2; background: #fff; color: #516F90;
  border-radius: 8px; padding: 6px 10px; font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.crm-plot-tabs button.is-on { background: #2D3E50; border-color: #2D3E50; color: #fff; }
.crm-call-view { background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 18px; }
.crm-call-n { font-size: 11px; font-weight: 800; color: #FF7A59; }
.crm-call-step h3 { margin: 6px 0 10px; font-size: 18px; color: #2D3E50; }
.crm-call-step p { margin: 0; font-size: 14px; line-height: 1.7; color: #33475B; }
.crm-call-nav { display: flex; gap: 8px; margin: 16px 0; }
.crm-call-branch {
  border-top: 1px solid #EAF0F6; padding-top: 14px; display: grid; gap: 8px;
}
.crm-call-branch strong { font-size: 12px; color: #7C98B6; }
.crm-call-branch button {
  text-align: left; border: 1px solid #CBD6E2; background: #F5F8FA;
  border-radius: 8px; padding: 10px 12px; font-size: 12.5px; font-weight: 700;
  color: #2D3E50; cursor: pointer;
}

/* Analytics toolbar / teleapo / share */
.crm-analytics-head { padding: 0; margin-bottom: 14px; }
.crm-analytics-toolbar {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
}
.crm-analytics-toolbar button[data-period] {
  border: 1px solid #CBD6E2; background: #fff; color: #516F90;
  border-radius: 8px; padding: 6px 10px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.crm-analytics-toolbar button[data-period].is-on { background: #2D3E50; border-color: #2D3E50; color: #fff; }
.crm-outcome-tabs {
  display: flex; flex-wrap: wrap; gap: 4px;
  padding: 10px 12px; background: rgba(234,240,246,0.55); border-bottom: 1px solid #CBD6E2;
}
.crm-outcome-tabs button {
  border: 1px solid #CBD6E2; background: #fff; color: #516F90;
  border-radius: 6px; padding: 6px 10px; font-size: 11.5px; font-weight: 700; cursor: pointer;
}
.crm-outcome-tabs button em { font-style: normal; margin-left: 4px; color: #7C98B6; }
.crm-outcome-tabs button.is-on { background: #FF7A59; border-color: #FF7A59; color: #fff; }
.crm-outcome-tabs button.is-on em { color: rgba(255,255,255,0.9); }
.sd-table-wrap .r, .sd-table-wrap th.r, .sd-table-wrap td.r { text-align: right; }

.crm-share-actions {
  display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: end;
  margin-bottom: 14px; background: #fff; border: 1px solid #CBD6E2;
  border-radius: 12px; padding: 14px;
}
.crm-share-dl { display: flex; flex-wrap: wrap; gap: 8px; }
.crm-jp-tabs {
  display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px;
  background: #EAF0F6; border-radius: 10px; padding: 4px;
}
.crm-jp-tabs button {
  border: 0; background: transparent; color: #516F90;
  border-radius: 7px; padding: 7px 12px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.crm-jp-tabs button.is-on { background: #fff; color: #2D3E50; box-shadow: 0 1px 2px rgba(45,62,80,0.08); }

/* Meetings */
.crm-meet-grid {
  display: grid; grid-template-columns: minmax(0,1fr) 300px; gap: 16px;
  padding: 16px 20px 24px; max-width: 1100px;
}
.crm-meet-main { display: grid; gap: 14px; align-content: start; }
.crm-meet-side { align-content: start; }
.crm-meet-hist .crm-mini { padding: 0 16px 8px; margin: 0; border-bottom: 1px solid #EAF0F6; }
.crm-hist-item {
  width: 100%; text-align: left; border: 0; border-bottom: 1px solid #EAF0F6;
  background: #fff; padding: 12px 14px; cursor: pointer;
  display: flex; flex-direction: column; gap: 4px;
}
.crm-hist-item:hover { background: #F5F8FA; }
.crm-hist-item strong { font-size: 13px; color: #2D3E50; }
.crm-hist-item span { font-size: 11px; color: #7C98B6; }
.crm-upload {
  border: 2px dashed #CBD6E2; border-radius: 14px; background: #F5F8FA;
  padding: 28px 16px; text-align: center; margin-bottom: 12px;
}
.crm-upload strong { display: block; font-size: 14px; color: #2D3E50; margin-bottom: 6px; }
.crm-upload span { font-size: 12px; color: #7C98B6; }

/* Reports */
.crm-month-nav {
  display: flex; align-items: center; gap: 0;
  border: 1px solid #CBD6E2; border-radius: 8px; overflow: hidden; background: #fff;
}
.crm-month-nav button {
  width: 32px; height: 34px; border: 0; background: #fff; cursor: pointer;
  font-weight: 800; color: #33475B;
}
.crm-month-nav button:hover { background: #F5F8FA; }
.crm-month-nav strong {
  min-width: 110px; text-align: center; font-size: 13px; color: #2D3E50;
  padding: 0 8px; border-left: 1px solid #EAF0F6; border-right: 1px solid #EAF0F6;
}
.crm-report-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.crm-report-card {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 16px;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-report-card .t { font-size: 12px; color: #7C98B6; font-weight: 700; }
.crm-report-card .n { font-size: 26px; font-weight: 800; color: #2D3E50; margin: 6px 0; }
.crm-report-card .d { font-size: 12px; color: #00BDA5; font-weight: 700; }
.crm-report-card .bar {
  height: 6px; background: #EAF0F6; border-radius: 999px; overflow: hidden; margin: 8px 0 6px;
}
.crm-report-card .bar > i { display: block; height: 100%; background: #FF7A59; border-radius: 999px; }

/* Form / Emails / LP */
.crm-form-tabs { margin-bottom: 14px; }
.crm-form-panel[hidden], .crm-email-panel[hidden] { display: none !important; }
.crm-form-panel.is-show, .crm-email-panel.is-show { display: block; }
.crm-campaign { display: grid; gap: 10px; }
.crm-camp-card {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 14px;
}
.crm-camp-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-bottom: 8px; }
.crm-camp-card strong { display: block; font-size: 14px; color: #2D3E50; }
.crm-camp-card span { font-size: 12px; color: #7C98B6; }
.crm-progress {
  height: 8px; background: #EAF0F6; border-radius: 999px; overflow: hidden; margin-bottom: 8px;
}
.crm-progress > i { display: block; height: 100%; background: #FF7A59; }
.crm-badge-run {
  font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 999px;
  background: #E4F5F1; color: #008F7A;
}
.crm-badge-done {
  font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 999px;
  background: #EAF0F6; color: #516F90;
}
.crm-badge-warn {
  font-size: 10px; font-weight: 800; padding: 3px 8px; border-radius: 999px;
  background: #fff7ed; color: #c2410c;
}

.crm-navy-tabs {
  display: flex; gap: 4px; margin-bottom: 14px;
  background: #EAF0F6; border-radius: 10px; padding: 4px; width: fit-content;
}
.crm-navy-tabs button {
  border: 0; background: transparent; color: #7C98B6;
  border-radius: 7px; padding: 8px 16px; font-size: 13px; font-weight: 800; cursor: pointer;
}
.crm-navy-tabs button.is-on { background: #2D3E50; color: #fff; }

.crm-mail-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.crm-mail-card {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 12px; padding: 14px;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.crm-mail-card strong { display: block; font-size: 13.5px; color: #2D3E50; margin-bottom: 6px; }
.crm-mail-card p { margin: 0; font-size: 12.5px; color: #7C98B6; line-height: 1.5; }
.crm-mail-meta { display: block; margin-top: 10px; font-size: 11px; color: #516F90; font-weight: 600; }

.crm-lp-layout {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px; min-height: 360px;
}
.crm-lp-preview {
  background: linear-gradient(160deg, #EAF0F6, #dfe8f1);
  border-radius: 12px; padding: 20px; display: grid; place-items: center;
  border: 1px solid #CBD6E2;
}
.crm-lp-frame {
  width: 100%; max-width: 340px;
}
.crm-lp-card {
  background: #fff; border-radius: 12px; padding: 28px 22px; width: 100%;
  box-shadow: 0 12px 32px rgba(45,62,80,0.12); text-align: center;
}
.crm-lp-brand { font-weight: 900; color: #2D3E50; margin-bottom: 12px; letter-spacing: -0.02em; }
.crm-lp-card h3 { margin: 0 0 8px; font-size: 18px; color: #2D3E50; }
.crm-lp-card p { margin: 0 0 16px; font-size: 13px; color: #7C98B6; line-height: 1.5; }
.crm-lp-cta {
  display: inline-block; background: #FF7A59; color: #fff; font-weight: 800;
  padding: 10px 16px; border-radius: 8px; font-size: 13px;
}

.crm-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11px; font-weight: 800; color: #EA6A4A;
  background: #FFEDE7; padding: 4px 10px; border-radius: 999px; margin-bottom: 8px;
  border: 1px solid rgba(255,122,89,0.25);
}

.crm-drawer {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(360px, 92%);
  background: #fff; border-left: 1px solid #CBD6E2;
  box-shadow: -16px 0 40px rgba(45,62,80,0.12);
  z-index: 7; display: flex; flex-direction: column;
}
.crm-drawer[hidden] { display: none !important; }
.crm-drawer-head {
  padding: 16px; border-bottom: 1px solid #EAF0F6;
  display: flex; justify-content: space-between; gap: 10px; align-items: flex-start;
}
.crm-drawer-kicker { font-size: 11px; color: #FF7A59; font-weight: 800; margin-bottom: 4px; }
.crm-drawer-head h3 { margin: 0; font-size: 18px; color: #2D3E50; }
.crm-drawer-head p { margin: 4px 0 0; font-size: 12px; color: #7C98B6; }
.crm-drawer-body { padding: 16px; overflow: auto; }
.crm-quick-logs { margin-top: 16px; }
.crm-quick-row { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.crm-quick-row button {
  border: 1px solid #CBD6E2; background: #F5F8FA; color: #33475B;
  border-radius: 8px; padding: 7px 10px; font-size: 12px; font-weight: 700; cursor: pointer;
}
.crm-quick-row button:hover { border-color: #FF7A59; color: #FF7A59; }

.crm-iframe {
  display: block;
  width: 100%;
  height: min(920px, 90vh);
  min-height: 720px;
  border: 0;
  background: #F5F8FA;
  border-radius: 0 0 12px 12px;
}
.sd-panel[data-try-view="crm"] {
  padding: 0 !important;
  position: relative;
  background: #F5F8FA;
  overflow: hidden;
}

@media (max-width: 900px) {
  .crm-shell { flex-direction: column; height: auto; min-height: 0; }
  .crm-nav { width: 100%; max-height: 200px; }
  .crm-nav-list { flex-direction: row; flex-wrap: wrap; }
  .crm-nav-item span { display: none; }
  .crm-nav-item { padding: 8px; }
  .crm-board { grid-template-columns: repeat(3, minmax(150px, 1fr)); }
  .crm-kpi-grid, .crm-report-grid, .crm-exec-grid, .crm-stat-row, .crm-quick-links, .crm-box-kpis, .crm-kpi-5, .crm-mail-grid, .crm-dash-2col, .crm-lp-layout, .crm-meet-grid, .crm-funnel-steps, .crm-share-actions, .crm-field-grid { grid-template-columns: 1fr 1fr; }
  .crm-prep-body { flex-direction: column; }
  .crm-prep-side { width: 100%; border-right: 0; border-bottom: 1px solid #CBD6E2; max-height: 200px; }
  .crm-co-layout.is-detail .crm-co-main { display: none; }
  .crm-co-layout.is-detail .crm-co-detail { width: 100%; border-left: 0; }
}
@media (max-width: 560px) {
  .crm-board { grid-template-columns: 1fr 1fr; }
  .crm-kpi-grid, .crm-report-grid, .crm-exec-grid, .crm-stat-row, .crm-quick-links, .crm-box-kpis, .crm-kpi-5, .crm-mail-grid, .crm-dash-2col, .crm-lp-layout, .crm-meet-grid, .crm-funnel-steps, .crm-share-actions, .crm-field-grid { grid-template-columns: 1fr; }
}

/* ===== Sheet views (求人 / PR / IG / 補助金) ===== */
.sd-sheet-view {
  display: none;
  flex-direction: row;
  min-height: 620px;
  background: #f8fafc;
}
.sd-sheet-view.is-show { display: flex; }
.sd-side-sm { width: 260px; }
.sd-side-md { width: 280px; }
.sd-side-ico.blue { background: #eff6ff; color: #2563eb; }
.sd-side-ico.pink { background: #fdf2f8; color: #db2777; }
.sd-side-ico.amber { background: #fffbeb; color: #d97706; }

.sd-sheet-head {
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
  padding: 12px 18px;
}
.sd-sheet-head h1 {
  margin: 0; font-size: 16px; font-weight: 800; color: #0f172a;
  display: flex; align-items: center; gap: 8px;
}
.sd-sheet-head p { margin: 3px 0 0; font-size: 11.5px; color: #94a3b8; }
.tone-blue { color: #2563eb; }
.tone-pink { color: #db2777; }
.tone-amber { color: #d97706; }

.sd-sheet-toolbar {
  background: #fff;
  border-bottom: 1px solid #e2e8f0;
  padding: 10px 16px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.sd-sheet-count .num {
  font-size: 24px; font-weight: 800; color: #0f172a; font-variant-numeric: tabular-nums;
}
.sd-sheet-count .unit { font-size: 13px; color: #94a3b8; margin-left: 2px; }
.sd-sort {
  display: inline-flex; border: 1px solid #e2e8f0; border-radius: 8px; overflow: hidden;
}
.sd-sort button {
  border: 0; background: #fff; color: #64748b; font-size: 12px; font-weight: 700;
  padding: 7px 12px; cursor: pointer;
}
.sd-sort button + button { border-left: 1px solid #e2e8f0; }
.sd-sort button.is-on { background: #4f46e5; color: #fff; }
.sd-inline-search { display: flex; gap: 6px; align-items: center; flex: 1; min-width: 200px; max-width: 360px; }
.sd-inline-search .sd-input { flex: 1; }
.sd-btn.dark { background: #334155; border-color: #334155; color: #fff; }
.sd-btn.danger { color: #b91c1c; border-color: #fecaca; }
.sd-btn.danger:hover { background: #fef2f2; }
.sd-sel-badge.pinkish { background: #fdf2f8; color: #db2777; }
.sd-sel-badge.blueish { background: #eff6ff; color: #2563eb; }
.sd-sel-badge.amberish { background: #fffbeb; color: #d97706; }

.sd-sheet-wrap {
  flex: 1; overflow: auto; padding: 0; background: #fff;
  max-height: 480px;
}
.sd-sheet {
  width: 100%; border-collapse: collapse; font-size: 12.5px; min-width: 920px;
}
.sd-sheet th {
  position: sticky; top: 0; z-index: 1;
  text-align: left; background: #f8fafc; padding: 10px 12px;
  color: #64748b; font-weight: 700; font-size: 11px;
  border-bottom: 1px solid #e2e8f0; white-space: nowrap;
}
.sd-sheet th.c, .sd-sheet td.c { width: 36px; text-align: center; }
.sd-sheet td {
  padding: 11px 12px; border-bottom: 1px solid #f1f5f9; vertical-align: top;
  color: #334155;
}
.sd-sheet tr:hover td { background: #f8fafc; }
.accent-blue .sd-sheet tr:hover td { background: #eff6ff; }
.accent-pink .sd-sheet tr:hover td { background: #fdf2f8; }
.accent-amber .sd-sheet tr:hover td { background: #fffbeb; }
.sd-sheet .co { font-weight: 700; color: #0f172a; white-space: nowrap; }
.sd-sheet .muted { color: #94a3b8; }
.sd-sheet .pay { color: #4f46e5; font-weight: 700; white-space: nowrap; }
.sd-sheet .handle { color: #db2777; font-weight: 700; }
.sd-badge-media {
  display: inline-block; font-size: 10.5px; font-weight: 700;
  padding: 2px 7px; border-radius: 999px; background: #eef2ff; color: #4338ca;
}
.sd-badge-sub {
  display: inline-block; font-size: 10px; font-weight: 700;
  padding: 2px 6px; border-radius: 4px; margin-right: 4px;
  background: #fffbeb; color: #b45309; border: 1px solid #fde68a;
}
.sd-sheet .clip {
  max-width: 220px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.sd-mylist-head { margin-bottom: 4px; }
.sd-mylist-head strong { display: block; font-size: 14px; color: #0f172a; }
.sd-mylist-head span { font-size: 11px; color: #94a3b8; }
.sd-mylist-item.is-on {
  background: #374151; border-color: #374151; color: #fff;
}
.sd-mylist-item.is-on span { color: rgba(255,255,255,0.7); }

@media (max-width: 900px) {
  .sd-sheet-view.is-show { flex-direction: column; }
  .sd-side-sm, .sd-side-md { width: 100%; max-height: 220px; border-right: 0; border-bottom: 1px solid #e2e8f0; }
}

/* ===== DEEPリサーチ（本番準拠） ===== */
.deep-page { display: flex; flex-direction: column; min-height: 100%; background: rgba(234,240,246,0.3); }
.deep-top {
  position: sticky; top: 0; z-index: 2;
  background: rgba(255,255,255,0.95); backdrop-filter: blur(8px);
  border-bottom: 1px solid #CBD6E2;
  padding: 12px 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.deep-top-l { display: flex; align-items: center; gap: 10px; min-width: 0; }
.deep-ico {
  width: 36px; height: 36px; border-radius: 10px; background: #FFEDE7;
  display: grid; place-items: center; font-size: 18px; flex-shrink: 0;
}
.deep-top h2 { margin: 0; font-size: 16px; font-weight: 800; color: #2D3E50; }
.deep-top p { margin: 2px 0 0; font-size: 11.5px; color: #7C98B6; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 280px; }
.deep-body { max-width: 720px; margin: 0 auto; padding: 16px; width: 100%; display: grid; gap: 16px; }
.deep-card {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 16px; padding: 16px 18px;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.deep-card h3 { margin: 0 0 12px; font-size: 13.5px; font-weight: 800; color: #2D3E50; }
.deep-selected {
  display: flex; align-items: center; gap: 10px;
  border: 1px solid rgba(0,189,165,0.3); background: rgba(0,189,165,0.08);
  border-radius: 8px; padding: 10px 12px;
}
.deep-selected strong { display: block; font-size: 13.5px; color: #2D3E50; }
.deep-selected span { font-size: 10.5px; color: #7C98B6; }
.deep-sel-ico { font-size: 16px; }
.deep-clear {
  margin-left: auto; border: 0; background: transparent; color: #7C98B6;
  width: 28px; height: 28px; border-radius: 999px; cursor: pointer; font-size: 16px;
}
.deep-clear:hover { background: #EAF0F6; color: #2D3E50; }
.deep-search { margin-top: 8px; position: relative; }
.deep-drop {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 3;
  background: #fff; border: 1px solid #CBD6E2; border-radius: 10px;
  box-shadow: 0 12px 28px rgba(45,62,80,0.12); max-height: 200px; overflow: auto;
}
.deep-drop button {
  width: 100%; text-align: left; border: 0; background: transparent;
  padding: 10px 12px; cursor: pointer; border-bottom: 1px solid #F5F8FA;
}
.deep-drop button:hover { background: #F5F8FA; }
.deep-drop strong { display: block; font-size: 13px; color: #2D3E50; }
.deep-drop span { font-size: 11px; color: #7C98B6; }

.deep-hero { text-align: center; padding: 8px 4px 0; }
.deep-badge {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255,237,231,0.7); color: #FF7A59;
  font-size: 11px; font-weight: 800; padding: 5px 12px; border-radius: 999px;
}
.deep-hero h3 { margin: 12px 0 6px; font-size: 18px; font-weight: 800; color: #2D3E50; line-height: 1.35; }
.deep-hero p { margin: 0; font-size: 12.5px; color: #7C98B6; line-height: 1.6; }

.deep-run {
  width: 100%; border: 0; border-radius: 16px; padding: 16px 20px;
  background: linear-gradient(90deg, #2D3E50, #33475B); color: #fff;
  font-size: 15px; font-weight: 800; cursor: pointer;
  box-shadow: 0 8px 20px rgba(45,62,80,0.2);
}
.deep-run:hover { opacity: 0.95; }
.deep-run.is-loading { opacity: 0.55; pointer-events: none; }

.deep-empty {
  border: 1px dashed #CBD6E2; background: #fff; border-radius: 16px;
  padding: 36px 20px; text-align: center;
}
.deep-empty-ico { font-size: 36px; opacity: 0.35; }
.deep-empty p { margin: 12px 0 0; font-size: 13px; color: #7C98B6; line-height: 1.65; }

.deep-result { display: grid; gap: 12px; }
.deep-sources { display: flex; flex-wrap: wrap; gap: 6px; }
.deep-sources span {
  font-size: 11px; font-weight: 700; color: #7C98B6;
  background: #EAF0F6; border-radius: 999px; padding: 4px 10px;
}
.deep-sources .ok { background: rgba(0,189,165,0.12); color: #008F7A; }
.deep-exec {
  border: 2px solid rgba(255,122,89,0.3); border-radius: 16px;
  background: linear-gradient(135deg, rgba(255,237,231,0.55), #fff);
  padding: 18px;
}
.deep-exec-k {
  font-size: 11px; font-weight: 800; letter-spacing: 0.06em;
  text-transform: uppercase; color: #FF7A59; margin-bottom: 8px;
}
.deep-exec p { margin: 0; font-size: 14.5px; font-weight: 700; color: #2D3E50; line-height: 1.6; }
.deep-approach { margin-top: 12px !important; font-size: 13px !important; font-weight: 500 !important; color: #33475B !important; }
.deep-sec {
  background: #fff; border: 1px solid #CBD6E2; border-radius: 16px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(45,62,80,0.04);
}
.deep-sec summary {
  list-style: none; cursor: pointer; padding: 14px 16px;
  font-size: 13.5px; font-weight: 800; color: #2D3E50;
  display: flex; align-items: center; gap: 8px;
}
.deep-sec summary::-webkit-details-marker { display: none; }
.deep-sec summary .accent { color: #FF7A59; }
.deep-sec-body { border-top: 1px solid #CBD6E2; padding: 12px 16px 16px; }
.deep-bullets { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.deep-bullets li {
  display: flex; gap: 8px; font-size: 13px; color: #2D3E50; line-height: 1.55;
}
.deep-bullets li::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%; background: #FF7A59;
  margin-top: 7px; flex-shrink: 0;
}
.deep-pain, .deep-q, .deep-obj {
  border: 1px solid #CBD6E2; border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; background: #F5F8FA;
}
.deep-pain strong, .deep-q strong { display: block; font-size: 13px; color: #2D3E50; }
.deep-pain span, .deep-q span { display: block; margin-top: 4px; font-size: 11.5px; color: #7C98B6; }
.deep-obj .obj { font-size: 11.5px; font-weight: 800; color: #FF7A59; }
.deep-obj .res { margin-top: 4px; font-size: 13px; color: #33475B; line-height: 1.5; }
.deep-to-prep { width: 100%; height: 48px; border-radius: 16px; font-size: 14px; justify-content: center; }
.deep-float {
  position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%);
  background: #2D3E50; color: #fff; font-size: 13px; font-weight: 800;
  padding: 12px 18px; border-radius: 999px; z-index: 6;
  box-shadow: 0 12px 28px rgba(45,62,80,0.25); white-space: nowrap;
}
.deep-float[hidden] { display: none !important; }
.crm-page[data-crm-view="deep"] { position: relative; padding: 0 !important; }
