/* Scoped NexWave CRM lead-to-order demo */
.nw-mfg {
  --nw-mfg-bg: #edf2f4;
}

.dark .nw-mfg {
  --nw-mfg-bg: #edf2f4;
}

/* Mock app UI stays light when the marketing site uses dark mode (guide layer keeps its own palette) */
html.dark .nw-mfg #nw-mfg-shell.nw-mock-light,
html.dark .nw-mfg .nw-mock-light#nw-mfg-shell {
  color-scheme: light;
  background-color: #f4f6f8 !important;
}

html.dark .nw-mfg #nw-mfg-main,
html.dark .nw-mfg #nw-mfg-side,
html.dark .nw-mfg #nw-mfg-ttl,
html.dark .nw-mfg #nw-mfg-acts,
html.dark .nw-mfg #nw-mfg-md {
  color: #1a1a1a;
}

html.dark .nw-mfg #nw-mfg-main,
html.dark .nw-mfg #nw-mfg-side {
  background-color: #fff !important;
}

html.dark .nw-mfg #nw-mfg-shell [style*="background:#fff"],
html.dark .nw-mfg #nw-mfg-shell [style*="background: #fff"],
html.dark .nw-mfg #nw-mfg-shell [style*="background:#FFF"] {
  background-color: #fff !important;
}

html.dark .nw-mfg #nw-mfg-shell input:not([type="checkbox"]):not([type="radio"]),
html.dark .nw-mfg #nw-mfg-shell select,
html.dark .nw-mfg #nw-mfg-shell textarea,
html.dark .nw-mfg #nw-mfg-shell .nwi,
html.dark .nw-mfg #nw-mfg-shell .nws {
  background-color: #fff !important;
  color: #1a1a1a !important;
  border-color: #c5e5ec !important;
}

html.dark .nw-mfg #nw-mfg-shell .nwro {
  background-color: #f5f9fa !important;
  color: #555 !important;
  border-color: #e0edf0 !important;
}

html.dark .nw-mfg #nw-mfg-main,
html.dark .nw-mfg #nw-mfg-main * {
  transition-property: background-color, border-color, opacity, transform, box-shadow, filter !important;
}

.nw-mfg .nwi,
.nw-mfg .nws,
.nw-mfg .nwro {
  box-sizing: border-box;
}

.nw-mfg .nwi {
  width: 100%;
  border: 1px solid #c5e5ec;
  border-radius: 4px;
  padding: 5px 8px;
  font-size: 12px;
  background: #fff;
  color: #1a1a1a;
  outline: none;
  font-family: inherit;
}

.nw-mfg .nwi:focus {
  border-color: #1ab8c8;
}

.nw-mfg .nws {
  width: 100%;
  border: 1px solid #c5e5ec;
  border-radius: 4px;
  padding: 5px 8px;
  font-size: 12px;
  background: #fff;
  color: #1a1a1a;
  font-family: inherit;
}

.nw-mfg .nwro {
  background: #f5f9fa;
  border: 1px solid #e0edf0;
  border-radius: 4px;
  padding: 5px 8px;
  font-size: 12px;
  color: #555;
  display: block;
}

@media (max-width: 640px) {
  #nw-mfg-shell [style*="min-height:500px"] {
    flex-direction: column !important;
  }

  #nw-mfg-side[style*="display: none"] {
    display: none !important;
  }

  #nw-mfg-side:not([style*="display: none"]) {
    width: 100% !important;
    min-width: 0 !important;
    border-right: none !important;
    border-bottom: 1px solid #eef3f5;
  }
}
/* Scoped NexWave sales-order → delivery demo (matches saved HTML mockup) */
body.nw-mfg-modal-open {
  overflow: hidden;
}

/* Coach: step track with arrows */
.nw-mfg-coach-track {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 0.25rem 0.35rem;
  row-gap: 0.5rem;
}

