/* Crunch Chat widget — all selectors prefixed to avoid theme clashes */
#ccw-root{--ccw-c:#1f4ed8;position:fixed;bottom:20px;z-index:2147483000;font:15px/1.45 -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;color:#1d2433;-webkit-font-smoothing:antialiased}
#ccw-root.ccw-right{right:20px}
#ccw-root.ccw-left{left:20px}
#ccw-root *,#ccw-root *::before,#ccw-root *::after{box-sizing:border-box;font-family:inherit;letter-spacing:normal;text-transform:none}
#ccw-root button{cursor:pointer;font:inherit;margin:0;border:0;background:none;color:inherit;text-shadow:none;box-shadow:none;min-height:0;line-height:1.2}
#ccw-root svg{display:block}

.ccw-launcher{position:relative;width:60px;height:60px;border-radius:50% !important;background:var(--ccw-c) !important;color:#fff !important;display:flex !important;align-items:center;justify-content:center;padding:0 !important;box-shadow:0 8px 24px rgba(15,23,42,.28) !important;transition:transform .15s ease}
.ccw-launcher:hover{transform:scale(1.06)}
#ccw-root button:focus{outline:none !important}
#ccw-root button:focus-visible{outline:3px solid rgba(59,130,246,.55) !important;outline-offset:2px !important}
#ccw-root.ccw-left .ccw-launcher{margin-right:auto}
#ccw-root.ccw-right .ccw-launcher{margin-left:auto}
.ccw-badge{position:absolute;top:2px;right:2px;width:14px;height:14px;border-radius:50%;background:#ef4444;border:2px solid #fff}

.ccw-teaser{position:absolute;bottom:72px;max-width:260px;width:max-content;background:#fff;border-radius:14px;padding:10px 14px;box-shadow:0 8px 28px rgba(15,23,42,.18);font-size:14px;cursor:pointer;opacity:0;transform:translateY(8px);pointer-events:none;transition:all .25s ease}
.ccw-right .ccw-teaser{right:0}
.ccw-left .ccw-teaser{left:0}
.ccw-teaser.ccw-show{opacity:1;transform:none;pointer-events:auto}

.ccw-panel{position:absolute;bottom:76px;width:380px;height:min(620px,calc(100vh - 110px));background:#fff;border-radius:18px;box-shadow:0 18px 50px rgba(15,23,42,.28);display:flex;flex-direction:column;overflow:hidden;opacity:0;transform:translateY(12px) scale(.98);pointer-events:none;transition:opacity .2s ease,transform .2s ease}
.ccw-right .ccw-panel{right:0}
.ccw-left .ccw-panel{left:0}
.ccw-open .ccw-panel{opacity:1;transform:none;pointer-events:auto}

.ccw-head{display:flex;align-items:center;gap:10px;padding:14px 14px 12px 16px;background:var(--ccw-c);color:#fff}
.ccw-avatar{width:38px;height:38px;border-radius:50%;background:rgba(255,255,255,.2);display:flex;align-items:center;justify-content:center;font-weight:700;font-size:17px;flex:none}
.ccw-title{flex:1;min-width:0;display:flex;flex-direction:column}
.ccw-title strong{font-size:16px;color:#fff}
.ccw-sub{font-size:12.5px;opacity:.9}
.ccw-x{color:#fff !important;padding:6px !important;border-radius:8px !important;opacity:.9}
.ccw-x:hover{background:rgba(255,255,255,.15) !important}

.ccw-bar{padding:8px 12px;border-bottom:1px solid #eef0f4;background:#fafbfc}
.ccw-human{display:inline-flex !important;align-items:center;gap:6px;font-size:13.5px !important;font-weight:600 !important;color:var(--ccw-c) !important;padding:7px 12px !important;border:1.5px solid var(--ccw-c) !important;border-radius:999px !important;background:#fff !important}
.ccw-human:hover{background:var(--ccw-c) !important;color:#fff !important}
.ccw-human[hidden]{display:none !important}

.ccw-msgs{flex:1;overflow-y:auto;padding:14px 12px;background:#f5f7fb;display:flex;flex-direction:column;gap:8px;overscroll-behavior:contain}
.ccw-row{display:flex;flex-direction:column;max-width:86%}
.ccw-me{align-self:flex-end;align-items:flex-end}
.ccw-them{align-self:flex-start}
.ccw-who{font-size:11.5px;color:#64748b;margin:0 0 2px 4px;font-weight:600}
.ccw-bubble{padding:9px 13px;border-radius:16px;white-space:normal;word-wrap:break-word;overflow-wrap:anywhere;font-size:14.5px}
.ccw-them .ccw-bubble{background:#fff;border:1px solid #e6e9f0;border-bottom-left-radius:5px}
.ccw-me .ccw-bubble{background:var(--ccw-c);color:#fff;border-bottom-right-radius:5px}
.ccw-bubble a{color:inherit;text-decoration:underline;word-break:break-all}
.ccw-them .ccw-bubble a{color:var(--ccw-c)}
.ccw-sys{align-self:center;text-align:center;font-size:12.5px;color:#475569;background:#e9edf5;padding:6px 12px;border-radius:10px;max-width:92%}
.ccw-chips{display:flex;flex-wrap:wrap;gap:6px;margin-top:2px}
.ccw-chip{font-size:13px !important;padding:7px 11px !important;border-radius:999px !important;background:#fff !important;border:1px solid #d6dbe6 !important;color:#1d2433 !important;text-align:left}
.ccw-chip:hover{border-color:var(--ccw-c) !important;color:var(--ccw-c) !important}

.ccw-typing{display:flex;gap:4px;padding:12px 14px}
.ccw-typing i{width:7px;height:7px;border-radius:50%;background:#94a3b8;animation:ccw-b 1.2s infinite ease-in-out}
.ccw-typing i:nth-child(2){animation-delay:.15s}.ccw-typing i:nth-child(3){animation-delay:.3s}
@keyframes ccw-b{0%,80%,100%{transform:translateY(0);opacity:.5}40%{transform:translateY(-4px);opacity:1}}

.ccw-form{display:flex;align-items:flex-end;gap:8px;padding:10px 10px 8px;border-top:1px solid #eef0f4;background:#fff;margin:0}
.ccw-form textarea{flex:1;resize:none;border:1px solid #d6dbe6 !important;border-radius:12px !important;padding:10px 12px !important;font-size:15px !important;line-height:1.35 !important;max-height:110px;min-height:42px;outline:none;background:#fff !important;color:#1d2433 !important;margin:0 !important;box-shadow:none !important}
.ccw-form textarea:focus{border-color:var(--ccw-c) !important}
.ccw-send{width:42px;height:42px;border-radius:12px !important;background:var(--ccw-c) !important;color:#fff !important;display:flex !important;align-items:center;justify-content:center;flex:none;padding:0 !important}
.ccw-foot{font-size:11px;color:#94a3b8;text-align:center;padding:0 0 8px;background:#fff}

.ccw-hand{background:#fff;border:1px solid #e1e5ee;border-radius:14px;padding:14px;display:flex;flex-direction:column;gap:8px;margin:4px 0;box-shadow:0 4px 14px rgba(15,23,42,.06)}
.ccw-hand-t{font-weight:700;font-size:15px}
.ccw-hand p{margin:0;font-size:13px;color:#475569}
.ccw-hand input,.ccw-hand textarea{width:100%;border:1px solid #d6dbe6 !important;border-radius:10px !important;padding:9px 11px !important;font-size:14.5px !important;background:#fff !important;color:#1d2433 !important;margin:0 !important;outline:none;box-shadow:none !important;height:auto !important}
.ccw-hand input:focus,.ccw-hand textarea:focus{border-color:var(--ccw-c) !important}
.ccw-hand-err{color:#b91c1c;font-size:13px}
.ccw-hand-b{display:flex;gap:8px;justify-content:flex-end}
.ccw-cancel{padding:8px 12px !important;color:#475569 !important;border-radius:10px !important}
.ccw-go{padding:9px 14px !important;background:var(--ccw-c) !important;color:#fff !important;border-radius:10px !important;font-weight:600 !important}
.ccw-go[disabled]{opacity:.6}

@media (max-width:480px){
	#ccw-root{bottom:14px}
	#ccw-root.ccw-right{right:14px}#ccw-root.ccw-left{left:14px}
	.ccw-open .ccw-launcher{display:none !important}
	.ccw-panel{position:fixed;inset:0;width:100%;height:100%;border-radius:0;bottom:0}
	.ccw-teaser{max-width:220px}
}
