/* Textos — Nancy, FAQ chat widget (client-side, rule-based, no backend) */
/* Colours are fixed on purpose, not pulled from the site's CSS variables —
   this page redefines those variables for a dark theme further down, which
   was making the widget (and typed text) unreadable. Keeping this widget's
   palette self-contained means it can't be broken by that again. */
:root{
  --tx-navy:#071d2b;
  --tx-gold:#c4a66a;
  --tx-cream:#f4f1e9;
  --tx-paper:#fbfaf6;
  --tx-ink:#12202a;
  --tx-line:rgba(16,38,48,.16);
  --tx-radius:18px;
}

.tx-chat-launcher{position:fixed;z-index:18;right:22px;bottom:96px;width:58px;height:58px;border:0;border-radius:50%;background:var(--tx-navy);color:#fff;box-shadow:0 16px 40px rgba(7,17,42,.32);display:flex;align-items:center;justify-content:center;cursor:pointer;transition:transform .2s ease,opacity .2s ease}
.tx-chat-launcher:hover{transform:translateY(-2px)}
.tx-chat-launcher svg{width:26px;height:26px}
.tx-chat-launcher .tx-chat-close-icon{display:none}
.tx-chat-launcher.is-open .tx-chat-open-icon{display:none}
.tx-chat-launcher.is-open .tx-chat-close-icon{display:block}
.tx-chat-dot{position:absolute;top:6px;right:6px;width:10px;height:10px;border-radius:50%;background:var(--tx-gold);border:2px solid var(--tx-navy)}

.tx-chat-panel{position:fixed;z-index:18;right:22px;bottom:164px;width:360px;max-width:calc(100vw - 32px);max-height:min(560px,calc(100vh - 264px));max-height:min(560px,calc(100dvh - 264px));background:var(--tx-paper);border-radius:var(--tx-radius);box-shadow:0 30px 80px rgba(7,17,42,.28);border:1px solid var(--tx-line);display:flex;flex-direction:column;overflow:hidden;opacity:0;transform:translateY(16px) scale(.98);pointer-events:none;transition:opacity .22s ease,transform .22s ease}
.tx-chat-panel.is-open{opacity:1;transform:none;pointer-events:auto}

.tx-chat-head{background:var(--tx-navy);color:#fff;padding:16px 20px;flex:0 0 auto;display:flex;align-items:center;gap:12px}
.tx-chat-avatar{flex:0 0 auto;width:38px;height:38px;border-radius:50%;background:var(--tx-gold);color:var(--tx-navy);display:flex;align-items:center;justify-content:center;font:600 15px/1 "Georgia",serif}
.tx-chat-head-copy strong{font:400 17px/1.2 "Georgia",serif;display:block}
.tx-chat-head-copy span{font-size:12px;color:rgba(255,255,255,.62);display:flex;align-items:center;gap:6px;margin-top:4px}
.tx-chat-head-copy span i{width:7px;height:7px;border-radius:50%;background:#77c6a7;display:inline-block}

.tx-chat-body{flex:1 1 auto;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:10px;background:var(--tx-cream)}
.tx-chat-row{display:flex}
.tx-chat-row.tx-bot{justify-content:flex-start}
.tx-chat-row.tx-user{justify-content:flex-end}
.tx-bubble{max-width:82%;padding:10px 13px;font-size:13.5px;line-height:1.5;border-radius:12px;white-space:pre-line}
.tx-bot .tx-bubble{background:#ffffff;color:var(--tx-ink);border:1px solid var(--tx-line);border-top-left-radius:3px}
.tx-user .tx-bubble{background:var(--tx-gold);color:var(--tx-ink);border-top-right-radius:3px}

.tx-chat-quick{display:flex;flex-wrap:wrap;gap:8px;margin-top:2px}
.tx-chip{border:1px solid var(--tx-line);background:#ffffff;color:var(--tx-ink);font-size:12px;padding:7px 12px;border-radius:999px;cursor:pointer;transition:.15s}
.tx-chip:hover{border-color:var(--tx-gold);color:var(--tx-navy)}

.tx-chat-foot{flex:0 0 auto;border-top:1px solid var(--tx-line);background:#ffffff;display:flex;align-items:center;gap:8px;padding:10px}
.tx-chat-input{flex:1;min-width:0;border:1px solid var(--tx-line);border-radius:10px;padding:10px 12px;font-size:13.5px;background:#ffffff;color:#000000;caret-color:#000000}
.tx-chat-input::placeholder{color:#6b7680;opacity:1}
.tx-chat-input:focus{outline:2px solid var(--tx-gold);outline-offset:1px}
.tx-chat-send{flex:0 0 auto;width:38px;height:38px;border:0;border-radius:10px;background:var(--tx-gold);color:var(--tx-navy);display:flex;align-items:center;justify-content:center;cursor:pointer}
.tx-chat-send svg{width:16px;height:16px}

@media (max-width:520px){
  .tx-chat-launcher{bottom:112px;right:16px}
  .tx-chat-panel{right:16px;left:16px;width:auto;bottom:180px;max-height:min(560px,calc(100vh - 280px));max-height:min(560px,calc(100dvh - 280px))}
}