.nw-mfg-coach-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  border-radius: 9999px;
  padding: 0.35rem 0.65rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  border: 1px solid rgba(6, 182, 212, 0.35);
  background: rgba(255, 255, 255, 0.75);
  color: #64748b;
  white-space: nowrap;
}

.dark .nw-mfg-coach-pill {
  background: rgba(15, 23, 42, 0.85);
  color: #94a3b8;
  border-color: rgba(34, 211, 238, 0.25);
}

.nw-mfg-coach-pill.is-upcoming {
  opacity: 0.55;
  border-style: dashed;
}

.nw-mfg-coach-pill.is-active {
  border-color: #0891b2;
  background: linear-gradient(135deg, #ecfeff 0%, #cffafe 100%);
  color: #0e7490;
  box-shadow: 0 0 0 2px rgba(6, 182, 212, 0.25);
}

.dark .nw-mfg-coach-pill.is-active {
  background: rgba(8, 145, 178, 0.25);
  color: #67e8f9;
  border-color: #22d3ee;
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.15);
}

.nw-mfg-coach-pill.is-done {
  border-color: rgba(34, 197, 94, 0.45);
  background: rgba(240, 253, 244, 0.95);
  color: #166534;
}

.dark .nw-mfg-coach-pill.is-done {
  background: rgba(20, 83, 45, 0.35);
  color: #86efac;
  border-color: rgba(74, 222, 128, 0.4);
}

.nw-mfg-coach-arrow {
  display: inline-flex;
  align-items: center;
  color: #0891b2;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0 0.1rem;
  user-select: none;
}

.dark .nw-mfg-coach-arrow {
  color: #22d3ee;
}

/* In-mock guide overlay (dims only #nw-mfg-shell; hole passes clicks through) */
.nw-mfg-guide-layer {
  position: absolute;
  inset: 0;
  z-index: 85;
  pointer-events: none;
}

.nw-mfg-dim {
  position: absolute;
  display: none;
  background: rgba(15, 23, 42, 0.34);
  z-index: 1;
  pointer-events: none;
}

.dark .nw-mfg-dim {
  background: rgba(0, 0, 0, 0.42);
}

.nw-mfg-guide-rim {
  position: absolute;
  display: none;
  border: 3px solid #22d3ee;
  border-radius: 10px;
  box-shadow:
    0 0 0 2px rgba(34, 211, 238, 0.45),
    0 0 24px rgba(34, 211, 238, 0.35);
  z-index: 2;
  pointer-events: none;
}

.nw-mfg-guide-pointer {
  position: absolute;
  display: none;
  font-size: 2.25rem;
  line-height: 1;
  color: #67e8f9;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
  z-index: 3;
  pointer-events: none;
  transform: translateX(-50%);
}

.nw-mfg-guide-card {
  position: absolute;
  max-width: 22rem;
  width: min(22rem, calc(100% - 1rem));
  padding: 1.1rem 1.25rem 1rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid rgba(6, 182, 212, 0.35);
  box-shadow:
    0 12px 40px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(255, 255, 255, 0.08) inset;
  z-index: 4;
  pointer-events: auto;
  text-align: left;
}

.dark .nw-mfg-guide-card {
  background: rgba(15, 23, 42, 0.97);
  border-color: rgba(34, 211, 238, 0.35);
}

.nw-mfg-guide-dismiss {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 2rem;
  height: 2rem;
  border: none;
  border-radius: 0.5rem;
  background: transparent;
  color: #64748b;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

.nw-mfg-guide-dismiss:hover {
  background: rgba(6, 182, 212, 0.12);
  color: #0e7490;
}

.nw-mfg-guide-kicker {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0891b2;
  margin: 0 0 0.75rem;
  padding-right: 2rem;
}

.dark .nw-mfg-guide-kicker {
  color: #67e8f9;
}

.nw-mfg-guide-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 0.5rem;
  line-height: 1.3;
}

.dark .nw-mfg-guide-title {
  color: #f8fafc;
}

.nw-mfg-guide-body {
  font-size: 0.8125rem;
  color: #475569;
  line-height: 1.55;
  margin: 0 0 0.75rem;
}

