/* Tuingigant WhatsApp-knop */
.tgwa{--tgwa-brand:#7bbb33;--tgwa-ink:#14200a;--tgwa-wa:#25d366;--tgwa-cta:#15803d;--tgwa-b:24px;--tgwa-bm:16px;
  position:fixed;right:24px;bottom:var(--tgwa-b);z-index:99990;font-family:inherit;line-height:1.4}
.tgwa *{box-sizing:border-box}

/* Knop */
.tgwa-fab{position:relative;width:64px;height:64px;border-radius:50%;border:0;padding:0;margin:0;
  background:var(--tgwa-wa);box-shadow:5px 7px 14px rgba(20,30,25,.28),2px 3px 5px rgba(20,30,25,.18);cursor:pointer;
  display:flex;align-items:center;justify-content:center;transition:transform .2s ease,box-shadow .2s ease,width .6s cubic-bezier(.3,1.3,.5,1),height .6s cubic-bezier(.3,1.3,.5,1);z-index:2}
/* Schaduw naar rechtsonder: de knop lijkt los boven de pagina te zweven */
.tgwa-fab:hover{transform:scale(1.06) translate(-1px,-1px);box-shadow:8px 11px 20px rgba(20,30,25,.30),3px 4px 7px rgba(20,30,25,.18)}
.tgwa-fab:focus-visible,.tgwa-close:focus-visible,.tgwa-cta:focus-visible{outline:3px solid #1c2421;outline-offset:3px}
.tgwa-fab>svg{width:34px;height:34px;transition:width .6s ease,height .6s ease}
/* Na 5x oplichten wordt de knop iets kleiner */
.tgwa.is-settled .tgwa-fab{width:54px;height:54px}
.tgwa.is-settled .tgwa-fab>svg{width:29px;height:29px}
.tgwa.is-settled .tgwa-label{right:66px}
.tgwa.is-settled .tgwa-genie{bottom:70px}
.tgwa.is-settled .tgwa-teaser{bottom:70px}
/* Rood stipje alleen onder werktijd */
.tgwa.is-offline .tgwa-badge{display:none}
.tgwa-label{position:absolute;right:76px;white-space:nowrap;background:#1c2421;color:#fff;font-size:14px;font-weight:600;
  padding:9px 14px;border-radius:999px;pointer-events:none;opacity:0;transform:translateX(8px);transition:opacity .15s,transform .15s}
.tgwa-fab:hover .tgwa-label{opacity:1;transform:none}
.tgwa-pulse::before{content:"";position:absolute;inset:0;border-radius:50%;background:var(--tgwa-wa);z-index:-1;animation:tgwaRing 2.4s ease-out 5;opacity:0}
.tgwa-badge{position:absolute;top:1px;right:1px;width:18px;height:18px}
.tgwa-badge>span,.tgwa-dot>span{position:absolute;inset:0;border-radius:50%;background:#ff3b30}
.tgwa-badge>span:last-child{border:3px solid #fff}
/* Alleen de groene knop licht op; het rode stipje en het statusstipje staan stil */
.tgwa-ping{display:none}
@keyframes tgwaRing{0%{transform:scale(1);opacity:.55}80%,100%{transform:scale(1.7);opacity:0}}
@keyframes tgwaPing{0%{transform:scale(1);opacity:.75}75%,100%{transform:scale(2.4);opacity:0}}

/* Kaartje + genie-effect: buitenste laag = hoogte, binnenste = breedte */
.tgwa-genie{position:absolute;right:0;bottom:80px;width:340px;
  transform-origin:calc(100% - 32px) calc(100% + 48px);
  transform:translateY(24px) scaleY(.04);pointer-events:none;visibility:hidden;
  transition:transform .4s cubic-bezier(.6,0,.7,.3) .1s,visibility 0s linear .5s}
.tgwa-card{background:#fff;color:#1c2421;border-radius:16px;overflow:hidden;
  box-shadow:0 12px 40px rgba(20,30,25,.18),0 2px 6px rgba(20,30,25,.08);
  transform-origin:calc(100% - 32px) 100%;transform:scaleX(.12);opacity:0;filter:blur(6px);
  transition:transform .3s cubic-bezier(.6,0,.8,.4),opacity .2s ease .28s,filter .3s ease .1s}
.tgwa[data-open="true"] .tgwa-genie{transform:none;pointer-events:auto;visibility:visible;transition:transform .45s cubic-bezier(.2,.9,.3,1.06),visibility 0s}
.tgwa[data-open="true"] .tgwa-card{transform:none;opacity:1;filter:none;
  transition:transform .42s cubic-bezier(.2,.9,.3,1.1) .08s,opacity .18s ease,filter .35s ease}
.tgwa[data-open="true"] .tgwa-fab{animation:none}
.tgwa[data-open="true"] .tgwa-pulse::before{display:none}

.tgwa-head{background:var(--tgwa-brand);color:var(--tgwa-ink);padding:16px 14px 16px 18px;display:flex;align-items:center;gap:12px}
.tgwa-avatar{width:56px;height:56px;border-radius:50%;flex:none;box-shadow:0 2px 8px rgba(20,32,10,.25)}
.tgwa-status{flex:1;min-width:0;display:flex;align-items:center;gap:8px;font-size:14px;font-weight:600}
.tgwa-dot{position:relative;width:10px;height:10px;flex:none}
.tgwa-dot>span{background:#fff}
.tgwa.is-offline .tgwa-dot{display:none}
.tgwa-close{width:44px;height:44px;border:0;background:transparent;color:var(--tgwa-ink);cursor:pointer;display:flex;align-items:center;justify-content:center;padding:0;border-radius:8px}
.tgwa-close svg{width:18px;height:18px}
.tgwa-body{padding:18px;display:flex;flex-direction:column;gap:14px}
/* Het bericht in het kaartje, als een binnenkomend WhatsApp-bericht */
.tgwa-chat{background:#efeae2;padding:16px 18px 18px;
  background-image:radial-gradient(rgba(20,32,10,.05) 1px,transparent 1.5px);background-size:14px 14px}
.tgwa-bubble{position:relative;display:inline-block;max-width:88%;background:#fff;color:#111b21;
  border-radius:0 10px 10px 10px;padding:6px 10px 8px;font-size:15px;line-height:1.4;
  box-shadow:0 1px .5px rgba(11,20,26,.13);transform-origin:top left}
.tgwa[data-open="true"] .tgwa-bubble{animation:tgwaMsgIn .4s cubic-bezier(.2,1.3,.4,1) .2s both}
.tgwa-bubble::before{content:"";position:absolute;top:0;left:-8px;width:8px;height:13px;background:#fff;
  clip-path:polygon(0 0,100% 0,100% 100%)}
.tgwa-msg-name{display:block;font-size:13px;font-weight:700;color:#4f8a1e;margin-bottom:2px}
.tgwa-bubble-text{display:inline}
.tgwa-msg-time{float:right;font-size:11px;color:#667781;margin:8px 0 -4px 12px;line-height:1}
.is-typing .tgwa-msg-time,.is-typing .tgwa-msg-name{display:none}
.tgwa-bubble.is-typing{padding:10px 14px}
@keyframes tgwaMsgIn{from{transform:scale(.7);opacity:0}to{transform:none;opacity:1}}
.tgwa-tips{font-size:14px;color:#3d4541}
.tgwa-tips ul{list-style:none;margin:8px 0 0;padding:0;display:flex;flex-direction:column;gap:8px}
.tgwa-tips li{display:flex;gap:10px;align-items:center;margin:0}
.tgwa-tips li svg{width:18px;height:18px;flex:none;fill:none;stroke:#4f8a1e;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.tgwa-cta{display:flex;align-items:center;justify-content:center;gap:10px;height:52px;border-radius:10px;
  background:var(--tgwa-cta);color:#fff!important;text-decoration:none!important;font-weight:600;font-size:16px}
.tgwa-cta:hover{background:#0f6b33}
.tgwa-cta svg{width:22px;height:22px}
.tgwa-dim{display:none}

/* Typ-puntjes, zoals in een echte chat */
.tgwa-typing{display:none;gap:4px;align-items:center;height:21px}
.tgwa-typing i{flex:none;width:7px;height:7px;border-radius:50%;background:#8a958f;display:block;animation:tgwaDot 1s ease-in-out infinite}
.tgwa-typing i:nth-child(2){animation-delay:.15s}
.tgwa-typing i:nth-child(3){animation-delay:.3s}
@keyframes tgwaDot{0%,60%,100%{transform:translateY(0);opacity:.5}30%{transform:translateY(-4px);opacity:1}}
.is-typing .tgwa-typing{display:flex}
.is-typing .tgwa-bubble-text,.is-typing .tgwa-teaser-text{display:none}

/* Ballonnetje dat uit de knop ploept */
.tgwa-teaser{position:absolute;right:2px;bottom:80px;width:max-content;display:flex;align-items:flex-end;gap:8px;
  transform-origin:calc(100% - 30px) calc(100% + 30px);transform:translateY(16px) scale(.2);opacity:0;pointer-events:none;visibility:hidden;
  transition:transform .5s cubic-bezier(.2,1.5,.4,1),opacity .18s ease,visibility 0s linear .5s}
.tgwa-teaser.is-on{transform:none;opacity:1;pointer-events:auto;visibility:visible;
  transition:transform .5s cubic-bezier(.2,1.5,.4,1),opacity .18s ease,visibility 0s}
.tgwa-teaser.is-off{transform:translateY(8px) scale(.6);opacity:0;pointer-events:none;visibility:hidden;
  transition:transform .25s ease-in,opacity .2s ease-in,visibility 0s linear .25s}
.tgwa[data-open="true"] .tgwa-teaser{display:none}
.tgwa-teaser-avatar{width:36px;height:36px;border-radius:50%;flex:none;box-shadow:0 2px 6px rgba(20,32,10,.25)}
.tgwa-teaser-bubble{display:block;max-width:250px;min-height:44px;text-align:left;background:#fff;color:#1c2421;border:0;
  border-radius:18px 18px 4px 18px;padding:11px 16px;font-family:inherit;font-weight:600;font-size:15px;line-height:1.35;
  box-shadow:0 10px 30px rgba(20,30,25,.18),0 2px 6px rgba(20,30,25,.08);transition:transform .15s ease}
.tgwa-teaser-text{display:block}
.tgwa-teaser-product{display:block;font-size:13px;font-weight:500;color:#5d625c;margin-top:2px}
.tgwa-teaser-actions{display:flex;flex-direction:column;gap:6px;margin-top:10px}
.tgwa-teaser-yes,.tgwa-teaser-no{display:flex;align-items:center;justify-content:center;gap:8px;min-height:40px;border-radius:999px;
  font-family:inherit;font-size:14px;font-weight:600;text-decoration:none!important;cursor:pointer;padding:0 14px}
.tgwa-teaser-yes{background:var(--tgwa-cta);color:#fff!important;border:0}
.tgwa-teaser-yes:hover{background:#0f6b33}
.tgwa-teaser-yes svg{width:18px;height:18px}
.tgwa-teaser-no{background:#fff;color:#1c2421;border:1px solid #c9c5ba}
.tgwa-teaser-no:hover{background:#f6f5f1}
.tgwa-teaser-yes:focus-visible,.tgwa-teaser-no:focus-visible,.tgwa-attach input:focus-visible{outline:3px solid #1c2421;outline-offset:2px}
.tgwa-q-label{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.tgwa-q{display:block;width:100%;min-height:48px;max-height:140px;resize:vertical;margin:0;padding:12px 14px;border:1px solid #c9c5ba;border-radius:10px;
  font-family:inherit;font-size:16px;line-height:1.4;color:#1c2421;background:#fff;box-shadow:none}
.tgwa-q::placeholder{color:#7a827d;opacity:1}
.tgwa-q:focus{outline:none;border-color:#15803d;box-shadow:0 0 0 3px rgba(21,128,61,.2)}
.tgwa-attach{display:flex;gap:10px;align-items:flex-start;font-size:14px;color:#3d4541;cursor:pointer;background:#f6f5f1;border-radius:10px;padding:10px 12px;margin:0}
.tgwa-attach input{width:18px;height:18px;margin:1px 0 0;accent-color:#15803d;flex:none}
.tgwa-attach strong{color:#1c2421}
.tgwa-teaser-bubble:focus-visible,.tgwa-teaser-close:focus-visible{outline:3px solid #1c2421;outline-offset:3px}
.tgwa-teaser-close{position:absolute;top:-14px;right:-6px;width:28px;height:28px;border-radius:50%;border:0;padding:0;cursor:pointer;
  background:#1c2421;color:#fff;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 6px rgba(0,0,0,.2)}
.tgwa-teaser-close::after{content:"";position:absolute;inset:-8px}
.tgwa-teaser-close svg{width:14px;height:14px}
.tgwa-teaser .tgwa-typing{height:22px}

/* Mobiel */
@media (max-width:480px){
  .tgwa{right:16px;bottom:var(--tgwa-bm)}
  .tgwa-fab{width:60px;height:60px}
  .tgwa-label{display:none}
  .tgwa-genie{position:fixed;left:12px;right:12px;bottom:calc(var(--tgwa-bm) + 76px);width:auto;transform-origin:calc(100% - 34px) calc(100% + 46px)}
  .tgwa-card{transform-origin:calc(100% - 34px) 100%}
  .tgwa-dim{display:block;position:fixed;inset:0;background:rgba(20,30,25,.35);opacity:0;pointer-events:none;transition:opacity .25s ease}
  .tgwa[data-open="true"] .tgwa-dim{opacity:1;pointer-events:auto}
  .tgwa-body{padding:16px;gap:12px}
  .tgwa-chat{padding:14px 16px 16px}
  .tgwa-teaser{bottom:74px}
  .tgwa-teaser-bubble{max-width:260px;font-size:14px}
  .tgwa-teaser-yes,.tgwa-teaser-no{font-size:13.5px;white-space:nowrap}
  .tgwa.is-settled .tgwa-fab{width:52px;height:52px}
  .tgwa.is-settled .tgwa-genie{bottom:calc(var(--tgwa-bm) + 68px)}
  .tgwa.is-settled .tgwa-teaser{bottom:66px}
}

@media (prefers-reduced-motion:reduce){
  .tgwa-genie,.tgwa-card,.tgwa-fab,.tgwa-fab>svg,.tgwa-dim,.tgwa-teaser,.tgwa-teaser-bubble{transition:none!important}
  .tgwa-ping,.tgwa-pulse::before,.tgwa-typing i,.tgwa-bubble{animation:none!important}
}

/* ------------------------------------------------------------------
   Bescherming tegen thema-stijlen: veel thema's geven alle <button>s
   een eigen vorm/kleur (bijv. border-radius:0). Met #tgwa en !important
   houden de knoppen altijd hun eigen uiterlijk.
   ------------------------------------------------------------------ */
#tgwa button,#tgwa a.tgwa-cta{-webkit-appearance:none!important;appearance:none!important;text-transform:none!important;
  letter-spacing:normal!important;text-shadow:none!important;min-width:0!important;min-height:0!important;
  font-family:inherit!important;background-image:none!important;outline-offset:3px}
#tgwa .tgwa-fab,#tgwa .tgwa-fab:hover,#tgwa .tgwa-fab:focus,#tgwa .tgwa-fab:active{
  border-radius:50%!important;background:var(--tgwa-wa)!important;border:0!important;padding:0!important;margin:0!important;
  line-height:1!important;color:#fff!important;display:flex!important;align-items:center!important;justify-content:center!important}
#tgwa .tgwa-fab{width:64px!important;height:64px!important;box-shadow:5px 7px 14px rgba(20,30,25,.28),2px 3px 5px rgba(20,30,25,.18)!important}
#tgwa .tgwa-fab:hover{box-shadow:8px 11px 20px rgba(20,30,25,.30),3px 4px 7px rgba(20,30,25,.18)!important}
#tgwa.is-settled .tgwa-fab{width:54px!important;height:54px!important}
#tgwa .tgwa-badge>span{border-radius:50%!important}
#tgwa .tgwa-close,#tgwa .tgwa-close:hover,#tgwa .tgwa-close:focus{border-radius:8px!important;background:transparent!important;border:0!important;
  padding:0!important;margin:0!important;width:44px!important;height:44px!important;color:var(--tgwa-ink)!important;box-shadow:none!important}
#tgwa .tgwa-teaser-close,#tgwa .tgwa-teaser-close:hover,#tgwa .tgwa-teaser-close:focus{border-radius:50%!important;background:#1c2421!important;
  border:0!important;padding:0!important;margin:0!important;width:28px!important;height:28px!important;color:#fff!important}
#tgwa .tgwa-teaser-yes,#tgwa .tgwa-teaser-no{border-radius:999px!important;margin:0!important;padding:0 14px!important;
  min-height:40px!important;height:auto!important;line-height:1.2!important;font-size:14px!important;font-weight:600!important;box-shadow:none!important}
#tgwa .tgwa-teaser-yes,#tgwa .tgwa-teaser-yes:focus{background:var(--tgwa-cta)!important;color:#fff!important;border:0!important}
#tgwa .tgwa-teaser-yes:hover{background:#0f6b33!important;color:#fff!important}
#tgwa .tgwa-teaser-no,#tgwa .tgwa-teaser-no:focus{background:#fff!important;color:#1c2421!important;border:1px solid #c9c5ba!important}
#tgwa .tgwa-teaser-no:hover{background:#f6f5f1!important;color:#1c2421!important}
#tgwa .tgwa-cta{border-radius:10px!important;background:var(--tgwa-cta)!important;color:#fff!important;border:0!important}
#tgwa .tgwa-cta:hover{background:#0f6b33!important}
#tgwa img.tgwa-avatar,#tgwa img.tgwa-teaser-avatar{border-radius:50%!important;max-width:none!important;padding:0!important;border:0!important}
@media (max-width:480px){
  #tgwa .tgwa-fab{width:60px!important;height:60px!important}
  #tgwa.is-settled .tgwa-fab{width:52px!important;height:52px!important}
  #tgwa .tgwa-teaser-yes,#tgwa .tgwa-teaser-no{font-size:13.5px!important}
}
