/* All States Express AI chat widget. Accent #FFCA00, ink-on-accent #171717. */
#ccchat { position: fixed; right: 22px; bottom: 22px; z-index: 999999; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; }
#ccchat * { box-sizing: border-box; }

/* Hardening vs site-theme globals (e.g. `svg{width:100%;height:100%}`, button resets) */
#ccchat .ccc-fab svg { width: 26px; height: 26px; flex: 0 0 26px; }
#ccchat .ccc-send svg { width: 20px; height: 20px; flex: 0 0 20px; }
#ccchat button {
  margin: 0; padding: 0; border: 0; text-transform: none; letter-spacing: normal; text-decoration: none;
  font-family: inherit; line-height: 1.2; box-shadow: none; min-width: 0; min-height: 0; width: auto; height: auto;
}
#ccchat input {
  display: block; margin: 0; text-transform: none; letter-spacing: normal;
  font-family: inherit; line-height: 1.4; box-shadow: none; height: auto; border-radius: 12px;
}

/* FAB */
#ccchat .ccc-fab {
  display: flex; align-items: center; gap: 10px;
  background: #FFCA00; color: #171717; border: 0; cursor: pointer;
  padding: 14px 20px; border-radius: 32px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, .38);
  font-size: 15px; font-weight: 700; line-height: 1;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
#ccchat .ccc-fab:hover { transform: translateY(-2px); filter: brightness(1.06); box-shadow: 0 12px 32px rgba(0, 0, 0, .45); }
#ccchat .ccc-fab.hidden { display: none; }
#ccchat .ccc-fab svg { flex: 0 0 auto; }

/* Panel */
#ccchat .ccc-panel {
  display: none; flex-direction: column; overflow: hidden;
  position: absolute; right: 0; bottom: 0;
  width: 372px; max-width: calc(100vw - 30px); height: 540px; max-height: calc(100vh - 60px);
  background: #fff; border-radius: 18px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .4);
}
#ccchat .ccc-panel.open { display: flex; }

/* Head */
#ccchat .ccc-head {
  display: flex; align-items: center; gap: 10px;
  background: #171717; color: #fff; padding: 14px 16px;
}
#ccchat .ccc-head-txt { flex: 1 1 auto; min-width: 0; }
#ccchat .ccc-head-txt b { display: block; font-size: 16px; }
#ccchat .ccc-head-txt span { display: block; font-size: 12px; opacity: .75; margin-top: 2px; }
#ccchat .ccc-human-link {
  flex: 0 0 auto; background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.35);
  border-radius: 16px; padding: 6px 11px; font-size: 12px; cursor: pointer; white-space: nowrap;
}
#ccchat .ccc-human-link:hover { background: rgba(255,255,255,.22); }
#ccchat .ccc-close {
  flex: 0 0 auto; background: none; border: 0; color: #fff; opacity: .85;
  font-size: 24px; cursor: pointer; padding: 6px 10px; line-height: 1;
}
#ccchat .ccc-close:hover { opacity: 1; }

/* Body */
#ccchat .ccc-body { flex: 1 1 auto; overflow-y: auto; padding: 16px 14px; background: #f4f5f7; }
#ccchat .ccc-msg {
  max-width: 86%; padding: 10px 14px; margin: 0 0 10px;
  border-radius: 14px; font-size: 14px; line-height: 1.5; color: #23262e;
  background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .09);
  white-space: pre-wrap; word-wrap: break-word;
}
#ccchat .ccc-msg.me { margin-left: auto; background: #171717; color: #fff; border-bottom-right-radius: 4px; }
#ccchat .ccc-msg.bot { margin-right: auto; border-bottom-left-radius: 4px; }
#ccchat .ccc-typing { display: flex; gap: 5px; align-items: center; padding: 15px 16px; }
#ccchat .ccc-typing i {
  display: block; width: 7px; height: 7px; border-radius: 50%; background: #9aa0ab;
  animation: ccc-bounce 1.2s infinite ease-in-out;
}
#ccchat .ccc-typing i:nth-child(2) { animation-delay: .15s; }
#ccchat .ccc-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes ccc-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: .45; }
  30% { transform: translateY(-4px); opacity: 1; }
}

/* Contact card */
#ccchat .ccc-card { width: 100%; max-width: 100%; border: 1px solid transparent; }
#ccchat .ccc-card.pulse { animation: ccc-pulse 1.2s ease 1; }
@keyframes ccc-pulse {
  0%   { border-color: #FFCA00; box-shadow: 0 0 0 0 rgba(255,202,0,.5); }
  60%  { border-color: #FFCA00; box-shadow: 0 0 0 9px rgba(0, 0, 0, 0); }
  100% { border-color: transparent; box-shadow: 0 1px 3px rgba(0, 0, 0, .09); }
}
#ccchat .ccc-card-t { font-weight: 600; margin-bottom: 10px; }
#ccchat .ccc-card input {
  display: block; width: 100%; margin: 0 0 8px; padding: 10px 14px;
  border: 1px solid #d5d8de; border-radius: 12px; font-size: 14px; color: #23262e; background: #fff;
}
#ccchat .ccc-card input:focus { outline: none; border-color: #FFCA00; }
#ccchat .ccc-cbtn {
  width: 100%; border: 0; cursor: pointer; padding: 11px 14px;
  background: #FFCA00; color: #171717; border-radius: 12px; font-size: 14px; font-weight: 700;
}
#ccchat .ccc-cbtn:hover { filter: brightness(1.06); }
#ccchat .ccc-cbtn:disabled { opacity: .6; cursor: default; }
#ccchat .ccc-cerr { color: #c0392b; font-size: 12px; margin-top: 6px; min-height: 14px; }

/* Suggestions */
#ccchat .ccc-sugg { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 14px 10px; background: #f4f5f7; }
#ccchat .ccc-sugg button {
  border: 1px solid #c9cdd5; background: #fff; color: #3a3e48;
  border-radius: 16px; padding: 6px 12px; font-size: 12.5px; cursor: pointer;
}
#ccchat .ccc-sugg button:hover { border-color: #FFCA00; color: #23262e; }

/* Input */
#ccchat .ccc-input { display: flex; gap: 8px; padding: 12px 14px; background: #fff; border-top: 1px solid #e8eaee; }
#ccchat .ccc-input input {
  flex: 1 1 auto; padding: 11px 16px; border: 1px solid #d5d8de; border-radius: 12px;
  font-size: 14px; color: #23262e;
}
#ccchat .ccc-input input:focus { outline: none; border-color: #FFCA00; }
#ccchat .ccc-send {
  flex: 0 0 auto; width: 44px; height: 44px; display: grid; place-items: center;
  background: #171717; color: #fff; border: 0; border-radius: 50%; cursor: pointer;
}
#ccchat .ccc-send:hover { filter: brightness(1.25); }

/* Mobile */
@media (max-width: 480px) {
  #ccchat { right: 12px; bottom: 12px; }
  #ccchat .ccc-fab-label { display: none; }
  #ccchat .ccc-fab { padding: 15px; border-radius: 50%; }
  #ccchat .ccc-panel { width: calc(100vw - 24px); height: 76vh; }
}