.dark .nw-mfg-guide-body {
  color: #cbd5e1;
}

.nw-mfg-guide-next {
  font-size: 0.8125rem;
  line-height: 1.55;
  color: #0f172a;
  background: rgba(207, 250, 254, 0.65);
  border: 1px solid rgba(6, 182, 212, 0.4);
  border-radius: 0.65rem;
  padding: 0.65rem 0.75rem;
  margin: 0 0 0.5rem;
}

.dark .nw-mfg-guide-next {
  color: #e2e8f0;
  background: rgba(8, 145, 178, 0.2);
  border-color: rgba(34, 211, 238, 0.35);
}

.nw-mfg-guide-after {
  font-size: 0.75rem;
  color: #64748b;
  line-height: 1.5;
  margin: 0 0 0.5rem;
}

.dark .nw-mfg-guide-after {
  color: #94a3b8;
}

.nw-mfg-guide-foot {
  font-size: 0.7rem;
  font-weight: 600;
  color: #64748b;
  margin: 0;
}

.dark .nw-mfg-guide-foot {
  color: #94a3b8;
}

.nw-mfg-guide-next .nw-mfg-next-label {
  display: block;
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #0e7490;
  margin-bottom: 0.35rem;
}

.dark .nw-mfg-guide-next .nw-mfg-next-label {
  color: #67e8f9;
}

/* Minimal guided overlay — lighter dim, numeric step arrows */
.nw-mfg-guide-kicker,
.nw-mfg-guide-title,
.nw-mfg-guide-body,
.nw-mfg-guide-next,
.nw-mfg-guide-after,
.nw-mfg-guide-foot {
  display: none !important;
}

.nw-mfg-guide-card {
  max-width: none;
  width: auto;
  min-width: 0;
  padding: 0.35rem 0.55rem 0.35rem 0.45rem;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
}

.dark .nw-mfg-guide-card {
  background: rgba(15, 23, 42, 0.92);
}

.nw-mfg-guide-dismiss {
  position: static;
  width: 1.65rem;
  height: 1.65rem;
  margin-right: 0.15rem;
  flex-shrink: 0;
}

.nw-mfg-guide-card {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
}

.nw-mfg-coach-track {
  justify-content: center;
  flex-wrap: nowrap;
  margin: 0 !important;
}

.nw-mfg-coach-pill {
  min-width: 1.65rem;
  justify-content: center;
  padding: 0.3rem 0.45rem;
  font-size: 0.75rem;
}

.nw-mfg-coach-arrow {
  font-size: 1rem;
  padding: 0 0.05rem;
}

.nw-mfg-guide-pointer {
  font-size: 2.75rem;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.35));
}

.nw-mfg-guide-rim {
  border-width: 2px;
  box-shadow:
    0 0 0 2px rgba(34, 211, 238, 0.35),
    0 0 14px rgba(34, 211, 238, 0.22);
}


