/* Floating chat widget (item 101) — uses design-tokens.css variables only,
   no hardcoded brand colors (MPE_BUILD_STANDARD white-label rule). */

.cw-root { position: fixed; right: 16px; bottom: 16px; z-index: 9999; font-family: var(--font); }

.cw-bubble {
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--orange); color: #fff; border: none;
  font-size: 24px; cursor: pointer; box-shadow: var(--shadow);
}
.cw-bubble:hover { filter: brightness(0.95); }

.cw-panel {
  position: fixed; right: 16px; bottom: 84px;
  width: min(340px, calc(100vw - 32px));
  max-height: min(480px, calc(100vh - 120px));
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card);
  box-shadow: var(--shadow); display: flex; flex-direction: column; overflow: hidden;
}

.cw-header {
  background: var(--navy); color: #fff; padding: 10px 14px;
  display: flex; align-items: center; justify-content: space-between; font-weight: 600;
}
.cw-close { background: none; border: none; color: #fff; font-size: 20px; cursor: pointer; line-height: 1; }

.cw-messages { flex: 1; overflow-y: auto; padding: 10px 12px; min-height: 160px; }
.cw-msg { max-width: 85%; margin: 6px 0; padding: 8px 10px; border-radius: var(--r-ctl); font-size: var(--fs-base); line-height: 1.35; }
.cw-msg-bot { background: var(--surface-2); color: var(--ink); }
.cw-msg-user { background: var(--blue-soft); color: var(--blue-ink); margin-left: auto; }

.cw-form, .cw-lead-form { display: flex; gap: 6px; padding: 10px 12px; border-top: 1px solid var(--line); flex-wrap: wrap; }
.cw-lead-form { flex-direction: column; }
.cw-lead-intro { margin: 0 0 4px; font-size: 13px; color: var(--ink2); }
.cw-lead-error { color: var(--bad); font-size: 13px; margin: 2px 0 0; }

.cw-input {
  flex: 1; min-width: 0; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--r-ctl);
  background: var(--surface); color: var(--ink); font-family: var(--font); font-size: var(--fs-base);
}
textarea.cw-input { width: 100%; resize: vertical; }

.cw-send {
  background: var(--orange); color: #fff; border: none; border-radius: var(--r-ctl);
  padding: 8px 14px; font-weight: 600; cursor: pointer;
}
.cw-send:disabled { opacity: 0.6; cursor: default; }

.cw-footer { margin: 0; padding: 6px 12px 10px; font-size: 12px; color: var(--ink3); }
.cw-footer a { color: var(--accent); }

.cw-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Spec #103 Ph2: push-to-talk mic. Rendered only when the browser has the Web Speech API. */
.cw-mic { background: var(--surface-2); color: var(--ink); border: 1px solid var(--line); border-radius: var(--r-ctl); padding: 0 10px; cursor: pointer; font-size: 16px; }
.cw-mic.cw-mic-on { background: var(--bad); color: #fff; border-color: var(--bad); }
.cw-mic-note { flex-basis: 100%; margin: 0; font-size: 11px; color: var(--ink3); }

/* Spec #103 Ph1 follow-up: "Never mind" on the verify form -- looks like a link, acts like a button. */
.cw-link { background: none; border: none; color: var(--accent); font-size: 13px; cursor: pointer; padding: 4px 0; text-decoration: underline; }
