/* frecH AI Assistant widget — hardened against theme CSS bleed */
#frech-ai-root{--fx-bg:#0e0e10;--fx-card:#17171b;--fx-line:#2a2a30;--fx-txt:#f4f1ea;--fx-muted:#9a968d;--fx-gold:#c8a86b;--fx-user:#2a2320;position:fixed;z-index:2147483000;bottom:22px;right:22px;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif;line-height:1.4}
#frech-ai-root,#frech-ai-root *{box-sizing:border-box!important}
/* neutralise theme form/element resets that leak in */
#frech-ai-root select,#frech-ai-root input,#frech-ai-root textarea,#frech-ai-root button{margin:0!important;max-width:none;min-height:0!important;line-height:normal;box-shadow:none!important;text-transform:none;letter-spacing:normal;float:none!important}

/* launcher bubble */
#frech-ai-root .fx-launch{width:60px;height:60px;border-radius:50%;background:linear-gradient(145deg,#1b1b1f,#000);color:var(--fx-gold);border:1px solid var(--fx-gold);cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 10px 30px rgba(0,0,0,.35);transition:transform .18s ease;padding:0}
#frech-ai-root .fx-launch:hover{transform:translateY(-2px) scale(1.04)}
#frech-ai-root .fx-launch svg{width:26px;height:26px}

/* panel */
#frech-ai-root .fx-panel{position:absolute;bottom:74px;right:0;width:370px;max-width:calc(100vw - 30px);height:520px;max-height:calc(100vh - 120px);background:var(--fx-bg);border:1px solid var(--fx-line);border-radius:18px;box-shadow:0 24px 60px rgba(0,0,0,.5);display:none;flex-direction:column;overflow:hidden;animation:fxIn .22s ease}
#frech-ai-root.fx-open .fx-panel{display:flex}
@keyframes fxIn{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:none}}

#frech-ai-root .fx-head{padding:14px 16px;background:linear-gradient(180deg,#151519,#0e0e10);border-bottom:1px solid var(--fx-line);display:flex;align-items:center;gap:10px}
#frech-ai-root .fx-badge{flex:0 0 auto;width:36px;height:36px;border-radius:50%;background:#000;border:1px solid var(--fx-gold);color:var(--fx-gold);display:flex;align-items:center;justify-content:center;font-weight:700;font-size:16px}
#frech-ai-root .fx-headtxt{flex:1 1 auto;min-width:0}
#frech-ai-root .fx-title{font-weight:600;color:var(--fx-txt);font-size:14.5px;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#frech-ai-root .fx-sub{color:var(--fx-muted);font-size:11.5px;margin-top:1px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#frech-ai-root .fx-lang{flex:0 0 auto;width:auto!important;background:#0e0e10;color:var(--fx-gold);border:1px solid var(--fx-line);border-radius:8px;font-size:12px;font-weight:600;padding:5px 8px;cursor:pointer;outline:none;appearance:none;-webkit-appearance:none;-moz-appearance:none;height:auto}
#frech-ai-root .fx-lang:hover{border-color:var(--fx-gold)}
#frech-ai-root .fx-lang option{background:#17171b;color:var(--fx-txt)}
#frech-ai-root .fx-close{flex:0 0 auto;background:none!important;border:none;color:var(--fx-muted);font-size:22px;cursor:pointer;line-height:1;padding:2px 4px;width:auto}
#frech-ai-root .fx-close:hover{color:var(--fx-txt)}

#frech-ai-root .fx-body{flex:1 1 auto;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:10px;background:radial-gradient(120% 60% at 50% 0%,#141419,#0e0e10)}
#frech-ai-root .fx-msg{max-width:82%;padding:10px 13px;border-radius:14px;font-size:14px;line-height:1.45;white-space:pre-wrap;word-wrap:break-word;color:var(--fx-txt)}
#frech-ai-root .fx-bot{align-self:flex-start;background:var(--fx-card);border:1px solid var(--fx-line);border-bottom-left-radius:5px}
#frech-ai-root .fx-you{align-self:flex-end;background:var(--fx-user);border:1px solid #3a2f27;border-bottom-right-radius:5px}
#frech-ai-root .fx-typing{align-self:flex-start;display:flex;gap:4px;padding:12px 14px}
#frech-ai-root .fx-typing span{width:7px;height:7px;border-radius:50%;background:var(--fx-gold);opacity:.5;animation:fxb 1s infinite}
#frech-ai-root .fx-typing span:nth-child(2){animation-delay:.2s}#frech-ai-root .fx-typing span:nth-child(3){animation-delay:.4s}
@keyframes fxb{0%,100%{opacity:.3;transform:translateY(0)}50%{opacity:1;transform:translateY(-3px)}}

#frech-ai-root .fx-foot{flex:0 0 auto;padding:12px;border-top:1px solid var(--fx-line);display:flex;gap:8px;align-items:flex-end;background:#0e0e10}
#frech-ai-root .fx-input{flex:1 1 auto;width:auto!important;resize:none;max-height:96px;background:var(--fx-card);border:1px solid var(--fx-line);border-radius:12px;color:var(--fx-txt);padding:10px 12px;font-size:14px;font-family:inherit;outline:none}
#frech-ai-root .fx-input:focus{border-color:var(--fx-gold)}
#frech-ai-root .fx-send{flex:0 0 auto;width:auto;background:var(--fx-gold);border:none;color:#111;border-radius:12px;padding:10px 16px;font-weight:600;cursor:pointer;font-size:14px;white-space:nowrap}
#frech-ai-root .fx-send:disabled{opacity:.4;cursor:default}
#frech-ai-root .fx-disc{flex:0 0 auto;font-size:10.5px;color:var(--fx-muted);text-align:center;padding:0 12px 10px}

@media (max-width:480px){#frech-ai-root .fx-panel{width:calc(100vw - 24px);height:calc(100vh - 100px)}#frech-ai-root{bottom:16px;right:12px}}