/* Manufacturing mock components */
.nw-mfg #nw-mfg-shell,
.nw-mfg #nw-mfg-shell *,
.nw-mfg #nw-mfg-shell *::before,
.nw-mfg #nw-mfg-shell *::after {
  box-sizing: border-box;
}
.nw-mfg #nw-mfg-shell select.nwi {
  cursor: pointer;
}
.nw-mfg #nw-mfg-shell table.data-tbl {
  width: 100%;
  border-collapse: collapse;
}
.nw-mfg #nw-mfg-shell input[type="checkbox"] {
  accent-color: #1ab8c8;
}
.nw-mfg #nw-mfg-shell .nwi{width:100%;border:1px solid #C5E5EC;border-radius:4px;padding:5px 9px;font-size:12px;background:#fff;color:#1a1a1a;box-sizing:border-box;outline:none;font-family:inherit;}
.nw-mfg #nw-mfg-shell .nwi:focus{border-color:#1AB8C8;}
.nw-mfg #nw-mfg-shell .nwro{background:#F5F9FA;border:1px solid #E0EDF0;border-radius:4px;padding:5px 9px;font-size:12px;color:#555;display:block;}
.nw-mfg #nw-mfg-shell .nwro.blue-border{border-color:#1AB8C8;background:#fff;}
.nw-mfg #nw-mfg-shell .act-btn{background:#fff;border:1px solid #C8D4D8;padding:5px 10px;border-radius:4px;font-size:12px;cursor:pointer;color:#2d3748;font-family:inherit;display:inline-flex;align-items:center;gap:4px;}
.nw-mfg #nw-mfg-shell .act-btn:hover{background:#F4F6F8;}
.nw-mfg #nw-mfg-shell .prim-btn{background:#1AB8C8;color:#fff;border:none;padding:5px 12px;border-radius:4px;font-size:12px;cursor:pointer;font-family:inherit;font-weight:500;display:inline-flex;align-items:center;gap:4px;}
.nw-mfg #nw-mfg-shell .prim-btn:hover{background:#17a3b2;}
.nw-mfg #nw-mfg-shell .cancel-btn{background:#fff;border:1px solid #C8D4D8;padding:5px 10px;border-radius:4px;font-size:12px;cursor:pointer;color:#E53E3E;font-family:inherit;}
.nw-mfg #nw-mfg-shell .dd-menu{position:absolute;background:#fff;border:1px solid #E0EAED;border-radius:6px;box-shadow:0 4px 20px rgba(0,0,0,.14);z-index:200;min-width:215px;}
.nw-mfg #nw-mfg-shell .dd-item{padding:9px 15px;font-size:12px;color:#1a1a1a;cursor:pointer;}
.nw-mfg #nw-mfg-shell .dd-item:hover{background:#F4F8FA;}
.nw-mfg #nw-mfg-shell .dd-item.active{font-weight:600;color:#1AB8C8;}
.nw-mfg #nw-mfg-shell .tab{padding:9px 14px;font-size:12px;color:#6B7280;cursor:pointer;border-bottom:2px solid transparent;display:inline-block;}
.nw-mfg #nw-mfg-shell .tab.active{color:#1AB8C8;border-bottom-color:#1AB8C8;font-weight:500;}
.nw-mfg #nw-mfg-shell .tab-bar{display:flex;border-bottom:1px solid #E0EAED;background:#fff;}
.nw-mfg #nw-mfg-shell .banner{background:#EBF9FB;border-bottom:1px solid #B8E2EC;padding:9px 16px 9px 16px;font-size:12px;color:#1A7D8D;display:flex;align-items:center;justify-content:space-between;}
.nw-mfg #nw-mfg-shell .chip{display:inline-flex;align-items:center;background:#EBF9FB;color:#1AB8C8;border-radius:3px;padding:0 5px;font-size:10px;font-weight:600;min-width:18px;justify-content:center;}
.nw-mfg #nw-mfg-shell .status-badge{border-radius:12px;padding:2px 10px;font-size:11px;font-weight:500;display:inline-block;}
.nw-mfg #nw-mfg-shell .tbl-wrap{overflow-x:auto;}
.nw-mfg #nw-mfg-shell .data-tbl th{font-size:10px;color:#6B7280;padding:7px 10px;background:#F8FBFC;border-bottom:1px solid #DDE9EE;font-weight:600;text-align:left;white-space:nowrap;}
.nw-mfg #nw-mfg-shell .data-tbl th.r{text-align:right;}
.nw-mfg #nw-mfg-shell .data-tbl td{font-size:11px;padding:7px 10px;border-bottom:1px solid #EEF3F5;color:#2d3748;white-space:nowrap;}
.nw-mfg #nw-mfg-shell .data-tbl td.r{text-align:right;}
.nw-mfg #nw-mfg-shell .data-tbl tr:hover td{background:#FAFCFD;}
.nw-mfg #nw-mfg-shell .sb-link{display:flex;align-items:center;justify-content:space-between;padding:7px 14px;font-size:12px;color:#4B5563;cursor:pointer;border-bottom:1px solid #F5F6F8;}
.nw-mfg #nw-mfg-shell .sb-link:hover{background:#F9FAFB;}
.nw-mfg #nw-mfg-shell .sb-link .plus{color:#9CA3AF;font-size:14px;}
.nw-mfg #nw-mfg-shell .field-lbl{font-size:11px;color:#888;margin-bottom:4px;}
.nw-mfg #nw-mfg-shell .field-req{color:#E53E3E;font-size:10px;}
.nw-mfg #nw-mfg-shell .sec-hdr{font-size:13px;font-weight:700;color:#1a1a1a;padding:12px 0 8px;border-bottom:1px solid #EEF3F5;margin-bottom:12px;}
.nw-mfg #nw-mfg-shell .lnav-item{display:flex;align-items:center;gap:8px;padding:5px 12px;cursor:default;transition:background .12s;}
.nw-mfg #nw-mfg-shell .lnav-item.cl{cursor:pointer;}
.nw-mfg #nw-mfg-shell .lnav-item.cl:hover{background:#F0F9FA;}
.nw-mfg #nw-mfg-shell .lnav-item.ac{background:#EBF9FB;}
.nw-mfg #nw-mfg-shell .lnav-icon{font-size:14px;width:16px;text-align:center;color:#9CA3AF;}
.nw-mfg #nw-mfg-shell .lnav-item.ac .lnav-icon{color:#1AB8C8;}
.nw-mfg #nw-mfg-shell .lnav-txt{font-size:12px;color:#4B5563;flex:1;}
.nw-mfg #nw-mfg-shell .lnav-item.ac .lnav-txt{font-weight:600;color:#1AB8C8;}
.nw-mfg #nw-mfg-shell .lnav-sub{display:flex;align-items:center;gap:6px;padding:4px 12px 4px 36px;}
.nw-mfg #nw-mfg-shell .ws-link{font-size:11px;color:#1AB8C8;padding:3px 0;cursor:pointer;display:flex;align-items:center;gap:4px;}
.nw-mfg #nw-mfg-shell .kpi-card{background:#fff;border-radius:6px;border:1px solid #E0EAED;padding:14px 16px;}
.nw-mfg #nw-mfg-shell .progress-bar{display:flex;justify-content:center;gap:6px;padding:8px 0 5px;}
.nw-mfg #nw-mfg-shell .pb-dot{width:8px;height:8px;border-radius:50%;background:#D0D8DC;transition:background .2s;}
.nw-mfg #nw-mfg-shell .pb-dot.active{background:#1AB8C8;}
.nw-mfg #nw-mfg-shell .pill{display:inline-block;padding:2px 8px;border-radius:10px;font-size:10px;font-weight:500;}
.nw-mfg #nw-mfg-shell .pill-open{background:#EBF9FB;color:#1AB8C8;}
.nw-mfg #nw-mfg-shell .pill-assigned{background:#D5F5E3;color:#1E8449;}
.nw-mfg #nw-mfg-shell .pill-draft{background:#FDEBD0;color:#CA6F1E;}
.nw-mfg #nw-mfg-shell .conn-row{display:flex;align-items:center;gap:8px;padding:4px 0;font-size:12px;color:#4B5563;}
.nw-mfg #nw-mfg-shell .conn-chip{background:#EEF3F5;border:1px solid #D0D8DC;border-radius:4px;padding:3px 10px;font-size:11px;color:#2d3748;display:inline-flex;align-items:center;gap:4px;}
.nw-mfg #nw-mfg-shell .quick-add{width:22px;height:22px;border-radius:4px;border:1px solid #C5E5EC;background:#EBF9FB;color:#1AB8C8;font-size:14px;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;font-weight:300;}

#nw-mfg-pdots { display: none !important; }
.nw-mfg #nw-mfg-shell .nw-guide-target-active { position: relative; z-index: 90; }
